Re: Some warnings in GLib 2.24 (gutils.h and gthread.h)



On Thu, 2010-04-22 at 21:04 +0200, José Luis García Pallero wrote:

> I'm using GLib 2.24 (the Debian GNU/Linux package in Sid) and in the
> compilation I obtain two warnings in GLib files.

you can safely ignore them.

> My gcc flags are:
> 
> -std=c99 -pedantic -Wall -Wextra -Wconversion -Wmissing-prototypes
> -Wstrict-prototypes -Wshadow -Wcast-qual -Wcast-align -Wwrite-strings
> -Wnested-externs

do not use -Wextra unless you know exactly what you're doing.

> And the warnings are:
> 
> 
> /usr/include/glib-2.0/glib/gutils.h: In function ‘g_bit_storage’:
> /usr/include/glib-2.0/glib/gutils.h:358: warning: conversion to
> ‘guint’ from ‘int’ may change the sign of the result
> /usr/include/glib-2.0/glib/gthread.h: In function ‘g_once_init_enter’:
> /usr/include/glib-2.0/glib/gthread.h:348: warning: cast discards
> qualifiers from pointer target type
> 
> I suppose that they can be easy to fix in next release.

there's nothing here to fix; if you enable pedantic warnings you get
exactly what you asked for.

ciao,
 Emmanuele.

-- 
W: http://www.emmanuelebassi.name
B: http://blogs.gnome.org/ebassi



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]