Open Bug 896272 Opened 6 years ago Updated 7 months ago

Gecko's is nullable, against spec


(Core :: DOM: Core & HTML, defect, P5)





(Reporter: crussell, Unassigned)


(Olli Pettay [:smaug] wrote in bug 790978, comment #2)
> .target is the only hack, since I want to make sure we don't crash even if
> CC or GC is buggy (and we end up using record even after unlink).

MutationObserver.webidl says:
> // .target is not nullable per the spec, but in order to prevent crashes,
> // if there are GC/CC bugs in Gecko, we let the property to be null.
> readonly attribute Node? target;
Can you actually produce a testcase in which null is returned?
No.  The bug is based solely on the fact that they do differ and smaug's comment and patch.
If it does return null in a debug build, will an assertion fire? ;)
> If it does return null in a debug build, will an assertion fire? ;)

Doesn't look like it (since it's marked nullable in the IDL).
Summary: Gecko's is nullable against spec → Gecko's is nullable, against spec
Ok. If you add an assertion, I'll let you know if my fuzzer hits it, and then you can be more confident enforcing it (with a crash) in release builds.

Move all DOM bugs that haven’t been updated in more than 3 years and has no one currently assigned to P5.

If you have questions, please contact :mdaly.
Priority: -- → P5
Component: DOM → DOM: Core & HTML
You need to log in before you can comment on or make changes to this bug.