diff options
author | Chris Robinson <[email protected]> | 2018-02-03 01:26:04 -0800 |
---|---|---|
committer | Chris Robinson <[email protected]> | 2018-02-03 01:26:04 -0800 |
commit | 4ef60d7214c28f58e2686006766556a92fc7d2c4 (patch) | |
tree | 801684167a41e675980ca48f85726cbe84138589 /OpenAL32 | |
parent | 40bda4d93f15b5b089b6736eb9fd2d04f8e683eb (diff) |
Add a couple missing lock calls
Diffstat (limited to 'OpenAL32')
-rw-r--r-- | OpenAL32/alSource.c | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/OpenAL32/alSource.c b/OpenAL32/alSource.c index e56e252c..c20226ca 100644 --- a/OpenAL32/alSource.c +++ b/OpenAL32/alSource.c @@ -1324,7 +1324,9 @@ static ALboolean GetSourcedv(ALsource *Source, ALCcontext *Context, SourceProp p * clock time with the device latency. Order is important. */ values[0] = GetSourceSecOffset(Source, Context, &srcclock); + almtx_lock(&device->BackendLock); clocktime = V0(device->Backend,getClockLatency)(); + almtx_unlock(&device->BackendLock); if(srcclock == (ALuint64)clocktime.ClockTime) values[1] = (ALdouble)clocktime.Latency / 1000000000.0; else @@ -1655,7 +1657,9 @@ static ALboolean GetSourcei64v(ALsource *Source, ALCcontext *Context, SourceProp * clock time with the device latency. Order is important. */ values[0] = GetSourceSampleOffset(Source, Context, &srcclock); + almtx_lock(&device->BackendLock); clocktime = V0(device->Backend,getClockLatency)(); + almtx_unlock(&device->BackendLock); if(srcclock == (ALuint64)clocktime.ClockTime) values[1] = clocktime.Latency; else |