Integrated: 8232861: (fc) FileChannel.force fails on WebDAV file systems (macOS)

Brian Burkhalter bpb at openjdk.java.net
Fri Apr 9 15:34:26 UTC 2021


On Wed, 7 Apr 2021 02:35:18 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.

This pull request has now been integrated.

Changeset: 6de0bb20
Author:    Brian Burkhalter <bpb at openjdk.org>
URL:       https://git.openjdk.java.net/jdk/commit/6de0bb20
Stats:     14 lines in 1 file changed: 11 ins; 0 del; 3 mod

8232861: (fc) FileChannel.force fails on WebDAV file systems (macOS)

Reviewed-by: alanb

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

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


More information about the nio-dev mailing list