mirror of
https://github.com/libsdl-org/SDL.git
synced 2026-05-04 15:12:47 +02:00
Include stdbool.h when using Visual Studio 2017+
Also cleaned up some incorrect return values from bool functions.
This commit is contained in:
@@ -157,7 +157,7 @@ static void SDL_LockMutex_cs(SDL_Mutex *mutex_) SDL_NO_THREAD_SAFETY_ANALYSIS /
|
||||
static bool SDL_TryLockMutex_cs(SDL_Mutex *mutex_)
|
||||
{
|
||||
SDL_mutex_cs *mutex = (SDL_mutex_cs *)mutex_;
|
||||
return TryEnterCriticalSection(&mutex->cs);
|
||||
return (TryEnterCriticalSection(&mutex->cs) == TRUE);
|
||||
}
|
||||
|
||||
static void SDL_UnlockMutex_cs(SDL_Mutex *mutex_) SDL_NO_THREAD_SAFETY_ANALYSIS // clang doesn't know about NULL mutexes
|
||||
|
||||
Reference in New Issue
Block a user