summaryrefslogtreecommitdiffstats
path: root/src/libknot/rrset-dump.c
diff options
context:
space:
mode:
authorDaniel Baumann <daniel.baumann@progress-linux.org>2024-04-13 08:02:36 +0000
committerDaniel Baumann <daniel.baumann@progress-linux.org>2024-04-13 08:02:36 +0000
commit07978ec28369b472f255fd7dde9085f42509e153 (patch)
treeb6614badfed18e6417673cf106d36d9d2dd6fff0 /src/libknot/rrset-dump.c
parentAdding upstream version 3.3.4. (diff)
downloadknot-07978ec28369b472f255fd7dde9085f42509e153.tar.xz
knot-07978ec28369b472f255fd7dde9085f42509e153.zip
Adding upstream version 3.3.5.upstream/3.3.5
Signed-off-by: Daniel Baumann <daniel.baumann@progress-linux.org>
Diffstat (limited to 'src/libknot/rrset-dump.c')
-rw-r--r--src/libknot/rrset-dump.c8
1 files changed, 6 insertions, 2 deletions
diff --git a/src/libknot/rrset-dump.c b/src/libknot/rrset-dump.c
index 7011a65..51a52dd 100644
--- a/src/libknot/rrset-dump.c
+++ b/src/libknot/rrset-dump.c
@@ -1,4 +1,4 @@
-/* Copyright (C) 2023 CZ.NIC, z.s.p.o. <knot-dns@labs.nic.cz>
+/* Copyright (C) 2024 CZ.NIC, z.s.p.o. <knot-dns@labs.nic.cz>
This program is free software: you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
@@ -598,7 +598,7 @@ static void wire_text_to_str(rrset_dump_params_t *p, size_t in_len,
CHECK_INMAX(in_len)
// Check if quotation can ever be disabled (parser protection fallback).
- if (!quote) {
+ if (!quote && !alpn_mode) {
for (size_t i = 0; i < in_len; i++) {
if (p->in[i] == ' ') { // Other WS characters are encoded.
quote = true;
@@ -1515,7 +1515,11 @@ static void wire_svcparam_to_str(rrset_dump_params_t *p)
wire_value_list_to_str(p, wire_svcb_paramkey_to_str, p->in + val_len);
break;
case KNOT_SVCB_PARAM_ALPN:
+ dump_string(p, "\"");
+ CHECK_PRET
wire_value_list_to_str(p, wire_text_to_str_alpn, p->in + val_len);
+ dump_string(p, "\"");
+ CHECK_PRET
break;
case KNOT_SVCB_PARAM_NDALPN:
p->ret = -1; // must not have value