From 3c13a0d05e83e23fd5846e66c8da2c0e87dbb88b Mon Sep 17 00:00:00 2001 From: Josh Kupershmidt Date: Sun, 18 Nov 2012 14:36:09 -0700 Subject: [PATCH] Don't forget to disconnect conn2 when disconnect() is called, otherwise we leave a connection hanging open for every database processed via pg_repack -a. --- bin/pgut/pgut-fe.c | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/bin/pgut/pgut-fe.c b/bin/pgut/pgut-fe.c index bcea19f..c7f888c 100644 --- a/bin/pgut/pgut-fe.c +++ b/bin/pgut/pgut-fe.c @@ -77,6 +77,11 @@ disconnect(void) pgut_disconnect(connection); connection = NULL; } + if (conn2) + { + pgut_disconnect(conn2); + conn2 = NULL; + } } static void