GCC warnings on x86-64

Bug #555695 reported by Didier Barvaux
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
rohc
Status tracked in Rohc-main
1.2.x
Fix Released
Low
Didier Barvaux
1.3.x
Fix Released
Low
Didier Barvaux
Rohc-main
Fix Released
Low
Didier Barvaux

Bug Description

On a x86-64 system, GCC 4.3.4 issues the following warnings while building version 1.3.0 of the ROHC library:

/bin/sh ../../libtool --tag=CC --mode=compile gcc -DHAVE_CONFIG_H -I. -I../.. -I../../src/common -I../../src/comp -g -Wall -Wstrict-prototypes -g -O2 -Werror -MT d_generic.lo -MD -MP -MF .deps/d_generic.Tpo -c -o d_generic.lo d_generic.c
libtool: compile: gcc -DHAVE_CONFIG_H -I. -I../.. -I../../src/common -I../../src/comp -g -Wall -Wstrict-prototypes -g -O2 -Werror -MT d_generic.lo -MD -MP -MF .deps/d_generic.Tpo -c d_generic.c -fPIC -DPIC -o .libs/d_generic.o
cc1: warnings being treated as errors
d_generic.c: In function ‘d_generic_decode_ir’:
d_generic.c:1772: erreur: format ‘%d’ expects type ‘int’, but argument 7 has type ‘long int’
d_generic.c: In function ‘decode_uo0’:
d_generic.c:2784: erreur: format ‘%d’ expects type ‘int’, but argument 7 has type ‘long int’
d_generic.c: In function ‘decode_uo1’:
d_generic.c:3032: erreur: format ‘%d’ expects type ‘int’, but argument 7 has type ‘long int’
d_generic.c: In function ‘decode_uor2’:
d_generic.c:3331: erreur: format ‘%d’ expects type ‘int’, but argument 7 has type ‘long int’
d_generic.c: In function ‘decode_irdyn’:
d_generic.c:3452: erreur: format ‘%d’ expects type ‘int’, but argument 7 has type ‘long int’
d_generic.c: In function ‘do_decode_uo0_and_uo1’:
d_generic.c:3667: erreur: format ‘%d’ expects type ‘int’, but argument 6 has type ‘long int’
d_generic.c: In function ‘do_decode_uor2’:
d_generic.c:4279: erreur: format ‘%d’ expects type ‘int’, but argument 6 has type ‘long int’
make[3]: *** [d_generic.lo] Erreur 1
make[3]: quittant le répertoire « /home/didier/documents/dev/rohc/rohc-1.3.x/src/decomp »
make[2]: *** [all-recursive] Erreur 1
make[2]: quittant le répertoire « /home/didier/documents/dev/rohc/rohc-1.3.x/src »
make[1]: *** [all-recursive] Erreur 1
make[1]: quittant le répertoire « /home/didier/documents/dev/rohc/rohc-1.3.x »
make: *** [all] Erreur 2

Tags: library
Revision history for this message
Didier Barvaux (didier-barvaux) wrote :

Confirmed for 1.3.0.

Revision history for this message
Didier Barvaux (didier-barvaux) wrote :

Confirmed for 1.2.1.

Revision history for this message
Didier Barvaux (didier-barvaux) wrote :

Confirmed for trunk.

Revision history for this message
Didier Barvaux (didier-barvaux) wrote :

Fix committed in branch 1.3.x, see http://bazaar.launchpad.net/~didier-barvaux/rohc/1.3.x/revision/136. Scheduled for release 1.3.1.

Revision history for this message
Didier Barvaux (didier-barvaux) wrote :

Fix committed in branch 1.2.x, see http://bazaar.launchpad.net/~didier-barvaux/rohc/1.2.x/revision/111. Scheduled for release 1.2.2.

Revision history for this message
Didier Barvaux (didier-barvaux) wrote :

Fix committed in trunk, see http://bazaar.launchpad.net/~didier-barvaux/rohc/main/revision/141. Scheduled for release 1.4.0.

The change is more invasive than for 1.2.x and 1.3.x branches. I decided to get rid of arithmetic on pointers. Such things are likely to be not portable accross platforms (16 bits, 32 bits, 64 bits...).

To achieve that, I added new local variables to count the numbers of bytes read in the packet. This required some changes in prototypes of several internal functions. Care was taken that the result of non-regression tests was unchanged: both ROHC packets and debug output.

Revision history for this message
Didier Barvaux (didier-barvaux) wrote :

Fix released in version 1.3.1.

Revision history for this message
Didier Barvaux (didier-barvaux) wrote :

Fix released in version 1.2.2.

To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.