From 3fea29baa97be9c132a8189eb00c7a782900d472 Mon Sep 17 00:00:00 2001 From: Ingo Franzki Date: Thu, 18 Nov 2021 10:15:53 +0100 Subject: [PATCH] API: Unlock GlobMutex if user and group check fails Closes: https://github.com/opencryptoki/opencryptoki/issues/493 Signed-off-by: Ingo Franzki --- usr/lib/api/api_interface.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/usr/lib/api/api_interface.c b/usr/lib/api/api_interface.c index 6fac7e0bf..20f605c3a 100644 --- a/usr/lib/api/api_interface.c +++ b/usr/lib/api/api_interface.c @@ -2872,7 +2872,7 @@ CK_RV C_Initialize(CK_VOID_PTR pVoid) rc = check_user_and_group(); if (rc != CKR_OK) - return rc; + goto done; if (!Anchor) { Anchor = (API_Proc_Struct_t *) malloc(sizeof(API_Proc_Struct_t));