Merge "Do not send new Intent to non-exported activity when navigateUpTo" into tm-qpr-dev am: df4e467f94 am: aea53a16bc
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/19492656 Change-Id: I21a8d3c1a7233a5dc9a48add4cb976f7a78f32bd Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
This commit is contained in:
@@ -5319,7 +5319,23 @@ class Task extends TaskFragment {
|
||||
parentLaunchMode == ActivityInfo.LAUNCH_SINGLE_TASK ||
|
||||
parentLaunchMode == ActivityInfo.LAUNCH_SINGLE_TOP ||
|
||||
(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 {
|
||||
try {
|
||||
ActivityInfo aInfo = AppGlobals.getPackageManager().getActivityInfo(
|
||||
|
||||
Reference in New Issue
Block a user