[PATCH 1/4] dlls/ntdll: Add handle count to NtQuerySystemInformation
wine-devel at kievinfo.com
Mon Jun 20 08:52:06 CDT 2011
On 06/20/2011 05:28 AM, Austin Lund wrote:
> Thanks for the review. Does this patch address these concerns correctly?
No quite there yet:
> + SERVER_START_REQ( create_snapshot )
You not checking if this call succeeded or not.
> + while (sizeof(ULONG) + sizeof(SYSTEM_HANDLE_ENTRY)*shi->Count >= len)
You don't need a loop to calculate new size.
> + shi = RtlReAllocateHeap(GetProcessHeap(), HEAP_ZERO_MEMORY, shi, len);
> + if (shi == NULL)
> + return STATUS_NO_MEMORY;
You leaking old shi here. Also why do you need to zero allocated memory if
you assigning all of it valid values?
More information about the wine-devel