iphlpapi: Close socket on failed HeapAlloc (coverity).
This commit is contained in:
parent
f08854ac3d
commit
6f8ac7cf1b
|
@ -168,6 +168,7 @@ HANDLE WINAPI IcmpCreateFile(VOID)
|
||||||
|
|
||||||
icp=HeapAlloc(GetProcessHeap(), 0, sizeof(*icp));
|
icp=HeapAlloc(GetProcessHeap(), 0, sizeof(*icp));
|
||||||
if (icp==NULL) {
|
if (icp==NULL) {
|
||||||
|
close(sid);
|
||||||
SetLastError(IP_NO_RESOURCES);
|
SetLastError(IP_NO_RESOURCES);
|
||||||
return INVALID_HANDLE_VALUE;
|
return INVALID_HANDLE_VALUE;
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue