Roel Messiant:

- Heap corruption fixes.

svn path=/trunk/; revision=49332
This commit is contained in:
Aleksey Bragin 2010-10-28 22:08:18 +00:00
parent 7f008d8e60
commit 0b6aeda1ed
3 changed files with 3 additions and 3 deletions

View file

@ -422,7 +422,7 @@ AllocateBuffers(PAPPINFO pInfo)
pInfo->RecvPacket = (PIPv4_HEADER)HeapAlloc(GetProcessHeap(),
0,
sizeof(IPv4_HEADER) + PACKET_SIZE);
MAX_PING_PACKET_SIZE);
if (!pInfo->RecvPacket)
{
HeapFree(GetProcessHeap(),

View file

@ -256,7 +256,7 @@ LdrpQueryAppPaths(IN PCWSTR ImageName)
/* Copy it to the heap allocd memory */
Path = RtlAllocateHeap(RtlGetProcessHeap(),
0,
wcslen(SearchPathBuffer) * sizeof(WCHAR));
(wcslen(SearchPathBuffer) + 1) * sizeof(WCHAR));
if (!Path)
{

View file

@ -2860,7 +2860,7 @@ Initialize(TcpipConfNotifyImpl * This)
}
pCurSettings->AutoconfigActive = pPerInfo->AutoconfigActive;
}
CoTaskMemFree(pInfo);
CoTaskMemFree(pPerInfo);
}
}