Add thread name to SDL_CreateThread calls.

SDL2's version of SDL_CreateThread has an extra parameter to specify
a name for the thread.
This commit is contained in:
Simon Howard 2014-11-28 15:43:26 -05:00
parent 326e00f5cf
commit 7fd60f8d9b
4 changed files with 8 additions and 5 deletions

View file

@ -184,7 +184,7 @@ int OPL_Timer_StartThread(void)
opl_timer_paused = 0;
pause_offset = 0;
timer_thread = SDL_CreateThread(ThreadFunction, NULL);
timer_thread = SDL_CreateThread(ThreadFunction, "OPL timer thread", NULL);
if (timer_thread == NULL)
{

View file

@ -291,7 +291,8 @@ static int PCSound_BSD_Init(pcsound_callback_func callback_func)
}
sound_thread_running = 1;
sound_thread_handle = SDL_CreateThread(SoundThread, NULL);
sound_thread_handle =
SDL_CreateThread(SoundThread, "PC speaker thread", NULL);
return 1;
}

View file

@ -142,8 +142,9 @@ static int PCSound_Linux_Init(pcsound_callback_func callback_func)
callback = callback_func;
sound_thread_running = 1;
sound_thread_handle = SDL_CreateThread(SoundThread, NULL);
sound_thread_handle =
SDL_CreateThread(SoundThread, "PC speaker thread", NULL);
return 1;
}

View file

@ -87,7 +87,8 @@ static int PCSound_Win32_Init(pcsound_callback_func callback_func)
callback = callback_func;
sound_thread_running = 1;
sound_thread_handle = SDL_CreateThread(SoundThread, NULL);
sound_thread_handle =
SDL_CreateThread(SoundThread, "PC speaker thread", NULL);
return 1;
}