Skip site navigation (1) Skip section navigation (2)

Re: windows / initdb oddness

From: Andrew Dunstan <andrew(at)dunslane(dot)net>
To: Andrew Dunstan <andrew(at)dunslane(dot)net>
Cc: Magnus Hagander <mha(at)sollentuna(dot)net>, PostgreSQL-development <pgsql-hackers(at)postgresql(dot)org>, "Patches (PostgreSQL)" <pgsql-patches(at)postgresql(dot)org>
Subject: Re: windows / initdb oddness
Date: 2006-02-22 02:29:59
Message-ID: (view raw or whole thread)
Lists: pgsql-hackerspgsql-patches

Andrew Dunstan wrote:

> I wrote:
>> I will add some trace writes when I get a chance. I was rather hoping 
>> something would jump out at you, but obviously it hasn't, so I'll 
>> have to dig into it the slow way. *sigh*
> Just eyeballing the code it looks to me like the problem is this line:
>        strcat(cmdline, *" --restrictedexec"*);
> which is appending an option type argument after the non-option argument.
> That would exactly account for the failure when we call "initdb foo" 
> but not "initdb -D foo".
> The solution would be put --restrictedexec earlier on the new command 
> line. I'll work on that.

The probem is apparently the one I identified above, and is fixed by the 
attached patch, which I will apply soon unless there are objections.

As for why we saw this on loris but not snake, I suspect they might have 
different getopt libraries installed.



Attachment: initdb.patch
Description: text/x-patch (2.2 KB)

In response to

pgsql-hackers by date

Next:From: Andrew DunstanDate: 2006-02-22 03:24:28
Subject: initdb -U wrongness
Previous:From: Mark KirkwoodDate: 2006-02-22 01:53:03
Subject: Re: pg_config, pg_service.conf, postgresql.conf ....

pgsql-patches by date

Next:From: Magnus HaganderDate: 2006-02-22 07:23:00
Subject: Re: windows / initdb oddness
Previous:From: Andrew DunstanDate: 2006-02-21 23:05:48
Subject: Re: windows / initdb oddness

Privacy Policy | About PostgreSQL
Copyright © 1996-2015 The PostgreSQL Global Development Group