Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 525f760c authored by riddle_hsu's avatar riddle_hsu Committed by Joey Rizzoli
Browse files

Restart persistent process if start timeout.

Sometimes bad applications may occupied all binder threads
of system server awhile, then persistent process may be
killed due to background ANR, and meet process start timeout
because no avaiable binder thread to attach.

After binder threads are free, system becomes normal but
the persistent process does not restart, and even it started
by someone use its component, it will have no persistent flag.

Change-Id: Ic72acf7b77e2f67cee1e8187e8308b1c69b83683
parent 105067d0
Loading
Loading
Loading
Loading
+3 −0
Original line number Diff line number Diff line
@@ -6629,6 +6629,9 @@ public final class ActivityManagerService extends ActivityManagerNative
                Slog.w(TAG, "Unattached app died before broadcast acknowledged, skipping");
                skipPendingBroadcastLocked(pid);
            }
            if (app.persistent && !app.isolated) {
                addAppLocked(app.info, false, null /* ABI override */);
            }
        } else {
            Slog.w(TAG, "Spurious process start timeout - pid not known for " + app);
        }