diff --git a/plugins/spu2-x/src/Windows/SndOut_XAudio2.cpp b/plugins/spu2-x/src/Windows/SndOut_XAudio2.cpp index 5d4afb7711..36b8af28a6 100644 --- a/plugins/spu2-x/src/Windows/SndOut_XAudio2.cpp +++ b/plugins/spu2-x/src/Windows/SndOut_XAudio2.cpp @@ -209,7 +209,11 @@ private: EnterCriticalSection( &cs ); // All of these checks are necessary because XAudio2 is wonky shizat. - if( pSourceVoice == NULL || context == NULL ) return; + if( pSourceVoice == NULL || context == NULL ) + { + LeaveCriticalSection( &cs ); + return; + } T* qb = (T*)context;