From fb80276084a9adc0014b1008f8bf8253f126293b Mon Sep 17 00:00:00 2001 From: Egor Tensin Date: Thu, 8 Jun 2023 23:57:49 +0200 Subject: add {file,net}_close as a wrapper to close(2) --- src/worker_queue.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'src/worker_queue.c') diff --git a/src/worker_queue.c b/src/worker_queue.c index 06119e2..b0dda38 100644 --- a/src/worker_queue.c +++ b/src/worker_queue.c @@ -7,11 +7,11 @@ #include "worker_queue.h" #include "log.h" +#include "net.h" #include #include #include -#include struct worker { pthread_t thread; @@ -38,7 +38,7 @@ void worker_destroy(struct worker *entry) { log("Waiting for worker %d thread to exit\n", entry->fd); pthread_errno_if(pthread_join(entry->thread, NULL), "pthread_join"); - log_errno_if(close(entry->fd), "close"); + net_close(entry->fd); free(entry); } -- cgit v1.2.3