aboutsummaryrefslogtreecommitdiffstats
path: root/Alc/backends/jack.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'Alc/backends/jack.cpp')
-rw-r--r--Alc/backends/jack.cpp3
1 files changed, 1 insertions, 2 deletions
diff --git a/Alc/backends/jack.cpp b/Alc/backends/jack.cpp
index 5ac0ff4d..78de2699 100644
--- a/Alc/backends/jack.cpp
+++ b/Alc/backends/jack.cpp
@@ -200,7 +200,7 @@ int JackPlayback::bufferSizeNotifyC(jack_nframes_t numframes, void *arg)
int JackPlayback::bufferSizeNotify(jack_nframes_t numframes)
{
- lock();
+ std::lock_guard<std::mutex> _{mDevice->StateLock};
mDevice->UpdateSize = numframes;
mDevice->NumUpdates = 2;
@@ -218,7 +218,6 @@ int JackPlayback::bufferSizeNotify(jack_nframes_t numframes)
ERR("Failed to reallocate ringbuffer\n");
aluHandleDisconnect(mDevice, "Failed to reallocate %u-sample buffer", bufsize);
}
- unlock();
return 0;
}