From: Vladimír Čunát Date: Wed, 11 Jan 2017 14:27:04 +0000 (+0100) Subject: utils: fix coverity warning 155456 X-Git-Tag: v1.2.0-rc1~29^2 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=247ac6c41f9f719ad9491647dc84721c3a0bed95;p=thirdparty%2Fknot-resolver.git utils: fix coverity warning 155456 I think the memory wouldn't really leak, due to being on a per-request mempool, but it still seems better to do this properly. --- diff --git a/lib/utils.c b/lib/utils.c index 35a7c19b2..2588ba159 100644 --- a/lib/utils.c +++ b/lib/utils.c @@ -450,6 +450,7 @@ int kr_ranked_rrarray_add(ranked_rr_array_t *array, const knot_rrset_t *rr, } knot_rrset_t *copy = knot_rrset_copy(rr, pool); if (!copy) { + mm_free(pool, entry); return kr_error(ENOMEM); }