@@ -993,9 +993,8 @@ def start(self):
993993
994994 """
995995 err = _lib .Pa_StartStream (self ._ptr )
996- if err == _lib .paStreamIsNotStopped :
997- return
998- _check (err , "Error starting stream" )
996+ if err != _lib .paStreamIsNotStopped :
997+ _check (err , "Error starting stream" )
999998
1000999 def stop (self ):
10011000 """Terminate audio processing.
@@ -1009,9 +1008,8 @@ def stop(self):
10091008
10101009 """
10111010 err = _lib .Pa_StopStream (self ._ptr )
1012- if err == _lib .paStreamIsStopped :
1013- return
1014- _check (err , "Error stopping stream" )
1011+ if err != _lib .paStreamIsStopped :
1012+ _check (err , "Error stopping stream" )
10151013
10161014 def abort (self ):
10171015 """Terminate audio processing immediately.
@@ -1024,9 +1022,8 @@ def abort(self):
10241022
10251023 """
10261024 err = _lib .Pa_AbortStream (self ._ptr )
1027- if err == _lib .paStreamIsStopped :
1028- return
1029- _check (err , "Error aborting stream" )
1025+ if err != _lib .paStreamIsStopped :
1026+ _check (err , "Error aborting stream" )
10301027
10311028 def close (self , ignore_errors = True ):
10321029 """Close the stream.
0 commit comments