All iov's were sent only after the last were sent (iov_len == 0). We
could have 'cur_len == 0' if the sent iov's were sent wholly but not all
iov's were sent (how about all but the last).
Signed-off-by: Yousong Zhou <yszhou4tech@gmail.com>
cur_len -= iov->iov_len;
iov_len--;
iov++;
cur_len -= iov->iov_len;
iov_len--;
iov++;
- if (!cur_len || !iov_len)
return len;
}
iov->iov_len -= cur_len;
return len;
}
iov->iov_len -= cur_len;