mirror of
https://github.com/reactos/reactos.git
synced 2025-08-05 19:42:57 +00:00
[COVERITY][SPOOLSS] Fix a resource leak
Unload the library pointed by hWinspool when the function fails. CID 1401149
This commit is contained in:
parent
d5b4570d23
commit
bd5fb32b79
1 changed files with 5 additions and 0 deletions
|
@ -227,8 +227,13 @@ SplInitializeWinSpoolDrv(PVOID* pTable)
|
||||||
|
|
||||||
// Verify that all calls succeeded.
|
// Verify that all calls succeeded.
|
||||||
for (i = 0; i < 9; i++)
|
for (i = 0; i < 9; i++)
|
||||||
|
{
|
||||||
if (!pTable[i])
|
if (!pTable[i])
|
||||||
|
{
|
||||||
|
FreeLibrary(hWinspool);
|
||||||
return FALSE;
|
return FALSE;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
return TRUE;
|
return TRUE;
|
||||||
}
|
}
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue