Re: new compiler warnings

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: Bruce Momjian <bruce(at)momjian(dot)us>
Cc: Robert Haas <robertmhaas(at)gmail(dot)com>, pgsql-hackers(at)postgresql(dot)org
Subject: Re: new compiler warnings
Date: 2011-01-27 00:58:52
Message-ID: 9726.1296089932@sss.pgh.pa.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

Bruce Momjian <bruce(at)momjian(dot)us> writes:
>> And I see this warning:
>>
>> compress_io.c:597: warning: passing arg 2 of `gzwrite' discards
>> qualifiers from pointer target type

> I can remove this warning by casting the pointer to (void *), rather
> than (const void *) because that is what the prototype uses on my system
> uses (libz.so.1.1.4):

Casting away const manually isn't much of an improvement, and will more
than likely provoke warnings of its own on other compilers.

Aren't you overdue for a zlib update? I'm pretty sure there are known
security bugs in 1.1.4 (which dates from 2002). I see no such warning
with zlib 1.2.3, which itself isn't exactly wet behind the ears (2005).

regards, tom lane

In response to

Browse pgsql-hackers by date

  From Date Subject
Next Message Bruce Momjian 2011-01-27 01:02:59 Re: new compiler warnings
Previous Message Tom Lane 2011-01-27 00:52:10 Re: ALTER TYPE 3: add facility to identify further no-work cases