aboutsummaryrefslogtreecommitdiffstats
path: root/sway/commands/bar/mode.c
diff options
context:
space:
mode:
Diffstat (limited to 'sway/commands/bar/mode.c')
-rw-r--r--sway/commands/bar/mode.c3
1 files changed, 1 insertions, 2 deletions
diff --git a/sway/commands/bar/mode.c b/sway/commands/bar/mode.c
index 8b3fb275..d69e910b 100644
--- a/sway/commands/bar/mode.c
+++ b/sway/commands/bar/mode.c
@@ -1,4 +1,3 @@
1#define _POSIX_C_SOURCE 200809L
2#include <string.h> 1#include <string.h>
3#include <strings.h> 2#include <strings.h>
4#include "sway/commands.h" 3#include "sway/commands.h"
@@ -58,7 +57,7 @@ struct cmd_results *bar_cmd_mode(int argc, char **argv) {
58 } 57 }
59 58
60 const char *mode = argv[0]; 59 const char *mode = argv[0];
61 if (config->reading) { 60 if (config->current_bar) {
62 error = bar_set_mode(config->current_bar, mode); 61 error = bar_set_mode(config->current_bar, mode);
63 } else { 62 } else {
64 const char *id = argc == 2 ? argv[1] : NULL; 63 const char *id = argc == 2 ? argv[1] : NULL;