From dc70e2d804fc3503a0ee06e9dbb58c1f8c7effe8 Mon Sep 17 00:00:00 2001 From: Ian Barwick Date: Thu, 29 Sep 2016 11:53:13 +0900 Subject: [PATCH] Remove superfluous PQfinish() call Connection was previously closed, if this error condition is triggered a segfault will occur. --- repmgr.c | 1 - 1 file changed, 1 deletion(-) diff --git a/repmgr.c b/repmgr.c index d83e308a..d0018c79 100644 --- a/repmgr.c +++ b/repmgr.c @@ -1500,7 +1500,6 @@ build_cluster_diagnose(int **cube, char **node_names, int *name_length) if (sscanf(p, "%d,%d,%d", &x, &y, &z) != 3) { fprintf(stderr, _("cannot parse --csv output: %s\n"), p); - PQfinish(conn); exit(ERR_INTERNAL); } (*cube)[i * n * n + (x - 1) * n + (y - 1)] =