Stop the recurring alarm if no scansettings are available
This will fix an NPE whenever no scansettings are available.
The stop of the recurring alarm should not introduce a permanent
stop though since the whole processPendingScans function is dependant
on mPendingBackgroundScanSettings != null.
Anyway, as soon as mPendingBackgroundScanSettings is changed,
the processPendingScans function will be called, either directly
or indirectly through handleScanPeriod().
Crash call stack:
java.lang.NullPointerException: Attempt to read from field
'int com.android.server.wifi.WifiNative$ScanSettings.base_period_ms'
on a null object reference
at com.android.server.wifi.scanner.SupplicantWifiScannerImpl.processPendingScans
(SupplicantWifiScannerImpl.java:395)
Bug: 29113658
Author: Ola Olsson <ola.olsson@sonymobile.com>
Change-Id: Ibf08c9d6c5e476052449ef11d82ce005e50bd4fd
1 file changed