diff options
author | Chris Robinson <[email protected]> | 2011-06-17 23:59:25 -0700 |
---|---|---|
committer | Chris Robinson <[email protected]> | 2011-06-17 23:59:25 -0700 |
commit | 0d39ac652889bc2ecea0286fe24fcdcd6c04995e (patch) | |
tree | d21b0a88ed08e2901c5e5a6049705fb64a9d8247 /OpenAL32/alEffect.c | |
parent | 157e1394d6d3d32630d287a9725396ec4dff24bb (diff) |
Allow alThunkAddEntry to return a proper error
Diffstat (limited to 'OpenAL32/alEffect.c')
-rw-r--r-- | OpenAL32/alEffect.c | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/OpenAL32/alEffect.c b/OpenAL32/alEffect.c index 62e4d0c4..45fd5e78 100644 --- a/OpenAL32/alEffect.c +++ b/OpenAL32/alEffect.c @@ -63,8 +63,9 @@ AL_API ALvoid AL_APIENTRY alGenEffects(ALsizei n, ALuint *effects) break; } - effect->effect = ALTHUNK_ADDENTRY(effect); - err = InsertUIntMapEntry(&device->EffectMap, effect->effect, effect); + err = ALTHUNK_ADDENTRY(effect, &effect->effect); + if(err == AL_NO_ERROR) + err = InsertUIntMapEntry(&device->EffectMap, effect->effect, effect); if(err != AL_NO_ERROR) { ALTHUNK_REMOVEENTRY(effect->effect); |