POINTBLOCK *tmpPtBlock;
UINT numFullPtBlocks = 0;
UINT poly, total;
+ BOOL bResult = FALSE;
/* Check if iMode is valid */
if ((iMode != ALTERNATE) && (iMode != WINDING))
if (tmpPtBlock == NULL)
{
DPRINT1("Can't alloc tmpPtBlock\n");
- ExFreePoolWithTag(pETEs, TAG_REGION);
- return FALSE;
+ goto Cleanup;
}
curPtBlock->next = tmpPtBlock;
if (tmpPtBlock == NULL)
{
DPRINT1("Can't alloc tPB\n");
- ExFreePoolWithTag(pETEs, TAG_REGION);
- return FALSE;
+ goto Cleanup;
}
curPtBlock->next = tmpPtBlock;
curPtBlock = tmpPtBlock;
}
}
- REGION_FreeStorage(SLLBlock.next);
REGION_PtsToRegion(numFullPtBlocks, iPts, &FirstPtBlock, prgn);
+ bResult = TRUE;
+
+Cleanup:
+ REGION_FreeStorage(SLLBlock.next);
for (curPtBlock = FirstPtBlock.next; numFullPtBlocks-- > 0;)
{
}
ExFreePoolWithTag(pETEs, TAG_REGION);
- return TRUE;
+ return bResult;
}
HRGN