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

Commit fd893875 authored by Jakob Schneider's avatar Jakob Schneider Committed by Android (Google) Code Review
Browse files

Merge "Only check for archived activities if the application info cannot be found." into main

parents 660c3c94 60e9a234
Loading
Loading
Loading
Loading
+11 −11
Original line number Diff line number Diff line
@@ -993,17 +993,6 @@ class ActivityStarter {
            }
        }

        if (Flags.archiving()) {
            PackageArchiver packageArchiver = mService
                    .getPackageManagerInternalLocked()
                    .getPackageArchiver();
            if (packageArchiver.isIntentResolvedToArchivedApp(intent, mRequest.userId)) {
                return packageArchiver
                        .requestUnarchiveOnActivityStart(
                                intent, callingPackage, mRequest.userId, realCallingUid);
            }
        }

        final int launchFlags = intent.getFlags();
        if ((launchFlags & Intent.FLAG_ACTIVITY_FORWARD_RESULT) != 0 && sourceRecord != null) {
            // Transfer the result target from the source activity to the new one being started,
@@ -1045,6 +1034,17 @@ class ActivityStarter {
        }

        if (err == ActivityManager.START_SUCCESS && aInfo == null) {
            if (Flags.archiving()) {
                PackageArchiver packageArchiver = mService
                        .getPackageManagerInternalLocked()
                        .getPackageArchiver();
                if (packageArchiver.isIntentResolvedToArchivedApp(intent, mRequest.userId)) {
                    return packageArchiver
                            .requestUnarchiveOnActivityStart(
                                    intent, callingPackage, mRequest.userId, realCallingUid);
                }
            }

            // We couldn't find the specific class specified in the Intent.
            // Also the end of the line.
            err = ActivityManager.START_CLASS_NOT_FOUND;