Re: [HACKERS] Re: [COMMITTERS] pgsql: Make initdb's suggested "pg_ctl start" command line more reliabl

2016-09-08 Thread Tom Lane
Peter Eisentraut writes: > More generally, I'm concerned that appendShellString() looks pretty > attractive for future use. It's not inconceivable that someone will > want to use it for say calling pg_dump from pg_dumpall or pg_upgrade at > some point, and then

Re: [HACKERS] Re: [COMMITTERS] pgsql: Make initdb's suggested "pg_ctl start" command line more reliabl

2016-09-08 Thread Peter Eisentraut
On 9/6/16 1:08 PM, Tom Lane wrote: >> As just mentioned elsewhere, this accidentally introduces a failure if >> > the PostgreSQL installation path contains LF/CR, because of the use of >> > appendShellString(). > I think that's intentional, not accidental. What actual use case is > there for

Re: [HACKERS] Re: [COMMITTERS] pgsql: Make initdb's suggested "pg_ctl start" command line more reliabl

2016-09-06 Thread Tom Lane
Claudio Freire writes: > On Tue, Sep 6, 2016 at 2:08 PM, Tom Lane wrote: >> Dash is considered a character that needs quoting. It might be possible >> to avoid that if we could be certain that appendShellString's output would >> never be placed in a

Re: [HACKERS] Re: [COMMITTERS] pgsql: Make initdb's suggested "pg_ctl start" command line more reliabl

2016-09-06 Thread Andres Freund
On 2016-09-06 13:08:51 -0400, Tom Lane wrote: > Dash is considered a character that needs quoting. It might be possible > to avoid that if we could be certain that appendShellString's output would > never be placed in a spot where it could be taken for a switch, but that > seems like a large

Re: [HACKERS] Re: [COMMITTERS] pgsql: Make initdb's suggested "pg_ctl start" command line more reliabl

2016-09-06 Thread Claudio Freire
On Tue, Sep 6, 2016 at 2:08 PM, Tom Lane wrote: >> The not-quoting-if-not-needed doesn't appear to do anything useful for me: >> 'pg-install/bin/pg_ctl' -D 'pg-install/var/data' -l logfile start > > Dash is considered a character that needs quoting. It might be possible >

Re: [HACKERS] Re: [COMMITTERS] pgsql: Make initdb's suggested "pg_ctl start" command line more reliabl

2016-09-06 Thread Tom Lane
Peter Eisentraut writes: > On 8/20/16 3:05 PM, Tom Lane wrote: >> Make initdb's suggested "pg_ctl start" command line more reliable. > A couple of problems with this: > The not-quoting-if-not-needed doesn't appear to do anything useful for me: >