[Bug 24576] Calling URL.createObjectURL() on a closed Blob

https://www.w3.org/Bugs/Public/show_bug.cgi?id=24576

--- Comment #19 from Arun <arun@mozilla.com> ---
(In reply to sof from comment #18)
> re: close(), https://www.w3.org/Bugs/Public/show_bug.cgi?id=23417 is
> relevant when considering how closed Blobs should be handled by platform.

So, after chatting with Jonas on IRC, I think Comment 11 is right about not
throwing for URL.createObjectURL and URL.createFor, since this might put the
burden of try/catch on a developer just trying to coin a URL.

But this does mean that some methods will throw, and some won't.  I think
FileReader.readAsxxx throwing is fine; I think close() itself throwing if
closing an already closed Blob is fine. Any of those failing differently seems
confusing.

Based on Comment 11, it seems your suggestion is to have the behavior be when
called on a closed blob, URL.create* will return a URL which when Parse/Fetch'd
will return a network error. OK.

-- 
You are receiving this mail because:
You are the QA Contact for the bug.

Received on Tuesday, 25 March 2014 20:40:47 UTC