mirror of
https://github.com/warmcat/libwebsockets.git
synced 2025-03-16 00:00:07 +01:00
cgi add generic wait as antizombie defence
Signed-off-by: Andy Green <andy@warmcat.com>
This commit is contained in:
parent
4eab21976c
commit
8b02454634
1 changed files with 5 additions and 0 deletions
|
@ -2305,6 +2305,11 @@ lws_cgi_kill_terminated(struct lws_context_per_thread *pt)
|
|||
}
|
||||
#endif
|
||||
|
||||
/* general anti zombie defence */
|
||||
n = waitpid(-1, &status, WNOHANG);
|
||||
if (n > 0)
|
||||
lwsl_notice("%s: anti-zombie wait says %d\n", __func__, n);
|
||||
|
||||
return 0;
|
||||
}
|
||||
#endif
|
||||
|
|
Loading…
Add table
Reference in a new issue