Skip to content

Commit 8613eac

Browse files
committed
Fix pg_ctl -D handling for Win32:
C:\msys\1.0\home\y-asaba>pg_ctl -D data restart waiting for postmaster to shut down...LOG: received smart shutdown request. LOG: shutting down LOG: database system is shut down done postmaster stopped postmaster starting C:\msys\1.0\home\y-asaba>postmaster.exe: invalid argument: "'-D'" Try "postmaster.exe --help" for more information. Yoshiyuki Asaba
1 parent a49f6ad commit 8613eac

File tree

2 files changed

+4
-4
lines changed

2 files changed

+4
-4
lines changed

src/backend/postmaster/postmaster.c

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -37,7 +37,7 @@
3737
*
3838
*
3939
* IDENTIFICATION
40-
* $PostgreSQL: pgsql/src/backend/postmaster/postmaster.c,v 1.433 2004/10/14 20:23:45 momjian Exp $
40+
* $PostgreSQL: pgsql/src/backend/postmaster/postmaster.c,v 1.434 2004/10/15 04:54:31 momjian Exp $
4141
*
4242
* NOTES
4343
*
@@ -3301,7 +3301,7 @@ CreateOptsFile(int argc, char *argv[], char *fullprogname)
33013301

33023302
fprintf(fp, "%s", fullprogname);
33033303
for (i = 1; i < argc; i++)
3304-
fprintf(fp, " '%s'", argv[i]);
3304+
fprintf(fp, " %s%s%s", SYSTEMQUOTE, argv[i], SYSTEMQUOTE);
33053305
fputs("\n", fp);
33063306

33073307
if (fclose(fp))

src/bin/pg_ctl/pg_ctl.c

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44
*
55
* Portions Copyright (c) 1996-2004, PostgreSQL Global Development Group
66
*
7-
* $PostgreSQL: pgsql/src/bin/pg_ctl/pg_ctl.c,v 1.37 2004/10/15 04:32:14 momjian Exp $
7+
* $PostgreSQL: pgsql/src/bin/pg_ctl/pg_ctl.c,v 1.38 2004/10/15 04:54:33 momjian Exp $
88
*
99
*-------------------------------------------------------------------------
1010
*/
@@ -501,7 +501,7 @@ do_start(void)
501501
{
502502
char *arg1;
503503

504-
arg1 = strchr(optline, '\'');
504+
arg1 = strchr(optline, *SYSTEMQUOTE);
505505
if (arg1 == NULL || arg1 == optline)
506506
post_opts = "";
507507
else

0 commit comments

Comments
 (0)
pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy