Memory leak in gas do_repeat

* read.c (do_repeat): Free sb on error path.
This commit is contained in:
Alan Modra 2023-03-01 12:48:59 +10:30
parent 3049589885
commit 0eb3224b35

View file

@ -3029,6 +3029,7 @@ do_repeat (size_t count, const char *start, const char *end,
if (!buffer_and_nest (start, end, &one, get_non_macro_line_sb))
{
as_bad (_("%s without %s"), start, end);
sb_kill (&one);
return;
}