Loading android/app/src/com/android/bluetooth/le_scan/ScanManager.java +15 −6 Original line number Diff line number Diff line Loading @@ -837,7 +837,9 @@ public class ScanManager { if (!mScanNative.isDowngradedScanClient(client)) { return false; } if (client.stats != null) { client.stats.setScanDowngrade(client.scannerId, false); } Log.d(TAG, "revertDowngradeScanModeFromMaxDuty() for " + client); if (mScreenOn) { return updateScanModeScreenOn(client); Loading Loading @@ -1349,7 +1351,8 @@ public class ScanManager { } void regularScanTimeout(ScanClient client) { if (!isExemptFromScanTimeout(client) && client.stats.isScanningTooLong()) { if (!isExemptFromScanTimeout(client) && (client.stats == null || client.stats.isScanningTooLong())) { Log.d(TAG, "regularScanTimeout - client scan time was too long"); if (client.filters == null || client.filters.isEmpty()) { Log.w(TAG, Loading @@ -1368,9 +1371,11 @@ public class ScanManager { int maxScanMode = SCAN_MODE_FORCE_DOWNGRADED; client.updateScanMode(getMinScanMode(scanMode, maxScanMode)); } if (client.stats != null) { client.stats.setScanTimeout(client.scannerId); client.stats.recordScanTimeoutCountMetrics(); } } // The scan should continue for background scans configureRegularScanParams(); Loading Loading @@ -1512,7 +1517,9 @@ public class ScanManager { TAG, "No hardware resources for onfound/onlost filter " + trackEntries); if (client.stats != null) { client.stats.recordTrackingHwFilterNotAvailableCountMetrics(); } try { mScanHelper.onScanManagerErrorCallback( scannerId, ScanCallback.SCAN_FAILED_INTERNAL_ERROR); Loading Loading @@ -1611,7 +1618,9 @@ public class ScanManager { return true; } if (client.filters.size() > mFilterIndexStack.size()) { if (client.stats != null) { client.stats.recordHwFilterNotAvailableCountMetrics(); } return true; } return false; Loading Loading
android/app/src/com/android/bluetooth/le_scan/ScanManager.java +15 −6 Original line number Diff line number Diff line Loading @@ -837,7 +837,9 @@ public class ScanManager { if (!mScanNative.isDowngradedScanClient(client)) { return false; } if (client.stats != null) { client.stats.setScanDowngrade(client.scannerId, false); } Log.d(TAG, "revertDowngradeScanModeFromMaxDuty() for " + client); if (mScreenOn) { return updateScanModeScreenOn(client); Loading Loading @@ -1349,7 +1351,8 @@ public class ScanManager { } void regularScanTimeout(ScanClient client) { if (!isExemptFromScanTimeout(client) && client.stats.isScanningTooLong()) { if (!isExemptFromScanTimeout(client) && (client.stats == null || client.stats.isScanningTooLong())) { Log.d(TAG, "regularScanTimeout - client scan time was too long"); if (client.filters == null || client.filters.isEmpty()) { Log.w(TAG, Loading @@ -1368,9 +1371,11 @@ public class ScanManager { int maxScanMode = SCAN_MODE_FORCE_DOWNGRADED; client.updateScanMode(getMinScanMode(scanMode, maxScanMode)); } if (client.stats != null) { client.stats.setScanTimeout(client.scannerId); client.stats.recordScanTimeoutCountMetrics(); } } // The scan should continue for background scans configureRegularScanParams(); Loading Loading @@ -1512,7 +1517,9 @@ public class ScanManager { TAG, "No hardware resources for onfound/onlost filter " + trackEntries); if (client.stats != null) { client.stats.recordTrackingHwFilterNotAvailableCountMetrics(); } try { mScanHelper.onScanManagerErrorCallback( scannerId, ScanCallback.SCAN_FAILED_INTERNAL_ERROR); Loading Loading @@ -1611,7 +1618,9 @@ public class ScanManager { return true; } if (client.filters.size() > mFilterIndexStack.size()) { if (client.stats != null) { client.stats.recordHwFilterNotAvailableCountMetrics(); } return true; } return false; Loading