From 2fa2dbd5fb9a3e7bc3cf29eff6b198581942d7b8 Mon Sep 17 00:00:00 2001 From: Mark Andrews Date: Thu, 2 Jul 2020 16:21:20 +1000 Subject: [PATCH] remove redundant rctx != NULL check --- lib/dns/client.c | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/lib/dns/client.c b/lib/dns/client.c index a86a5da468..11ecd05300 100644 --- a/lib/dns/client.c +++ b/lib/dns/client.c @@ -1407,10 +1407,8 @@ cleanup: if (sigrdataset != NULL) { putrdataset(client->mctx, &sigrdataset); } - if (rctx != NULL) { - isc_mutex_destroy(&rctx->lock); - isc_mem_put(mctx, rctx, sizeof(*rctx)); - } + isc_mutex_destroy(&rctx->lock); + isc_mem_put(mctx, rctx, sizeof(*rctx)); isc_event_free(ISC_EVENT_PTR(&event)); isc_task_detach(&tclone); dns_view_detach(&view);