mirror of
https://github.com/isc-projects/bind9.git
synced 2026-06-13 23:30:01 -04:00
only emit a single space between mac length and the orginal id if the mac length is zero
(cherry picked from commit ac1c3aaa27)
This commit is contained in:
parent
2ff91a5143
commit
e4fd1abccf
1 changed files with 19 additions and 15 deletions
|
|
@ -187,22 +187,26 @@ totext_any_tsig(ARGS_TOTEXT) {
|
|||
/*
|
||||
* Signature.
|
||||
*/
|
||||
REQUIRE(n <= sr.length);
|
||||
sigr = sr;
|
||||
sigr.length = n;
|
||||
if ((tctx->flags & DNS_STYLEFLAG_MULTILINE) != 0)
|
||||
RETERR(str_totext(" (", target));
|
||||
RETERR(str_totext(tctx->linebreak, target));
|
||||
if (tctx->width == 0) /* No splitting */
|
||||
RETERR(isc_base64_totext(&sigr, 60, "", target));
|
||||
else
|
||||
RETERR(isc_base64_totext(&sigr, tctx->width - 2,
|
||||
tctx->linebreak, target));
|
||||
if ((tctx->flags & DNS_STYLEFLAG_MULTILINE) != 0)
|
||||
RETERR(str_totext(" ) ", target));
|
||||
else
|
||||
if (n != 0U) {
|
||||
REQUIRE(n <= sr.length);
|
||||
sigr = sr;
|
||||
sigr.length = n;
|
||||
if ((tctx->flags & DNS_STYLEFLAG_MULTILINE) != 0)
|
||||
RETERR(str_totext(" (", target));
|
||||
RETERR(str_totext(tctx->linebreak, target));
|
||||
if (tctx->width == 0) /* No splitting */
|
||||
RETERR(isc_base64_totext(&sigr, 60, "", target));
|
||||
else
|
||||
RETERR(isc_base64_totext(&sigr, tctx->width - 2,
|
||||
tctx->linebreak, target));
|
||||
if ((tctx->flags & DNS_STYLEFLAG_MULTILINE) != 0)
|
||||
RETERR(str_totext(" ) ", target));
|
||||
else
|
||||
RETERR(str_totext(" ", target));
|
||||
isc_region_consume(&sr, n);
|
||||
} else {
|
||||
RETERR(str_totext(" ", target));
|
||||
isc_region_consume(&sr, n);
|
||||
}
|
||||
|
||||
/*
|
||||
* Original ID.
|
||||
|
|
|
|||
Loading…
Reference in a new issue