mirror of
https://github.com/gwenhael-le-moine/sway-patched-tray-menu.git
synced 2024-12-26 21:58:08 +01:00
Fix swaybar crash when there's no status_command
This commit is contained in:
parent
a5cb4cca15
commit
851b442f73
1 changed files with 6 additions and 4 deletions
|
@ -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;
|
||||
|
|
Loading…
Reference in a new issue