aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorItagaki Takahiro <itagaki.takahiro@gmail.com>2010-04-07 03:48:51 +0000
committerItagaki Takahiro <itagaki.takahiro@gmail.com>2010-04-07 03:48:51 +0000
commit1a8957a6f7f17eaed848f5eb0f09de9c04355f97 (patch)
tree25fa18fd001f3644d1549ea71d50808ffcec9a03
parent26eb0c72ab564d17e72f45b16d8ff42d357986b9 (diff)
downloadpostgresql-1a8957a6f7f17eaed848f5eb0f09de9c04355f97.tar.gz
postgresql-1a8957a6f7f17eaed848f5eb0f09de9c04355f97.zip
Add cygwin version check before using cygwin_conv_path(),
and use cygwin_conv_to_full_win32_path() in older versions.
-rw-r--r--src/bin/pg_ctl/pg_ctl.c6
1 files changed, 5 insertions, 1 deletions
diff --git a/src/bin/pg_ctl/pg_ctl.c b/src/bin/pg_ctl/pg_ctl.c
index 53ea26107b5..810f6fef6e3 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-2010, PostgreSQL Global Development Group
*
- * $PostgreSQL: pgsql/src/bin/pg_ctl/pg_ctl.c,v 1.121 2010/04/05 02:25:56 itagaki Exp $
+ * $PostgreSQL: pgsql/src/bin/pg_ctl/pg_ctl.c,v 1.122 2010/04/07 03:48:51 itagaki Exp $
*
*-------------------------------------------------------------------------
*/
@@ -1080,7 +1080,11 @@ pgwin32_CommandLine(bool registration)
#ifdef __CYGWIN__
/* need to convert to windows path */
+#if CYGWIN_VERSION_DLL_MAJOR >= 1007
cygwin_conv_path(CCP_POSIX_TO_WIN_A, cmdLine, buf, sizeof(buf));
+#else
+ cygwin_conv_to_full_win32_path(cmdLine, buf);
+#endif
strcpy(cmdLine, buf);
#endif