From ad2f53db8f51c088d4a556aae4704a0a82aedb17 Mon Sep 17 00:00:00 2001 From: Alexander Morozov Date: Fri, 4 Jul 2008 14:00:29 +0400 Subject: [PATCH] wininet: Add support of INTERNET_FLAG_NO_CACHE_WRITE. --- dlls/wininet/http.c | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/dlls/wininet/http.c b/dlls/wininet/http.c index 970e50243f5..8171838282e 100644 --- a/dlls/wininet/http.c +++ b/dlls/wininet/http.c @@ -3181,6 +3181,12 @@ BOOL WINAPI HTTP_HttpSendRequestW(LPWININETHTTPREQW lpwhr, LPCWSTR lpszHeaders, static const WCHAR pragma_nocache[] = {'P','r','a','g','m','a',':',' ','n','o','-','c','a','c','h','e','\r','\n',0}; HTTP_HttpAddRequestHeadersW(lpwhr, pragma_nocache, strlenW(pragma_nocache), HTTP_ADDREQ_FLAG_ADD_IF_NEW); } + if ((lpwhr->hdr.dwFlags & INTERNET_FLAG_NO_CACHE_WRITE) && !strcmpW(lpwhr->lpszVerb, szPost)) + { + static const WCHAR cache_control[] = {'C','a','c','h','e','-','C','o','n','t','r','o','l',':', + ' ','n','o','-','c','a','c','h','e','\r','\n',0}; + HTTP_HttpAddRequestHeadersW(lpwhr, cache_control, strlenW(cache_control), HTTP_ADDREQ_FLAG_ADD_IF_NEW); + } do {