diff options
author | taiyu <taiyu.len@gmail.com> | 2015-10-08 08:12:31 -0700 |
---|---|---|
committer | taiyu <taiyu.len@gmail.com> | 2015-10-08 08:12:31 -0700 |
commit | 18f4905e62e1fb2042abd79b2a4c756187e3d506 (patch) | |
tree | 08b4326d5e5b69b8b91e842ccc63a57b7f6f79fb /sway/main.c | |
parent | Merge pull request #189 from SirCmpwn/revert-188-master (diff) | |
download | sway-18f4905e62e1fb2042abd79b2a4c756187e3d506.tar.gz sway-18f4905e62e1fb2042abd79b2a4c756187e3d506.tar.zst sway-18f4905e62e1fb2042abd79b2a4c756187e3d506.zip |
#187, let init handle child processes
Diffstat (limited to 'sway/main.c')
-rw-r--r-- | sway/main.c | 9 |
1 files changed, 0 insertions, 9 deletions
diff --git a/sway/main.c b/sway/main.c index 66921184..de17f440 100644 --- a/sway/main.c +++ b/sway/main.c | |||
@@ -22,8 +22,6 @@ void sway_terminate(void) { | |||
22 | wlc_terminate(); | 22 | wlc_terminate(); |
23 | } | 23 | } |
24 | 24 | ||
25 | static void sigchld_handle(int signal); | ||
26 | |||
27 | static void wlc_log_handler(enum wlc_log_type type, const char *str) { | 25 | static void wlc_log_handler(enum wlc_log_type type, const char *str) { |
28 | if (type == WLC_LOG_ERROR) { | 26 | if (type == WLC_LOG_ERROR) { |
29 | sway_log(L_ERROR, "[wlc] %s", str); | 27 | sway_log(L_ERROR, "[wlc] %s", str); |
@@ -64,9 +62,6 @@ int main(int argc, char **argv) { | |||
64 | {0, 0, 0, 0} | 62 | {0, 0, 0, 0} |
65 | }; | 63 | }; |
66 | 64 | ||
67 | /* Signal handling */ | ||
68 | signal(SIGCHLD, sigchld_handle); | ||
69 | |||
70 | setenv("WLC_DIM", "0", 0); | 65 | setenv("WLC_DIM", "0", 0); |
71 | 66 | ||
72 | wlc_log_set_handler(wlc_log_handler); | 67 | wlc_log_set_handler(wlc_log_handler); |
@@ -153,7 +148,3 @@ int main(int argc, char **argv) { | |||
153 | return 0; | 148 | return 0; |
154 | } | 149 | } |
155 | 150 | ||
156 | void sigchld_handle(int signal) { | ||
157 | (void) signal; | ||
158 | while (waitpid((pid_t)-1, 0, WNOHANG) > 0); | ||
159 | } | ||