summaryrefslogtreecommitdiff
path: root/src/backend/postmaster/postmaster.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/backend/postmaster/postmaster.c')
-rw-r--r--src/backend/postmaster/postmaster.c9
1 files changed, 5 insertions, 4 deletions
diff --git a/src/backend/postmaster/postmaster.c b/src/backend/postmaster/postmaster.c
index 0a3064753d3..eba940cf428 100644
--- a/src/backend/postmaster/postmaster.c
+++ b/src/backend/postmaster/postmaster.c
@@ -37,7 +37,7 @@
*
*
* IDENTIFICATION
- * $PostgreSQL: pgsql/src/backend/postmaster/postmaster.c,v 1.611 2010/06/03 21:02:11 petere Exp $
+ * $PostgreSQL: pgsql/src/backend/postmaster/postmaster.c,v 1.612 2010/06/16 00:54:16 petere Exp $
*
* NOTES
*
@@ -3381,9 +3381,10 @@ BackendInitialize(Port *port)
(errmsg_internal("pg_getnameinfo_all() failed: %s",
gai_strerror(ret))));
}
- snprintf(remote_ps_data, sizeof(remote_ps_data),
- remote_port[0] == '\0' ? "%s" : "%s(%s)",
- remote_host, remote_port);
+ if (remote_port[0] == '\0')
+ snprintf(remote_ps_data, sizeof(remote_ps_data), "%s", remote_host);
+ else
+ snprintf(remote_ps_data, sizeof(remote_ps_data), "%s(%s)", remote_host, remote_port);
if (Log_connections)
{