aboutsummaryrefslogtreecommitdiffstats
path: root/Alc/ALc.c
diff options
context:
space:
mode:
Diffstat (limited to 'Alc/ALc.c')
-rw-r--r--Alc/ALc.c8
1 files changed, 6 insertions, 2 deletions
diff --git a/Alc/ALc.c b/Alc/ALc.c
index e03e3655..53295fa0 100644
--- a/Alc/ALc.c
+++ b/Alc/ALc.c
@@ -1927,6 +1927,7 @@ static ALCenum UpdateDeviceParams(ALCdevice *device, const ALCint *attrList)
ALactivesource *src = context->ActiveSources[pos];
ALsource *source = src->Source;
ALuint s = device->NumAuxSends;
+
while(s < MAX_SENDS)
{
src->Send[s].Moving = AL_FALSE;
@@ -1934,8 +1935,11 @@ static ALCenum UpdateDeviceParams(ALCdevice *device, const ALCint *attrList)
s++;
}
- src->Update(src, context);
- ATOMIC_STORE(&source->NeedsUpdate, AL_FALSE);
+ if(source)
+ {
+ src->Update(src, source, context);
+ ATOMIC_STORE(&source->NeedsUpdate, AL_FALSE);
+ }
}
context = context->next;