changeset 5028:fffb33ae85e8

Whoops, good catch from Greg Jandl
author Sam Lantinga <slouken@libsdl.org>
date Tue, 18 Jan 2011 22:10:37 -0800
parents 8c33dd30f6a6
children 5d7d48157be7
files src/atomic/SDL_spinlock.c
diffstat 1 files changed, 1 insertions(+), 9 deletions(-) [+]
line wrap: on
line diff
--- a/src/atomic/SDL_spinlock.c	Tue Jan 18 17:23:44 2011 -0800
+++ b/src/atomic/SDL_spinlock.c	Tue Jan 18 22:10:37 2011 -0800
@@ -24,20 +24,12 @@
 #include "SDL_atomic.h"
 #include "SDL_timer.h"
 
-#if defined(__WIN32__)
-#include <intrin.h>
-
-#elif defined(__MACOSX__)
-#include <libkern/OSAtomic.h>
-
-#endif
-
 
 /* This function is where all the magic happens... */
 SDL_bool
 SDL_AtomicTryLock(SDL_SpinLock *lock)
 {
-#if defined(__WIN32__)
+#if defined(_MSC_VER)
     SDL_COMPILE_TIME_ASSERT(locksize, sizeof(*lock) == sizeof(long));
     return (_InterlockedExchange((long*)lock, 1) == 0);