sway

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

commit 970501f05e8a1835b880953888ad3022fb2e9ada
parent a5cb4cca15273f20a218cb96fc4da26e4e8da72c
Author: emersion <contact@emersion.fr>
Date:   Tue, 23 Oct 2018 10:50:36 +0200

Merge pull request #2940 from RyanDwyer/fix-swaybar-crash

Fix swaybar crash when there's no status_command
Diffstat:
Mswaybar/bar.c | 10++++++----
1 file changed, 6 insertions(+), 4 deletions(-)

diff --git a/swaybar/bar.c b/swaybar/bar.c @@ -155,10 +155,12 @@ bool determine_bar_visibility(struct swaybar *bar, bool moving_layer) { if (visible != bar->visible) { bar->visible = visible; - wlr_log(WLR_DEBUG, "Sending %s signal to status command", - visible ? "cont" : "stop"); - kill(bar->status->pid, - visible ? bar->status->cont_signal : bar->status->stop_signal); + if (bar->status) { + wlr_log(WLR_DEBUG, "Sending %s signal to status command", + visible ? "cont" : "stop"); + kill(bar->status->pid, visible ? + bar->status->cont_signal : bar->status->stop_signal); + } } return visible;