From: Mukund Sivaraman Date: Mon, 28 Jul 2014 03:11:59 +0000 (+0530) Subject: 3900. [bug] Fix a crash in PostgreSQL DLZ driver. [RT #36637] X-Git-Tag: v9.11.0a1~1447 X-Git-Url: http://git.ipfire.org/gitweb/?a=commitdiff_plain;h=586db4a3e4664109fe8ce31fdd6a1b9c5bb67cbf;p=thirdparty%2Fbind9.git 3900. [bug] Fix a crash in PostgreSQL DLZ driver. [RT #36637] Squashed commit of the following: commit ebdade4dfe59fc11d3c4ad8111729f722aab2008 Author: Mukund Sivaraman Date: Thu Jul 24 22:52:54 2014 +0530 Move statement to be after comment commit 4b5d6a33350a469afb8e273bc552055824a32570 Author: Mukund Sivaraman Date: Thu Jul 24 21:42:52 2014 +0530 Return NULL in *rs so that caller doesn't PQclear() it again --- diff --git a/CHANGES b/CHANGES index b2bcd033a01..ba766b8e243 100644 --- a/CHANGES +++ b/CHANGES @@ -1,3 +1,5 @@ +3900. [bug] Fix a crash in PostgreSQL DLZ driver. [RT #36637] + 3899. [bug] "request-ixfr" is only applicable to slave and redirect zones. [RT #36608] diff --git a/contrib/dlz/drivers/dlz_postgres_driver.c b/contrib/dlz/drivers/dlz_postgres_driver.c index ac64c8fbe83..6c6082dad27 100644 --- a/contrib/dlz/drivers/dlz_postgres_driver.c +++ b/contrib/dlz/drivers/dlz_postgres_driver.c @@ -577,6 +577,7 @@ postgres_get_resultset(const char *zone, const char *record, #endif PQclear(*rs); /* get rid of it */ /* in case this was the last attempt */ + *rs = NULL; result = ISC_R_FAILURE; } }