Throw caught DeadObjectException when trying to create a service.
We don't want to continue trying to start the service if the service appliction is dead. This will lead to an NPE later on since we have set ServiceRecord.app to null in the finally block. Bug: 5227987 Change-Id: I3ee5111f4a20d9455fedbf41ac54d41c43aa8d76
This commit is contained in:
@@ -1519,6 +1519,7 @@ public final class ActiveServices {
|
||||
} catch (DeadObjectException e) {
|
||||
Slog.w(TAG, "Application dead when creating service " + r);
|
||||
mAm.appDiedLocked(app);
|
||||
throw e;
|
||||
} finally {
|
||||
if (!created) {
|
||||
// Keep the executeNesting count accurate.
|
||||
|
||||
@@ -50,7 +50,7 @@ import static com.android.server.am.ActivityManagerDebugConfig.*;
|
||||
* foreground priority, and one for normal (background-priority) broadcasts.
|
||||
*/
|
||||
public final class BroadcastQueue {
|
||||
private static final String TAG = TAG_WITH_CLASS_NAME ? "BroadcastQueue" : TAG_AM;
|
||||
private static final String TAG = "BroadcastQueue";
|
||||
private static final String TAG_MU = TAG + POSTFIX_MU;
|
||||
private static final String TAG_BROADCAST = TAG + POSTFIX_BROADCAST;
|
||||
|
||||
|
||||
Reference in New Issue
Block a user