Fix usage of QMutexLocker, destroy it only at end of scope
Change-Id: I8b47d49f7a83a71a1b90ab57ee7bc3791ef59667 Reviewed-by: Marc Mutz <marc.mutz@kdab.com> Reviewed-by: Yoann Lopes <yoann.lopes@theqtcompany.com>
This commit is contained in:
committed by
Yoann Lopes
parent
c953ef3910
commit
0521766417
@@ -90,7 +90,7 @@ void QT_WIN_CALLBACK QWindowsAudioInput::waveInProc( HWAVEIN hWaveIn, UINT uMsg,
|
|||||||
if(!qAudio)
|
if(!qAudio)
|
||||||
return;
|
return;
|
||||||
|
|
||||||
QMutexLocker(&qAudio->mutex);
|
QMutexLocker locker(&qAudio->mutex);
|
||||||
|
|
||||||
switch(uMsg) {
|
switch(uMsg) {
|
||||||
case WIM_OPEN:
|
case WIM_OPEN:
|
||||||
|
|||||||
@@ -90,7 +90,7 @@ void CALLBACK QWindowsAudioOutput::waveOutProc( HWAVEOUT hWaveOut, UINT uMsg,
|
|||||||
if(!qAudio)
|
if(!qAudio)
|
||||||
return;
|
return;
|
||||||
|
|
||||||
QMutexLocker(&qAudio->mutex);
|
QMutexLocker locker(&qAudio->mutex);
|
||||||
|
|
||||||
switch(uMsg) {
|
switch(uMsg) {
|
||||||
case WOM_OPEN:
|
case WOM_OPEN:
|
||||||
|
|||||||
Reference in New Issue
Block a user