]> git.sesse.net Git - vlc/commitdiff
WinCE: missing threading functions
authorGeoffroy Couprie <geo.couprie@gmail.com>
Wed, 1 Oct 2008 13:28:04 +0000 (15:28 +0200)
committerGeoffroy Couprie <geo.couprie@gmail.com>
Wed, 1 Oct 2008 13:28:04 +0000 (15:28 +0200)
include/vlc_threads.h
src/misc/threads.c

index 4050150378b29c07f593f419f05584cbeee091f4..00e5b18e5dcb826abfef5073f45d8ee10db55bda 100644 (file)
@@ -356,7 +356,12 @@ typedef CRITICAL_SECTION vlc_spinlock_t;
  */
 static inline int vlc_spin_init (vlc_spinlock_t *spin)
 {
+#ifdef UNDER_CE
+    InitializeCriticalSection(spin);
+    return 0;
+#else
     return !InitializeCriticalSectionAndSpinCount(spin, 4000);
+#endif
 }
 
 /**
index b2f52a343b5d18f75f1b7b9eae7b66483deed338..72022d5d67c0a3f2c5dad83055413a469e9536d4 100644 (file)
@@ -1061,6 +1061,8 @@ void vlc_control_cancel (int cmd, ...)
 #endif
 #if defined (LIBVLC_USE_PTHREAD)
                 pthread_exit (PTHREAD_CANCELLED);
+#elif defined (UNDER_CE)
+                ExitThread(0);
 #elif defined (WIN32)
                 _endthread ();
 #else