Fix memory leak in GENERAL_NAME_set0_othername.
(Imported from upstream's deee898ef94a176a22fce3b9effc957cb75bb535.) Change-Id: Ifcef31baa1f8b185c2014481ca9bb4e23fe74a53 Reviewed-on: https://boringssl-review.googlesource.com/22364 Commit-Queue: Steven Valdez <svaldez@google.com> Reviewed-by: Steven Valdez <svaldez@google.com> CQ-Verified: CQ bot account: commit-bot@chromium.org <commit-bot@chromium.org>
This commit is contained in:
parent
98ca81daae
commit
a67b101594
@ -231,6 +231,7 @@ int GENERAL_NAME_set0_othername(GENERAL_NAME *gen,
|
||||
oth = OTHERNAME_new();
|
||||
if (!oth)
|
||||
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 New Issue
Block a user