Index: Source/core/page/PrintContext.cpp |
diff --git a/Source/core/page/PrintContext.cpp b/Source/core/page/PrintContext.cpp |
index 61a4f8adfd842d261be70e6ecfc6e50db7242c08..12033b10c77f9d6ae05de434b4fb1056f03a9597 100644 |
--- a/Source/core/page/PrintContext.cpp |
+++ b/Source/core/page/PrintContext.cpp |
@@ -273,10 +273,10 @@ void PrintContext::collectLinkedDestinations(Node* node) |
const AtomicString& href = toElement(node)->getAttribute(HTMLNames::hrefAttr); |
if (href.isNull()) |
return; |
- KURL url = node->document().completeURL(href); |
+ KURL url = node->treeScope().completeURL(href); |
if (!url.isValid()) |
return; |
- if (url.hasFragmentIdentifier() && equalIgnoringFragmentIdentifier(url, node->document().baseURL())) { |
+ if (url.hasFragmentIdentifier() && equalIgnoringFragmentIdentifier(url, node->treeScope().baseURL())) { |
String name = url.fragmentIdentifier(); |
Element* element = node->document().findAnchor(name); |
if (element) |