Fix some potential memory leaks

This commit is contained in:
Peter Bui
2011-08-08 21:44:39 -04:00
committed by Michael Stapelberg
parent 6fb5d6e313
commit 5e06b1b21d
5 changed files with 11 additions and 3 deletions

View File

@ -39,7 +39,9 @@ void run_assignments(i3Window *window) {
DLOG("execute command %s\n", current->dest.command);
char *full_command;
asprintf(&full_command, "[id=\"%d\"] %s", window->id, current->dest.command);
parse_cmd(full_command);
char *json_result = parse_cmd(full_command);
FREE(full_command);
FREE(json_result);
}
/* Store that we ran this assignment to not execute it again */