# HG changeset patch # User Ryan C. Gordon # Date 1127820458 0 # Node ID ab0154afe93892aabaaceb94149a6a046ac76138 # Parent d31afac94eff6a203e8dc2f76a6144e5da12df95 Date: Sat, 17 Sep 2005 13:38:49 +0200 From: Jon Daniel To: sdl@libsdl.org Subject: [SDL] SDL_SemWaitTimeout patch for BeOS The current SDL-1.2.9/src/thread/beos/SDL_syssem.c returns -1 if the acquire_sem timeouts which according to the DocWiki is not correct. I've added support for the B_TIMED_OUT and B_WOULD_BLOCK in the switch. Jon Daniel diff -r d31afac94eff -r ab0154afe938 src/thread/beos/SDL_syssem.c --- a/src/thread/beos/SDL_syssem.c Tue Sep 27 09:00:42 2005 +0000 +++ b/src/thread/beos/SDL_syssem.c Tue Sep 27 11:27:38 2005 +0000 @@ -90,6 +90,12 @@ case B_NO_ERROR: retval = 0; break; + case B_TIMED_OUT: + retval = SDL_MUTEX_TIMEDOUT; + break; + case B_WOULD_BLOCK: + retval = SDL_MUTEX_TIMEDOUT; + break; default: SDL_SetError("acquire_sem() failed"); retval = -1;