Allow factory reset when bluetooth is off (1/2)
Bug: 27348444 Change-Id: I6c2709371b86581709649d7faf09391230449b9b
This commit is contained in:
committed by
Andre Eisenbach
parent
d1427fbe0d
commit
b6e1dafe78
@@ -36,6 +36,7 @@ import android.os.IBinder;
|
||||
import android.os.ParcelUuid;
|
||||
import android.os.RemoteException;
|
||||
import android.os.ServiceManager;
|
||||
import android.os.SystemProperties;
|
||||
import android.util.Log;
|
||||
import android.util.Pair;
|
||||
|
||||
@@ -1015,6 +1016,8 @@ public final class BluetoothAdapter {
|
||||
try {
|
||||
if (mService != null) {
|
||||
return mService.factoryReset();
|
||||
} else {
|
||||
SystemProperties.set("persist.bluetooth.factoryreset", "true");
|
||||
}
|
||||
} catch (RemoteException e) {Log.e(TAG, "", e);}
|
||||
return false;
|
||||
|
||||
Reference in New Issue
Block a user