Remove PM query for silent provisioning BroadcastReceiver.
This fixes TetherService unit tests. Change-Id: I404d0e9322d14242997576e30ba75941423b331b
This commit is contained in:
@@ -29,7 +29,6 @@ import android.content.Context;
|
||||
import android.content.Intent;
|
||||
import android.content.IntentFilter;
|
||||
import android.content.SharedPreferences;
|
||||
import android.content.pm.PackageManager;
|
||||
import android.net.ConnectivityManager;
|
||||
import android.os.IBinder;
|
||||
import android.os.ResultReceiver;
|
||||
@@ -236,16 +235,6 @@ public class TetherService extends Service {
|
||||
intent.putExtra(TETHER_CHOICE, type);
|
||||
intent.setFlags(Intent.FLAG_RECEIVER_FOREGROUND);
|
||||
|
||||
// Ensure that the provisioning app will actually handle the intent.
|
||||
final PackageManager packageManager = getPackageManager();
|
||||
if (packageManager.queryBroadcastReceivers(
|
||||
intent, PackageManager.MATCH_DEFAULT_ONLY).isEmpty()) {
|
||||
Log.e(TAG, "Provisioning app is configured, but not available.");
|
||||
fireCallbacksForType(type, ConnectivityManager.TETHER_ERROR_PROVISION_FAILED);
|
||||
removeTypeAtIndex(index);
|
||||
return;
|
||||
}
|
||||
|
||||
sendBroadcast(intent);
|
||||
mInProvisionCheck = true;
|
||||
}
|
||||
|
Reference in New Issue
Block a user