From 8823462c4180663806265304a6d0f1419c491f4a Mon Sep 17 00:00:00 2001 From: Con Kolivas Date: Sun, 31 Aug 2014 10:00:39 +1000 Subject: [PATCH] Sanity check on failed startup shutdown combination where child processes never get started --- src/ckpool.c | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/src/ckpool.c b/src/ckpool.c index 090c5b56..c88781ad 100644 --- a/src/ckpool.c +++ b/src/ckpool.c @@ -803,6 +803,10 @@ static void __shutdown_children(ckpool_t *ckp, int sig) cancel_join_pthread(&ckp->pth_watchdog); + /* They never got set up in the first place */ + if (!ckp->children) + return; + for (i = 0; i < ckp->proc_instances; i++) { pid_t pid = ckp->children[i]->pid; if (!kill_pid(pid, 0))