diff --git a/process.c b/process.c index abb777b..f55826a 100644 --- a/process.c +++ b/process.c @@ -123,7 +123,8 @@ process_handle_child_termination(int signal) else break; } - number_of_children--; + if (number_of_children) + number_of_children--; remove_process_info(pid); } }