mirror of
https://github.com/swaywm/sway.git
synced 2024-12-28 07:56:31 +01:00
fix memory leak in swaymsg
This commit is contained in:
parent
f35575f71d
commit
a4c1270ef0
1 changed files with 3 additions and 1 deletions
|
@ -308,9 +308,11 @@ int main(int argc, char **argv) {
|
||||||
}
|
}
|
||||||
free(cmdtype);
|
free(cmdtype);
|
||||||
|
|
||||||
char *command = strdup("");
|
char *command = NULL;
|
||||||
if (optind < argc) {
|
if (optind < argc) {
|
||||||
command = join_args(argv + optind, argc - optind);
|
command = join_args(argv + optind, argc - optind);
|
||||||
|
} else {
|
||||||
|
command = strdup("");
|
||||||
}
|
}
|
||||||
|
|
||||||
int ret = 0;
|
int ret = 0;
|
||||||
|
|
Loading…
Reference in a new issue