diff options
author | Rich Salz <rsalz@openssl.org> | 2015-05-01 10:02:07 -0400 |
---|---|---|
committer | Rich Salz <rsalz@openssl.org> | 2015-05-01 10:02:07 -0400 |
commit | b548a1f11c06ccdfa4f52a539912d22d77ee309e (patch) | |
tree | 37ff8792ddf09e4805aa3ba76b805923d3c52734 /crypto/asn1/bio_ndef.c | |
parent | 33fbca83dcd05b77f807fab205c4523b8cfe85b5 (diff) |
free null cleanup finale
Don't check for NULL before calling OPENSSL_free
Reviewed-by: Richard Levitte <levitte@openssl.org>
Diffstat (limited to 'crypto/asn1/bio_ndef.c')
-rw-r--r-- | crypto/asn1/bio_ndef.c | 6 |
1 files changed, 2 insertions, 4 deletions
diff --git a/crypto/asn1/bio_ndef.c b/crypto/asn1/bio_ndef.c index 99ab5f66e1..de517f22e4 100644 --- a/crypto/asn1/bio_ndef.c +++ b/crypto/asn1/bio_ndef.c @@ -143,8 +143,7 @@ BIO *BIO_new_NDEF(BIO *out, ASN1_VALUE *val, const ASN1_ITEM *it) err: BIO_free(asn_bio); - if (ndef_aux) - OPENSSL_free(ndef_aux); + OPENSSL_free(ndef_aux); return NULL; } @@ -186,8 +185,7 @@ static int ndef_prefix_free(BIO *b, unsigned char **pbuf, int *plen, ndef_aux = *(NDEF_SUPPORT **)parg; - if (ndef_aux->derbuf) - OPENSSL_free(ndef_aux->derbuf); + OPENSSL_free(ndef_aux->derbuf); ndef_aux->derbuf = NULL; *pbuf = NULL; |