Log exec failures

This can happen when the swaybar or its status command isn't found.
Instead of silently doing nothing, log the error.
This commit is contained in:
Simon Ser 2021-09-12 09:05:46 +02:00
parent 30c28ff8f7
commit c2c15b5625
2 changed files with 4 additions and 0 deletions

View file

@ -168,6 +168,8 @@ struct status_line *status_line_init(char *cmd) {
char *const _cmd[] = { "sh", "-c", cmd, NULL, };
execvp(_cmd[0], _cmd);
sway_log(SWAY_ERROR, "Failed to start status command");
exit(1);
}