Permalink
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Browse files
Use no-cache fetch mode when loading main documents with location.rel…
…oad() https://bugs.webkit.org/show_bug.cgi?id=181285 LayoutTests/imported/w3c: Patch by Youenn Fablet <youenn@apple.com> on 2018-01-10 Reviewed by Alex Christensen. * web-platform-tests/service-workers/service-worker/fetch-event.https-expected.txt: Source/WebCore: Patch by Youenn Fablet <youenn@apple.com> on 2018-01-10 Reviewed by Alex Christensen. Covered by rebased tests. Start to translate cache policy used for navigation as FetchOptions::Cache. This allows ensuring service workers receive the right cache mode when intercepting navigation loads. To not change current navigation behavior, ReturnCacheDataElseLoad and ReturnCacheDataDontLoad still trigger default fetch cache mode. For Reload and ReloadExpiredOnly frame load types, using no-cache mode is more efficient than reload mode, as a conditional request will be sent if possible. This applies to location.reload which is consistent with other browsers. Keep reload mode for ReloadFromOrigin. * loader/DocumentLoader.cpp: (WebCore::toFetchOptionsCache): (WebCore::DocumentLoader::loadMainResource): * loader/FrameLoader.cpp: (WebCore::FrameLoader::loadFrameRequest): (WebCore::FrameLoader::loadURL): (WebCore::FrameLoader::load): (WebCore::FrameLoader::reload): (WebCore::FrameLoader::defaultRequestCachingPolicy): (WebCore::FrameLoader::loadDifferentDocumentItem): * loader/NavigationScheduler.cpp: LayoutTests: <rdar://problem/36356831> Patch by Youenn Fablet <youenn@apple.com> on 2018-01-10 Reviewed by Alex Christensen. * http/tests/inspector/network/har/har-page-expected.txt: * http/tests/inspector/network/har/har-page.html: Canonical link: https://commits.webkit.org/197362@main git-svn-id: https://svn.webkit.org/repository/webkit/trunk@226745 268f45cc-cd09-0410-ab3c-d52691b4dbfc
- Loading branch information
Showing
with
94 additions
and 17 deletions.
- +11 −0 LayoutTests/ChangeLog
- +3 −3 LayoutTests/http/tests/inspector/network/har/har-page-expected.txt
- +3 −0 LayoutTests/http/tests/inspector/network/har/har-page.html
- +9 −0 LayoutTests/imported/w3c/ChangeLog
- +1 −2 ...sts/imported/w3c/web-platform-tests/service-workers/service-worker/fetch-event.https-expected.txt
- +29 −0 Source/WebCore/ChangeLog
- +24 −1 Source/WebCore/loader/DocumentLoader.cpp
- +11 −8 Source/WebCore/loader/FrameLoader.cpp
- +3 −3 Source/WebCore/loader/NavigationScheduler.cpp
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters