diff options
author | Dianne Hackborn <hackbod@google.com> | 2015-08-14 13:29:47 -0700 |
---|---|---|
committer | Dianne Hackborn <hackbod@google.com> | 2015-08-14 14:08:43 -0700 |
commit | ae498721001c6cdcdb6cce1b2f3ba5abbce36f8a (patch) | |
tree | 0931a63ac9b37b7fbb5d44cdf271779549fea5b2 /services | |
parent | 0cd143adae642465a26a7eaac96030bb18826e94 (diff) | |
download | frameworks_base-ae498721001c6cdcdb6cce1b2f3ba5abbce36f8a.zip frameworks_base-ae498721001c6cdcdb6cce1b2f3ba5abbce36f8a.tar.gz frameworks_base-ae498721001c6cdcdb6cce1b2f3ba5abbce36f8a.tar.bz2 |
Add debugging for issue #23190084: [APPComm][Dev Test] {Unable to share photo...
...from Camera360 to Hangouts }
In the short URI toString, include a small summary of the ClipData (instead
of just saying it has a clip data). This makes it a lot easier to understand
what is happening when you look at the log of activity starts.
Also separate out the activity manager dump of URI permission grants from
its dump of providers, so it is easy to just look at that state.
Change-Id: I68093d9f279944e1aa9a29347075f237f4f55ed3
Diffstat (limited to 'services')
-rw-r--r-- | services/core/java/com/android/server/am/ActivityManagerService.java | 22 |
1 files changed, 22 insertions, 0 deletions
diff --git a/services/core/java/com/android/server/am/ActivityManagerService.java b/services/core/java/com/android/server/am/ActivityManagerService.java index 3d523d9..113c9b6 100644 --- a/services/core/java/com/android/server/am/ActivityManagerService.java +++ b/services/core/java/com/android/server/am/ActivityManagerService.java @@ -12850,6 +12850,7 @@ public final class ActivityManagerService extends ActivityManagerNative pw.println(" i[ntents] [PACKAGE_NAME]: pending intent state"); pw.println(" p[rocesses] [PACKAGE_NAME]: process state"); pw.println(" o[om]: out of memory management"); + pw.println(" perm[issions]: URI permission grant state"); pw.println(" prov[iders] [COMP_SPEC ...]: content provider state"); pw.println(" provider [COMP_SPEC]: provider client-side state"); pw.println(" s[ervices] [COMP_SPEC ...]: service state"); @@ -12940,6 +12941,10 @@ public final class ActivityManagerService extends ActivityManagerNative synchronized (this) { dumpOomLocked(fd, pw, args, opti, true); } + } else if ("permissions".equals(cmd) || "perm".equals(cmd)) { + synchronized (this) { + dumpPermissionsLocked(fd, pw, args, opti, true, null); + } } else if ("provider".equals(cmd)) { String[] newArgs; String name; @@ -13055,6 +13060,11 @@ public final class ActivityManagerService extends ActivityManagerNative if (dumpAll) { pw.println("-------------------------------------------------------------------------------"); } + dumpPermissionsLocked(fd, pw, args, opti, dumpAll, dumpPackage); + pw.println(); + if (dumpAll) { + pw.println("-------------------------------------------------------------------------------"); + } mServices.dumpServicesLocked(fd, pw, args, opti, dumpAll, dumpClient, dumpPackage); pw.println(); if (dumpAll) { @@ -14075,6 +14085,18 @@ public final class ActivityManagerService extends ActivityManagerNative } } + if (!printedAnything) { + pw.println(" (nothing)"); + } + } + + void dumpPermissionsLocked(FileDescriptor fd, PrintWriter pw, String[] args, + int opti, boolean dumpAll, String dumpPackage) { + boolean needSep = false; + boolean printedAnything = false; + + pw.println("ACTIVITY MANAGER URI PERMISSIONS (dumpsys activity permissions)"); + if (mGrantedUriPermissions.size() > 0) { boolean printed = false; int dumpUid = -2; |