Commit 8b812b41 authored by Marcus Meissner's avatar Marcus Meissner Committed by Alexandre Julliard

urlmon: Fixed target buffer length to MultiByteToWideChar.

parent 635ec22e
...@@ -1185,7 +1185,7 @@ HRESULT WINAPI URLDownloadToCacheFileA(LPUNKNOWN lpUnkCaller, LPCSTR szURL, LPST ...@@ -1185,7 +1185,7 @@ HRESULT WINAPI URLDownloadToCacheFileA(LPUNKNOWN lpUnkCaller, LPCSTR szURL, LPST
if(szURL) { if(szURL) {
len = MultiByteToWideChar(CP_ACP, 0, szURL, -1, NULL, 0); len = MultiByteToWideChar(CP_ACP, 0, szURL, -1, NULL, 0);
url = heap_alloc(len*sizeof(WCHAR)); url = heap_alloc(len*sizeof(WCHAR));
MultiByteToWideChar(CP_ACP, 0, szURL, -1, url, -1); MultiByteToWideChar(CP_ACP, 0, szURL, -1, url, len);
} }
if(szFileName) if(szFileName)
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment