Windows: Fix wrong parameter to CloseHandle function in case of failure of CreateEvent (Coverity)

This commit is contained in:
Mounir IDRASSI 2022-03-26 18:43:28 +01:00
parent 69a9c6b394
commit 533269ca9a
No known key found for this signature in database
GPG Key ID: 02C30AE90FAE4A6F
1 changed files with 1 additions and 1 deletions

View File

@ -285,7 +285,7 @@ int ReadVolumeHeader (BOOL bBoot, char *encryptedHeader, Password *password, int
*noOutstandingWorkItemEvent = CreateEvent (NULL, FALSE, TRUE, NULL);
if (!*noOutstandingWorkItemEvent)
{
CloseHandle (keyDerivationCompletedEvent);
CloseHandle (*keyDerivationCompletedEvent);
TCfree (keyDerivationWorkItems);
TCfree(keyDerivationCompletedEvent);
TCfree(noOutstandingWorkItemEvent);