Changeset 82296 in webkit


Ignore:
Timestamp:
Mar 29, 2011 11:50:32 AM (13 years ago)
Author:
mario@webkit.org
Message:

2011-03-29 Mario Sanchez Prada <msanchez@igalia.com>

Reviewed by Martin Robinson.

[Gtk] Consistent crash from Google/ARIA combobox click
https://bugs.webkit.org/show_bug.cgi?id=55883

Added new layout test to check this doesn't crash anymore in GTK.

  • platform/gtk/accessibility/aria-options-and-menuitems-crash-expected.txt: Added.
  • platform/gtk/accessibility/aria-options-and-menuitems-crash.html: Added.

2011-03-29 Mario Sanchez Prada <msanchez@igalia.com>

Reviewed by Martin Robinson.

[Gtk] Consistent crash from Google/ARIA combobox click
https://bugs.webkit.org/show_bug.cgi?id=55883

Do not call to firstChild() to avoid entering into infinite loops.

This would happen when current item is a WebCore Group and some of
its children have either role 'option' or 'menuitem'. Other than
that the logic behind that call to firstChild() seems to be no
longer needed so it's safe to remove it.

Test: platform/gtk/accessibility/aria-options-and-menuitems-crash.html

  • accessibility/gtk/AccessibilityObjectAtk.cpp: (WebCore::AccessibilityObject::accessibilityPlatformIncludesObject): Remove call to firsChild, which was leading to crashes sometimes.
Location:
trunk
Files:
2 added
3 edited

Legend:

Unmodified
Added
Removed
  • trunk/LayoutTests/ChangeLog

    r82295 r82296  
     12011-03-29  Mario Sanchez Prada  <msanchez@igalia.com>
     2
     3        Reviewed by Martin Robinson.
     4
     5        [Gtk] Consistent crash from Google/ARIA combobox click
     6        https://bugs.webkit.org/show_bug.cgi?id=55883
     7
     8        Added new layout test to check this doesn't crash anymore in GTK.
     9
     10        * platform/gtk/accessibility/aria-options-and-menuitems-crash-expected.txt: Added.
     11        * platform/gtk/accessibility/aria-options-and-menuitems-crash.html: Added.
     12
    1132011-03-29  Mario Sanchez Prada  <msanchez@igalia.com>
    214
  • trunk/Source/WebCore/ChangeLog

    r82295 r82296  
     12011-03-29  Mario Sanchez Prada  <msanchez@igalia.com>
     2
     3        Reviewed by Martin Robinson.
     4
     5        [Gtk] Consistent crash from Google/ARIA combobox click
     6        https://bugs.webkit.org/show_bug.cgi?id=55883
     7
     8        Do not call to firstChild() to avoid entering into infinite loops.
     9
     10        This would happen when current item is a WebCore Group and some of
     11        its children have either role 'option' or 'menuitem'. Other than
     12        that the logic behind that call to firstChild() seems to be no
     13        longer needed so it's safe to remove it.
     14
     15        Test: platform/gtk/accessibility/aria-options-and-menuitems-crash.html
     16
     17        * accessibility/gtk/AccessibilityObjectAtk.cpp:
     18        (WebCore::AccessibilityObject::accessibilityPlatformIncludesObject):
     19        Remove call to firsChild, which was leading to crashes sometimes.
     20
    1212011-03-29  Mario Sanchez Prada  <msanchez@igalia.com>
    222
  • trunk/Source/WebCore/accessibility/gtk/AccessibilityObjectAtk.cpp

    r77235 r82296  
    4444        return IncludeObject;
    4545
    46     if (isGroup()) {
    47         // When a list item is made up entirely of children (e.g. paragraphs)
    48         // the list item gets ignored. We need it.
    49         if (parent->isList())
    50             return IncludeObject;
    51 
    52         // We expect the parent of a table cell to be a table.
    53         AccessibilityObject* child = firstChild();
    54         if (child && child->roleValue() == CellRole)
    55             return IgnoreObject;
    56     }
     46    // When a list item is made up entirely of children (e.g. paragraphs)
     47    // the list item gets ignored. We need it.
     48    if (isGroup() && parent->isList())
     49        return IncludeObject;
    5750
    5851    // Entries and password fields have extraneous children which we want to ignore.
Note: See TracChangeset for help on using the changeset viewer.