Merge "Fix bypass BAL via LocationManager.requestFlush" into sc-v2-dev

This commit is contained in:
Kate Montgomery
2023-02-02 20:30:09 +00:00
committed by Android (Google) Code Review

View File

@@ -281,6 +281,7 @@ public class LocationProviderManager extends
public void deliverOnFlushComplete(int requestCode) throws PendingIntent.CanceledException { public void deliverOnFlushComplete(int requestCode) throws PendingIntent.CanceledException {
BroadcastOptions options = BroadcastOptions.makeBasic(); BroadcastOptions options = BroadcastOptions.makeBasic();
options.setDontSendToRestrictedApps(true); options.setDontSendToRestrictedApps(true);
options.setPendingIntentBackgroundActivityLaunchAllowed(false);
mPendingIntent.send(mContext, 0, new Intent().putExtra(KEY_FLUSH_COMPLETE, requestCode), mPendingIntent.send(mContext, 0, new Intent().putExtra(KEY_FLUSH_COMPLETE, requestCode),
null, null, null, options.toBundle()); null, null, null, options.toBundle());