summaryrefslogtreecommitdiffstats
path: root/services
diff options
context:
space:
mode:
Diffstat (limited to 'services')
-rw-r--r--services/audioflinger/Threads.cpp10
1 files changed, 7 insertions, 3 deletions
diff --git a/services/audioflinger/Threads.cpp b/services/audioflinger/Threads.cpp
index 2b37761..515368c 100644
--- a/services/audioflinger/Threads.cpp
+++ b/services/audioflinger/Threads.cpp
@@ -4474,13 +4474,17 @@ reacquire_wakelock:
{ // scope for mLock
Mutex::Autolock _l(mLock);
- if (exitPending()) {
- break;
- }
+
processConfigEvents_l();
// return value 'reconfig' is currently unused
bool reconfig = checkForNewParameters_l();
+ // check exitPending here because checkForNewParameters_l() and
+ // checkForNewParameters_l() can temporarily release mLock
+ if (exitPending()) {
+ break;
+ }
+
// if no active track(s), then standby and release wakelock
size_t size = mActiveTracks.size();
if (size == 0) {