aboutsummaryrefslogtreecommitdiffstats
path: root/Alc/ALc.c
diff options
context:
space:
mode:
authorChris Robinson <[email protected]>2012-01-29 22:49:17 -0800
committerChris Robinson <[email protected]>2012-01-29 22:49:17 -0800
commit4393b6b05fc06ed1eaabd583ce91f45f8eefb5b7 (patch)
tree795a459abc636b9b4a6c82432987ebbffd4aee13 /Alc/ALc.c
parented037698fdb917d69d31c143816e2e98e0c6b663 (diff)
Only initialize the default reverb effect when a slot is available
Diffstat (limited to 'Alc/ALc.c')
-rw-r--r--Alc/ALc.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/Alc/ALc.c b/Alc/ALc.c
index dfdece10..acb11733 100644
--- a/Alc/ALc.c
+++ b/Alc/ALc.c
@@ -2263,7 +2263,8 @@ ALC_API ALCcontext* ALC_APIENTRY alcCreateContext(ALCdevice *device, const ALCin
} while(!CompExchangePtr((XchgPtr*)&device->ContextList, ALContext->next, ALContext));
UnlockLists();
- InitializeEffect(ALContext, device->DefaultSlot, &ForcedEffect);
+ if(device->DefaultSlot)
+ InitializeEffect(ALContext, device->DefaultSlot, &ForcedEffect);
ALContext->LastError = AL_NO_ERROR;
ALCdevice_DecRef(device);