WebKit Bugzilla
New
Browse
Log In
×
Sign in with GitHub
or
Remember my login
Create Account
·
Forgot Password
Forgotten password account recovery
RESOLVED FIXED
158008
The 2 first parameters to addEventListener() / removeEventListener() should be mandatory
https://bugs.webkit.org/show_bug.cgi?id=158008
Summary
The 2 first parameters to addEventListener() / removeEventListener() should b...
Chris Dumez
Reported
2016-05-23 19:41:38 PDT
The 2 first parameters to addEventListener() / removeEventListener() should be mandatory:
https://dom.spec.whatwg.org/#interface-eventtarget
Firefox 46 and Chrome 50 both match the specification and throw an exception when those parameters are omitted. However, those parameters are currently optional in WebKit and the calls are merely no-ops if the parameters are omitted.
Attachments
Patch
(52.14 KB, patch)
2016-05-23 19:50 PDT
,
Chris Dumez
no flags
Details
Formatted Diff
Diff
Patch
(52.83 KB, patch)
2016-05-23 19:52 PDT
,
Chris Dumez
no flags
Details
Formatted Diff
Diff
Patch
(52.65 KB, patch)
2016-05-23 20:38 PDT
,
Chris Dumez
no flags
Details
Formatted Diff
Diff
Patch
(51.78 KB, patch)
2016-07-18 13:11 PDT
,
Chris Dumez
no flags
Details
Formatted Diff
Diff
Show Obsolete
(3)
View All
Add attachment
proposed patch, testcase, etc.
Chris Dumez
Comment 1
2016-05-23 19:50:26 PDT
Created
attachment 279613
[details]
Patch
Chris Dumez
Comment 2
2016-05-23 19:52:50 PDT
Created
attachment 279614
[details]
Patch
Darin Adler
Comment 3
2016-05-23 20:29:41 PDT
Comment on
attachment 279614
[details]
Patch View in context:
https://bugs.webkit.org/attachment.cgi?id=279614&action=review
There is some risk of failure if an exception causes a problem, in content that was only ever tested with WebKit, that accidentally calls the addEventListener or removeEventListener with too few arguments. Like the video-remote-control-playpause.html test, for example. Is this worth the risk at this point?
> Source/WebCore/ChangeLog:20 > + (GetFunctionLength): Deleted.
This is untrue. The function was not deleted. This is a bug in the prepare-ChangeLog script "Deleted" feature.
> Source/WebCore/ChangeLog:23 > + (WebCore::EventTarget::addEventListenerForBindings): Deleted. > + (WebCore::EventTarget::removeEventListenerForBindings): Deleted.
Same thing here too.
Chris Dumez
Comment 4
2016-05-23 20:37:50 PDT
(In reply to
comment #3
)
> Comment on
attachment 279614
[details]
> Patch > > View in context: >
https://bugs.webkit.org/attachment.cgi?id=279614&action=review
> > There is some risk of failure if an exception causes a problem, in content > that was only ever tested with WebKit, that accidentally calls the > addEventListener or removeEventListener with too few arguments. Like the > video-remote-control-playpause.html test, for example. Is this worth the > risk at this point?
I will wait to land it.
Chris Dumez
Comment 5
2016-05-23 20:38:44 PDT
Created
attachment 279619
[details]
Patch
Chris Dumez
Comment 6
2016-07-18 13:11:47 PDT
Created
attachment 283919
[details]
Patch
Radar WebKit Bug Importer
Comment 7
2016-07-18 13:12:05 PDT
<
rdar://problem/27408657
>
WebKit Commit Bot
Comment 8
2016-07-18 15:34:27 PDT
Comment on
attachment 283919
[details]
Patch Clearing flags on attachment: 283919 Committed
r203377
: <
http://trac.webkit.org/changeset/203377
>
WebKit Commit Bot
Comment 9
2016-07-18 15:34:33 PDT
All reviewed patches have been landed. Closing bug.
Note
You need to
log in
before you can comment on or make changes to this bug.
Top of Page
Format For Printing
XML
Clone This Bug