Bug in new timer code in SDL 1.1.0

The current implementation of the threaded timer code in SDL 1.1.0 is bogus.
A separate thread for the timer is always started, even if you start the timer
after the event thread has been started by SDL_Init(). This is because
SDL_Init() tries to initialize the timer BEFORE the video/event subsystem.

The following patch fixes it, basically you just need to make sure that the
timers are initialized after the event subsystem.–
Stephane Peter
Programmer
Loki Entertainment Software

“Microsoft has done to computers what McDonald’s has done to gastronomy”
-------------- next part --------------
A non-text attachment was scrubbed…
Name: SDL.c.diff
Type: application/octet-stream
Size: 2198 bytes
Desc: not available
URL: http://lists.libsdl.org/pipermail/sdl-libsdl.org/attachments/20000121/dcb9b0b8/attachment.obj

The current implementation of the threaded timer code in SDL 1.1.0 is bogus.
A separate thread for the timer is always started, even if you start the timer
after the event thread has been started by SDL_Init(). This is because
SDL_Init() tries to initialize the timer BEFORE the video/event subsystem.

The following patch fixes it, basically you just need to make sure that the
timers are initialized after the event subsystem.

Thanks! It’s integrated into the latest 1.1 CVS.

See ya,
-Sam Lantinga (slouken at devolution.com)

Lead Programmer, Loki Entertainment Software–
“Any sufficiently advanced bug is indistinguishable from a feature”
– Rich Kulawiec