RFR: 8232861: (fc) FileChannel.force fails on WebDAV file systems (macOS) [v4]

Alan Bateman alanb at openjdk.java.net
Thu Apr 8 16:03:33 UTC 2021


On Thu, 8 Apr 2021 16:00:44 GMT, Brian Burkhalter <bpb at openjdk.org> wrote:

>> Apparently `fcntl(fd, F_FULLFSYNC)` can fail with `ENOTTY` in addition to `ENOTSUP` although it is not so documented. The `ioctl()` case is documented as
>> [ENOTTY]       fildes is not associated with a character special
>>                device.
>> [ENOTTY]       The specified request does not apply to the kind of
>>                object that the descriptor fildes references.
>> 
>> This request proposes to catch `ENOTTY` as well and fall back to `fsync(fd)`. The change was verified manually using a WebDAV server and no failures in CI test tiers 1-3 were observed. An alternative would be to fall back to `fsync(fd)` for **all** errors.
>
> Brian Burkhalter has updated the pull request incrementally with one additional commit since the last revision:
> 
>   8232861: Remove ENOTSUP fallback for fcntl(fd, F_FULLFSYNC) failure

Marked as reviewed by alanb (Reviewer).

-------------

PR: https://git.openjdk.java.net/jdk/pull/3366


More information about the nio-dev mailing list