- From: <bugzilla@jessica.w3.org>
- Date: Wed, 23 Apr 2014 20:54:01 +0000
- To: public-webapps-bugzilla@w3.org
https://www.w3.org/Bugs/Public/show_bug.cgi?id=25081 --- Comment #27 from Arun <arun@mozilla.com> --- (In reply to Anne from comment #26) > The reason you want to separate the URL parser and fetch is because of > things like <img srcset>. There can be multiple URLs that you want to parse > synchronously, but not necessarily all fetch at the same time (or indeed not > necessarily at any point in the future). The way I would expect this to work is: 1. Parser sets URL's object to a structured clone of the entry in the Blob URL store. (Note: if the Blob has been closed with a blob.close(), currently this revokes all entries from the Blob URL store too. It's been suggested that this is not the right behavior. Assuming it is, the Parse Algo may obtain the structured clone only if there is an entry in the Blob URL Store; if there isn't, it will simply return without an object. In other words, if there isn't an entry in the Blob URL store, it could mean the Blob has been closed.) 2. Fetch operates on the URL object in 1. Fetch can invoke a read operation on the URL's object, which is a structured clone that is opened. Fetch's invocation of the read operation still works, even if the original object has been closed; the structured clone obtained in 1. is still opened, and not closed. So, I'm not sure we'll take a structured clone for the read operation, contrary to Comment 22; the read operation will operate on a Blob, whether it's a structured clone of another Blob or not. > > I would expect reading from a blob to also have other failure conditions > that might need to be enumerated. E.g. if if it was a blob backing a file > that was moved by the user. That's why I thought it would be a longer > algorithm. It does. If it was a blob backed by a file that was moved by the user, that's still an error that has to be reported through an error event. So's reading on a closed blob. It would be nice to have all of these in one algorithm. > As for the closed flag, I suppose I need to add a check for that here > http://url.spec.whatwg.org/#concept-url-parser and not set a url's object if > the blob is closed? If the Blob is closed, it is expected to flush an entry from the Blob URL store now. If that's the model, then checking for closed is redundant for URL parser. -- You are receiving this mail because: You are the QA Contact for the bug.
Received on Wednesday, 23 April 2014 20:54:03 UTC