It should be greater than zero, and less than IOSIZE_MAX. Remove now redundand checks from functions calling kern_preadv() and kern_pwritev(), i.e. read/pread and write/pwrite syscalls implementations.
Details
Details
Diff Detail
Diff Detail
- Repository
- rG FreeBSD src repository
- Lint
Lint Skipped - Unit
Tests Skipped
Event Timeline
Comment Actions
iov_len is size_t, while uio_resid is ssize_t. When IOSIZE_MAX is unclamped, the checks in copyinuio() probably do not check much.
I think at least iov_len should be verified to fit into ssize_t, but still I believe that the final check for uio_resid in dofileread/write is useful.
Comment Actions
https://people.freebsd.org/~pho/stress/log/log0091.txt
This patch does not fix the issue for me using this test scenario:
https://people.freebsd.org/~pho/stress/log/log0091.txt