mirror of
https://github.com/mirror/tinycc.git
synced 2024-12-26 03:50:07 +08:00
tccgen: free inline functions correctly
This commit is contained in:
parent
697f9e305d
commit
0d34c2136e
6
tccgen.c
6
tccgen.c
@ -4945,13 +4945,17 @@ static void gen_inline_functions(void)
|
||||
gen_function(sym);
|
||||
macro_ptr = NULL; /* fail safe */
|
||||
|
||||
tok_str_free(str);
|
||||
inline_generated = 1;
|
||||
}
|
||||
}
|
||||
if (!inline_generated)
|
||||
break;
|
||||
}
|
||||
for (i = 0; i < tcc_state->nb_inline_fns; ++i) {
|
||||
fn = tcc_state->inline_fns[i];
|
||||
str = fn->token_str;
|
||||
tok_str_free(str);
|
||||
}
|
||||
dynarray_reset(&tcc_state->inline_fns, &tcc_state->nb_inline_fns);
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user