commit 5fdffea99ac5fcfd3618256a0291c9ff71cb1480
parent e9c77970fa23a7eda88fc0dde684961e3caca5e9
Author: Rouven Czerwinski <rouven@czerwinskis.de>
Date: Mon, 5 Nov 2018 20:28:59 +0100
commands/exec_always: defer command on config validation
The exec_always command was executed twice, since it was not checking for the
config->validating variable.
Fix this by defering the command if the configuration is validating.
Fixes #3072
Diffstat:
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/sway/commands/exec_always.c b/sway/commands/exec_always.c
@@ -15,7 +15,7 @@
struct cmd_results *cmd_exec_always(int argc, char **argv) {
struct cmd_results *error = NULL;
- if (!config->active) return cmd_results_new(CMD_DEFER, NULL, NULL);
+ if (!config->active || config->validating) return cmd_results_new(CMD_DEFER, NULL, NULL);
if ((error = checkarg(argc, argv[-1], EXPECTED_AT_LEAST, 1))) {
return error;
}