Closed ao2 closed 10 years ago
Thank you, Antonio! I fixed a bunch of other Clang warnings as well.
Great.
About the other warnings: casting in printf can often be avoided by picking the right format argument, but I don't know the specifics here, so I trust you.
BTW, what would be the best way to add stricter compilation flags to hidrd? (-std=c99 -pedantic
, etc.)? I see that you reset CFLAGS in an unusual way in configure.ac, IIRC Makefile.am is the standard location for CFLAGS (re)definition.
Thanks for the printf hint. In this case (0beaf93138c19f8a17300992a943a85c12b9f8c5) Clang was complaining about (promoted?) constant arguments which were actually supposed to be of specific types to which the commit casts them, so in my understanding this is correct.
The particular way CFLAGS is handled was a rather mindless carry-over from projects at work at the time. I should probably rethink it, read some docs and do it in a less unusual and a more useful way. Thanks for the comment. Meanwhile you'll probably need to repeat the default CFLAGS on the make command line if you want to add them.
Hi,
I was playing with warning flags and other compilers, and
clang -Wall
gives some warnings:In enum hidrd_item_pfx_size you never set a value to 4.
There are other similar warnings.