From 1daf69477e1a7c36a8a57ccc4d7fe6cf70736a88 Mon Sep 17 00:00:00 2001 From: Ryan Dwyer Date: Sun, 6 May 2018 08:16:34 +1000 Subject: Fix PATH setenv() in exec_always --- sway/commands/exec_always.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'sway') diff --git a/sway/commands/exec_always.c b/sway/commands/exec_always.c index b3078640..f631d7d8 100644 --- a/sway/commands/exec_always.c +++ b/sway/commands/exec_always.c @@ -82,7 +82,7 @@ struct cmd_results *cmd_exec_always(int argc, char **argv) { // Append /usr/lib/sway to PATH strcat(path, extra_path); - if (!setenv("PATH", path, 1)) { + if (setenv("PATH", path, 1) == -1) { free(path); wlr_log(L_ERROR, "exec_always: Unable to set PATH"); exit(EXIT_FAILURE); -- cgit v1.2.3