From: David Rowley <drowley@postgresql.org>
To: pgsql-committers@lists.postgresql.org
Subject: pgsql: Use appendBinaryStringInfo in more places where the length is kn
Date: Mon, 22 Jul 2019 12:14:36 +0000
Message-ID: <E1hpXDA-0004Be-Vl@gemulon.postgresql.org> (raw)
Use appendBinaryStringInfo in more places where the length is known
When we already know the length that we're going to append, then it
makes sense to use appendBinaryStringInfo instead of
appendStringInfoString so that the append can be performed with a simple
memcpy() using a known length rather than having to first perform a
strlen() call to obtain the length.
Discussion: https://postgr.es/m/CAKJS1f8+FRAM1s5+mAa3isajeEoAaicJ=4e0WzrH3tAusbbiMQ@mail.gmail.com
Branch
------
master
Details
-------
https://git.postgresql.org/pg/commitdiff/1e6a759838f7c104f3cd1fe6981a98780da4131b
Modified Files
--------------
contrib/postgres_fdw/deparse.c | 4 ++--
src/backend/executor/execMain.c | 4 ++--
src/backend/executor/execPartition.c | 2 +-
src/backend/storage/lmgr/deadlock.c | 2 +-
src/backend/utils/adt/ri_triggers.c | 4 ++--
src/backend/utils/adt/ruleutils.c | 10 +++++-----
src/backend/utils/adt/xml.c | 12 +++++++-----
7 files changed, 20 insertions(+), 18 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: drowley@postgresql.org
Subject: Re: pgsql: Use appendBinaryStringInfo in more places where the length is kn
In-Reply-To: <E1hpXDA-0004Be-Vl@gemulon.postgresql.org>
References: <E1hpXDA-0004Be-Vl@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