Title: [167163] tags/Safari-538.26.5/Source/WebCore
- Revision
- 167163
- Author
- lforsch...@apple.com
- Date
- 2014-04-11 15:29:32 -0700 (Fri, 11 Apr 2014)
Log Message
Merged r167160.
Modified Paths
Diff
Modified: tags/Safari-538.26.5/Source/WebCore/ChangeLog (167162 => 167163)
--- tags/Safari-538.26.5/Source/WebCore/ChangeLog 2014-04-11 22:23:38 UTC (rev 167162)
+++ tags/Safari-538.26.5/Source/WebCore/ChangeLog 2014-04-11 22:29:32 UTC (rev 167163)
@@ -1,5 +1,26 @@
2014-04-11 Lucas Forschler <lforsch...@apple.com>
+ Merge r167160
+
+ 2014-04-11 David Kilzer <ddkil...@apple.com>
+
+ Build fix (r167151): Do not dereference Node::document() before passing to Range::create()
+ <https://webkit.org/b/131475>
+
+ Fixes the following build failure:
+
+ WebCore/editing/AlternativeTextController.cpp:275:71: error: indirection requires pointer operand ('WebCore::Document' invalid)
+ int paragraphStartIndex = TextIterator::rangeLength(Range::create(*rootNode.document(), &rootNode, 0, paragraphRangeContainingCorrection.get()->startContainer(), paragraphRangeContainingCorrection.get()->startOffset()).get());
+ ^~~~~~~~~~~~~~~~~~~~
+
+ * editing/AlternativeTextController.cpp:
+ (WebCore::AlternativeTextController::applyAlternativeTextToRange):
+ Remove unneeded '*' operator since Node::document() returns a
+ Document& and Range::create() accepts a Document& for its first
+ argument.
+
+2014-04-11 Lucas Forschler <lforsch...@apple.com>
+
Merge r167151
2014-04-09 Myles C. Maxfield <mmaxfi...@apple.com>
Modified: tags/Safari-538.26.5/Source/WebCore/editing/AlternativeTextController.cpp (167162 => 167163)
--- tags/Safari-538.26.5/Source/WebCore/editing/AlternativeTextController.cpp 2014-04-11 22:23:38 UTC (rev 167162)
+++ tags/Safari-538.26.5/Source/WebCore/editing/AlternativeTextController.cpp 2014-04-11 22:29:32 UTC (rev 167163)
@@ -272,7 +272,7 @@
RefPtr<Range> rangeWithAlternative = range->cloneRange(ec);
ContainerNode& rootNode = paragraphRangeContainingCorrection.get()->startContainer()->treeScope().rootNode();
- int paragraphStartIndex = TextIterator::rangeLength(Range::create(*rootNode.document(), &rootNode, 0, paragraphRangeContainingCorrection.get()->startContainer(), paragraphRangeContainingCorrection.get()->startOffset()).get());
+ int paragraphStartIndex = TextIterator::rangeLength(Range::create(rootNode.document(), &rootNode, 0, paragraphRangeContainingCorrection.get()->startContainer(), paragraphRangeContainingCorrection.get()->startOffset()).get());
applyCommand(SpellingCorrectionCommand::create(rangeWithAlternative, alternative));
// Recalculate pragraphRangeContainingCorrection, since SpellingCorrectionCommand modified the DOM, such that the original paragraphRangeContainingCorrection is no longer valid. Radar: 10305315 Bugzilla: 89526
paragraphRangeContainingCorrection = TextIterator::rangeFromLocationAndLength(&rootNode, paragraphStartIndex, correctionStartOffsetInParagraph + alternative.length());
_______________________________________________
webkit-changes mailing list
webkit-changes@lists.webkit.org
https://lists.webkit.org/mailman/listinfo/webkit-changes