summaryrefslogtreecommitdiff
path: root/src/sxwm.c
diff options
context:
space:
mode:
authoruint23 <72694427+uint23@users.noreply.github.com>2025-05-17 21:37:56 +0100
committerGitHub <noreply@github.com>2025-05-17 21:37:56 +0100
commit919ec209e76f947b16cbba8ae25c84679e1a2227 (patch)
treebbd3673333803ca6f13e50ea025f2935c72e8d57 /src/sxwm.c
parentd2b05329c73d035d7e8b2cd5134e096d53b13efd (diff)
parent4730937f2d00844d173cec3bcaa0c0d69c1a4349 (diff)
Merge pull request #18 from bbergeron0/main
Prevent child processes from becoming zombies
Diffstat (limited to 'src/sxwm.c')
-rw-r--r--src/sxwm.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/src/sxwm.c b/src/sxwm.c
index dd779df..dcf8dbf 100644
--- a/src/sxwm.c
+++ b/src/sxwm.c
@@ -17,6 +17,7 @@
#include <err.h>
#include <stdio.h>
#include <limits.h>
+#include <signal.h>
#include <stdlib.h>
#include <string.h>
#include <sys/wait.h>
@@ -1230,6 +1231,8 @@ void setup(void)
evtable[MotionNotify] = hdl_motion;
evtable[PropertyNotify] = hdl_root_property;
scan_existing_windows();
+
+ signal(SIGCHLD, SIG_IGN); /* Prevent child processes from becoming zombies */
}
void setup_atoms(void)