From: Vladimír Čunát Date: Fri, 10 Nov 2017 10:14:53 +0000 (+0100) Subject: fix clang warnings X-Git-Tag: v2.0.0~6^2~71 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=96fe93320bdec99e9e043b4475a35dcde3041ae6;p=thirdparty%2Fknot-resolver.git fix clang warnings --- diff --git a/daemon/bindings.c b/daemon/bindings.c index ce75fb276..cbbbb18be 100644 --- a/daemon/bindings.c +++ b/daemon/bindings.c @@ -891,7 +891,7 @@ static int cache_get(lua_State *L) } /* Clear a sub-tree in cache. */ - const char *args = lua_tostring(L, 1); + //const char *args = lua_tostring(L, 1); /* Retrieve set of keys */ static knot_db_val_t result_set[100]; int ret = kr_error(ENOSYS); // FIXME cache_prefixed(cache, args, result_set, 100); diff --git a/lib/layer/iterate.c b/lib/layer/iterate.c index dfd738cb6..efed229ab 100644 --- a/lib/layer/iterate.c +++ b/lib/layer/iterate.c @@ -284,7 +284,7 @@ static int update_cut(knot_pkt_t *pkt, const knot_rrset_t *rr, continue; } int ret = kr_zonecut_add(cut, ns_name, NULL); - assert(!ret); + assert(!ret); (void)ret; /* Choose when to use glue records. */ bool in_bailiwick = knot_dname_in(current_cut, ns_name); diff --git a/lib/zonecut.c b/lib/zonecut.c index b7e0ca70d..398bbbf07 100644 --- a/lib/zonecut.c +++ b/lib/zonecut.c @@ -272,7 +272,6 @@ int kr_zonecut_set_sbelt(struct kr_context *ctx, struct kr_zonecut *cut) static void fetch_addr(struct kr_zonecut *cut, struct kr_cache *cache, const knot_dname_t *ns, uint16_t rrtype, uint32_t timestamp) // LATER(optim.): excessive data copying { - uint8_t rank = 0; struct kr_cache_p peek = {}; if (kr_cache_peek_exact(cache, ns, rrtype, &peek) != 0) { return;