Fix memory leak in GENERAL_NAME_set0_othername.
CLA: trivial Reviewed-by: Tim Hudson <tjh@openssl.org> Reviewed-by: Richard Levitte <levitte@openssl.org> (Merged from https://github.com/openssl/openssl/pull/4544)
This commit is contained in:
parent
590bbdfdf4
commit
04761b557a
1 changed files with 1 additions and 0 deletions
|
@ -181,6 +181,7 @@ int GENERAL_NAME_set0_othername(GENERAL_NAME *gen,
|
|||
oth = OTHERNAME_new();
|
||||
if (oth == NULL)
|
||||
return 0;
|
||||
ASN1_TYPE_free(oth->value);
|
||||
oth->type_id = oid;
|
||||
oth->value = value;
|
||||
GENERAL_NAME_set0_value(gen, GEN_OTHERNAME, oth);
|
||||
|
|
Loading…
Reference in a new issue