Merge "Enhance media temp-allowlist logging" into tm-dev am: e8f7dc02c6
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/18820312 Change-Id: Ia87542eb69d2169eb89319f6a6e74e01eb5f35d2 Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
This commit is contained in:
@@ -563,14 +563,16 @@ public class MediaSessionService extends SystemService implements Monitor {
|
||||
try {
|
||||
enforcePackageName(callingPackage, callingUid);
|
||||
if (targetUid != callingUid) {
|
||||
Log.d(TAG, "tempAllowlistTargetPkgIfPossible callingPackage:"
|
||||
+ callingPackage + " targetPackage:" + targetPackage
|
||||
+ " reason:" + reason);
|
||||
boolean canAllowWhileInUse = mActivityManagerLocal
|
||||
.canAllowWhileInUsePermissionInFgs(callingPid, callingUid, callingPackage);
|
||||
boolean canStartFgs = canAllowWhileInUse
|
||||
|| mActivityManagerLocal.canStartForegroundService(callingPid, callingUid,
|
||||
callingPackage);
|
||||
Log.i(TAG, "tempAllowlistTargetPkgIfPossible callingPackage:"
|
||||
+ callingPackage + " targetPackage:" + targetPackage
|
||||
+ " reason:" + reason
|
||||
+ (canAllowWhileInUse ? " [WIU]" : "")
|
||||
+ (canStartFgs ? " [FGS]" : ""));
|
||||
if (canAllowWhileInUse) {
|
||||
mActivityManagerLocal.tempAllowWhileInUsePermissionInFgs(targetUid,
|
||||
MediaSessionDeviceConfig
|
||||
|
||||
Reference in New Issue
Block a user