From 69c4115c10242c965edfffab86a5937e78005f2e Mon Sep 17 00:00:00 2001 From: Jacek Caban Date: Thu, 3 Jul 2014 16:31:23 +0200 Subject: [PATCH] wininet: Forward InternetGetCookieW to InternetGetCookieExW, not the other way around. --- dlls/wininet/cookie.c | 43 ++++++++++++++++++------------------------- 1 file changed, 18 insertions(+), 25 deletions(-) diff --git a/dlls/wininet/cookie.c b/dlls/wininet/cookie.c index 9d7c98af509..b48cc04ef20 100644 --- a/dlls/wininet/cookie.c +++ b/dlls/wininet/cookie.c @@ -649,7 +649,7 @@ DWORD get_cookie(const WCHAR *host, const WCHAR *path, WCHAR *cookie_data, DWORD } /*********************************************************************** - * InternetGetCookieW (WININET.@) + * InternetGetCookieExW (WININET.@) * * Retrieve cookie from the specified url * @@ -661,14 +661,17 @@ DWORD get_cookie(const WCHAR *host, const WCHAR *path, WCHAR *cookie_data, DWORD * FALSE on failure * */ -BOOL WINAPI InternetGetCookieW(LPCWSTR lpszUrl, LPCWSTR lpszCookieName, - LPWSTR lpCookieData, LPDWORD lpdwSize) +BOOL WINAPI InternetGetCookieExW(LPCWSTR lpszUrl, LPCWSTR lpszCookieName, + LPWSTR lpCookieData, LPDWORD lpdwSize, DWORD flags, void *reserved) { WCHAR host[INTERNET_MAX_HOST_NAME_LENGTH], path[INTERNET_MAX_PATH_LENGTH]; DWORD res; BOOL ret; - TRACE("(%s, %s, %p, %p)\n", debugstr_w(lpszUrl),debugstr_w(lpszCookieName), lpCookieData, lpdwSize); + TRACE("(%s, %s, %p, %p, %x, %p)\n", debugstr_w(lpszUrl),debugstr_w(lpszCookieName), lpCookieData, lpdwSize, flags, reserved); + + if (flags) + FIXME("flags 0x%08x not supported\n", flags); if (!lpszUrl) { @@ -689,6 +692,17 @@ BOOL WINAPI InternetGetCookieW(LPCWSTR lpszUrl, LPCWSTR lpszCookieName, return res == ERROR_SUCCESS; } +/*********************************************************************** + * InternetGetCookieW (WININET.@) + * + * Retrieve cookie for the specified URL. + */ +BOOL WINAPI InternetGetCookieW(const WCHAR *url, const WCHAR *name, WCHAR *data, DWORD *size) +{ + TRACE("(%s, %s, %s, %p)\n", debugstr_w(url), debugstr_w(name), debugstr_w(data), size); + + return InternetGetCookieExW(url, name, data, size, 0, NULL); +} /*********************************************************************** * InternetGetCookieExA (WININET.@) @@ -1088,27 +1102,6 @@ DWORD WINAPI InternetSetCookieExW( LPCWSTR lpszURL, LPCWSTR lpszCookieName, LPCW return InternetSetCookieW(lpszURL, lpszCookieName, lpszCookieData); } -/*********************************************************************** - * InternetGetCookieExW (WININET.@) - * - * Retrieve cookie for the specified URL. - * - * RETURNS - * TRUE on success - * FALSE on failure - * - */ -BOOL WINAPI InternetGetCookieExW( LPCWSTR pchURL, LPCWSTR pchCookieName, LPWSTR pchCookieData, - LPDWORD pcchCookieData, DWORD dwFlags, LPVOID lpReserved) -{ - TRACE("(%s, %s, %s, %p, 0x%08x, %p)\n", - debugstr_w(pchURL), debugstr_w(pchCookieName), debugstr_w(pchCookieData), - pcchCookieData, dwFlags, lpReserved); - - if (dwFlags) FIXME("flags 0x%08x not supported\n", dwFlags); - return InternetGetCookieW(pchURL, pchCookieName, pchCookieData, pcchCookieData); -} - /*********************************************************************** * InternetClearAllPerSiteCookieDecisions (WININET.@) *