Couple small error handling fixups

This commit is contained in:
Chris Robinson
2012-04-24 03:52:21 -07:00
parent dec8e81211
commit 3e49e79140
2 changed files with 5 additions and 5 deletions
+4 -3
View File
@@ -56,10 +56,10 @@ AL_API ALboolean AL_APIENTRY alIsExtensionPresent(const ALchar *extName)
Context = GetContextRef();
if(!Context) return AL_FALSE;
if(!extName)
alSetError(Context, AL_INVALID_VALUE);
else
al_try
{
CHECK_VALUE(Context, extName);
len = strlen(extName);
ptr = Context->ExtensionList;
while(ptr && *ptr)
@@ -78,6 +78,7 @@ AL_API ALboolean AL_APIENTRY alIsExtensionPresent(const ALchar *extName)
}
}
}
al_endtry;
ALCcontext_DecRef(Context);
return ret;
+1 -2
View File
@@ -699,8 +699,7 @@ AL_API void AL_APIENTRY alSource3i(ALuint source, ALenum param, ALint value1, AL
break;
default:
alSetError(Context, AL_INVALID_ENUM);
break;
al_throwerr(Context, AL_INVALID_ENUM);
}
}
al_endtry;