Changeset 183555 in webkit
- Timestamp:
- Apr 29, 2015 10:09:51 AM (9 years ago)
- Location:
- trunk
- Files:
-
- 3 added
- 3 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/LayoutTests/ChangeLog
r183552 r183555 1 2015-04-29 Antti Koivisto <antti@apple.com> 2 3 Main resource loaded via 304 response becomes empty if reloaded by user 4 https://bugs.webkit.org/show_bug.cgi?id=144386 5 6 Reviewed by Darin Adler. 7 8 * http/tests/cache/main-resource-304-reload-expected.txt: Added. 9 * http/tests/cache/main-resource-304-reload.html: Added. 10 * http/tests/cache/resources/iframe304body.php: Added. 11 1 12 2015-04-29 Darin Adler <darin@apple.com> 2 13 -
trunk/Source/WebCore/ChangeLog
r183554 r183555 1 2015-04-29 Antti Koivisto <antti@apple.com> 2 3 Main resource loaded via 304 response becomes empty if reloaded by user 4 https://bugs.webkit.org/show_bug.cgi?id=144386 5 6 Reviewed by Darin Adler. 7 8 Memory cache layer may make a main resource request conditional (add If-modified-since/If-none-match header). 9 DocumentLoader stores the final ResourceRequest associated with document. If user triggered reload for 10 conditionally loaded document DocumentLoader would include the same conditionals to the new request as well. 11 Since these were not added by the memory cache it would pass any 304 response back to the DocumentLoader. 12 However DocumentLoader has no code to handle 304 so we would end up with an empty document. 13 14 Test: http/tests/cache/main-resource-304-reload.html 15 16 * loader/DocumentLoader.cpp: 17 (WebCore::DocumentLoader::startLoadingMainResource): 18 19 Ensure DocumentLoader doesn't issue conditional requests. 20 1 21 2015-04-28 Jer Noble <jer.noble@apple.com> 2 22 -
trunk/Source/WebCore/loader/DocumentLoader.cpp
r183467 r183555 1401 1401 ResourceRequest request(m_request); 1402 1402 request.setRequester(ResourceRequest::Requester::Main); 1403 1403 // If this is a reload the cache layer might have made the previous request conditional. DocumentLoader can't handle 304 responses itself. 1404 request.makeUnconditional(); 1405 1404 1406 static NeverDestroyed<ResourceLoaderOptions> mainResourceLoadOptions(SendCallbacks, SniffContent, BufferData, AllowStoredCredentials, AskClientForAllCredentials, SkipSecurityCheck, UseDefaultOriginRestrictionsForType, IncludeCertificateInfo); 1405 1407 CachedResourceRequest cachedResourceRequest(request, mainResourceLoadOptions);
Note: See TracChangeset
for help on using the changeset viewer.