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/x509/x509spki.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/x509/x509spki.c')
-rw-r--r-- | crypto/x509/x509spki.c | 6 |
1 files changed, 2 insertions, 4 deletions
diff --git a/crypto/x509/x509spki.c b/crypto/x509/x509spki.c index 347ab4cd7b..fb46d4e3af 100644 --- a/crypto/x509/x509spki.c +++ b/crypto/x509/x509spki.c @@ -113,10 +113,8 @@ char *NETSCAPE_SPKI_b64_encode(NETSCAPE_SPKI *spki) b64_str = OPENSSL_malloc(der_len * 2); if (!der_spki || !b64_str) { X509err(X509_F_NETSCAPE_SPKI_B64_ENCODE, ERR_R_MALLOC_FAILURE); - if (der_spki != NULL) - OPENSSL_free(der_spki); - if (b64_str != NULL) - OPENSSL_free(b64_str); + OPENSSL_free(der_spki); + OPENSSL_free(b64_str); return NULL; } p = der_spki; |