From 90a06febf7b54540ac8bdf3c9ae89c062c1f2466 Mon Sep 17 00:00:00 2001 From: Christian Grothoff Date: Wed, 25 Jan 2017 15:53:43 +0100 Subject: [PATCH] fix leak --- src/core/core_api.c | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/src/core/core_api.c b/src/core/core_api.c index b6d8f61d2..18b07068f 100644 --- a/src/core/core_api.c +++ b/src/core/core_api.c @@ -204,6 +204,11 @@ disconnect_and_free_peer_entry (void *cls, pr)); GNUNET_MQ_destroy (pr->mq); GNUNET_assert (NULL == pr->mq); + if (NULL != pr->env) + { + GNUNET_MQ_discard (pr->env); + pr->env = NULL; + } GNUNET_free (pr); return GNUNET_YES; } -- 2.25.1