Re: [HACKERS] [PATCHES] A patch to pg_regress for Windows port

2007-01-05 Thread Tom Lane
Gurjeet Singh [EMAIL PROTECTED] writes:
 This patch removes double-quotes from around the listen_addresses=%s part; I
 couldn't find a way of doing that. But then, the questions is, can the %s
 (hostname) have spaces embedded in it?

Yes, because it can be more than one hostname.  Why do you want to
remove the quotes?

regards, tom lane

PS: there wasn't any patch attached, but I doubt we'd have accepted it
anyway ...

---(end of broadcast)---
TIP 5: don't forget to increase your free space map settings


Re: [HACKERS] [PATCHES] A patch to pg_regress for Windows port

2007-01-05 Thread Gurjeet Singh

On 1/6/07, Tom Lane [EMAIL PROTECTED] wrote:


Gurjeet Singh [EMAIL PROTECTED] writes:
 This patch removes double-quotes from around the listen_addresses=%s
part; I
 couldn't find a way of doing that. But then, the questions is, can the
%s
 (hostname) have spaces embedded in it?

Yes, because it can be more than one hostname.



But the code in postmaster.c expects the list to be comma separated.

   if (!SplitIdentifierString(rawstring, ',', elemlist))
   {
   /* syntax error in list */
   ereport(FATAL,
   (errcode(ERRCODE_INVALID_PARAMETER_VALUE),
errmsg(invalid list syntax for
\listen_addresses\)));
   }

 Why do you want to

remove the quotes?



No, I didn't want to, but I was getting FATAL:  the database system is
starting up in the log if I surrounded that var=val with double-quotes.
Later I remedied that by attaching a -w option to the pg_ctl command.

PS: there wasn't any patch attached,


Please refer
http://archives.postgresql.org/pgsql-patches/2007-01/msg00056.php

but I doubt we'd have accepted it

anyway ...



Any particular reason?

A few minutes after the submission, after I read more code, I wouldn't have
either! I noticed (and Magnus also pointed it out) that we use the returned
PID to kill the postmaster if it doesn't respond. There's no easy way of
doing that if we use pg_ctl to start the postmaster! Let's wait for Magnus'
patch to make pg_regress independent of MinGW.

Best regards,

--
[EMAIL PROTECTED]
[EMAIL PROTECTED] gmail | hotmail | yahoo }.com


Re: [HACKERS] [PATCHES] A patch to pg_regress for Windows port

2007-01-05 Thread Tom Lane
Gurjeet Singh [EMAIL PROTECTED] writes:
 On 1/6/07, Tom Lane [EMAIL PROTECTED] wrote:
 Yes, because it can be more than one hostname.

 But the code in postmaster.c expects the list to be comma separated.

Sure, but SplitIdentifierString allows for whitespace, eg

'host1, host2, host3'

regards, tom lane

---(end of broadcast)---
TIP 2: Don't 'kill -9' the postmaster