Current gcc warnings on ia64, hppa and sparc
Julien ÉLIE
julien at trigofacile.com
Thu Jun 27 20:55:02 UTC 2013
Hi all,
As a few servers of the GCC Compile Farm are shutdown on June, 30th because of difficulties in their maintenance, I have just run a last build of CURRENT.
These servers were pretty interesting: Debian ia64 (HP zx6000), Debian hppa (HP 9000/785/J6000), Debian sparc (Sun Enterprise 4500) and OpenBSD 5.1 sparc64 (Sun V210) are not easy to find for testing!
Here are the points that need investigating. I write this mail to keep a trace of them.
Besides, a few components are shared with C TAP Harness and rra-c-util, so maybe it could be worthwhile fixing the issues there too.
network.c: In function 'network_sockaddr_sprint':
network.c:648: warning: cast increases required alignment of target type
network.c:662: warning: cast increases required alignment of target type
network.c: In function 'network_sockaddr_equal':
network.c:680: warning: cast increases required alignment of target type
network.c:681: warning: cast increases required alignment of target type
network.c:684: warning: cast increases required alignment of target type
network.c:685: warning: cast increases required alignment of target type
network.c:692: warning: cast increases required alignment of target type
network.c:693: warning: cast increases required alignment of target type
network.c: In function 'network_sockaddr_port':
network.c:729: warning: cast increases required alignment of target type
network.c:736: warning: cast increases required alignment of target type
rc.c: In function 'GoodIdent':
rc.c:152: warning: cast increases required alignment of target type
rc.c:153: warning: cast increases required alignment of target type
rc.c:154: warning: cast increases required alignment of target type
rc.c:155: warning: cast increases required alignment of target type
rc.c:161: warning: cast increases required alignment of target type
rc.c:162: warning: cast increases required alignment of target type
rc.c:163: warning: cast increases required alignment of target type
rc.c:164: warning: cast increases required alignment of target type
buffindexed/buffindexed.c: In function 'buffindexed_open':
buffindexed/buffindexed.c:1050: warning: cast increases required alignment of target type
buffindexed/buffindexed.c: In function 'GROUPremapifneeded':
buffindexed/buffindexed.c:1205: warning: cast increases required alignment of target type
buffindexed/buffindexed.c: In function 'GROUPexpand':
buffindexed/buffindexed.c:1240: warning: cast increases required alignment of target type
buffindexed/buffindexed.c: In function 'ovgroupmmap':
buffindexed/buffindexed.c:1666: warning: cast increases required alignment of target type
timecaf/timecaf.c: In function 'PathNumToToken':
timecaf/timecaf.c:193: warning: cast increases required alignment of target type
timehash/timehash.c: In function 'PathToToken':
timehash/timehash.c:123: warning: cast increases required alignment of target type
perl.c: In function 'HandleHeaders':
perl.c:149:17: warning: cast increases required alignment of target type [-Wcast-align]
perl.c:149:17: warning: cast increases required alignment of target type [-Wcast-align]
perl.c:149:17: warning: cast increases required alignment of target type [-Wcast-align]
perl.c:149:17: warning: cast increases required alignment of target type [-Wcast-align]
sasl.c: In function 'SASLauth':
sasl.c:214:20: warning: cast increases required alignment of target type [-Wcast-align]
his.c: In function 'his_logger':
his.c:446: warning: dereferencing type-punned pointer will break strict-aliasing rules
sasl.c: In function 'SASLauth':
sasl.c:214: warning: dereferencing type-punned pointer will break strict-aliasing rules
imap_connection.c: In function 'lmtp_readCB':
imap_connection.c:3386: warning: dereferencing type-punned pointer will break strict-aliasing rules
lex.yy.c: In function 'yy_get_next_buffer':
lex.yy.c:1126: warning: old-style function definition
lex.yy.c: In function 'yy_get_previous_state':
lex.yy.c:1258: warning: old-style function definition
buffindexed/buffindexed.c: In function 'mmapwrite':
buffindexed/buffindexed.c:310: warning: pointer of type 'void *' used in arithmetic
art.c: In function 'ARTlog':
art.c:311: warning: passing argument 1 of 'ctime' from incompatible pointer type
art.c:317: warning: passing argument 1 of 'ctime' from incompatible pointer type
art.c: In function 'ARTcheckheader':
art.c:652: warning: array subscript has type 'char'
post.c: In function 'StripOffHeaders':
post.c:211: warning: array subscript has type 'char'
inews.c: In function 'FormatUserName':
inews.c:462: warning: array subscript has type 'char'
art.o(.text+0x143c): In function `ARTcancel':
/home/iulius/autobuild/inn/inn2/inn-CURRENT-20130619/innd/art.c:1214: warning: sprintf() is often misused, please use snprintf()
nnrpd.o(.text+0x2754): In function `main':
/home/iulius/autobuild/inn/inn2/inn-CURRENT-20130619/nnrpd/nnrpd.c:1262: warning: sprintf() is often misused, please use snprintf()
config_y.o(.text+0xca0): In function `yyerror':
/home/iulius/autobuild/inn/inn2/inn-CURRENT-20130619/innfeed/configfile.y:784: warning: sprintf() is often misused, please use snprintf()
imap_connection.o(.text+0x3b24): In function `imap_readCB':
/home/iulius/autobuild/inn/inn2/inn-CURRENT-20130619/innfeed/imap_connection.c:2823: warning: strcat() is almost always misused, please use strlcat()
config_y.o(.text+0xca0): In function `yyerror':
/home/iulius/autobuild/inn/inn2/inn-CURRENT-20130619/innfeed/configfile.y:784: warning: sprintf() is often misused, please use snprintf()
inews.o(.text+0xd2c): In function `ProcessHeaders':
/home/iulius/autobuild/inn/inn2/inn-CURRENT-20130619/frontends/inews.c:545: warning: sprintf() is often misused, please use snprintf()
/home/iulius/autobuild/inn/inn2/inn-CURRENT-20130619/history/.libs/libinnhist.so.3.0: warning: sprintf() is often misused, please use snprintf()
[this error appears several times, maybe because of one of the previous errors]
Test suite
----------
../lib/getaddrinfo.c: In function 'gai_addrinfo_new':
../lib/getaddrinfo.c:204: warning: cast increases required alignment of target type
../lib/getaddrinfo.c:205: warning: cast increases required alignment of target type
../lib/getaddrinfo.c:206: warning: cast increases required alignment of target type
../lib/getaddrinfo.c:207: warning: cast increases required alignment of target type
lib/getaddrinfo-t.c: In function 'main':
lib/getaddrinfo-t.c:74: warning: cast increases required alignment of target type
lib/getaddrinfo-t.c:84: warning: cast increases required alignment of target type
lib/getaddrinfo-t.c:97: warning: cast increases required alignment of target type
lib/getaddrinfo-t.c:112: warning: cast increases required alignment of target type
lib/getaddrinfo-t.c:138: warning: cast increases required alignment of target type
lib/getaddrinfo-t.c:152: warning: cast increases required alignment of target type
lib/getaddrinfo-t.c:165: warning: cast increases required alignment of target type
lib/getaddrinfo-t.c:177: warning: cast increases required alignment of target type
lib/getaddrinfo-t.c:193: warning: cast increases required alignment of target type
lib/getaddrinfo-t.c:210: warning: cast increases required alignment of target type
lib/getaddrinfo-t.c:220: warning: cast increases required alignment of target type
lib/getaddrinfo-t.c:233: warning: cast increases required alignment of target type
lib/getaddrinfo-t.c:256: warning: cast increases required alignment of target type
lib/getaddrinfo-t.c:269: warning: cast increases required alignment of target type
../lib/getnameinfo.c: In function 'test_getnameinfo':
../lib/getnameinfo.c:151: warning: cast increases required alignment of target type
lib/network-t.c: In function 'listener_any':
lib/network-t.c:116: warning: cast increases required alignment of target type
overview/api-t.c: In function 'check_data':
overview/api-t.c:297: warning: format '%lu' expects type 'long unsigned int', but argument 4 has type 'time_t'
overview/api-t.c:307: warning: format '%lu' expects type 'long unsigned int', but argument 4 has type 'time_t'
lib/date-t.o(.text+0x11c): In function `check_nntp':
lib/date-t.c:108: warning: sprintf() is often misused, please use snprintf()
libtest.o(.text+0x408): In function `test_file_path':
/home/iulius/autobuild/inn/inn2/inn-CURRENT-20130619/tests/libtest.c:563: warning: sprintf() is often misused, please use snprintf()
runtests.o(.text+0x32c): In function `find_test':
/home/iulius/autobuild/inn/inn2/inn-CURRENT-20130619/tests/runtests.c:929: warning: sprintf() is often misused, please use snprintf()
lib/inet_ntoa.o(.text+0x3c): In function `test_inet_ntoa':
../lib/inet_ntoa.c:33: warning: sprintf() is often misused, please use snprintf()
lib/messages-t.o(.text+0xdd4): In function `main':
lib/messages-t.c:277: warning: sprintf() is often misused, please use snprintf()
lib/snprintf-t.o(.text+0x5cc): In function `main':
lib/snprintf-t.c:168: warning: sprintf() is often misused, please use snprintf()
That's all!
--
Julien ÉLIE
« Ne craignez pas d'être lent, craignez seulement d'être à
l'arrêt. »
More information about the inn-workers
mailing list