Loading services/core/java/com/android/server/am/ActiveServices.java +3 −3 Original line number Diff line number Diff line Loading @@ -1628,7 +1628,7 @@ public final class ActiveServices { // Once the apps have become associated, if one of them is caller is ephemeral // the target app should now be able to see the calling app mAm.grantEphemeralAccessLocked(callerApp.userId, service, s.appInfo.uid, UserHandle.getAppId(callerApp.uid)); UserHandle.getAppId(s.appInfo.uid), UserHandle.getAppId(callerApp.uid)); AppBindRecord b = s.retrieveAppBindingLocked(service, callerApp); ConnectionRecord c = new ConnectionRecord(b, activity, Loading Loading @@ -2581,8 +2581,8 @@ public final class ActiveServices { mAm.mUgmInternal.grantUriPermissionUncheckedFromIntent(si.neededGrants, si.getUriPermissionsLocked()); } mAm.grantEphemeralAccessLocked(r.userId, si.intent, r.appInfo.uid, UserHandle.getAppId(si.callingId)); mAm.grantEphemeralAccessLocked(r.userId, si.intent, UserHandle.getAppId(r.appInfo.uid), UserHandle.getAppId(si.callingId)); bumpServiceExecutingLocked(r, execInFg, "start"); if (!oomAdjusted) { oomAdjusted = true; Loading services/core/java/com/android/server/am/ActivityManagerService.java +2 −1 Original line number Diff line number Diff line Loading @@ -8239,7 +8239,8 @@ public class ActivityManagerService extends IActivityManager.Stub checkTime(startTime, "getContentProviderImpl: done!"); grantEphemeralAccessLocked(userId, null /*intent*/, cpi.applicationInfo.uid, UserHandle.getAppId(Binder.getCallingUid())); UserHandle.getAppId(cpi.applicationInfo.uid), UserHandle.getAppId(Binder.getCallingUid())); } // Wait for the provider to be published... Loading services/core/java/com/android/server/am/ActivityStarter.java +1 −1 Original line number Diff line number Diff line Loading @@ -1469,7 +1469,7 @@ class ActivityStarter { mService.mUgmInternal.grantUriPermissionFromIntent(mCallingUid, mStartActivity.packageName, mIntent, mStartActivity.getUriPermissionsLocked(), mStartActivity.userId); mService.mAm.grantEphemeralAccessLocked(mStartActivity.userId, mIntent, mStartActivity.appInfo.uid, UserHandle.getAppId(mCallingUid)); UserHandle.getAppId(mStartActivity.appInfo.uid), UserHandle.getAppId(mCallingUid)); if (newTask) { EventLog.writeEvent(EventLogTags.AM_CREATE_TASK, mStartActivity.userId, mStartActivity.getTask().taskId); Loading services/core/java/com/android/server/pm/PackageManagerService.java +16 −2 Original line number Diff line number Diff line Loading @@ -3214,6 +3214,21 @@ public class PackageManagerService extends IPackageManager.Stub mRequiredPermissionControllerPackage = null; } // Initialize InstantAppRegistry's Instant App list for all users. final int[] userIds = UserManagerService.getInstance().getUserIds(); for (PackageParser.Package pkg : mPackages.values()) { if (pkg.isSystem()) { continue; } for (int userId : userIds) { final PackageSetting ps = (PackageSetting) pkg.mExtras; if (ps == null || !ps.getInstantApp(userId) || !ps.getInstalled(userId)) { continue; } mInstantAppRegistry.addInstantAppLPw(userId, ps.appId); } } mInstallerService = new PackageInstallerService(context, this); final Pair<ComponentName, String> instantAppResolverComponent = getInstantAppResolverLPr(); Loading Loading @@ -3241,8 +3256,7 @@ public class PackageManagerService extends IPackageManager.Stub // should take a fairly small time compare to the other activities (e.g. package // scanning). final Map<Integer, List<PackageInfo>> userPackages = new HashMap<>(); final int[] currentUserIds = UserManagerService.getInstance().getUserIds(); for (int userId : currentUserIds) { for (int userId : userIds) { userPackages.put(userId, getInstalledPackages(/*flags*/ 0, userId).getList()); } mDexManager.load(userPackages); Loading
services/core/java/com/android/server/am/ActiveServices.java +3 −3 Original line number Diff line number Diff line Loading @@ -1628,7 +1628,7 @@ public final class ActiveServices { // Once the apps have become associated, if one of them is caller is ephemeral // the target app should now be able to see the calling app mAm.grantEphemeralAccessLocked(callerApp.userId, service, s.appInfo.uid, UserHandle.getAppId(callerApp.uid)); UserHandle.getAppId(s.appInfo.uid), UserHandle.getAppId(callerApp.uid)); AppBindRecord b = s.retrieveAppBindingLocked(service, callerApp); ConnectionRecord c = new ConnectionRecord(b, activity, Loading Loading @@ -2581,8 +2581,8 @@ public final class ActiveServices { mAm.mUgmInternal.grantUriPermissionUncheckedFromIntent(si.neededGrants, si.getUriPermissionsLocked()); } mAm.grantEphemeralAccessLocked(r.userId, si.intent, r.appInfo.uid, UserHandle.getAppId(si.callingId)); mAm.grantEphemeralAccessLocked(r.userId, si.intent, UserHandle.getAppId(r.appInfo.uid), UserHandle.getAppId(si.callingId)); bumpServiceExecutingLocked(r, execInFg, "start"); if (!oomAdjusted) { oomAdjusted = true; Loading
services/core/java/com/android/server/am/ActivityManagerService.java +2 −1 Original line number Diff line number Diff line Loading @@ -8239,7 +8239,8 @@ public class ActivityManagerService extends IActivityManager.Stub checkTime(startTime, "getContentProviderImpl: done!"); grantEphemeralAccessLocked(userId, null /*intent*/, cpi.applicationInfo.uid, UserHandle.getAppId(Binder.getCallingUid())); UserHandle.getAppId(cpi.applicationInfo.uid), UserHandle.getAppId(Binder.getCallingUid())); } // Wait for the provider to be published... Loading
services/core/java/com/android/server/am/ActivityStarter.java +1 −1 Original line number Diff line number Diff line Loading @@ -1469,7 +1469,7 @@ class ActivityStarter { mService.mUgmInternal.grantUriPermissionFromIntent(mCallingUid, mStartActivity.packageName, mIntent, mStartActivity.getUriPermissionsLocked(), mStartActivity.userId); mService.mAm.grantEphemeralAccessLocked(mStartActivity.userId, mIntent, mStartActivity.appInfo.uid, UserHandle.getAppId(mCallingUid)); UserHandle.getAppId(mStartActivity.appInfo.uid), UserHandle.getAppId(mCallingUid)); if (newTask) { EventLog.writeEvent(EventLogTags.AM_CREATE_TASK, mStartActivity.userId, mStartActivity.getTask().taskId); Loading
services/core/java/com/android/server/pm/PackageManagerService.java +16 −2 Original line number Diff line number Diff line Loading @@ -3214,6 +3214,21 @@ public class PackageManagerService extends IPackageManager.Stub mRequiredPermissionControllerPackage = null; } // Initialize InstantAppRegistry's Instant App list for all users. final int[] userIds = UserManagerService.getInstance().getUserIds(); for (PackageParser.Package pkg : mPackages.values()) { if (pkg.isSystem()) { continue; } for (int userId : userIds) { final PackageSetting ps = (PackageSetting) pkg.mExtras; if (ps == null || !ps.getInstantApp(userId) || !ps.getInstalled(userId)) { continue; } mInstantAppRegistry.addInstantAppLPw(userId, ps.appId); } } mInstallerService = new PackageInstallerService(context, this); final Pair<ComponentName, String> instantAppResolverComponent = getInstantAppResolverLPr(); Loading Loading @@ -3241,8 +3256,7 @@ public class PackageManagerService extends IPackageManager.Stub // should take a fairly small time compare to the other activities (e.g. package // scanning). final Map<Integer, List<PackageInfo>> userPackages = new HashMap<>(); final int[] currentUserIds = UserManagerService.getInstance().getUserIds(); for (int userId : currentUserIds) { for (int userId : userIds) { userPackages.put(userId, getInstalledPackages(/*flags*/ 0, userId).getList()); } mDexManager.load(userPackages);