diff options
author | Adam <adam@sigterm.info> | 2012-10-12 14:50:05 -0700 |
---|---|---|
committer | Adam <adam@sigterm.info> | 2012-10-12 14:50:05 -0700 |
commit | c05ad37bfd03486475889485606ed5cffc7bf5a2 (patch) | |
tree | fe01825889769500a0f080371a0714aa15505b9a /include/threadengines/threadengine_win32.h | |
parent | e496d321efe3e9b27f2f116bd22a05ec44aec564 (diff) | |
parent | 5b9682275e384635a1fd9f7320cf4d9a604a43b4 (diff) |
Merge pull request #320 from ChrisTX/insp20+cleanupwin
Windows: In-depth cleanup (see details)
Diffstat (limited to 'include/threadengines/threadengine_win32.h')
-rw-r--r-- | include/threadengines/threadengine_win32.h | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/include/threadengines/threadengine_win32.h b/include/threadengines/threadengine_win32.h index 9ca180cef..f068ac707 100644 --- a/include/threadengines/threadengine_win32.h +++ b/include/threadengines/threadengine_win32.h @@ -108,12 +108,15 @@ class ThreadQueueData public: ThreadQueueData() { - InitializeCriticalSection(&mutex); event = CreateEvent(NULL, false, false, NULL); + if (event == NULL) + throw CoreException("CreateEvent() failed in ThreadQueueData::ThreadQueueData()!"); + InitializeCriticalSection(&mutex); } ~ThreadQueueData() { + CloseHandle(event); DeleteCriticalSection(&mutex); } |