aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorChris Robinson <[email protected]>2018-11-30 10:08:18 -0800
committerChris Robinson <[email protected]>2018-11-30 10:08:18 -0800
commit364850e8f9a224144c91c7b562d44321b7aa4505 (patch)
tree7e1375df3723185444e516bc1919a196cbc14866
parentb582f1346a2e0e2e82eb4a2d4e72d670cc066971 (diff)
Move a variable declaration to a more appropriate place
-rw-r--r--OpenAL32/alSource.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/OpenAL32/alSource.cpp b/OpenAL32/alSource.cpp
index 0eaed61f..c0e48c5c 100644
--- a/OpenAL32/alSource.cpp
+++ b/OpenAL32/alSource.cpp
@@ -52,9 +52,9 @@ namespace {
inline ALvoice *GetSourceVoice(ALsource *source, ALCcontext *context)
{
ALint idx{source->VoiceIdx};
- ALuint sid{source->id};
if(idx >= 0 && idx < context->VoiceCount.load(std::memory_order_relaxed))
{
+ ALuint sid{source->id};
ALvoice *voice{context->Voices[idx]};
if(voice->SourceID.load(std::memory_order_acquire) == sid)
return voice;