Bug 1733097 [wpt PR 30909] - FSA: Make removal of files compatible with file locking...
commit39ac297cdeecb46756ac99d96e81626087de2a47
authorAustin Sullivan <asully@chromium.org>
Mon, 4 Oct 2021 23:18:15 +0000 (4 23:18 +0000)
committermoz-wptsync-bot <wptsync@mozilla.com>
Tue, 5 Oct 2021 12:49:08 +0000 (5 12:49 +0000)
tree65c87f3849e2dbb8645371993305b9d2371bdb27
parent4c735703d4878484d6bad77c976d55a3f1045e77
Bug 1733097 [wpt PR 30909] - FSA: Make removal of files compatible with file locking, a=testonly

Automatic update from web-platform-tests
FSA: Make removal of files compatible with file locking

Removing a file requires acquiring a write lock at the URL.
The lock is released once the operation completes.

remove() requires acquiring an exclusive lock at the URL.

For the sake of backwards compatibility, removeEntry() only requires
acquiring a shared lock. This means that you cannot remove a file with
an open access handle, but you CAN remove a file with open writables.

Removal of directories is not yet compatible with file locking.

Bug: 11149231254078
Change-Id: I1eee08deaff9508e3c90d78ae35b2c181bb18122
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/3174315
Commit-Queue: Austin Sullivan <asully@chromium.org>
Auto-Submit: Austin Sullivan <asully@chromium.org>
Reviewed-by: Marijn Kruisselbrink <mek@chromium.org>
Cr-Commit-Position: refs/heads/main@{#926938}

--

wpt-commits: 2a49a9e6e4cfadbc32eebdc8be0c14e72e0b77cf
wpt-pr: 30909
testing/web-platform/tests/file-system-access/script-tests/FileSystemBaseHandle-remove.js
testing/web-platform/tests/file-system-access/script-tests/FileSystemDirectoryHandle-removeEntry.js