gcc4 compile fixes in bugzilla.gnome #162582

John Ellson ellson at research.att.com
Thu Dec 30 17:51:11 EST 2004


Derek Atkins wrote:

>Also, I've looked at the patch -- it seems to add a bunch of casts.  I
>really don't think those casts are necessary, and in many cases an
>explicit cast that hide bugs.  Perhaps there's another way to fix the
>compiler warnings?
>  
>
Derek,

The majority of the casts were fixing the use of unsigned char (xmlChar) 
for libxml2
routines versus signed char (char and gchar) in routines like strcmp.

I think that restructuring the code to be more table driven could help, 
but probably won't
completely eliminate the problem which originates from libxml2. 

Every cast in the patch fixed a warning message from gcc4.  I did not 
attempt any more generalized changes.

John


More information about the gnucash-devel mailing list