wininet: Fixed leak in InternetGetConnectedStateExA.
This commit is contained in:
parent
a6a9b05dee
commit
e1dbfb762c
|
@ -1294,11 +1294,10 @@ BOOL WINAPI InternetGetConnectedStateExA(LPDWORD lpdwStatus, LPSTR lpszConnectio
|
||||||
rc = InternetGetConnectedStateExW(lpdwStatus,lpwszConnectionName, dwNameLen,
|
rc = InternetGetConnectedStateExW(lpdwStatus,lpwszConnectionName, dwNameLen,
|
||||||
dwReserved);
|
dwReserved);
|
||||||
if (rc && lpwszConnectionName)
|
if (rc && lpwszConnectionName)
|
||||||
{
|
|
||||||
WideCharToMultiByte(CP_ACP,0,lpwszConnectionName,-1,lpszConnectionName,
|
WideCharToMultiByte(CP_ACP,0,lpwszConnectionName,-1,lpszConnectionName,
|
||||||
dwNameLen, NULL, NULL);
|
dwNameLen, NULL, NULL);
|
||||||
|
|
||||||
heap_free(lpwszConnectionName);
|
heap_free(lpwszConnectionName);
|
||||||
}
|
|
||||||
return rc;
|
return rc;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue