Merge "Address crash if no tokens which allow BAL present" into udc-dev

This commit is contained in:
Hani Kazmi
2023-05-24 11:33:47 +00:00
committed by Android (Google) Code Review

View File

@@ -190,6 +190,11 @@ class BackgroundLaunchProcessController {
return false;
}
List<IBinder> binderTokens = getOriginatingTokensThatAllowBal();
if (binderTokens.isEmpty()) {
// no tokens to allow anything
return false;
}
// The callback will decide.
return mBackgroundActivityStartCallback.isActivityStartAllowed(
binderTokens, uid, packageName);