Skip to content
Snippets Groups Projects
Commit 7dce61f0 authored by Dmitri Plotnikov's avatar Dmitri Plotnikov Committed by Android (Google) Code Review
Browse files

Merge "Catch RejectedExecutionException in BatteryExternalStatsWorker" into main

parents 2c00da4e 21431c63
No related branches found
No related tags found
No related merge requests found
......@@ -386,7 +386,11 @@ public class BatteryExternalStatsWorker implements BatteryStatsImpl.ExternalStat
}
}
return mExecutorService.schedule(syncRunnable, delayMillis, TimeUnit.MILLISECONDS);
try {
return mExecutorService.schedule(syncRunnable, delayMillis, TimeUnit.MILLISECONDS);
} catch (RejectedExecutionException e) {
return CompletableFuture.failedFuture(e);
}
}
public synchronized Future<?> scheduleWrite() {
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment