From 9b73be38abe18a09ef8a767ca4af1c31731a7fa5 Mon Sep 17 00:00:00 2001 From: "Dr. Stephen Henson" Date: Mon, 27 Feb 2012 16:27:00 +0000 Subject: [PATCH] free headers after use in error message --- crypto/asn1/asn_mime.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/crypto/asn1/asn_mime.c b/crypto/asn1/asn_mime.c index dc2a35d0c8..42536f77e3 100644 --- a/crypto/asn1/asn_mime.c +++ b/crypto/asn1/asn_mime.c @@ -486,9 +486,9 @@ ASN1_VALUE *SMIME_read_ASN1(BIO *bio, BIO **bcont, const ASN1_ITEM *it) if(strcmp(hdr->value, "application/x-pkcs7-signature") && strcmp(hdr->value, "application/pkcs7-signature")) { - sk_MIME_HEADER_pop_free(headers, mime_hdr_free); ASN1err(ASN1_F_SMIME_READ_ASN1,ASN1_R_SIG_INVALID_MIME_TYPE); ERR_add_error_data(2, "type: ", hdr->value); + sk_MIME_HEADER_pop_free(headers, mime_hdr_free); sk_BIO_pop_free(parts, BIO_vfree); return NULL; } -- 2.25.1