Use mDatabaseManager when calling database functions
When Bluetooth is turning off, there were cases that getConnectedPolicy() or setConnectedPolicy() of ProfileService are called, which threw NPE as mAdapterService is null. This CL adds mDatabaseManager to profile services so that they can handle those cases. Bug: 231243228 Tag: #stability Test: atest GoogleBluetoothInstrumentationTests && manually turning on/off Bluetooth to confirm NPE is not thrown Merged-In: I7e6006d69d0ce245f27e27002e9e6c5740e7093b Change-Id: I7e6006d69d0ce245f27e27002e9e6c5740e7093b (cherry picked from commit c7b7420e) (cherry picked from commit ee511dd6)
Loading
Please register or sign in to comment