RFR: 8274548: (fc) FileChannel gathering write fails with IOException "Invalid argument" on macOS 11.6 [v4]

Alan Bateman alanb at openjdk.java.net
Fri Oct 8 12:07:08 UTC 2021


On Thu, 7 Oct 2021 18:33:33 GMT, Brian Burkhalter <bpb at openjdk.org> wrote:

>> On macOS, handle the case where `writev()` is given an array of `struct iovec` the sum of whose `iov_len` fields overflows `INT_MAX`.
>
> Brian Burkhalter has updated the pull request incrementally with one additional commit since the last revision:
> 
>   8274548: Native macOS-only code change with no modification of iovec array

One approach is try to add a writevMax method along side of iovMax that returns the maximum value of the sum of the iov_len. If this is merged with your v2 then it might not be too bad.

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

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


More information about the nio-dev mailing list