diff options
Diffstat (limited to 'crypto/bio/bss_bio.c')
-rw-r--r-- | crypto/bio/bss_bio.c | 11 |
1 files changed, 3 insertions, 8 deletions
diff --git a/crypto/bio/bss_bio.c b/crypto/bio/bss_bio.c index c6bb3d6885..c9b8e7f1c6 100644 --- a/crypto/bio/bss_bio.c +++ b/crypto/bio/bss_bio.c @@ -170,10 +170,7 @@ static int bio_free(BIO *bio) if (b->peer) bio_destroy_pair(bio); - if (b->buf != NULL) { - OPENSSL_free(b->buf); - } - + OPENSSL_free(b->buf); OPENSSL_free(b); return 1; @@ -507,10 +504,8 @@ static long bio_ctrl(BIO *bio, int cmd, long num, void *ptr) size_t new_size = num; if (b->size != new_size) { - if (b->buf) { - OPENSSL_free(b->buf); - b->buf = NULL; - } + OPENSSL_free(b->buf); + b->buf = NULL; b->size = new_size; } ret = 1; |