Remove old ASN.1 code from evp_asn1.c
[openssl.git] / crypto / asn1 / d2i_pr.c
index c96da091d39c441a549619205ce0633d381d4562..793532f4933901827e696e4aec8da8dbc20f0532 100644 (file)
@@ -66,7 +66,7 @@
 #endif
 #include <openssl/x509.h>
 #include <openssl/asn1.h>
-#include "asn1_locl.h"
+#include "internal/asn1_int.h"
 
 EVP_PKEY *d2i_PrivateKey(int type, EVP_PKEY **a, const unsigned char **pp,
                          long length)
@@ -113,7 +113,7 @@ EVP_PKEY *d2i_PrivateKey(int type, EVP_PKEY **a, const unsigned char **pp,
         (*a) = ret;
     return (ret);
  err:
-    if ((ret != NULL) && ((a == NULL) || (*a != ret)))
+    if (a == NULL || *a != ret)
         EVP_PKEY_free(ret);
     return (NULL);
 }