Open
Bug 906897
Opened 11 years ago
Updated 2 years ago
Calling abort() on an inactive FileReader throws an exception
Categories
(Core :: DOM: Core & HTML, defect, P5)
Tracking
()
NEW
People
(Reporter: arun, Unassigned)
Details
Attachments
(1 file)
759 bytes,
patch
|
Details | Diff | Splinter Review |
Current Behavior:
var f = new FileReader();
f.abort();
will throw an exception, owing to bug 657964.
Expected Behavior:
The File API says: http://dev.w3.org/2006/webapi/FileAPI/#abort which is to do nothing about an abort() call when the status is EMPTY or DONE, NOT to throw an exception.
Other Browsers:
Chrome and Safari do not throw an exception.
Updated•11 years ago
|
Flags: needinfo?(khuey)
Comment 1•11 years ago
|
||
Is this a regression?
Comment 2•11 years ago
|
||
Somewhat: we purposefully changed to a behavior that does not match the spec.
Reporter | ||
Comment 3•11 years ago
|
||
bz, I think that this behavior was introduced because the spec. itself was in flux. I don't think it was a willful violation of spec. If you think spec. behavior is wrong, I'd like to know of course :)
I vaguely recall that we intended to align with XHR or something here. Maybe that never ended up happening.
Flags: needinfo?(khuey)
Comment 5•11 years ago
|
||
XMLHttpRequest's abort() never throws. I think generally we should throwing unless it catches something that's an actual mistake or cannot be readily handled. I don't think that's the case here.
Comment 6•11 years ago
|
||
Attachment #826457 -
Flags: review?(bugs)
Comment 7•11 years ago
|
||
Hey guys,
Should I also remove [Throws] just before void abort(); in FileReader.webid?
Thanks
Comment 8•11 years ago
|
||
Comment on attachment 826457 [details] [diff] [review]
FileReaderException.diff
Yes, you should remove [Throws] and the ErrorResult param since per spec
the method doesn't throw.
Attachment #826457 -
Flags: review?(bugs)
Comment 9•7 years ago
|
||
https://bugzilla.mozilla.org/show_bug.cgi?id=1472046
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
Assignee | ||
Updated•6 years ago
|
Component: DOM → DOM: Core & HTML
Updated•2 years ago
|
Severity: normal → S3
You need to log in
before you can comment on or make changes to this bug.
Description
•