mirror of
https://github.com/swaywm/sway.git
synced 2025-11-10 13:29:51 -05:00
#187, let init handle child processes
This commit is contained in:
parent
d2680ac8fe
commit
18f4905e62
2 changed files with 12 additions and 13 deletions
|
|
@ -22,8 +22,6 @@ void sway_terminate(void) {
|
|||
wlc_terminate();
|
||||
}
|
||||
|
||||
static void sigchld_handle(int signal);
|
||||
|
||||
static void wlc_log_handler(enum wlc_log_type type, const char *str) {
|
||||
if (type == WLC_LOG_ERROR) {
|
||||
sway_log(L_ERROR, "[wlc] %s", str);
|
||||
|
|
@ -64,9 +62,6 @@ int main(int argc, char **argv) {
|
|||
{0, 0, 0, 0}
|
||||
};
|
||||
|
||||
/* Signal handling */
|
||||
signal(SIGCHLD, sigchld_handle);
|
||||
|
||||
setenv("WLC_DIM", "0", 0);
|
||||
|
||||
wlc_log_set_handler(wlc_log_handler);
|
||||
|
|
@ -153,7 +148,3 @@ int main(int argc, char **argv) {
|
|||
return 0;
|
||||
}
|
||||
|
||||
void sigchld_handle(int signal) {
|
||||
(void) signal;
|
||||
while (waitpid((pid_t)-1, 0, WNOHANG) > 0);
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue