projects
/
fio.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
|
inline
| side by side (parent:
166dce4
)
net: exit on WAITALL and !ret
author
Jens Axboe
<axboe@kernel.dk>
Thu, 29 Nov 2012 18:57:35 +0000
(19:57 +0100)
committer
Jens Axboe
<axboe@kernel.dk>
Thu, 29 Nov 2012 18:57:35 +0000
(19:57 +0100)
Otherwise we can loop forever if the other end hung up.
Signed-off-by: Jens Axboe <axboe@kernel.dk>
engines/net.c
patch
|
blob
|
blame
|
history
diff --git
a/engines/net.c
b/engines/net.c
index 101f7540789b9994a084777e02529e4be102429b..419508e47a5ec037a33c2c00781973820cbdc752 100644
(file)
--- a/
engines/net.c
+++ b/
engines/net.c
@@
-360,6
+360,8
@@
static int fio_netio_recv(struct thread_data *td, struct io_u *io_u)
}
if (ret > 0)
break;
}
if (ret > 0)
break;
+ else if (!ret && (flags & MSG_WAITALL))
+ break;
ret = poll_wait(td, io_u->file->fd, POLLIN);
if (ret <= 0)
ret = poll_wait(td, io_u->file->fd, POLLIN);
if (ret <= 0)