diff options
Diffstat (limited to 'swaymsg')
-rw-r--r-- | swaymsg/main.c | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/swaymsg/main.c b/swaymsg/main.c index dfc175a8..b431872a 100644 --- a/swaymsg/main.c +++ b/swaymsg/main.c @@ -308,9 +308,11 @@ int main(int argc, char **argv) { } free(cmdtype); - char *command = strdup(""); + char *command = NULL; if (optind < argc) { command = join_args(argv + optind, argc - optind); + } else { + command = strdup(""); } int ret = 0; |