Bug 46822 - [GTK] editing/selection/selection-modify-crash.html crashes when run in Xvfb
Summary: [GTK] editing/selection/selection-modify-crash.html crashes when run in Xvfb
Status: RESOLVED FIXED
Alias: None
Product: WebKit
Classification: Unclassified
Component: WebKitGTK (show other bugs)
Version: 528+ (Nightly build)
Hardware: PC Linux
: P3 Normal
Assignee: Nobody
URL:
Keywords: Gtk
Depends on:
Blocks:
 
Reported: 2010-09-29 10:46 PDT by Martin Robinson
Modified: 2010-09-29 10:58 PDT (History)
2 users (show)

See Also:


Attachments
Patch for this issue (4.56 KB, patch)
2010-09-29 10:50 PDT, Martin Robinson
cfleizach: review+
Details | Formatted Diff | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Martin Robinson 2010-09-29 10:46:30 PDT
This is the crashing section of code:

AccessibilityObject* objectAndOffsetUnignored(AccessibilityObject* coreObject, int& offset, bool ignoreLinks)
{
    Node* endNode = static_cast<AccessibilityRenderObject*>(coreObject)->renderer()->node();
    int endOffset = coreObject->selection().end().computeOffsetInContainerNode();
    // Indication that something bogus has transpired.
    offset = -1;

    AccessibilityObject* realObject = coreObject;
    if (realObject->accessibilityIsIgnored())
        realObject = realObject->parentObjectUnignored();

    if (ignoreLinks && realObject->isLink()) <------- Guilty line
        realObject = realObject->parentObjectUnignored();

    [...]
}

The issue here is that parentObjectUnignored may return null, particularly in the case that the AccessibilityObject is a WebArea.
Comment 1 Martin Robinson 2010-09-29 10:50:56 PDT
Created attachment 69218 [details]
Patch for this issue
Comment 2 chris fleizach 2010-09-29 10:53:59 PDT
Comment on attachment 69218 [details]
Patch for this issue

r=me
Comment 3 Martin Robinson 2010-09-29 10:58:47 PDT
Committed r68665: <http://trac.webkit.org/changeset/68665>