[pulseaudio-discuss] [PATCH RFCv3 23/51] rtpoll: Fix condition for DEBUG_TIMING output

Peter Meerwald pmeerw at pmeerw.net
Tue Nov 4 15:26:18 PST 2014


From: Peter Meerwald <p.meerwald at bct-electronic.com>

Signed-off-by: Peter Meerwald <pmeerw at pmeerw.net>
---
 src/pulsecore/rtpoll.c | 6 ++++--
 1 file changed, 4 insertions(+), 2 deletions(-)

diff --git a/src/pulsecore/rtpoll.c b/src/pulsecore/rtpoll.c
index 09e5e8a..c657cb6 100644
--- a/src/pulsecore/rtpoll.c
+++ b/src/pulsecore/rtpoll.c
@@ -298,10 +298,12 @@ int pa_rtpoll_run(pa_rtpoll *p, bool wait_op) {
         pa_usec_t now = pa_rtclock_now();
         p->awake = now - p->timestamp;
         p->timestamp = now;
-        if (!wait_op || p->quit || p->timer_enabled)
+        if (wait_op && !p->quit && p->timer_enabled)
             pa_log("poll timeout: %d ms ",(int) ((timeout.tv_sec*1000) + (timeout.tv_usec / 1000)));
-        else
+        else if (q->quit)
             pa_log("poll timeout is ZERO");
+        else
+            pa_log("poll timeout is FOREVER");
     }
 #endif
 
-- 
1.9.1



More information about the pulseaudio-discuss mailing list