Closed Bug 627306 Opened 9 years ago Closed 9 years ago

UMR with dispatchEvent

Categories

(Core :: DOM: Events, defect)

x86_64
Linux
defect
Not set

Tracking

()

RESOLVED FIXED

People

(Reporter: jruderman, Assigned: jruderman)

References

(Blocks 1 open bug)

Details

(Keywords: testcase, valgrind, Whiteboard: [sg:low?])

Attachments

(4 files)

Attached file testcase
With this testcase, Valgrind complains of uninitialized memory from nsIDOMEventTarget_DispatchEvent making its way into js::Interpret.  And lo, if I print the return value from dispatchEvent, sometimes I get true and sometimes I get false, seemingly at random.

http://hg.mozilla.org/mozilla-central/annotate/80c4d7317c29/content/events/src/nsEventListenerManager.cpp#l1316 returns NS_OK without setting _retval, so it's suspicious.
Attached file valgrind's complaint
Looks like a regression from quickstubs...
Er, no, this is ancient.
What's the correct behavior? Set the retval to true, I guess?

http://www.w3.org/TR/DOM-Level-2-Events/events.html#Events-EventTarget-dispatchEvent
Yeah
Whiteboard: [sg:low?]
Attached patch patchSplinter Review
Assignee: nobody → jruderman
Status: NEW → ASSIGNED
Attachment #505690 - Flags: review?(Olli.Pettay)
This patch makes the Valgrind complaint go away for me.
Attachment #505690 - Flags: review?(Olli.Pettay) → review+
Attachment #505690 - Flags: approval2.0?
Attachment #505690 - Flags: approval2.0? → approval2.0+
http://hg.mozilla.org/mozilla-central/rev/e3b9490af708
Status: ASSIGNED → RESOLVED
Closed: 9 years ago
Resolution: --- → FIXED
Group: core-security → core-security-release
Group: core-security-release
You need to log in before you can comment on or make changes to this bug.