From 8f683115512d6a6a3fbad934a21021b8ccd727a8 Mon Sep 17 00:00:00 2001 From: Marko Kreen Date: Thu, 3 Mar 2011 23:35:23 +0200 Subject: [PATCH] Fix uninitialized variable problems --- src/objects.c | 2 +- src/util.c | 1 + 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/src/objects.c b/src/objects.c index e93b3d2..48533d0 100644 --- a/src/objects.c +++ b/src/objects.c @@ -1048,7 +1048,7 @@ bool finish_client_login(PgSocket *client) void accept_cancel_request(PgSocket *req) { struct List *pitem, *citem; - PgPool *pool; + PgPool *pool = NULL; PgSocket *server = NULL, *client, *main_client = NULL; Assert(req->state == CL_LOGIN); diff --git a/src/util.c b/src/util.c index 951de4f..afa9683 100644 --- a/src/util.c +++ b/src/util.c @@ -43,6 +43,7 @@ int log_socket_prefix(enum LogLevel lev, void *ctx, char *dst, unsigned int dstl host = "unix"; } else { pga_ntop(&sock->remote_addr, host6, INET6_ADDRSTRLEN); + host = host6; } port = pga_port(&sock->remote_addr); -- 2.40.0