From: Wolfgang Bumiller Date: Wed, 2 Jan 2013 09:45:55 +0000 (+0100) Subject: fix a leak: delete the output string of macro calls X-Git-Tag: before-library~395 X-Git-Url: https://git.xonotic.org/?p=xonotic%2Fgmqcc.git;a=commitdiff_plain;h=3c212c8389318db13c536fe85a29dad11633522c fix a leak: delete the output string of macro calls --- diff --git a/ftepp.c b/ftepp.c index d9197e5..10c945e 100644 --- a/ftepp.c +++ b/ftepp.c @@ -652,11 +652,13 @@ static bool ftepp_macro_expand(ftepp_t *ftepp, ppmacro *macro, macroparam *param ftepp->lex = inlex; ftepp_recursion_header(ftepp); if (!ftepp_preprocess(ftepp)) { + vec_free(ftepp->lex->open_string); old_string = ftepp->output_string; lex_close(ftepp->lex); retval = false; goto cleanup; } + vec_free(ftepp->lex->open_string); ftepp_recursion_footer(ftepp); old_string = ftepp->output_string;