From c6eaa53c3739ea2fb39a088e50bfa142b1cdb136 Mon Sep 17 00:00:00 2001 From: jcorgan Date: Sat, 4 Nov 2006 21:38:39 +0000 Subject: Fixes ticket:95. git-svn-id: http://gnuradio.org/svn/gnuradio/trunk@3936 221aa14e-8319-0410-a670-987f0aec2ac5 --- gnuradio-core/src/lib/omnithread/nt.cc | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) (limited to 'gnuradio-core') diff --git a/gnuradio-core/src/lib/omnithread/nt.cc b/gnuradio-core/src/lib/omnithread/nt.cc index 644501a35..03398aaa7 100644 --- a/gnuradio-core/src/lib/omnithread/nt.cc +++ b/gnuradio-core/src/lib/omnithread/nt.cc @@ -32,6 +32,7 @@ #include #include +#include #include #include @@ -385,7 +386,8 @@ omni_semaphore::trywait(void) void omni_semaphore::post(void) { - if (!ReleaseSemaphore(nt_sem, 1, NULL)) + if (!ReleaseSemaphore(nt_sem, 1, NULL) + && GetLastError() != ERROR_TOO_MANY_POSTS ) // MinGW fix by Don Ward throw omni_thread_fatal(GetLastError()); } -- cgit