]> git.ipfire.org Git - thirdparty/bind9.git/commit
Define DNS_NAME_MAXLABELS and DNS_NAME_LABELLEN
authorTony Finch <fanf@isc.org>
Fri, 24 Feb 2023 08:10:20 +0000 (08:10 +0000)
committerTony Finch <fanf@isc.org>
Mon, 27 Feb 2023 11:27:12 +0000 (11:27 +0000)
commitc6bf51492dbd2606287e77eaae262fea80d583c5
treec9d5ab1cb0b977df5676cc1680ca7b028ca11c73
parentc3ae4e125c7cf39c0c618b3dd80ed59fb8de7194
Define DNS_NAME_MAXLABELS and DNS_NAME_LABELLEN

Some qp-trie operations will need to know the maximum number of labels
in a name, so I wanted a standard macro definition with the right
value.

Replace DNS_MAX_LABELS from <dns/resolver.h with DNS_NAME_MAXLABELS in
<dns/name.h>, and add its counterpart DNS_NAME_LABELLEN.

Use these macros in `name.c` and `resolver.c`.

Fix an off-by-one error in an assertion in `dns_name_countlabels()`.
lib/dns/include/dns/name.h
lib/dns/include/dns/resolver.h
lib/dns/name.c
lib/dns/resolver.c