pg_regress not waiting for postmaster to stop

From: Michael Paquier <michael(dot)paquier(at)gmail(dot)com>
To: PostgreSQL mailing lists <pgsql-hackers(at)postgresql(dot)org>
Subject: pg_regress not waiting for postmaster to stop
Date: 2015-06-19 06:33:12
Message-ID: CAB7nPqS+6ed9jYpCofWo7zrRatgW8rjx+atNVN+8NX9W+zZMJA@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

Hi all,

In pg_regress.c, there is the following code:
static void
stop_postmaster(void)
{
if (postmaster_running)
{
/* We use pg_ctl to issue the kill and wait for stop */
char buf[MAXPGPATH * 2];
int r;

/* On Windows, system() seems not to force fflush, so... */
fflush(stdout);
fflush(stderr);

snprintf(buf, sizeof(buf),
"\"%s%spg_ctl\" stop -D \"%s/data\"
-w -s -m fast",
bindir ? bindir : "",
bindir ? "/" : "",
temp_instance);

Except if I am missing something, the comment mentions that we should
wait for the stop but there is no -w switch in the command of pg_ctl.
Doesn't the patch attached make sense?
Regards
--
Michael

Attachment Content-Type Size
20150619_regress_pgctl_stop.patch application/x-patch 458 bytes

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Brendan Jurd 2015-06-19 06:41:19 Re: Tab completion for CREATE SEQUENCE
Previous Message Michael Paquier 2015-06-19 05:49:49 SSL TAP tests and chmod