InternetGetConnectedStateExA

Alexandre Julliard julliard at winehq.org
Wed Nov 3 14:28:39 CST 2004


Aric Stewart <aric at codeweavers.com> writes:

> +BOOL WINAPI InternetGetConnectedStateExA(LPDWORD lpdwStatus, 
> +                LPSTR lpszConnectionName, DWORD dwNameLen, DWORD dwReserved)
> +{
> +    INT len;
> +    LPWSTR lpwszConnectionName = NULL;
> +    BOOL rc;
> +
> +    TRACE("(%p, %s, %ld, 0x%08lx)\n", lpdwStatus, debugstr_a(lpszConnectionName), dwNameLen, dwReserved);
> +
> +    if (lpszConnectionName)
> +    {
> +        len = MultiByteToWideChar(CP_ACP, 0, lpszConnectionName, -1, NULL, 0);
> +        lpwszConnectionName= HeapAlloc(GetProcessHeap(), 0, len*sizeof(WCHAR));
> +        MultiByteToWideChar(CP_ACP, 0, lpszConnectionName, -1,
> +                            lpwszConnectionName, len);
> +    }
> +
> +    rc = InternetGetConnectedStateExW(lpdwStatus,lpwszConnectionName, dwNameLen,

lpszConnectionName is an output parameter, it should be converted on
return from the W call.

-- 
Alexandre Julliard
julliard at winehq.org



More information about the wine-devel mailing list