From: José Fonseca Date: Sun, 6 Mar 2011 09:10:38 +0000 (+0000) Subject: os: Fix pipe_static_mutex on Windows. X-Git-Tag: 062012170305~6767 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=db6d0d9ebf20bfc16ebabd3ff9e8f560ac306210;p=profile%2Fivi%2Fmesa.git os: Fix pipe_static_mutex on Windows. --- diff --git a/src/gallium/auxiliary/os/os_thread.h b/src/gallium/auxiliary/os/os_thread.h index a084310..8173d4c 100644 --- a/src/gallium/auxiliary/os/os_thread.h +++ b/src/gallium/auxiliary/os/os_thread.h @@ -152,8 +152,9 @@ static INLINE int pipe_thread_destroy( pipe_thread thread ) */ typedef CRITICAL_SECTION pipe_mutex; +/* http://locklessinc.com/articles/pthreads_on_windows/ */ #define pipe_static_mutex(mutex) \ - /*static*/ pipe_mutex mutex = {0,0,0,0,0,0} + static pipe_mutex mutex = {(PCRITICAL_SECTION_DEBUG)-1, -1, 0, 0, 0, 0} #define pipe_mutex_init(mutex) \ InitializeCriticalSection(&mutex)