From 664539d25180ab8f77e0521533ea2821cf28985f Mon Sep 17 00:00:00 2001 From: Eric Laurent Date: Mon, 23 Sep 2013 18:24:31 -0700 Subject: [PATCH] audioflinger: fix ro.audio.silent in offload again Commit 1abbdb4 was not working 100% of the times because it is possible that the offload thread loop never sleeps after being created in which case the property is never read. The loop now reads the property once when starting. Bug: 10899309. Change-Id: I2e2ca332f2d7086e59d65f6010378c4d9618ba9e --- services/audioflinger/Threads.cpp | 2 ++ 1 file changed, 2 insertions(+) diff --git a/services/audioflinger/Threads.cpp b/services/audioflinger/Threads.cpp index 5f36cabc0c..b771e3b4e7 100644 --- a/services/audioflinger/Threads.cpp +++ b/services/audioflinger/Threads.cpp @@ -2115,6 +2115,8 @@ bool AudioFlinger::PlaybackThread::threadLoop() // and then that string will be logged at the next convenient opportunity. const char *logString = NULL; + checkSilentMode_l(); + while (!exitPending()) { cpuStats.sample(myName); -- 2.11.0