Add test for attribute android:allowEmbedded
Throw a SecurityException if it is not true for an activity launched using ActivityContainer.startActivity(). Change-Id: Id1d70e630195a49a3eccdc64a0beccc420400332
This commit is contained in:
@@ -705,6 +705,10 @@ public final class ActivityStackSupervisor implements DisplayListener {
|
||||
profileFile, profileFd, userId);
|
||||
|
||||
ActivityContainer container = (ActivityContainer)iContainer;
|
||||
if (container != null && (aInfo.flags & ActivityInfo.FLAG_ALLOW_EMBEDDED) == 0) {
|
||||
throw new SecurityException(
|
||||
"Activities launched in ActivityContainers must set allowEmbedded=\"true\"");
|
||||
}
|
||||
synchronized (mService) {
|
||||
int callingPid;
|
||||
if (callingUid >= 0) {
|
||||
|
||||
Reference in New Issue
Block a user