diff options
author | Dr. David von Oheimb <David.von.Oheimb@siemens.com> | 2020-12-21 08:16:30 +0100 |
---|---|---|
committer | Dr. David von Oheimb <dev@ddvo.net> | 2021-01-16 11:29:43 +0100 |
commit | ed4a9b15d9cd1eea7493873d01949f075cea2b65 (patch) | |
tree | 3ab4f7e4257ccf2bf823d085b6f3c7a5a3fe0215 /crypto/bio/bio_lib.c | |
parent | dc88a0390608ccba76df6a26358215d1c0592948 (diff) |
replace all BIO_R_NULL_PARAMETER by ERR_R_PASSED_NULL_PARAMETER
Reviewed-by: Tomas Mraz <tomas@openssl.org>
(Merged from https://github.com/openssl/openssl/pull/13713)
Diffstat (limited to 'crypto/bio/bio_lib.c')
-rw-r--r-- | crypto/bio/bio_lib.c | 22 |
1 files changed, 11 insertions, 11 deletions
diff --git a/crypto/bio/bio_lib.c b/crypto/bio/bio_lib.c index 3f86db41b1..17537de6d9 100644 --- a/crypto/bio/bio_lib.c +++ b/crypto/bio/bio_lib.c @@ -253,7 +253,7 @@ static int bio_read_intern(BIO *b, void *data, size_t dlen, size_t *readbytes) int ret; if (b == NULL) { - ERR_raise(ERR_LIB_BIO, BIO_R_NULL_PARAMETER); + ERR_raise(ERR_LIB_BIO, ERR_R_PASSED_NULL_PARAMETER); return -1; } if (b->method == NULL || b->method->bread == NULL) { @@ -318,7 +318,7 @@ static int bio_write_intern(BIO *b, const void *data, size_t dlen, int ret; if (b == NULL) { - ERR_raise(ERR_LIB_BIO, BIO_R_NULL_PARAMETER); + ERR_raise(ERR_LIB_BIO, ERR_R_PASSED_NULL_PARAMETER); return -1; } if (b->method == NULL || b->method->bwrite == NULL) { @@ -377,7 +377,7 @@ int BIO_puts(BIO *b, const char *buf) size_t written = 0; if (b == NULL) { - ERR_raise(ERR_LIB_BIO, BIO_R_NULL_PARAMETER); + ERR_raise(ERR_LIB_BIO, ERR_R_PASSED_NULL_PARAMETER); return -1; } if (b->method == NULL || b->method->bputs == NULL) { @@ -426,7 +426,7 @@ int BIO_gets(BIO *b, char *buf, int size) size_t readbytes = 0; if (b == NULL) { - ERR_raise(ERR_LIB_BIO, BIO_R_NULL_PARAMETER); + ERR_raise(ERR_LIB_BIO, ERR_R_PASSED_NULL_PARAMETER); return -1; } if (b->method == NULL || b->method->bgets == NULL) { @@ -507,7 +507,7 @@ long BIO_ctrl(BIO *b, int cmd, long larg, void *parg) long ret; if (b == NULL) { - ERR_raise(ERR_LIB_BIO, BIO_R_NULL_PARAMETER); + ERR_raise(ERR_LIB_BIO, ERR_R_PASSED_NULL_PARAMETER); return -1; } if (b->method == NULL || b->method->ctrl == NULL) { @@ -535,8 +535,8 @@ long BIO_callback_ctrl(BIO *b, int cmd, BIO_info_cb *fp) long ret; if (b == NULL) { - ERR_raise(ERR_LIB_BIO, BIO_R_NULL_PARAMETER); - return -1; + ERR_raise(ERR_LIB_BIO, ERR_R_PASSED_NULL_PARAMETER); + return -2; } if (b->method == NULL || b->method->callback_ctrl == NULL || cmd != BIO_CTRL_SET_CALLBACK) { @@ -599,7 +599,7 @@ BIO *BIO_pop(BIO *b) BIO *ret; if (b == NULL) { - ERR_raise(ERR_LIB_BIO, BIO_R_NULL_PARAMETER); + ERR_raise(ERR_LIB_BIO, ERR_R_PASSED_NULL_PARAMETER); return NULL; } ret = b->next_bio; @@ -649,7 +649,7 @@ BIO *BIO_find_type(BIO *bio, int type) int mt, mask; if (bio == NULL) { - ERR_raise(ERR_LIB_BIO, BIO_R_NULL_PARAMETER); + ERR_raise(ERR_LIB_BIO, ERR_R_PASSED_NULL_PARAMETER); return NULL; } mask = type & 0xff; @@ -672,7 +672,7 @@ BIO *BIO_find_type(BIO *bio, int type) BIO *BIO_next(BIO *b) { if (b == NULL) { - ERR_raise(ERR_LIB_BIO, BIO_R_NULL_PARAMETER); + ERR_raise(ERR_LIB_BIO, ERR_R_PASSED_NULL_PARAMETER); return NULL; } return b->next_bio; @@ -855,7 +855,7 @@ int BIO_do_connect_retry(BIO *bio, int timeout, int nap_milliseconds) int rv; if (bio == NULL) { - ERR_raise(ERR_LIB_BIO, BIO_R_NULL_PARAMETER); + ERR_raise(ERR_LIB_BIO, ERR_R_PASSED_NULL_PARAMETER); return -1; } |