Boost logo

Boost-Commit :

Subject: [Boost-commit] svn:boost r60722 - trunk/boost/asio/detail
From: chris_at_[hidden]
Date: 2010-03-19 19:57:51


Author: chris_kohlhoff
Date: 2010-03-19 19:57:50 EDT (Fri, 19 Mar 2010)
New Revision: 60722
URL: http://svn.boost.org/trac/boost/changeset/60722

Log:
WinCE doesn't provide InitializeCriticalSectionAndSpinCount.

Text files modified:
   trunk/boost/asio/detail/win_mutex.hpp | 8 ++++++++
   1 files changed, 8 insertions(+), 0 deletions(-)

Modified: trunk/boost/asio/detail/win_mutex.hpp
==============================================================================
--- trunk/boost/asio/detail/win_mutex.hpp (original)
+++ trunk/boost/asio/detail/win_mutex.hpp 2010-03-19 19:57:50 EDT (Fri, 19 Mar 2010)
@@ -84,12 +84,20 @@
 #if defined(__MINGW32__)
     // Not sure if MinGW supports structured exception handling, so for now
     // we'll just call the Windows API and hope.
+# if defined(UNDER_CE)
+ ::InitializeCriticalSection(&crit_section_);
+# else
     ::InitializeCriticalSectionAndSpinCount(&crit_section_, 0x80000000);
+# endif
     return 0;
 #else
     __try
     {
+# if defined(UNDER_CE)
+ ::InitializeCriticalSection(&crit_section_);
+# else
       ::InitializeCriticalSectionAndSpinCount(&crit_section_, 0x80000000);
+# endif
     }
     __except(GetExceptionCode() == STATUS_NO_MEMORY
         ? EXCEPTION_EXECUTE_HANDLER : EXCEPTION_CONTINUE_SEARCH)


Boost-Commit list run by bdawes at acm.org, david.abrahams at rcn.com, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk