Fixed double-free in libpopen_noshell.

Fixes #3250.
This commit is contained in:
Gunnar Beutner 2012-10-08 13:02:33 +02:00
parent c63a9da326
commit ab5f57ea17
1 changed files with 1 additions and 1 deletions

View File

@ -253,7 +253,7 @@ static int popen_noshell_add_token(char ***argv, int *count, char *start, char *
return 0;
}
#define popen_noshell_split_return_NULL { if (argv != NULL) free(argv); if (command != NULL) free(command); return NULL; }
#define popen_noshell_split_return_NULL { if (argv != NULL) free(argv); if (command != NULL) free(command); *free_this_buf = NULL; return NULL; }
char ** popen_noshell_split_command_to_argv(const char *command_original, char **free_this_buf) {
char *command;
size_t i, len;