Commit bf6a96ca authored by Michael Stefaniuc's avatar Michael Stefaniuc Committed by Alexandre Julliard

ntdll: Fix missing unlock on error path. Found by Smatch.

parent ef134dc7
......@@ -1806,7 +1806,11 @@ NTSTATUS WINAPI LdrGetDllHandle( LPCWSTR load_path, ULONG flags, const UNICODE_S
if (filename != buffer) RtlFreeHeap( GetProcessHeap(), 0, filename );
if (status != STATUS_BUFFER_TOO_SMALL) break;
/* grow the buffer and retry */
if (!(filename = RtlAllocateHeap( GetProcessHeap(), 0, size ))) return STATUS_NO_MEMORY;
if (!(filename = RtlAllocateHeap( GetProcessHeap(), 0, size )))
{
status = STATUS_NO_MEMORY;
break;
}
}
if (status == STATUS_SUCCESS)
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment