diff options
author | Chris Robinson <[email protected]> | 2012-01-20 12:53:41 -0800 |
---|---|---|
committer | Chris Robinson <[email protected]> | 2012-01-20 12:53:41 -0800 |
commit | e52e4b1a8c2dbf4db4717ce188e9bfd79c27a723 (patch) | |
tree | bae2230f6142b70201860bf496633444d6434309 | |
parent | 0ef3a30b84759c3a1e9046fe790b02f845cbdedb (diff) |
Not all devices will have a default effect slot
-rw-r--r-- | Alc/ALc.c | 7 |
1 files changed, 5 insertions, 2 deletions
@@ -1302,8 +1302,11 @@ static ALCvoid FreeDevice(ALCdevice *device) { TRACE("%p\n", device); - ALeffectState_Destroy(device->DefaultSlot->EffectState); - device->DefaultSlot->EffectState = NULL; + if(device->DefaultSlot) + { + ALeffectState_Destroy(device->DefaultSlot->EffectState); + device->DefaultSlot->EffectState = NULL; + } if(device->BufferMap.size > 0) { |