Fix failures for Webview tests in sandbox

Bug: b/261764855
Test: atest WebViewSandboxTest
Change-Id: I561f14badc23ee44c757250becc11f6dfb609fb8
This commit is contained in:
Shiwangi Shah
2022-12-15 12:11:47 +00:00
parent bbc4a2643e
commit abe0059229

View File

@@ -3869,8 +3869,8 @@ public final class ActiveServices {
throw new SecurityException("BIND_EXTERNAL_SERVICE failed, "
+ className + " is not an isolatedProcess");
}
if (AppGlobals.getPackageManager().getPackageUid(callingPackage,
0, userId) != callingUid) {
if (!mAm.getPackageManagerInternal().isSameApp(callingPackage, callingUid,
userId)) {
throw new SecurityException("BIND_EXTERNAL_SERVICE failed, "
+ "calling package not owned by calling UID ");
}