diff options
Diffstat (limited to 'src/lib/libcrypto/asn1/x_info.c')
| -rw-r--r-- | src/lib/libcrypto/asn1/x_info.c | 19 |
1 files changed, 11 insertions, 8 deletions
diff --git a/src/lib/libcrypto/asn1/x_info.c b/src/lib/libcrypto/asn1/x_info.c index b55f0ce77a..d44f6cdb01 100644 --- a/src/lib/libcrypto/asn1/x_info.c +++ b/src/lib/libcrypto/asn1/x_info.c | |||
| @@ -58,15 +58,15 @@ | |||
| 58 | 58 | ||
| 59 | #include <stdio.h> | 59 | #include <stdio.h> |
| 60 | #include "cryptlib.h" | 60 | #include "cryptlib.h" |
| 61 | #include "evp.h" | 61 | #include <openssl/evp.h> |
| 62 | #include "asn1_mac.h" | 62 | #include <openssl/asn1.h> |
| 63 | #include "x509.h" | 63 | #include <openssl/x509.h> |
| 64 | 64 | ||
| 65 | X509_INFO *X509_INFO_new() | 65 | X509_INFO *X509_INFO_new(void) |
| 66 | { | 66 | { |
| 67 | X509_INFO *ret=NULL; | 67 | X509_INFO *ret=NULL; |
| 68 | 68 | ||
| 69 | ret=(X509_INFO *)Malloc(sizeof(X509_INFO)); | 69 | ret=(X509_INFO *)OPENSSL_malloc(sizeof(X509_INFO)); |
| 70 | if (ret == NULL) | 70 | if (ret == NULL) |
| 71 | { | 71 | { |
| 72 | ASN1err(ASN1_F_X509_INFO_NEW,ERR_R_MALLOC_FAILURE); | 72 | ASN1err(ASN1_F_X509_INFO_NEW,ERR_R_MALLOC_FAILURE); |
| @@ -84,8 +84,7 @@ X509_INFO *X509_INFO_new() | |||
| 84 | return(ret); | 84 | return(ret); |
| 85 | } | 85 | } |
| 86 | 86 | ||
| 87 | void X509_INFO_free(x) | 87 | void X509_INFO_free(X509_INFO *x) |
| 88 | X509_INFO *x; | ||
| 89 | { | 88 | { |
| 90 | int i; | 89 | int i; |
| 91 | 90 | ||
| @@ -107,5 +106,9 @@ X509_INFO *x; | |||
| 107 | if (x->x509 != NULL) X509_free(x->x509); | 106 | if (x->x509 != NULL) X509_free(x->x509); |
| 108 | if (x->crl != NULL) X509_CRL_free(x->crl); | 107 | if (x->crl != NULL) X509_CRL_free(x->crl); |
| 109 | if (x->x_pkey != NULL) X509_PKEY_free(x->x_pkey); | 108 | if (x->x_pkey != NULL) X509_PKEY_free(x->x_pkey); |
| 110 | Free((char *)x); | 109 | if (x->enc_data != NULL) OPENSSL_free(x->enc_data); |
| 110 | OPENSSL_free(x); | ||
| 111 | } | 111 | } |
| 112 | |||
| 113 | IMPLEMENT_STACK_OF(X509_INFO) | ||
| 114 | |||
