From: Tom Lane <tgl@sss.pgh.pa.us>
To: pgsql-committers@lists.postgresql.org
Subject: pgsql: Fix omissions in snprintf.c's coverage of standard *printf funct
Date: Mon, 08 Oct 2018 23:16:27 +0000
Message-ID: <E1g9elH-0004MK-HS@gemulon.postgresql.org> (raw)
Fix omissions in snprintf.c's coverage of standard *printf functions.
A warning on a NetBSD box revealed to me that pg_waldump/compat.c
is using vprintf(), which snprintf.c did not provide coverage for.
This is not good if we want to have uniform *printf behavior, and
it's pretty silly to omit when it's a one-line function.
I also noted that snprintf.c has pg_vsprintf() but for some reason
it was not exposed to the outside world, creating another way in
which code might accidentally invoke the platform *printf family.
Let's just make sure that we replace all eight of the POSIX-standard
printf family.
Also, upgrade plperl.h and plpython.h to make sure that they do
their undefine/redefine rain dance for all eight, not some random
maybe-sufficient subset thereof.
Branch
------
master
Details
-------
https://git.postgresql.org/pg/commitdiff/7767aadd94cd252a12fa00f6122ad4dd10455791
Modified Files
--------------
src/include/port.h | 10 ++++++++++
src/pl/plperl/plperl.h | 40 +++++++++++++++++++++++++++++++++++-----
src/pl/plpython/plpython.h | 43 +++++++++++++++++++++++++++++++++++++------
src/port/snprintf.c | 10 +++++++++-
4 files changed, 91 insertions(+), 12 deletions(-)
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-committers@postgresql.org
Cc: tgl@sss.pgh.pa.us
Subject: Re: pgsql: Fix omissions in snprintf.c's coverage of standard *printf funct
In-Reply-To: <E1g9elH-0004MK-HS@gemulon.postgresql.org>
References: <E1g9elH-0004MK-HS@gemulon.postgresql.org>
* 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