diff options
| author | 2020-09-24 08:36:36 +0000 | |
|---|---|---|
| committer | 2020-09-24 08:36:36 +0000 | |
| commit | a788fea989d5d3f858088dd32e49d3060f863af9 (patch) | |
| tree | 47c1879152871acd830cc92d80fa21b86b09a4d1 | |
| parent | 07fcb0ee95baedbbe74b1eea63a3c08cd9252601 (diff) | |
| parent | fd55a98702c491b5fa3730f14873228a61644e9a (diff) | |
Merge "Excessive battery usage fix." into rvc-qpr-dev am: fd55a98702
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/12672273
Change-Id: Ied1283b556a86c8c69c9a4f6dac18a2f1d1a0db0
| -rw-r--r-- | services/incremental/IncrementalService.cpp | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/services/incremental/IncrementalService.cpp b/services/incremental/IncrementalService.cpp index f7082a9a1a0c..f3940e609b8b 100644 --- a/services/incremental/IncrementalService.cpp +++ b/services/incremental/IncrementalService.cpp @@ -305,6 +305,7 @@ IncrementalService::~IncrementalService() { } mJobCondition.notify_all(); mJobProcessor.join(); + mLooper->wake(); mCmdLooperThread.join(); mTimedQueue->stop(); // Ensure that mounts are destroyed while the service is still valid. @@ -1377,7 +1378,7 @@ bool IncrementalService::mountExistingImage(std::string_view root) { } void IncrementalService::runCmdLooper() { - constexpr auto kTimeoutMsecs = 1000; + constexpr auto kTimeoutMsecs = -1; while (mRunning.load(std::memory_order_relaxed)) { mLooper->pollAll(kTimeoutMsecs); } |