Re: new compiler warnings
Tom Lane <tgl@sss.pgh.pa.us>
From: Tom Lane <tgl@sss.pgh.pa.us>
To: Bruce Momjian <bruce@momjian.us>
Cc: Robert Haas <robertmhaas@gmail.com>, pgsql-hackers@postgresql.org
Date: 2011-01-27T00:58:52Z
Lists: pgsql-hackers
Bruce Momjian <bruce@momjian.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