comparison src/audio/SDL_audio.c @ 1408:ceb5c2fec4f1

Fixed some preprocessor mangling
author Sam Lantinga <slouken@libsdl.org>
date Tue, 21 Feb 2006 18:29:39 +0000
parents 39ca9a4b22f3
children e3242177fe4a
comparison
equal deleted inserted replaced
1407:0c6941483cc6 1408:ceb5c2fec4f1
446 return(-1); 446 return(-1);
447 } 447 }
448 #else 448 #else
449 D(bug("Locking semaphore...")); 449 D(bug("Locking semaphore..."));
450 SDL_mutexP(audio->mixer_lock); 450 SDL_mutexP(audio->mixer_lock);
451 #endif 451
452 452
453 #if (defined(__WIN32__) && !defined(_WIN32_WCE)) && !defined(HAVE_LIBC)
454 #undef SDL_CreateThread
455 audio->thread = SDL_CreateThread(SDL_RunAudio, audio, NULL, NULL);
456 #else
457 audio->thread = SDL_CreateThread(SDL_RunAudio, audio); 453 audio->thread = SDL_CreateThread(SDL_RunAudio, audio);
458 #endif
459 D(bug("Created thread...\n")); 454 D(bug("Created thread...\n"));
460 455
461 if ( audio->thread == NULL ) { 456 if ( audio->thread == NULL ) {
462 SDL_mutexV(audio->mixer_lock); 457 SDL_mutexV(audio->mixer_lock);
463 SDL_CloseAudio(); 458 SDL_CloseAudio();
464 SDL_SetError("Couldn't create audio thread"); 459 SDL_SetError("Couldn't create audio thread");
465 return(-1); 460 return(-1);
466 } 461 }
467 462
468 #if SDL_AUDIO_DRIVER_AHI
469 while(!audio_configured) 463 while(!audio_configured)
470 SDL_Delay(100); 464 SDL_Delay(100);
471 #endif 465 #endif
472 466
473 /* If the audio driver changes the buffer size, accept it */ 467 /* If the audio driver changes the buffer size, accept it */