On 10/23/26 12:24 PM, Yalagada Pavan Kumar wrote:
On Thu, Oct 22, 2026 at 09:30:26AM -0400, Julia Lawall wrote:
On Thu, 22 Oct 2026, Alex Elder wrote:
On 10/21/26 11:34 AM,pavankumaryalagada@gmail.com wrote:
From: Yalagada Pavan Kumarpavankumaryalagada@gmail.com
Unsigned variables are printed using %d. Replace them with %u to match their types.
Signed-off-by: Yalagada Pavan Kumarpavankumaryalagada@gmail.com
I have reviewed every one of these and they look good. Quite a few of them--because the size of the value being formatted is less than 32 bits--would print correctly no matter what their value. But I think it at least does no harm to convert the format specifier to unsigned in all of these cases.
I was suprised the compiler doesn't complain about this. It seems to complain a lot about type-related format specifiers. Yalagada maybe it could be worth adding something clearly invalid in one of the argument lists to see if the code is actually getting compiled, or if you need to set some config option to make that happen.
The files compiled sucessfully with the normal build settings. I also enabled -Wformat-signedness to check for format mismatchse, as this check is not enabled by default. It revealed a few more issues, which i'll look into as well.
I think you might find that "sparse" complains. Run your build with "C=1" to run (by default) sparse, and see if it says something.
-Alex
Pavan
julia