From 131470867d7f1af25787a89cb30519c2ec40ab73 Mon Sep 17 00:00:00 2001 From: "Ryan C. Gordon" Date: Wed, 21 Sep 2011 02:42:25 -0400 Subject: [PATCH] Replaced a sanity check with an SDL_assert(). --- src/audio/SDL_audio.c | 6 +----- 1 file changed, 1 insertion(+), 5 deletions(-) diff --git a/src/audio/SDL_audio.c b/src/audio/SDL_audio.c index 1a544fcd8..7fb5d2422 100644 --- a/src/audio/SDL_audio.c +++ b/src/audio/SDL_audio.c @@ -1075,12 +1075,8 @@ SDL_OpenAudio(SDL_AudioSpec * desired, SDL_AudioSpec * obtained) } else { id = open_audio_device(NULL, 0, desired, desired, 0, 1); } - if (id > 1) { /* this should never happen in theory... */ - SDL_CloseAudioDevice(id); - SDL_SetError("Internal error"); /* MUST be Device ID #1! */ - return (-1); - } + SDL_assert((id == 0) || (id == 1)); return ((id == 0) ? -1 : 0); }