On 02.06.21 12:57, Olaf Hering wrote: > Am Wed, 2 Jun 2021 08:30:08 +0200 > schrieb Juergen Gross : > >> On 01.06.21 18:10, Olaf Hering wrote: >>> +int readv_exact(int fd, const struct iovec *iov, int iovcnt) > >>> + if ( len <= 0 ) >>> + { >>> + rc = -1; >> Is EOF really an error? > > I think yes, that's what "exact" implies IMO. Shouldn't you check for zero length iovec elements as in the writev_exact() case then? >> This will stop the loop, even if idx hasn't reached iovcnt. > > Yes, it will trigger yet another readv(). Ah, right. Juergen