Stop PulseAudio callback busy-waiting when stream is stopped.
authorCarl Hetherington <cth@carlh.net>
Sat, 19 Mar 2016 21:14:37 +0000 (21:14 +0000)
committerCarl Hetherington <cth@carlh.net>
Sat, 19 Mar 2016 21:14:37 +0000 (21:14 +0000)
This sets the runnable flag to false, as is done for other APIs.

RtAudio.cpp

index 882fa0e2830202407c2f17814c8a4e372947993d..5284bdb329b145fca84af16dc16f74c7417bf89d 100644 (file)
@@ -8337,6 +8337,7 @@ void RtApiPulse::stopStream( void )
   }\r
 \r
   stream_.state = STREAM_STOPPED;\r
+  pah->runnable = false;\r
   MUTEX_LOCK( &stream_.mutex );\r
 \r
   if ( pah && pah->s_play ) {\r
@@ -8371,6 +8372,7 @@ void RtApiPulse::abortStream( void )
   }\r
 \r
   stream_.state = STREAM_STOPPED;\r
+  pah->runnable = false;\r
   MUTEX_LOCK( &stream_.mutex );\r
 \r
   if ( pah && pah->s_play ) {\r