diff options
author | tb <> | 2023-05-12 13:56:17 +0000 |
---|---|---|
committer | tb <> | 2023-05-12 13:56:17 +0000 |
commit | 3c367af393ea803ce1c1eb36aac82b354c7816ec (patch) | |
tree | 3b81e8e07c4ef4750171db0536d98ab2381ad47c /src/lib/libtls/tls_util.c | |
parent | 691f32f6d318c9bab9c2d738a840e54776d6d9e8 (diff) | |
download | openbsd-3c367af393ea803ce1c1eb36aac82b354c7816ec.tar.gz openbsd-3c367af393ea803ce1c1eb36aac82b354c7816ec.tar.bz2 openbsd-3c367af393ea803ce1c1eb36aac82b354c7816ec.zip |
Rewrite string_to_hex() and hex_to_string() using CBB/CBS
These helpers used to contain messy pointer bashing some with weird logic
for NUL termination. This can be written more safely and cleanly using
CBB/CBS, so do that. The result is nearly but not entirely identical to
code used elsewhere due to some strange semantics. Apart from errors pushed
on the stack due to out-of-memory conditions, care was taken to preserve
error codes.
ok jsing
Diffstat (limited to 'src/lib/libtls/tls_util.c')
0 files changed, 0 insertions, 0 deletions