sway

i3-compatible Wayland compositor
git clone https://git.awy.one/sway
Log | Files | Refs | README | LICENSE

commit 16e20ec251b027c5a8dbc5e85804012f2602629d
parent 154cc8a9c30a8eddb140102a095e3b5dc84bb8f9
Author: Drew DeVault <sir@cmpwn.com>
Date:   Mon, 12 Jun 2017 18:03:25 -0400

Merge pull request #1236 from ykrivopalov/fix_complex_status_command

swaybar: Group child processes for signalling
Diffstat:
Mswaybar/bar.c | 3++-
1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/swaybar/bar.c b/swaybar/bar.c @@ -34,6 +34,7 @@ static void spawn_status_cmd_proc(struct bar *bar) { close(pipefd[0]); dup2(pipefd[1], STDOUT_FILENO); close(pipefd[1]); + setpgid(bar->status_command_pid, 0); char *const cmd[] = { "sh", "-c", @@ -274,7 +275,7 @@ static void free_outputs(list_t *outputs) { static void terminate_status_command(pid_t pid) { if (pid) { // terminate status_command process - int ret = kill(pid, SIGTERM); + int ret = killpg(pid, SIGTERM); if (ret != 0) { sway_log(L_ERROR, "Unable to terminate status_command [pid: %d]", pid); } else {