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

Commit b0c34b33 authored by Mohammad Samiul Islam's avatar Mohammad Samiul Islam Committed by Automerger Merge Worker
Browse files

Merge "Prevent sessions from resuming once boot is completed" into rvc-dev am: 4c11355e

Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/11837601

Change-Id: I5c04041cb9698ab890fa28e402283d58fb993524
parents 2c141935 4c11355e
Loading
Loading
Loading
Loading
+6 −0
Original line number Diff line number Diff line
@@ -53,6 +53,7 @@ import android.os.ParcelableException;
import android.os.PowerManager;
import android.os.RemoteException;
import android.os.ServiceManager;
import android.os.SystemProperties;
import android.os.UserHandle;
import android.os.UserManagerInternal;
import android.os.storage.IStorageManager;
@@ -1155,6 +1156,11 @@ public class StagingManager {
    }

    private void checkStateAndResume(@NonNull PackageInstallerSession session) {
        // Do not resume session if boot completed already
        if (SystemProperties.getBoolean("sys.boot_completed", false)) {
            return;
        }

        if (!session.isCommitted()) {
            // Session hasn't been committed yet, ignore.
            return;