From 7f42dabca82e43581b65f4a479e6c664f22045ea Mon Sep 17 00:00:00 2001
From: Bruce Momjian <bruce@momjian.us>
Date: Thu, 29 Jul 2004 16:11:11 +0000
Subject: [PATCH] Fix for pg_ctl -o processing.  Report from  Sean Chittenden.

---
 src/bin/pg_ctl/pg_ctl.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/src/bin/pg_ctl/pg_ctl.c b/src/bin/pg_ctl/pg_ctl.c
index 52f2ea874f1..d49338f4903 100644
--- a/src/bin/pg_ctl/pg_ctl.c
+++ b/src/bin/pg_ctl/pg_ctl.c
@@ -4,7 +4,7 @@
  *
  * Portions Copyright (c) 1996-2003, PostgreSQL Global Development Group
  *
- * $PostgreSQL: pgsql/src/bin/pg_ctl/pg_ctl.c,v 1.23 2004/07/22 01:44:36 tgl Exp $
+ * $PostgreSQL: pgsql/src/bin/pg_ctl/pg_ctl.c,v 1.24 2004/07/29 16:11:11 momjian Exp $
  *
  *-------------------------------------------------------------------------
  */
@@ -359,7 +359,7 @@ test_postmaster_connection(void)
 			/* keep looking, maybe there is another -p */
 		}
 		/* Advance to next whitespace */
-		while (!isspace(*p))
+		while (*p && !isspace(*p))
 			p++;
 	}
 
-- 
GitLab