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

Commit cedb99de authored by Riddle Hsu's avatar Riddle Hsu
Browse files

Do not restart process of a finishing activity

The destruction operation should have higher priority.
That also avoids disturbing DESTROYING state when the
client reports destroyed.

Currently some callers of restartProcessIfVisible such as
ActivityTaskManagerInternal and TaskOrganizerController
also ignore finishing activity. So this just adds a double
check for the path from config change.

Bug: 276467485
Test: CompatChangeTests
Change-Id: Icd24147abb1d4e5859c44862ed42f4557ecb2387
parent ebba1751
Loading
Loading
Loading
Loading
+1 −0
Original line number Original line Diff line number Diff line
@@ -9760,6 +9760,7 @@ final class ActivityRecord extends WindowToken implements WindowManagerService.A
     * directly with keeping its record.
     * directly with keeping its record.
     */
     */
    void restartProcessIfVisible() {
    void restartProcessIfVisible() {
        if (finishing) return;
        Slog.i(TAG, "Request to restart process of " + this);
        Slog.i(TAG, "Request to restart process of " + this);


        // Reset the existing override configuration so it can be updated according to the latest
        // Reset the existing override configuration so it can be updated according to the latest