[PATCH] io: ftw: Use state stack instead of recursion (BZ 33882)
Adhemerval Zanella Netto
adhemerval.zanella@linaro.org
Thu Feb 19 12:16:44 GMT 2026
On 19/02/26 08:42, Andreas Schwab wrote:
> On Feb 18 2026, Adhemerval Zanella wrote:
>
>> +static struct ftw_frame *
>> +stack_top(struct ftw_data *data)
>> +{
>> + if (data->stack_size == 0)
>> + return NULL;
>
> I think this should be an assertion, this and stack_pop should never be
> called with an empty stack. The uses of stack_top don't check for NULL
> anyway.
>
Agreed, I will change it.
More information about the Libc-alpha
mailing list