From 19b14f69a9683ce8672d8a7da4be0efe81832df4 Mon Sep 17 00:00:00 2001 From: Rithvik Vibhu Date: Thu, 7 Mar 2024 00:26:55 +0530 Subject: [PATCH] rs: do not strip authority section in response --- src/rs.c | 7 +------ 1 file changed, 1 insertion(+), 6 deletions(-) diff --git a/src/rs.c b/src/rs.c index 3794190d..7c82b879 100644 --- a/src/rs.c +++ b/src/rs.c @@ -458,13 +458,8 @@ hsk_rs_respond( if (result->secure && !result->bogus) msg->flags |= HSK_DNS_AD; - // Strip out non-answer sections. + // Strip out additional section if (msg->an.size > 0) { - while (msg->ns.size > 0) { - hsk_dns_rr_t *rr = hsk_dns_rrs_pop(&msg->ns); - hsk_dns_rr_free(rr); - } - while (msg->ar.size > 0) { hsk_dns_rr_t *rr = hsk_dns_rrs_pop(&msg->ar); hsk_dns_rr_free(rr);