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: Fix pgbench lexer's "continuation" rule to cope with Windows new
Date: Mon, 17 Sep 2018 16:11:52 +0000
Message-ID: <E1g1w7s-0006Z4-OE@gemulon.postgresql.org> (raw)

Fix pgbench lexer's "continuation" rule to cope with Windows newlines.

Our general practice in frontend code is to accept input with either
Unix-style newlines (\n) or DOS-style (\r\n).  pgbench was mostly down
with that, but its rule for line continuations (backslash-newline) was
not.  This had been masked on Windows buildfarm machines before commit
0ba06e0bf by use of Windows text mode to read files.  We could have fixed
it by forcing text mode again, but it's better to fix the parsing code
so that Windows-style text files on Unix systems don't cause problems.

Back-patch to v10 where pgbench grew line continuations.

Discussion: https://postgr.es/m/17194.1537191697@sss.pgh.pa.us

Branch
------
REL_11_STABLE

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

Modified Files
--------------
src/bin/pgbench/exprscan.l | 10 +++++++---
1 file changed, 7 insertions(+), 3 deletions(-)



view thread (3+ messages)  latest in thread

Message-ID: <E1g1w7s-0006Z4-OE@gemulon.postgresql.org>
Permalink:  ../E1g1w7s-0006Z4-OE@gemulon.postgresql.org/
Also on:    postgresql.org/message-id/E1g1w7s-0006Z4-OE@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: Fix pgbench lexer's "continuation" rule to cope with Windows new
  In-Reply-To: <E1g1w7s-0006Z4-OE@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