pg.ddx.io  pgsql-committers@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Tom Lane <tgl@sss.pgh.pa.us>
To: pgsql-committers@lists.postgresql.org
Subject: pgsql: pgbench: fix misprocessing of some nested \if constructs.
Date: Sun, 15 Dec 2024 19:14:33 +0000
Message-ID: <E1tMu4W-002sdp-Rj@gemulon.postgresql.org> (raw)

pgbench: fix misprocessing of some nested \if constructs.

An \if command appearing within a false (not-to-be-executed) \if
branch was incorrectly treated the same as \elif.  This could allow
statements within the inner \if to be executed when they should
not be.  Also the missing inner \if stack entry would result in an
assertion failure (in assert-enabled builds) when the final \endif
is reached.

Report and patch by Michail Nikolaev.  Back-patch to all
supported branches.

Discussion: https://postgr.es/m/CANtu0oiA1ke=SP6tauhNqkUdv5QFsJtS1p=aOOf_iU+EhyKkjQ@mail.gmail.com

Branch
------
REL_15_STABLE

Details
-------
https://git.postgresql.org/pg/commitdiff/ff88db91036fed10dedb9e38786506d0460bd7dd

Modified Files
--------------
src/bin/pgbench/pgbench.c                    | 16 +++++----
src/bin/pgbench/t/001_pgbench_with_server.pl | 50 ++++++++++++++++++++++++++++
2 files changed, 59 insertions(+), 7 deletions(-)



view thread (6+ messages)  latest in thread

Message-ID: <E1tMu4W-002sdp-Rj@gemulon.postgresql.org>
Permalink:  ../E1tMu4W-002sdp-Rj@gemulon.postgresql.org/
Also on:    postgresql.org/message-id/E1tMu4W-002sdp-Rj@gemulon.postgresql.org

 · 

reply

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 using the --to and --cc options:
  reply via email

  To: pgsql-committers@postgresql.org
  Cc: tgl@sss.pgh.pa.us, pgsql-committers@lists.postgresql.org
  Subject: Re: pgsql: pgbench: fix misprocessing of some nested \if constructs.
  In-Reply-To: <E1tMu4W-002sdp-Rj@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