diff options
author | Dr. Stephen Henson <steve@openssl.org> | 2002-06-13 00:43:27 +0000 |
---|---|---|
committer | Dr. Stephen Henson <steve@openssl.org> | 2002-06-13 00:43:27 +0000 |
commit | 04cc76660a46575c568125c997d0f3c73d4ec711 (patch) | |
tree | 3533e638d28bf9a17d59336bd5e6044e61d9f615 | |
parent | e1f7ea25d21966e2f2f17a908da570da42a5b14b (diff) |
The new ASN1 code automatically allocates
structures for fields that are not OPTIONAL.
However in the AUTHORITY_INFO_ACCESS case
the 'location' field was set to NULL in
the old code.
So in 0.9.7+ we should free up the field before
overwriting it in v2i_AUTHORITY_INFO_ACCESS.
-rw-r--r-- | crypto/x509v3/v3_info.c | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/crypto/x509v3/v3_info.c b/crypto/x509v3/v3_info.c index 7f17f3231d..e1cf01a9b4 100644 --- a/crypto/x509v3/v3_info.c +++ b/crypto/x509v3/v3_info.c @@ -158,6 +158,7 @@ static AUTHORITY_INFO_ACCESS *v2i_AUTHORITY_INFO_ACCESS(X509V3_EXT_METHOD *metho objlen = ptmp - cnf->name; ctmp.name = ptmp + 1; ctmp.value = cnf->value; + GENERAL_NAME_free(acc->location); if(!(acc->location = v2i_GENERAL_NAME(method, ctx, &ctmp))) goto err; if(!(objtmp = OPENSSL_malloc(objlen + 1))) { |