Commit 17254837 authored by Ryan C. Gordon's avatar Ryan C. Gordon

From: Jim Paris <jim_jtan_com>

To: sdl@libsdl.org
Date: Sat, 9 Jul 2005 13:59:33 -0400
Subject: [PATCH] fix locking in src/timer/SYS_timer.c

SDL_SetTimer has a typo in CVS.  This code was added since 1.2.8.  The
result is that the SDL_timer_mutex is locked twice and never unlocked,
breaking systems that use a threaded timer implementation.

-jim

--HG--
extra : convert_revision : svn%3Ac70aab31-4412-0410-b14c-859654838e24/trunk%401118
parent afa9f374
......@@ -287,7 +287,7 @@ int SDL_SetTimer(Uint32 ms, SDL_TimerCallback callback)
}
}
if ( SDL_timer_threaded ) {
SDL_mutexP(SDL_timer_mutex);
SDL_mutexV(SDL_timer_mutex);
}
return retval;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment