Cached main resources report a zero identifer on 304s
authorjaphet@chromium.org <japhet@chromium.org@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Fri, 1 Feb 2013 19:25:38 +0000 (19:25 +0000)
committerjaphet@chromium.org <japhet@chromium.org@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Fri, 1 Feb 2013 19:25:38 +0000 (19:25 +0000)
commit5eb6058bc0c64893e6b0b80d95e396ce73995cc1
tree0397afa81db14f6a18bf8f65eeb7eca0994264fa
parent66e524c61c585db3483efe9176b503c7e3581a22
Cached main resources report a zero identifer on 304s
https://bugs.webkit.org/show_bug.cgi?id=108402

Reviewed by Adam Barth.

Source/WebCore:

Test: http/tests/cache/iframe-304-crash.html

* loader/MainResourceLoader.cpp:
(WebCore::MainResourceLoader::responseReceived): Throughout, check m_identifierForLoadWithoutResourceLoader
    instead of !loader() to determine whether MainResourceLoader needs to synthesize resource load callbacks.
(WebCore::MainResourceLoader::dataReceived):
(WebCore::MainResourceLoader::didFinishLoading):

LayoutTests:

* http/tests/cache/iframe-304-crash-expected.txt: Added.
* http/tests/cache/iframe-304-crash.html: Added.
* http/tests/cache/resources/iframe304.php: Added.
* platform/chromium/TestExpectations: New test requires main resource caching, which isn't supported on chromium at the moment.
* platform/mac/TestExpectations: New test requires main resource caching, which isn't supported on mac at the moment.

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@141615 268f45cc-cd09-0410-ab3c-d52691b4dbfc
LayoutTests/ChangeLog
LayoutTests/http/tests/cache/iframe-304-crash-expected.txt [new file with mode: 0644]
LayoutTests/http/tests/cache/iframe-304-crash.html [new file with mode: 0644]
LayoutTests/http/tests/cache/resources/iframe304.php [new file with mode: 0644]
LayoutTests/platform/chromium/TestExpectations
LayoutTests/platform/mac/TestExpectations
Source/WebCore/ChangeLog
Source/WebCore/loader/MainResourceLoader.cpp