From b09eff9f76e85d2f5bd3bf27880d342b1ff82b6c Mon Sep 17 00:00:00 2001 From: Jaime Casanova Date: Fri, 27 Apr 2012 02:08:40 -0500 Subject: [PATCH] Avoid the possibility of a double free. Fix by Carlo Ascani --- repmgrd.c | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/repmgrd.c b/repmgrd.c index c7005a9c..87214a74 100644 --- a/repmgrd.c +++ b/repmgrd.c @@ -456,7 +456,10 @@ checkNodeConfiguration(char *conninfo) exit(ERR_BAD_CONFIG); } } - PQclear(res); + else + { + PQclear(res); + } }