Merge "Do not send new Intent to non-exported activity when navigateUpTo" into tm-qpr-dev am: df4e467f94
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/19492656 Change-Id: If11551913e055f49eda9283a55cae89faa596a7f Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
This commit is contained in:
@@ -5328,7 +5328,23 @@ class Task extends TaskFragment {
|
|||||||
parentLaunchMode == ActivityInfo.LAUNCH_SINGLE_TASK ||
|
parentLaunchMode == ActivityInfo.LAUNCH_SINGLE_TASK ||
|
||||||
parentLaunchMode == ActivityInfo.LAUNCH_SINGLE_TOP ||
|
parentLaunchMode == ActivityInfo.LAUNCH_SINGLE_TOP ||
|
||||||
(destIntentFlags & Intent.FLAG_ACTIVITY_CLEAR_TOP) != 0) {
|
(destIntentFlags & Intent.FLAG_ACTIVITY_CLEAR_TOP) != 0) {
|
||||||
parent.deliverNewIntentLocked(callingUid, destIntent, destGrants, srec.packageName);
|
boolean abort;
|
||||||
|
try {
|
||||||
|
abort = !mTaskSupervisor.checkStartAnyActivityPermission(destIntent,
|
||||||
|
parent.info, null /* resultWho */, -1 /* requestCode */, srec.getPid(),
|
||||||
|
callingUid, srec.info.packageName, null /* callingFeatureId */,
|
||||||
|
false /* ignoreTargetSecurity */, false /* launchingInTask */, srec.app,
|
||||||
|
null /* resultRecord */, null /* resultRootTask */);
|
||||||
|
} catch (SecurityException e) {
|
||||||
|
abort = true;
|
||||||
|
}
|
||||||
|
if (abort) {
|
||||||
|
Slog.e(TAG, "Cannot navigateUpTo, intent =" + destIntent);
|
||||||
|
foundParentInTask = false;
|
||||||
|
} else {
|
||||||
|
parent.deliverNewIntentLocked(callingUid, destIntent, destGrants,
|
||||||
|
srec.packageName);
|
||||||
|
}
|
||||||
} else {
|
} else {
|
||||||
try {
|
try {
|
||||||
ActivityInfo aInfo = AppGlobals.getPackageManager().getActivityInfo(
|
ActivityInfo aInfo = AppGlobals.getPackageManager().getActivityInfo(
|
||||||
|
|||||||
Reference in New Issue
Block a user