jsproxy: Don't use the length parameters in InternetGetProxyInfo.

Signed-off-by: Hans Leidekker <hans@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
This commit is contained in:
Hans Leidekker 2016-04-20 10:14:48 +02:00 committed by Alexandre Julliard
parent d4c9440f71
commit 6ea6b37096
1 changed files with 3 additions and 3 deletions

View File

@ -97,7 +97,7 @@ static inline BOOL heap_free( LPVOID mem )
return HeapFree( GetProcessHeap(), 0, mem );
}
static inline WCHAR *strdupAW( const char *src, DWORD len )
static inline WCHAR *strdupAW( const char *src, int len )
{
WCHAR *dst = NULL;
if (src)
@ -628,8 +628,8 @@ BOOL WINAPI InternetGetProxyInfo( LPCSTR url, DWORD len_url, LPCSTR hostname, DW
EnterCriticalSection( &cs_jsproxy );
if (!global_script->text) goto done;
if (!(urlW = strdupAW( url, len_url ))) goto done;
if (hostname && !(hostnameW = strdupAW( hostname, len_hostname ))) goto done;
if (!(urlW = strdupAW( url, -1 ))) goto done;
if (hostname && !(hostnameW = strdupAW( hostname, -1 ))) goto done;
TRACE( "%s\n", debugstr_w(global_script->text) );
ret = run_script( global_script->text, urlW, hostnameW, proxy, len_proxy );