W3C home > Mailing lists > Public > public-webapps@w3.org > January to March 2010

Re: File API: Blob and underlying file changes.

From: Jonas Sicking <jonas@sicking.cc>
Date: Tue, 12 Jan 2010 15:46:46 -0800
Message-ID: <63df84f1001121546i646acd4ah42c2fd36d257018f@mail.gmail.com>
To: arun@mozilla.com
Cc: Dmitry Titov <dimich@chromium.org>, Web Applications Working Group WG <public-webapps@w3.org>
>> Today, if a user selects a file using <input type=file>, and then the file
>> on the disk changes before the 'submit' is clicked, the form will submit
>> the
>> latest version of the file.
>> This may be a surprisingly popular use case, when user submits a file via
>> form and wants to do 'last moment' changes in the file, after partial
>> pre-populating the form. It works 'intuitively' today.
> It is possible that two reads at different time intervals yield different
> results, if the underlying file has undergone changes between those time
> intervals.  This holds true for read methods that take a Blob or a File
> argument.
> The case of modifications *during* a read may be operating system dependent.

For the record, I'd like to make the read "atomic", such that you can
never get half a file before a change, and half after. But it likely
depends on what OSs can enforce here.

/ Jonas
Received on Tuesday, 12 January 2010 23:47:39 UTC

This archive was generated by hypermail 2.3.1 : Friday, 27 October 2017 07:26:22 UTC