Re: [PATCH 4/4] lib/vsprintf: add missing (u8) cast in format_decode() lookup

Andy Shevchenko
2026-03-25T12:02:33Z

On Tue, Mar 24, 2026 at 10:49:40PM +0000, Josh Law wrote:
> The first lookup into the format_state table correctly casts to (u8)
> at line 2778, but the second lookup after consuming a length qualifier
> does not. On signed-char platforms, a byte >= 0x80 sign-extends to a
> negative index, reading before the array.
>
> Add the same (u8) cast for consistency.

Maybe yes, but get familiar on how the Linux kernel is built.
There is no such possibility IRL with this project since a commit
in the past. Feel free to find what I meant as your learning curve.

--
With Best Regards,
Andy Shevchenko