Update of /cvsroot/boost/boost/boost/thread/win32
In directory sc8-pr-cvs3.sourceforge.net:/tmp/cvs-serv7220

Modified Files:
      Tag: thread_rewrite
        thread_primitives.hpp 
Log Message:
New look read-write mutex


Index: thread_primitives.hpp
===================================================================
RCS file: /cvsroot/boost/boost/boost/thread/win32/Attic/thread_primitives.hpp,v
retrieving revision 1.1.2.2
retrieving revision 1.1.2.3
diff -u -d -r1.1.2.2 -r1.1.2.3
--- thread_primitives.hpp       27 Apr 2006 14:04:45 -0000      1.1.2.2
+++ thread_primitives.hpp       5 Oct 2006 09:38:31 -0000       1.1.2.3
@@ -32,6 +32,57 @@
     namespace detail
     {
         typedef ULONG_PTR ulong_ptr;
+
+        extern "C"
+        {
+            inline BOOL CloseHandle(HANDLE h)
+            {
+                return ::CloseHandle(h);
+            }
+            inline int ReleaseMutex(HANDLE h)
+            {
+                return ::ReleaseMutex(h);
+            }
+            inline HANDLE CreateMutexA(::_SECURITY_ATTRIBUTES* sa,BOOL 
owner,char const* name)
+            {
+                return ::CreateMutexA(sa,owner,name);
+            }
+            inline HANDLE CreateEventA(LPSECURITY_ATTRIBUTES 
lpEventAttributes,BOOL bManualReset,
+                                                 BOOL bInitialState,LPCSTR 
lpName)
+            {
+                return 
::CreateEventA(lpEventAttributes,bManualReset,bInitialState,lpName);
+            }
+
+            inline BOOL ReleaseSemaphore(HANDLE hSemaphore,LONG 
lReleaseCount,LPLONG lpPreviousCount)
+            {
+                return 
::ReleaseSemaphore(hSemaphore,lReleaseCount,lpPreviousCount);
+            }
+
+            inline HANDLE CreateSemaphoreA(LPSECURITY_ATTRIBUTES 
lpSemaphoreAttributes,LONG lInitialCount,
+                                                     LONG lMaximumCount,LPCSTR 
lpName)
+            {
+                return 
::CreateSemaphoreA(lpSemaphoreAttributes,lInitialCount,lMaximumCount,lpName);
+            }
+            inline BOOL SetEvent(HANDLE hEvent)
+            {
+                return ::SetEvent(hEvent);
+            }
+            inline BOOL ResetEvent(HANDLE hEvent)
+            {
+                return ::ResetEvent(hEvent);
+            }
+
+
+//             inline unsigned long GetCurrentProcessId();
+//             inline unsigned long GetCurrentThreadId();
+//             inline unsigned long WaitForSingleObject(HANDLE,unsigned long);
+//             inline HANDLE GetCurrentThread();
+//             inline HANDLE GetCurrentProcess();
+//             inline int 
DuplicateHandle(HANDLE,HANDLE,HANDLE,HANDLE*,unsigned long,int,unsigned long);
+//             inline unsigned long SleepEx(unsigned long,int);
+//             typedef void (*queue_user_apc_callback_function)(ulong_ptr);
+//             inline unsigned long 
QueueUserAPC(queue_user_apc_callback_function,HANDLE,ulong_ptr);
+        }
     }
 }
 #elif defined( WIN32 ) || defined( _WIN32 ) || defined( __WIN32__ )
@@ -62,6 +113,9 @@
             __declspec(dllimport) unsigned long __stdcall SleepEx(unsigned 
long,int);
             typedef void (__stdcall 
*queue_user_apc_callback_function)(ulong_ptr);
             __declspec(dllimport) unsigned long __stdcall 
QueueUserAPC(queue_user_apc_callback_function,void*,ulong_ptr);
+            __declspec(dllimport) void* 
CreateEventA(_SECURITY_ATTRIBUTES*,int,int,char const*);
+            __declspec(dllimport) int __stdcall SetEvent(void*);
+            __declspec(dllimport) int __stdcall ResetEvent(void*);
         }
     }
 }


-------------------------------------------------------------------------
Take Surveys. Earn Cash. Influence the Future of IT
Join SourceForge.net's Techsay panel and you'll get the chance to share your
opinions on IT & business topics through brief surveys -- and earn cash
http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV
_______________________________________________
Boost-cvs mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/boost-cvs

Reply via email to