aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorTamino Bauknecht <dev@tb6.eu>2023-12-12 14:53:50 +0100
committerSimon Zeni <simon@bl4ckb0ne.ca>2023-12-12 09:39:46 -0500
commit255ff665c53c8d042bce0c4cff4081d2bd35beeb (patch)
tree1da30d1486e27bf8aec6e86037b7d294f11e78e6
parentbf2b79b2845a070d84aafaf95e6cfcf9af7eeb9b (diff)
sway: raise error on non-accessible background file
-rw-r--r--sway/commands/output/background.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/sway/commands/output/background.c b/sway/commands/output/background.c
index 67f212ff..d691295f 100644
--- a/sway/commands/output/background.c
+++ b/sway/commands/output/background.c
@@ -123,7 +123,10 @@ struct cmd_results *output_cmd_background(int argc, char **argv) {
src);
config_add_swaynag_warning("Unable to access background file '%s'",
src);
+ struct cmd_results *result = cmd_results_new(CMD_FAILURE,
+ "unable to access background file '%s'", src);
free(src);
+ return result;
} else {
output->background = src;
output->background_option = strdup(mode);