From: Peter Eisentraut <peter.eisentraut@2ndquadrant.com>
To: Aleksander Alekseev <a.alekseev@postgrespro.ru>
To: David Steele <david@pgmasters.net>
Cc: PostgreSQL Developers <pgsql-hackers@postgresql.org>
Subject: Re: [PATCH] Suppress Clang 3.9 warnings
Date: Fri, 17 Mar 2017 18:02:40 -0400
Message-ID: <74b8619a-6077-83b6-efce-7b4fdc111bb8@2ndquadrant.com> (raw)
In-Reply-To: <20170313153553.GB2564@e733.localdomain>
References: <20170220141239.GD12278@e733.localdomain>
<alpine.DEB.2.20.1702221532100.22403@lancre>
<dc2a33c7-a498-c277-592e-30a9ad8c7926@pgmasters.net>
<20170313153553.GB2564@e733.localdomain>
List-Unsubscribe: <mailto:majordomo@postgresql.org?body=unsub%20pgsql-hackers>
On 3/13/17 11:35, Aleksander Alekseev wrote:
> Here is a new patch. I tried to make as little changes as possible. This
> is no doubt not the most beautiful patch on Earth but it removes all
> warnings. I anyone could suggest an approach that would be significantly
> better please don't hesitate to share your ideas.
I'm also seeing the -Wconstant-conversion warnings with clang-4.0. The
warnings about strlcpy don't appear here. That might be something
specific to the operating system.
To address the -Wconstant-conversion warnings, I suggest changing the
variables to unsigned char * as appropriate.
However, this would require a large number of changes to all call sites
of XLogRegisterData(), because they all have a cast like this:
XLogRegisterData((char *) &xlrec, SizeOfHashMovePageContents);
Perhaps the first argument could be changed to void *.
--
Peter Eisentraut http://www.2ndQuadrant.com/
PostgreSQL Development, 24x7 Support, Remote DBA, Training & Services
--
Sent via pgsql-hackers mailing list (pgsql-hackers@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-hackers
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Reply to all the recipients from your mail client; the link fills in
the headers below: reply via email
Some clients, webmail especially, drop In-Reply-To and References from
a link, and the reply then starts a new thread: use the mbox below.
To: pgsql-hackers@postgresql.org
Cc: peter.eisentraut@2ndquadrant.com, a.alekseev@postgrespro.ru, david@pgmasters.net
Subject: Re: [PATCH] Suppress Clang 3.9 warnings
In-Reply-To: <74b8619a-6077-83b6-efce-7b4fdc111bb8@2ndquadrant.com>
References: <20170220141239.GD12278@e733.localdomain> <alpine.DEB.2.20.1702221532100.22403@lancre> <dc2a33c7-a498-c277-592e-30a9ad8c7926@pgmasters.net> <20170313153553.GB2564@e733.localdomain> <74b8619a-6077-83b6-efce-7b4fdc111bb8@2ndquadrant.com>
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox