Merge "profcollect: check hardware capability on a background thread"

This commit is contained in:
Yi Kong
2021-11-19 09:54:48 +00:00
committed by Gerrit Code Review

View File

@@ -91,10 +91,12 @@ public final class ProfcollectForwardingService extends SystemService {
if (mIProfcollect == null) { if (mIProfcollect == null) {
return; return;
} }
if (serviceHasSupportedTraceProvider()) { BackgroundThread.get().getThreadHandler().post(() -> {
registerObservers(); if (serviceHasSupportedTraceProvider()) {
} registerObservers();
ProfcollectBGJobService.schedule(getContext()); ProfcollectBGJobService.schedule(getContext());
}
});
} }
} }