mirror of
https://github.com/isc-projects/bind9.git
synced 2026-05-27 20:25:55 -04:00
Use SET_IF_NOT_NULL in isc__nm_base64*
(cherry picked from commit d91e8ed575)
This commit is contained in:
parent
d14f5cb894
commit
184cb00814
1 changed files with 2 additions and 6 deletions
|
|
@ -3582,9 +3582,7 @@ isc__nm_base64url_to_base64(isc_mem_t *mem, const char *base64url,
|
|||
|
||||
INSIST(i == len);
|
||||
|
||||
if (res_len != NULL) {
|
||||
*res_len = len;
|
||||
}
|
||||
SET_IF_NOT_NULL(res_len, len);
|
||||
|
||||
res[len] = '\0';
|
||||
|
||||
|
|
@ -3635,9 +3633,7 @@ isc__nm_base64_to_base64url(isc_mem_t *mem, const char *base64,
|
|||
}
|
||||
}
|
||||
end:
|
||||
if (res_len) {
|
||||
*res_len = i;
|
||||
}
|
||||
SET_IF_NOT_NULL(res_len, i);
|
||||
|
||||
res[i] = '\0';
|
||||
|
||||
|
|
|
|||
Loading…
Reference in a new issue