From: Vladimír Čunát Date: Wed, 17 May 2017 11:00:33 +0000 (+0200) Subject: validate: fix a typo leading to lower rank X-Git-Tag: v1.3.0~18^2 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=47d1fcd57c1253e7858f8d3839396b785ff5aea4;p=thirdparty%2Fknot-resolver.git validate: fix a typo leading to lower rank The authority records weren't marked with _INSECURE rank and remained with a *lower* one. That could lead to them not being cached, effectively. --- diff --git a/lib/layer/validate.c b/lib/layer/validate.c index 32d63ff82..9b9b43d24 100644 --- a/lib/layer/validate.c +++ b/lib/layer/validate.c @@ -590,7 +590,7 @@ static void rank_records(kr_layer_t *ctx, uint8_t rank_to_set) struct kr_request *req = ctx->req; struct kr_query *qry = req->current_query; ranked_rr_array_t *ptrs[2] = { &req->answ_selected, &req->auth_selected }; - for (size_t i = 0; i < 1; ++i) { + for (size_t i = 0; i < 2; ++i) { ranked_rr_array_t *arr = ptrs[i]; for (size_t j = 0; j < arr->len; ++j) { ranked_rr_array_entry_t *entry = arr->at[j];