[ccan] New warning with GCC 4.6: -Wunused-but-set-variable
Joseph Adams
joeyadams3.14159 at gmail.com
Sun May 29 12:30:44 EST 2011
I tried running `make -j2 check' on CCAN in Fedora 15 (which has GCC
4.6.0), and it failed because of a warning in some of the tests:
Module tests compile (tests_compile): FAIL
/home/joey/ccan/ccan/cast/test/compile_fail-cast_const.c:Compile gave
warnings without -DFAIL:
/home/joey/ccan/ccan/cast/test/compile_fail-cast_const.c: In function ‘main’:
/home/joey/ccan/ccan/cast/test/compile_fail-cast_const.c:11:8:
warning: variable ‘uc’ set but not used [-Wunused-but-set-variable]
The attached patch fixes these warnings. Otherwise, `make check'
works on Fedora 15.
Joey
-------------- next part --------------
A non-text attachment was scrubbed...
Name: 0001-cast-container_of-tlist-Fix-warning-with-GCC-4.6-Wun.patch
Type: text/x-patch
Size: 6984 bytes
Desc: not available
URL: <http://lists.ozlabs.org/pipermail/ccan/attachments/20110528/d890690b/attachment.bin>
More information about the ccan
mailing list