From d1cac7c0fe9b41dced22f3ddbfc17f26b0f457f7 Mon Sep 17 00:00:00 2001 From: ian Date: Tue, 27 Jun 2000 23:16:48 +0000 Subject: [PATCH] + * Do not free something twice if query fails and is then cancelled. @@ -10,6 +10,7 @@ + * Do not free something twice if query fails and is then cancelled. --- changelog | 1 + src/query.c | 1 + 2 files changed, 2 insertions(+) diff --git a/changelog b/changelog index fa349c0..647762d 100644 --- a/changelog +++ b/changelog @@ -10,6 +10,7 @@ adns (0.9) unstable; urgency=high * Do not spin if TCP connection blocks for writing (and add test case). * Fail queries if TCP dies repeatedly, rather than retrying many times. * Do not abort in a couple of places if TCP unexpectedly broken. + * Do not free something twice if query fails and is then cancelled. Portability/compilation fixes: * Move `extern "C" {' to after #include <...>'s. diff --git a/src/query.c b/src/query.c index 966f409..61ae7be 100644 --- a/src/query.c +++ b/src/query.c @@ -423,6 +423,7 @@ static void free_query_allocs(adns_query qu) { adns__vbuf_free(&qu->vb); adns__vbuf_free(&qu->search_vb); free(qu->query_dgram); + qu->query_dgram= 0; } void adns_cancel(adns_query qu) { -- 2.11.0