From f763cb37885b02c310aa906147669a29b99405dc Mon Sep 17 00:00:00 2001 From: Jay Sorg Date: Wed, 17 Jan 2018 11:09:09 -0800 Subject: [PATCH] fix for zombie processes sometimes appearing --- xrdp/xrdp.c | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/xrdp/xrdp.c b/xrdp/xrdp.c index adf182b9..65bd40a0 100644 --- a/xrdp/xrdp.c +++ b/xrdp/xrdp.c @@ -123,7 +123,11 @@ xrdp_shutdown(int sig) void xrdp_child(int sig) { - g_waitchild(); + int safety; + + for (safety = 0; (g_waitchild() >= 0) && (safety <= 10); safety++) + { + } } /*****************************************************************************/