Re: 2x compile warning

From: Martijn van Oosterhout <kleptog(at)svana(dot)org>
To: Kris Jurka <books(at)ejurka(dot)com>
Cc: Gevik Babakhani <pgdev(at)xs4all(dot)nl>, pgsql-hackers <pgsql-hackers(at)postgresql(dot)org>
Subject: Re: 2x compile warning
Date: 2006-04-24 20:37:58
Message-ID: 20060424203758.GF2747@svana.org
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

On Mon, Apr 24, 2006 at 01:16:04PM -0500, Kris Jurka wrote:
>
>
> On Mon, 24 Apr 2006, Gevik Babakhani wrote:
>
> >I noticed the following compile warnings. Perhaps someone is interested
> >to know about them.
>
> Also I was testing a gcc 4.2 snapshot (20060419) and it has a whole lot of
> warnings stemming from heap_getattr's isnull check:
>
> aclchk.c:791: warning: the address of 'isNull', will always evaluate as
> 'true'

Perhaps someone could check if changing the test explicitly check
against NULL:

> ((attnum) > (int) (tup)->t_data->t_natts) ? \
> ( \
> (((isnull) != NULL)? (*(isnull) = true) : (dummyret)NULL), \
> (Datum)NULL \

removes the warning. It seems silly for the GCC people to add warnings
for this kind of stuff without a simple way to bypass it...
--
Martijn van Oosterhout <kleptog(at)svana(dot)org> http://svana.org/kleptog/
> From each according to his ability. To each according to his ability to litigate.

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Kris Jurka 2006-04-24 21:02:30 Re: 2x compile warning
Previous Message Magnus Hagander 2006-04-24 20:24:56 Re: Regression error on float8