From 1fd2c6ba498e61f4fe823bf552f9d2fce8612de4 Mon Sep 17 00:00:00 2001 From: Brian Ashworth Date: Mon, 2 Sep 2019 21:41:11 -0400 Subject: swaybar: complete barconfig_update event handling This adds complete support for the barconfig_update ipc event. This also changes the bar command and subcommand handlers to correctly emit the event. This makes it so all bar subcommands other than id and swaybar_command are dynamically changeable at runtime. sway-bar.5 has been updated accordingly --- swaybar/status_line.c | 3 +++ 1 file changed, 3 insertions(+) (limited to 'swaybar/status_line.c') diff --git a/swaybar/status_line.c b/swaybar/status_line.c index 342f981e..2a9e1da8 100644 --- a/swaybar/status_line.c +++ b/swaybar/status_line.c @@ -5,6 +5,8 @@ #include #include #include +#include +#include #include #include "log.h" #include "loop.h" @@ -174,6 +176,7 @@ struct status_line *status_line_init(char *cmd) { void status_line_free(struct status_line *status) { status_line_close_fds(status); kill(status->pid, SIGTERM); + waitpid(status->pid, NULL, 0); if (status->protocol == PROTOCOL_I3BAR) { struct i3bar_block *block, *tmp; wl_list_for_each_safe(block, tmp, &status->blocks, link) { -- cgit v1.2.3