[SCM] WebKit Debian packaging branch, debian/experimental, updated. upstream/1.3.3-9427-gc2be6fc

commit-queue at webkit.org commit-queue at webkit.org
Wed Dec 22 11:16:37 UTC 2010


The following commit has been merged in the debian/experimental branch:
commit ccadbd2de49dbc90513cf7b408ff8cc9ee3fd16c
Author: commit-queue at webkit.org <commit-queue at webkit.org@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Date:   Fri Jul 16 14:07:35 2010 +0000

    2010-07-16  Andrey Kosyakov  <caseq at chromium.org>
    
            Reviewed by Pavel Feldman.
    
            Check that end node of a range has a valid renderer in WebViewImpl::caretOrSelectionBounds()
            to avoid crash in Position::getInlineBoxAndOffset() when start node has renderer but end one doesn't.
            https://bugs.webkit.org/show_bug.cgi?id=42449
    
            * src/WebViewImpl.cpp:
            (WebKit::WebViewImpl::caretOrSelectionBounds):
    
    git-svn-id: http://svn.webkit.org/repository/webkit/trunk@63545 268f45cc-cd09-0410-ab3c-d52691b4dbfc

diff --git a/WebKit/chromium/ChangeLog b/WebKit/chromium/ChangeLog
index f258c2a..996197d 100644
--- a/WebKit/chromium/ChangeLog
+++ b/WebKit/chromium/ChangeLog
@@ -1,3 +1,14 @@
+2010-07-16  Andrey Kosyakov  <caseq at chromium.org>
+
+        Reviewed by Pavel Feldman.
+
+        Check that end node of a range has a valid renderer in WebViewImpl::caretOrSelectionBounds()
+        to avoid crash in Position::getInlineBoxAndOffset() when start node has renderer but end one doesn't.
+        https://bugs.webkit.org/show_bug.cgi?id=42449
+
+        * src/WebViewImpl.cpp:
+        (WebKit::WebViewImpl::caretOrSelectionBounds):
+
 2010-07-16  Mikhail Naganov  <mnaganov at chromium.org>
 
         Reviewed by Pavel Feldman.
diff --git a/WebKit/chromium/src/WebViewImpl.cpp b/WebKit/chromium/src/WebViewImpl.cpp
index 3b81b2c..a982c1b 100644
--- a/WebKit/chromium/src/WebViewImpl.cpp
+++ b/WebKit/chromium/src/WebViewImpl.cpp
@@ -1245,6 +1245,9 @@ WebRect WebViewImpl::caretOrSelectionBounds()
     if (controller->isCaret())
         rect = view->contentsToWindow(controller->absoluteCaretBounds());
     else if (controller->isRange()) {
+        node = controller->end().node();
+        if (!node || !node->renderer())
+            return rect;
         RefPtr<Range> range = controller->toNormalizedRange();
         rect = view->contentsToWindow(focused->firstRectForRange(range.get()));
     }

-- 
WebKit Debian packaging



More information about the Pkg-webkit-commits mailing list