aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--src/windows.c3
1 files changed, 1 insertions, 2 deletions
diff --git a/src/windows.c b/src/windows.c
index 0139441..17bcf6e 100644
--- a/src/windows.c
+++ b/src/windows.c
@@ -1,6 +1,5 @@
/* Standard C headers */
#include <assert.h>
-#include <limits.h>
#include <stdbool.h>
#include <stdint.h>
#include <stdlib.h>
@@ -352,7 +351,7 @@ void pthreadpool_destroy(struct pthreadpool* threadpool) {
const BOOL close_status = CloseHandle(threadpool->command_event[i]);
assert(close_status != FALSE);
}
- if (threadpool->completion_event != NULL) {
+ if (threadpool->completion_event[i] != NULL) {
const BOOL close_status = CloseHandle(threadpool->completion_event[i]);
assert(close_status != FALSE);
}