Chromium Code Reviews| Index: third_party/WebKit/Source/core/loader/DocumentLoader.cpp |
| diff --git a/third_party/WebKit/Source/core/loader/DocumentLoader.cpp b/third_party/WebKit/Source/core/loader/DocumentLoader.cpp |
| index db77967ab6c8f5ebb6d4107d8bf7a8d0ce5d5860..5d39b98035e414c0021b95372c7c995f48b91150 100644 |
| --- a/third_party/WebKit/Source/core/loader/DocumentLoader.cpp |
| +++ b/third_party/WebKit/Source/core/loader/DocumentLoader.cpp |
| @@ -669,7 +669,6 @@ void DocumentLoader::EnsureWriter(const AtomicString& mime_type, |
| } |
| DocumentInit init(owner, Url(), frame_); |
| init.WithNewRegistrationContext(); |
| - frame_->Loader().Clear(); |
| DCHECK(frame_->GetPage()); |
| ParserSynchronizationPolicy parsing_policy = kAllowAsynchronousParsing; |
| @@ -1052,6 +1051,11 @@ void DocumentLoader::InstallNewDocument( |
| DCHECK(!frame_->GetDocument() || !frame_->GetDocument()->IsActive()); |
| DCHECK_EQ(frame_->Tree().ChildCount(), 0u); |
| + if (GetFrameLoader().StateMachine()->IsDisplayingInitialEmptyDocument()) { |
| + GetFrameLoader().StateMachine()->AdvanceTo( |
| + FrameLoaderStateMachine::kCommittedFirstRealLoad); |
|
Nate Chapin
2017/05/17 18:18:59
This feels like a slightly weird place for this, b
dcheng
2017/05/22 21:23:26
Hmm... I think this is OK.
|
| + } |
| + |
| SecurityOrigin* previous_security_origin = nullptr; |
| if (frame_->GetDocument()) |
| previous_security_origin = frame_->GetDocument()->GetSecurityOrigin(); |