[SDL] failure at SDL_AddEvent()
Chris Thielen
chris at luethy.net
Sat Nov 9 14:41:01 PST 2002
hello,
in my attempts to use SDL timers in my code, I have a structure which
contains a SDL_Event variable and a timer callback:
static Uint32 sdl_timer_callback(ep_session *session) {
SDL_PushEvent(&session->event);
return (55);
}
which uses SDL_PushEvent() to push an event into that structure's event.
The only thing in the main thread is SDL_WaitEvent(), and for some
reason, when SDL_PushEvent() is run, the code seg faults, and a
backtrace shows it's in SDL_AddEvent(). Am I missing something here? I
thought it was always safe to call SDL_PushEvent() from a SDL timer
callback.
--
Chris Thielen <chris at luethy.net>
More information about the SDL
mailing list