summaryrefslogtreecommitdiffstats
path: root/core/java/com
diff options
context:
space:
mode:
authorDianne Hackborn <hackbod@google.com>2013-10-14 16:55:09 -0700
committerDianne Hackborn <hackbod@google.com>2013-10-14 17:15:40 -0700
commit878deb3c7b33a0c508137143c776e07bab0296cf (patch)
tree22f09fb67d0450d2e3b2dec204f0dedccc9ef2db /core/java/com
parentb5da7b23df5278a5e722b601eb8ef7e98537a51e (diff)
downloadframeworks_base-878deb3c7b33a0c508137143c776e07bab0296cf.zip
frameworks_base-878deb3c7b33a0c508137143c776e07bab0296cf.tar.gz
frameworks_base-878deb3c7b33a0c508137143c776e07bab0296cf.tar.bz2
Fix issue #11223335: APR: Lots of failures in procstats due to...
...bad cleanup of crashing processes We now have a special path for crashing processes, to silently clean up their state. Also some tweaks to Log/Slog.wtf to get better stack crawl summaries in APR. Change-Id: Ieced26989907a6e7615b6fa033813fced78d7474
Diffstat (limited to 'core/java/com')
-rw-r--r--core/java/com/android/internal/app/ProcessStats.java25
1 files changed, 17 insertions, 8 deletions
diff --git a/core/java/com/android/internal/app/ProcessStats.java b/core/java/com/android/internal/app/ProcessStats.java
index 430e43a..222e446 100644
--- a/core/java/com/android/internal/app/ProcessStats.java
+++ b/core/java/com/android/internal/app/ProcessStats.java
@@ -2918,29 +2918,38 @@ public final class ProcessStats implements Parcelable {
}
}
- public void clearCurrentOwner(Object owner) {
+ public void clearCurrentOwner(Object owner, boolean silently) {
if (mOwner == owner) {
- mOwner = null;
mProc.decActiveServices(mName);
if (mStartedState != STATE_NOTHING || mBoundState != STATE_NOTHING
|| mExecState != STATE_NOTHING) {
long now = SystemClock.uptimeMillis();
if (mStartedState != STATE_NOTHING) {
- Slog.wtfStack(TAG, "Service owner " + owner + " cleared while started: pkg="
- + mPackage + " service=" + mName + " proc=" + mProc);
+ if (!silently) {
+ Slog.wtfStack(TAG, "Service owner " + owner
+ + " cleared while started: pkg=" + mPackage + " service="
+ + mName + " proc=" + mProc);
+ }
setStarted(false, 0, now);
}
if (mBoundState != STATE_NOTHING) {
- Slog.wtfStack(TAG, "Service owner " + owner + " cleared while bound: pkg="
- + mPackage + " service=" + mName + " proc=" + mProc);
+ if (!silently) {
+ Slog.wtfStack(TAG, "Service owner " + owner
+ + " cleared while bound: pkg=" + mPackage + " service="
+ + mName + " proc=" + mProc);
+ }
setBound(false, 0, now);
}
if (mExecState != STATE_NOTHING) {
- Slog.wtfStack(TAG, "Service owner " + owner + " cleared while exec: pkg="
- + mPackage + " service=" + mName + " proc=" + mProc);
+ if (!silently) {
+ Slog.wtfStack(TAG, "Service owner " + owner
+ + " cleared while exec: pkg=" + mPackage + " service="
+ + mName + " proc=" + mProc);
+ }
setExecuting(false, 0, now);
}
}
+ mOwner = null;
}
}