Keep a null check before accessing the BluetoothA2dpWrapper APIs.
When switching from default user mode to guest mode from system settings,
Bluetooth gets turn OFF and ON. Then, try connect to peer device which was
connected previousely in the default user mode. At this point if BluetoothA2dpWrapper
has not init, then its object would be null, and accessing the APIs of BluetoothA2dpWrapper
in A2dpProfile, results in NPE. So keep a null check on object of BluetoothA2dpWrapper
class before accessing APIs using it.
[wight554: updated code from LA.QSSI.11.0.r1-05600-qssi.0]
Conflicts:
packages/SettingsLib/src/com/android/settingslib/bluetooth/A2dpProfile.java
CRs-Fixed: 2454049
Change-Id: Idd949bc27fec10b46a149b5db67abc6f3b5097d1
Signed-off-by:
Volodymyr Zhdanov <wight554@gmail.com>
Loading
Please register or sign in to comment