BIO_set_prefix: fix return check

Reviewed-by: Paul Dale <pauli@openssl.org>
Reviewed-by: Tomas Mraz <tomas@openssl.org>
(Merged from https://github.com/openssl/openssl/pull/17028)
This commit is contained in:
Peiwei Hu 2021-11-14 23:45:39 +08:00 committed by Tomas Mraz
parent a8f4cdd70c
commit ac6568ecc6

View File

@ -242,7 +242,7 @@ static int setup(void)
progname, idx, amount - 1);
return 0;
}
if (!BIO_set_prefix(chain[idx], colon)) {
if (BIO_set_prefix(chain[idx], colon) <= 0) {
BIO_printf(bio_err, "%s: failed setting prefix: %s",
progname, arg);
return 0;