diff options
author | Chris Robinson <[email protected]> | 2017-02-13 21:30:20 -0800 |
---|---|---|
committer | Chris Robinson <[email protected]> | 2017-02-13 21:30:20 -0800 |
commit | 69dd57096183c4e381cc3f5c0a8ac4e33048b346 (patch) | |
tree | 1a1b2b694987a78007903c487d218d289b57e433 /OpenAL32/alSource.c | |
parent | 0d19a209014582f1e77ab3b927dfb1af6c307d66 (diff) |
Fix build with non-C11 atomics
Diffstat (limited to 'OpenAL32/alSource.c')
-rw-r--r-- | OpenAL32/alSource.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/OpenAL32/alSource.c b/OpenAL32/alSource.c index edcb49cd..036b7542 100644 --- a/OpenAL32/alSource.c +++ b/OpenAL32/alSource.c @@ -46,7 +46,7 @@ extern inline void LockSourcesWrite(ALCcontext *context); extern inline void UnlockSourcesWrite(ALCcontext *context); extern inline struct ALsource *LookupSource(ALCcontext *context, ALuint id); extern inline struct ALsource *RemoveSource(ALCcontext *context, ALuint id); -extern inline ALboolean IsPlayingOrPaused(ALsource *source); +extern inline ALboolean IsPlayingOrPaused(const ALsource *source); static void InitSourceParams(ALsource *Source); static void DeinitSource(ALsource *source); @@ -141,7 +141,7 @@ static inline ALvoice *GetSourceVoice(const ALsource *source, const ALCcontext * static inline bool SourceShouldUpdate(const ALsource *source, const ALCcontext *context) { - return (source->state == AL_PLAYING || source->state == AL_PAUSED) && + return IsPlayingOrPaused(source) && !ATOMIC_LOAD(&context->DeferUpdates, almemory_order_acquire); } |