From a2f907def2edfc825d9e3cec19c6bc1c6c035661 Mon Sep 17 00:00:00 2001 From: doug <> Date: Fri, 25 Jul 2014 06:05:32 +0000 Subject: BIO_free() returns immediately when the sole input is NULL. Remove unnecessary NULL check. ok miod@ --- src/lib/libcrypto/asn1/bio_ndef.c | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) (limited to 'src/lib/libcrypto/asn1') diff --git a/src/lib/libcrypto/asn1/bio_ndef.c b/src/lib/libcrypto/asn1/bio_ndef.c index fd6b0e5f17..1a23c27d04 100644 --- a/src/lib/libcrypto/asn1/bio_ndef.c +++ b/src/lib/libcrypto/asn1/bio_ndef.c @@ -1,4 +1,4 @@ -/* $OpenBSD: bio_ndef.c,v 1.8 2014/06/12 15:49:27 deraadt Exp $ */ +/* $OpenBSD: bio_ndef.c,v 1.9 2014/07/25 06:05:32 doug Exp $ */ /* Written by Dr Stephen N Henson (steve@openssl.org) for the OpenSSL * project. */ @@ -144,8 +144,7 @@ BIO_new_NDEF(BIO *out, ASN1_VALUE *val, const ASN1_ITEM *it) return sarg.ndef_bio; err: - if (asn_bio) - BIO_free(asn_bio); + BIO_free(asn_bio); free(ndef_aux); return NULL; } -- cgit v1.2.3-55-g6feb