]> git.lyx.org Git - lyx.git/blobdiff - boost/boost/detail/lwm_win32_cs.hpp
boost: add eol property
[lyx.git] / boost / boost / detail / lwm_win32_cs.hpp
index c4547de84e7a89ec4ea5cfdf4d9e400a7194ba7b..8142069e67b3aef720208e3d131fad588e7a3c5b 100644 (file)
 //
 //  Copyright (c) 2002, 2003 Peter Dimov
 //
-//  Permission to copy, use, modify, sell and distribute this software
-//  is granted provided this copyright notice appears in all copies.
-//  This software is provided "as is" without express or implied
-//  warranty, and with no claim as to its suitability for any purpose.
+// Distributed under the Boost Software License, Version 1.0. (See
+// accompanying file LICENSE_1_0.txt or copy at
+// http://www.boost.org/LICENSE_1_0.txt)
 //
 
 #ifdef BOOST_USE_WINDOWS_H
@@ -30,7 +29,7 @@ namespace detail
 
 #ifndef BOOST_USE_WINDOWS_H
 
-struct CRITICAL_SECTION
+struct critical_section
 {
     struct critical_section_debug * DebugInfo;
     long LockCount;
@@ -44,10 +43,14 @@ struct CRITICAL_SECTION
 #endif
 };
 
-extern "C" __declspec(dllimport) void __stdcall InitializeCriticalSection(CRITICAL_SECTION *);
-extern "C" __declspec(dllimport) void __stdcall EnterCriticalSection(CRITICAL_SECTION *);
-extern "C" __declspec(dllimport) void __stdcall LeaveCriticalSection(CRITICAL_SECTION *);
-extern "C" __declspec(dllimport) void __stdcall DeleteCriticalSection(CRITICAL_SECTION *);
+extern "C" __declspec(dllimport) void __stdcall InitializeCriticalSection(critical_section *);
+extern "C" __declspec(dllimport) void __stdcall EnterCriticalSection(critical_section *);
+extern "C" __declspec(dllimport) void __stdcall LeaveCriticalSection(critical_section *);
+extern "C" __declspec(dllimport) void __stdcall DeleteCriticalSection(critical_section *);
+
+#else
+
+typedef ::CRITICAL_SECTION critical_section;
 
 #endif // #ifndef BOOST_USE_WINDOWS_H
 
@@ -55,7 +58,7 @@ class lightweight_mutex
 {
 private:
 
-    CRITICAL_SECTION cs_;
+    critical_section cs_;
 
     lightweight_mutex(lightweight_mutex const &);
     lightweight_mutex & operator=(lightweight_mutex const &);