From 29edb4dde0625cba9a8e4bb8df70009799bcbf3c Mon Sep 17 00:00:00 2001 From: Jan Hák Date: Wed, 18 Dec 2024 10:54:19 +0100 Subject: utils: use knsupdate style of output when printing UPDATE message --- src/utils/common/exec.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/utils/common/exec.c b/src/utils/common/exec.c index 798ae421f..b91cc605a 100644 --- a/src/utils/common/exec.c +++ b/src/utils/common/exec.c @@ -1133,7 +1133,9 @@ void print_packet(const knot_pkt_t *packet, } // Print DNS sections. - switch (style->format) { + format_t format = (knot_wire_get_opcode(packet->wire) == KNOT_OPCODE_UPDATE) + ? FORMAT_NSUPDATE : style->format; + switch (format) { case FORMAT_DIG: if (ancount > 0) { print_section_dig(knot_pkt_rr(answers, 0), ancount, style); -- cgit v1.2.3