update old_string on failure in ftepp_macro_expand to not segfault on a preprocessor-error inside recursive preprocessor calls

This commit is contained in:
Wolfgang Bumiller 2013-01-02 10:44:39 +01:00
parent c7280fca52
commit dce7a0c72b

View file

@ -652,6 +652,7 @@ static bool ftepp_macro_expand(ftepp_t *ftepp, ppmacro *macro, macroparam *param
ftepp->lex = inlex;
ftepp_recursion_header(ftepp);
if (!ftepp_preprocess(ftepp)) {
old_string = ftepp->output_string;
lex_close(ftepp->lex);
retval = false;
goto cleanup;