| Summary: | Fix passing null / undefined as NodeFilter parameter for createNodeIterator() / createTreeWalker() | ||||||||
|---|---|---|---|---|---|---|---|---|---|
| Product: | WebKit | Reporter: | Chris Dumez <cdumez> | ||||||
| Component: | DOM | Assignee: | Chris Dumez <cdumez> | ||||||
| Status: | RESOLVED FIXED | ||||||||
| Severity: | Normal | CC: | ap, commit-queue, darin, rniwa | ||||||
| Priority: | P2 | ||||||||
| Version: | Other | ||||||||
| Hardware: | Unspecified | ||||||||
| OS: | Unspecified | ||||||||
| Bug Depends on: | 148238 | ||||||||
| Bug Blocks: | |||||||||
| Attachments: |
|
||||||||
|
Description
Chris Dumez
2015-08-20 16:01:51 PDT
Created attachment 259513 [details]
Patch
Created attachment 259530 [details]
Patch
Comment on attachment 259530 [details] Patch View in context: https://bugs.webkit.org/attachment.cgi?id=259530&action=review > Source/WebCore/bindings/js/JSNodeFilterCustom.cpp:43 > + if (!value.isObject()) NodeFilter can be implemented as a JavaScript object. This is why we have a custom toWrapped() and we create a NodeFilter from that object. However, if we are not passed an object, we should simply return null instead of constructing a NodeFilter. Comment on attachment 259530 [details] Patch Clearing flags on attachment: 259530 Committed r188745: <http://trac.webkit.org/changeset/188745> All reviewed patches have been landed. Closing bug. |