Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Skip to content
Commit 56db1f02 authored by weichinweng's avatar weichinweng
Browse files

Use mDatabaseManager when calling database functions

In some corner cases, when the Bluetooth is turning off,
setConnectionPolicy() in each profile could be invoked right after
mAdapterService is set to null.
This patch replaces mAdapterService.getDatabase() to mDatabaseManager
in order to avoid null pointer dereference. It also makes
setConnectionPolicy() to return the correct result.

Bug: 157973675
Test: atest BluetoothInstrumentationTests
Tag: #stability

Change-Id: I422571e63a9f01bc531e2ba21c0b303e92383efb
parent 890409fa
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment