From 7c66bf33e18939d7ee6fabc47ed624c8caa6c46c Mon Sep 17 00:00:00 2001 From: Niels Provos Date: Mon, 10 Sep 2007 01:30:11 +0000 Subject: [PATCH] fix a memory leak in the dns server; found by valgrind svn:r422 --- ChangeLog | 1 + evdns.c | 1 + 2 files changed, 2 insertions(+) diff --git a/ChangeLog b/ChangeLog index 9cadd717..6f82da9b 100644 --- a/ChangeLog +++ b/ChangeLog @@ -6,3 +6,4 @@ Changes in current version: o Support specifying the local address of an evhttp_connection using set_local_address o Fix a memory leak in which failed HTTP connections whould not free the request object o Make adding of array members in event_rpcgen more efficient, but doubling memory allocation + o Fix a memory leak in the DNS server diff --git a/evdns.c b/evdns.c index 4b0510e9..471f42a9 100644 --- a/evdns.c +++ b/evdns.c @@ -1729,6 +1729,7 @@ server_request_free(struct server_request *req) if (req->base.questions) { for (i = 0; i < req->base.nquestions; ++i) free(req->base.questions[i]); + free(req->base.questions); } if (req->port) { -- 2.40.0