Skip to content
This repository has been archived by the owner on Feb 11, 2021. It is now read-only.

Commit

Permalink
Browse files Browse the repository at this point in the history
Replaced strncmp for SDL_AUDIODRIVER test with strcasecmp.
 Fixes Bugzilla #334.
  • Loading branch information
icculus committed Oct 1, 2006
1 parent 0d21df5 commit dfe494b
Showing 1 changed file with 2 additions and 3 deletions.
5 changes: 2 additions & 3 deletions src/audio/SDL_audio.c
Expand Up @@ -371,7 +371,7 @@ SDL_AudioInit(const char *driver_name)
This probably isn't the place to do this, but... Shh! :)
*/
for (i = 0; bootstrap[i]; ++i) {
if (SDL_strcmp(bootstrap[i]->name, "esd") == 0) {
if (SDL_strcasecmp(bootstrap[i]->name, "esd") == 0) {
#ifdef HAVE_PUTENV
const char *esd_no_spawn;

Expand All @@ -397,8 +397,7 @@ SDL_AudioInit(const char *driver_name)
if (audio == NULL) {
if (driver_name != NULL) {
for (i = 0; bootstrap[i]; ++i) {
if (SDL_strncmp(bootstrap[i]->name, driver_name,
SDL_strlen(bootstrap[i]->name)) == 0) {
if (SDL_strcasecmp(bootstrap[i]->name, driver_name) == 0) {
if (bootstrap[i]->available()) {
audio = bootstrap[i]->create(idx);
}
Expand Down

0 comments on commit dfe494b

Please sign in to comment.