projects
/
pgpool2.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
0725c5d
)
Skip over "host=" when getting info from conninfo string.
author
Bo Peng
<pengbo@sraoss.co.jp>
Mon, 18 Feb 2019 06:18:15 +0000
(15:18 +0900)
committer
Bo Peng
<pengbo@sraoss.co.jp>
Mon, 18 Feb 2019 06:18:15 +0000
(15:18 +0900)
Patch provided by Nathan Ward.
src/main/pgpool_main.c
patch
|
blob
|
blame
|
history
diff --git
a/src/main/pgpool_main.c
b/src/main/pgpool_main.c
index 2c04d2958663820ac1b1e8f9ffe86852ba5dc05c..718f4d4597e683d6388e9f7ba52d5a6b5876ff1b 100644
(file)
--- a/
src/main/pgpool_main.c
+++ b/
src/main/pgpool_main.c
@@
-4337,6
+4337,10
@@
get_info_from_conninfo(char *conninfo, char *host, char *port)
p = strstr(conninfo, "host");
if (p)
{
+ /* skip "host=" */
+ while (*p && *p++ != '=')
+ ;
+
while (*p && *p != ' ')
*host++ = *p++;
*host = '\0';