Index: third_party/WebKit/Source/core/loader/FrameLoader.cpp |
diff --git a/third_party/WebKit/Source/core/loader/FrameLoader.cpp b/third_party/WebKit/Source/core/loader/FrameLoader.cpp |
index fb740684346ca8425b8860db0f06f577492eb3aa..a578f07bcb78d85f800a6728fdfd64bba44a170b 100644 |
--- a/third_party/WebKit/Source/core/loader/FrameLoader.cpp |
+++ b/third_party/WebKit/Source/core/loader/FrameLoader.cpp |
@@ -1220,18 +1220,15 @@ void FrameLoader::receivedMainResourceError(DocumentLoader* loader, const Resour |
if (loader != m_provisionalDocumentLoader) |
return; |
detachDocumentLoader(m_provisionalDocumentLoader); |
- // If the provisional load failed, and we haven't yet rendered anything |
- // into the frame, then act as though the non-provisional loader failed |
- // as well. If we don't do this, the main load will never finish. |
- if (!stateMachine()->committedFirstRealDocumentLoad()) |
- m_documentLoader->setSentDidFinishLoad(); |
+ m_progressTracker->progressCompleted(); |
} else { |
ASSERT(loader == m_documentLoader); |
if (m_frame->document()->parser()) |
m_frame->document()->parser()->stopParsing(); |
- if (!m_documentLoader->sentDidFinishLoad()) { |
+ m_documentLoader->setSentDidFinishLoad(); |
+ if (!m_provisionalDocumentLoader && m_frame->isLoading()) { |
client()->dispatchDidFailLoad(error, historyCommitType); |
- m_documentLoader->setSentDidFinishLoad(); |
+ m_progressTracker->progressCompleted(); |
} |
} |
checkCompleted(); |