Fix various problems with the timer code.
* SDL_timer_running wasn't always updated correctly. * Fixed occasional crash in SDL_SetTimer() when clearing threaded timers * It was possible to get both the timer thread and event thread running * Other misc. cleanup --HG-- extra : convert_revision : svn%3Ac70aab31-4412-0410-b14c-859654838e24/trunk%401029
This commit is contained in:
parent
74c5533520
commit
37382b468c
3 changed files with 70 additions and 65 deletions
|
@ -81,6 +81,8 @@ typedef Uint32 (SDLCALL *SDL_TimerCallback)(Uint32 interval);
|
|||
* in the same program, as it is implemented using setitimer(). You also
|
||||
* should not use this function in multi-threaded applications as signals
|
||||
* to multi-threaded apps have undefined behavior in some implementations.
|
||||
*
|
||||
* This function returns 0 if successful, or -1 if there was an error.
|
||||
*/
|
||||
extern DECLSPEC int SDLCALL SDL_SetTimer(Uint32 interval, SDL_TimerCallback callback);
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue