Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(596)

Unified Diff: Source/web/WebPageSerializer.cpp

Issue 189573002: Convert HTMLFrameOwnerElement and FocusController to use Frame. (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Missed a null check Created 6 years, 9 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « Source/web/WebFrameImpl.cpp ('k') | Source/web/WebViewImpl.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: Source/web/WebPageSerializer.cpp
diff --git a/Source/web/WebPageSerializer.cpp b/Source/web/WebPageSerializer.cpp
index 9982ae41d0a1317192275919d552d220b7b8763e..f3ac50c8d3f63c41048c3d812ec2921fd826fc0d 100644
--- a/Source/web/WebPageSerializer.cpp
+++ b/Source/web/WebPageSerializer.cpp
@@ -86,9 +86,10 @@ void retrieveResourcesForElement(Element* element,
ASSERT(element);
// If the node is a frame, we'll process it later in retrieveResourcesForFrame.
if (isHTMLFrameElementBase(*element) || isHTMLObjectElement(*element) || isHTMLEmbedElement(*element)) {
- if (LocalFrame* frame = toHTMLFrameOwnerElement(element)->contentFrame()) {
- if (!visitedFrames->contains(frame))
- framesToVisit->append(frame);
+ Frame* frame = toHTMLFrameOwnerElement(element)->contentFrame();
+ if (frame && frame->isLocalFrame()) {
+ if (!visitedFrames->contains(toLocalFrame(frame)))
+ framesToVisit->append(toLocalFrame(frame));
return;
}
}
« no previous file with comments | « Source/web/WebFrameImpl.cpp ('k') | Source/web/WebViewImpl.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698