Failure to read and write on pseudo semaphores on apple happens routinely on shut down so should not be a quit error, just a warning.
diff --git a/util.c b/util.c
index d04e67b..4f38f0d 100644
--- a/util.c
+++ b/util.c
@@ -1881,7 +1881,7 @@ void cgsem_post(cgsem_t *cgsem)
ret = write(cgsem->pipefd[1], &buf, 1);
if (unlikely(ret == 0))
- quit(1, "Failed to write in cgsem_post");
+ applog(LOG_WARNING, "Failed to write in cgsem_post");
}
void cgsem_wait(cgsem_t *cgsem)
@@ -1891,7 +1891,7 @@ void cgsem_wait(cgsem_t *cgsem)
ret = read(cgsem->pipefd[0], &buf, 1);
if (unlikely(ret == 0))
- quit(1, "Failed to read in cgsem_wait");
+ applog(LOG_WARNING, "Failed to read in cgsem_wait");
}
void cgsem_destroy(cgsem_t *cgsem)