trousers/trousers-0.3.14-unlock-in-err-path.patch
Troy Dawson c31e244e08 RHEL 9.0.0 Alpha bootstrap
The content of this branch was automatically imported from Fedora ELN
with the following as its source:
https://src.fedoraproject.org/rpms/trousers#ba65b02d14df4e4a21c824845cabda9bf5b5995d
2020-10-15 13:04:17 -07:00

12 lines
483 B
Diff

diff -ur a/src/tspi/obj_context.c b/src/tspi/obj_context.c
--- a/src/tspi/obj_context.c 2014-11-03 12:31:55.000000000 -0700
+++ b/src/tspi/obj_context.c 2018-08-10 11:02:02.246962638 -0700
@@ -276,6 +276,7 @@
context->machineName = (BYTE *)calloc(1, len);
if (context->machineName == NULL) {
LogError("malloc of %u bytes failed.", len);
+ obj_list_put(&context_list);
return TSPERR(TSS_E_OUTOFMEMORY);
}
memcpy(context->machineName, name, len);