setupapi: Fix HeapFree of wrong pointer (found by Smatch).

This commit is contained in:
Lionel Debroux 2007-09-06 11:32:44 +02:00 committed by Alexandre Julliard
parent 1fbedd92d4
commit d7abb09b46
1 changed files with 2 additions and 2 deletions

View File

@ -86,7 +86,7 @@ StringTableInitialize(VOID)
pStringTable->pSlots = MyMalloc(sizeof(TABLE_SLOT) * TABLE_DEFAULT_SIZE);
if (pStringTable->pSlots == NULL)
{
MyFree(pStringTable->pSlots);
MyFree(pStringTable);
return NULL;
}
@ -131,7 +131,7 @@ StringTableInitializeEx(DWORD dwMaxExtraDataSize,
pStringTable->pSlots = MyMalloc(sizeof(TABLE_SLOT) * TABLE_DEFAULT_SIZE);
if (pStringTable->pSlots == NULL)
{
MyFree(pStringTable->pSlots);
MyFree(pStringTable);
return NULL;
}