]> git.ipfire.org Git - thirdparty/openssl.git/commit
Fix incomplete error check on BIO_set_accept_name()
authorndossche <niels.dossche@ugent.be>
Fri, 3 Feb 2023 12:43:03 +0000 (13:43 +0100)
committerTodd Short <todd.short@me.com>
Wed, 8 Feb 2023 14:35:19 +0000 (09:35 -0500)
commita811b6305b1f98e8ec66b8a426d359150fea69b2
treed6c0c2e5508d3f108118123babbcde88467a81d9
parenta97ca33f83cc6201fe11d6c76a035c05dbaaf5bc
Fix incomplete error check on BIO_set_accept_name()

BIO_set_accept_name() can return error values -1 and 0 according to
my analysis tool and the documentation. Documentation says a value of 1
indicates success. Currently, only an error value != 0 is checked which
erroneously interprets a -1 error return value as success.
Fix it by changing the check condition.

CLA: trivial

Reviewed-by: Tomas Mraz <tomas@openssl.org>
Reviewed-by: Paul Dale <pauli@openssl.org>
Reviewed-by: Todd Short <todd.short@me.com>
(Merged from https://github.com/openssl/openssl/pull/20206)
crypto/bio/bss_acpt.c