pg.ddx.io  pgsql-bugs@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Tom Lane <tgl@sss.pgh.pa.us>
To: julian.schauder@credativ.de
Cc: pgsql-bugs@postgresql.org
Subject: Re: BUG #14063: ALTER SYSTEM accepts 'newline' and renders itself inoperable.
Date: Mon, 04 Apr 2016 17:40:43 -0400
Message-ID: <14245.1459806043@sss.pgh.pa.us> (raw)
In-Reply-To: <20160404194024.15198.21684@wrigleys.postgresql.org>
References: <20160404194024.15198.21684@wrigleys.postgresql.org>
List-Unsubscribe: <mailto:majordomo@postgresql.org?body=unsub%20pgsql-bugs>

julian.schauder@credativ.de writes:
> PostgreSQLs ALTER SYSTEM accepts a newline in its string-statements. This
> will cause the postgresql.auto.conf to become unreadable and requires system
> intervention (aka removal of the auto.conf)

Yeah, there's no provision for allowing a newline in postgresql.conf
string literals.  I believe we debated this in the past and decided it
wasn't something we wanted to change, as it would create more confusion
than it was worth (for example: what line number to ascribe to such an
assignment).  It looks like newline is the only troublesome character;
there are quoting conventions for backslash and quote, which are the only
other characters that are special there.

> According to code analysis i believe the easiest way around this is
> tightening the value validation and ignore whitespaces or just remove
> newline as a whitespace.

I'm inclined to just throw an error if someone tries this, not try to
clean up after them.  If we get lots of complaints about it, we will know
we should revisit the aforementioned decision.  But there's no reason to
put restrictions on GUC values that aren't getting written by ALTER SYSTEM.

			regards, tom lane


-- 
Sent via pgsql-bugs mailing list (pgsql-bugs@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-bugs



view thread (2+ messages)

Message-ID: <14245.1459806043@sss.pgh.pa.us>
Permalink:  ../14245.1459806043@sss.pgh.pa.us/
Also on:    postgresql.org/message-id/14245.1459806043@sss.pgh.pa.us

 · 

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 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-bugs@postgresql.org
  Cc: tgl@sss.pgh.pa.us, julian.schauder@credativ.de
  Subject: Re: BUG #14063: ALTER SYSTEM accepts 'newline' and renders itself inoperable.
  In-Reply-To: <14245.1459806043@sss.pgh.pa.us>
  References: <20160404194024.15198.21684@wrigleys.postgresql.org> <14245.1459806043@sss.pgh.pa.us>

* 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