Adding receiver exported flag.

Since the broadcast receiver in question is permission protected we will add a RECEIVER_EXPORTED flag to make this receiver compatible with Android T+.

Change-Id: Ib6453b47641a32796e202f4f9e37099c36b6c683
Test:no-op
Bug:161145287
This commit is contained in:
Jacob Hobbie
2021-11-02 21:44:01 +00:00
parent 66cffd469f
commit 0a3acc1c3f

View File

@@ -119,7 +119,8 @@ public class TetherService extends Service {
if (mExpectedProvisionResponseAction != null) unregisterReceiver(mReceiver);
registerReceiver(mReceiver, new IntentFilter(responseAction),
android.Manifest.permission.TETHER_PRIVILEGED, null /* handler */);
android.Manifest.permission.TETHER_PRIVILEGED, null /* handler */,
Context.RECEIVER_EXPORTED);
mExpectedProvisionResponseAction = responseAction;
if (DEBUG) Log.d(TAG, "registerReceiver " + responseAction);
}