summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
author Wale Ogunwale <ogunwale@google.com> 2015-07-07 17:13:13 -0700
committer Wale Ogunwale <ogunwale@google.com> 2015-07-07 17:24:54 -0700
commit31dd3a74c1d5a6746eec6b7f1260fae11f488af0 (patch)
tree8bb9651b5701050e008cce78298a6fbe93676780
parentf2474d336a7df696f3897e2cd255d138eb3fac02 (diff)
Set AppErrorDialog result during dismissal if it isn't already set
The system watch dog was triggering because all binder threads were waiting for AppErrorResult#set() to be called which never happened. One situation where this can occur is if a process continues to crash and the activity manager marks the process as bad there by causing it to kill the process immediately which causes a binder death notification that automatically dismisses the app error dialog before the user ACKs it. We now set the result during dialog dismissal if it isn't already set. Bug: 22141958 Change-Id: If3ac116df5e29c6fba43ee556a859ad3c84c66f3
-rw-r--r--services/core/java/com/android/server/am/AppErrorDialog.java9
1 files changed, 9 insertions, 0 deletions
diff --git a/services/core/java/com/android/server/am/AppErrorDialog.java b/services/core/java/com/android/server/am/AppErrorDialog.java
index 098b0b65210f..c8fb351bc416 100644
--- a/services/core/java/com/android/server/am/AppErrorDialog.java
+++ b/services/core/java/com/android/server/am/AppErrorDialog.java
@@ -102,4 +102,13 @@ final class AppErrorDialog extends BaseErrorDialog {
dismiss();
}
};
+
+ @Override
+ public void dismiss() {
+ if (!mResult.mHasResult) {
+ // We are dismissing and the result has not been set...go ahead and set.
+ mResult.set(FORCE_QUIT);
+ }
+ super.dismiss();
+ }
}