Merge pull request #16803 from dmick/master

common/buffer: off-by-one error in max iov length blocking

Reviewed-by: Greg Farnum <gfarnum@redhat.com>
This commit is contained in:
Gregory Farnum 2017-08-04 11:58:41 -07:00 committed by GitHub
commit 62a2e420bf

View File

@ -2382,7 +2382,7 @@ int buffer::list::write_fd(int fd) const
}
++p;
if (iovlen == IOV_MAX-1 ||
if (iovlen == IOV_MAX ||
p == _buffers.end()) {
iovec *start = iov;
int num = iovlen;