[Webkit-unassigned] [Bug 56334] Web Inspector: crash upon "//html//@id" search in elements panel.

bugzilla-daemon at webkit.org bugzilla-daemon at webkit.org
Mon Mar 14 14:31:13 PDT 2011


https://bugs.webkit.org/show_bug.cgi?id=56334





--- Comment #2 from Joseph Pecoraro <joepeck at webkit.org>  2011-03-14 14:31:12 PST ---
(From update of attachment 85719)
View in context: https://bugs.webkit.org/attachment.cgi?id=85719&action=review

> Source/WebCore/inspector/InspectorDOMAgent.cpp:212
> +            if (node->nodeType() == Node::ATTRIBUTE_NODE)
> +                node = static_cast<Attr*>(node)->ownerElement();
>              if (!ec)
>                  resultCollector.add(node);

This should probably go inside the (!ec) block. Or make it an early continue check. "if (ec) continue;" 

Are there other node types we should avoid here? Should we whitelist certain types?

Other then this, the patch looks good to me.

-- 
Configure bugmail: https://bugs.webkit.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.



More information about the webkit-unassigned mailing list