Re: File API: closed Blob objects

On Thu, Dec 12, 2013 at 12:21 PM, Arun Ranganathan <arun@mozilla.com> wrote:
>
> On Dec 12, 2013, at 3:14 PM, Jonas Sicking wrote:
>
> This does seem like an argument to create a asynchronous error rather than
> throwing an exception though, since for form submission there would be no
> place to throw an exception from.
>
> Just to be clear, are you proposing an asynchronous error reported through
> an error event firing off of FileReader with a DOMError?

Yes, I suggest we treat it as an IO error.

> Also, it isn't clear what fileListObject.files[0].close() would do for an
> asynchronous error, so perhaps both are necessary: treating it as "0 bytes"
> (empty byte sequence) *and* (where possible) using an asynchronous error
> reporting mechanism.

Hmm.. good point. I don't know what to do during submission at all.
Maybe the submission code could transparently drop any closed Blobs
from the set of name/value pairs before submitting.

/ Jonas

Received on Thursday, 12 December 2013 21:28:24 UTC