Fix a bug where the AmbientContextManager is not registered if the AmbientContextDetectionService is not available. The manager should always be available, and return STATUS_SERVICE_NOT_AVAILABLE in this case.
Test: end-to-end test Bug: 192476579 Change-Id: Ifce8c8dbb71a7bb6efd65db41686c14681cf0e4a
This commit is contained in:
@@ -3171,11 +3171,6 @@ public final class SystemServer implements Dumpable {
|
||||
}
|
||||
|
||||
private void startAmbientContextService(@NonNull TimingsTraceAndSlog t) {
|
||||
if (!AmbientContextManagerService.isDetectionServiceConfigured()) {
|
||||
Slog.d(TAG, "AmbientContextDetectionService is not configured on this device");
|
||||
return;
|
||||
}
|
||||
|
||||
t.traceBegin("StartAmbientContextService");
|
||||
mSystemServiceManager.startService(AmbientContextManagerService.class);
|
||||
t.traceEnd();
|
||||
|
||||
Reference in New Issue
Block a user