Add null check in ScanManager.downgradeScanModeFromMaxDuty
In function ScanManager.downgradeScanModeFromMaxDuty, ScanClient.stats.setScanDowngrade is called while ScanClient.stats maybe null. This is resulting in a NullPointerException. All other functions inside ScanManager using ScanClient.stats perform a null check beforehand, and therefore a null check is added to fix the NPE issue. Unit test to check NPE fix is added as well. Bug: 279848544 Test: atest BluetoothInstrumentationTests Change-Id: I2dc50d15f7c45b2cc954c00b8ccc4f4313d7e6da
Loading
Please register or sign in to comment