aboutsummaryrefslogtreecommitdiffstats
path: root/crypto/asn1/tasn_dec.c
diff options
context:
space:
mode:
authorDr. Stephen Henson <steve@openssl.org>2006-08-31 20:10:37 +0000
committerDr. Stephen Henson <steve@openssl.org>2006-08-31 20:10:37 +0000
commit539d4c1030d8e69801d56787d6d2fd50cfcb8c2e (patch)
treeacd696e2436250316c54ee7310a45521dff80f31 /crypto/asn1/tasn_dec.c
parentaa6d1a0c19c2f7631b2d3473e4ae25581d2b4dff (diff)
downloadopenssl-539d4c1030d8e69801d56787d6d2fd50cfcb8c2e.tar.gz
Fix leak
Diffstat (limited to 'crypto/asn1/tasn_dec.c')
-rw-r--r--crypto/asn1/tasn_dec.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/crypto/asn1/tasn_dec.c b/crypto/asn1/tasn_dec.c
index 0eefcfb6e0..fe1bfd0a90 100644
--- a/crypto/asn1/tasn_dec.c
+++ b/crypto/asn1/tasn_dec.c
@@ -878,7 +878,10 @@ static int asn1_d2i_ex_primitive(ASN1_VALUE **pval,
* for UNIVERSAL class and ignore the tag.
*/
if (!asn1_collect(&buf, &p, plen, inf, -1, V_ASN1_UNIVERSAL))
+ {
+ free_cont = 1;
goto err;
+ }
len = buf.length;
/* Append a final null to string */
if (!BUF_MEM_grow_clean(&buf, len + 1))