Proper SDL library initialization for Audio and Joystick subsystems (ported from master)

This commit is contained in:
Damjan Adamic
2015-04-25 18:03:47 +02:00
parent df2318a45d
commit 2a667d1d53
5 changed files with 55 additions and 5 deletions
+5
View File
@@ -498,6 +498,11 @@ bool audio_thread_running = false;
void *audio_thread(void *)
{
if ( !SDL_WasInit(SDL_INIT_AUDIO) ) {
fprintf(stderr, "ERROR: couldn't initialize SDL audio support\n");
return 0;
}
SDL_AudioSpec wanted, have;
/* Set the audio format */