summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorbors[bot] <bors[bot]@users.noreply.github.com>2019-06-07 13:33:42 +0000
committerbors[bot] <bors[bot]@users.noreply.github.com>2019-06-07 13:33:42 +0000
commit5a2586b38e7312e90dfca4cb390b8b908175c70e (patch)
tree795a04b77b8906898dfb2192193a22a645429045 /src
parentde9ae7d6cd9b95d9d29ba8f181889bb201da82a5 (diff)
parent3ffbd40b9cb238948409f5fe258a56cd3feac175 (diff)
downloadnix-5a2586b38e7312e90dfca4cb390b8b908175c70e.zip
Merge #1079
1079: socket: expose MSG_WAITALL in MsgFlags r=asomers a=stefano-garzarella MSG_WAITALL can be useful with recv() to wait the full amount of data requested. Co-authored-by: Stefano Garzarella <sgarzare@redhat.com>
Diffstat (limited to 'src')
-rw-r--r--src/sys/socket/mod.rs4
1 files changed, 4 insertions, 0 deletions
diff --git a/src/sys/socket/mod.rs b/src/sys/socket/mod.rs
index 0ba28358..a8631f24 100644
--- a/src/sys/socket/mod.rs
+++ b/src/sys/socket/mod.rs
@@ -132,6 +132,10 @@ libc_bitflags!{
/// [`recv()`](fn.recv.html)
/// or similar function shall still return this data.
MSG_PEEK;
+ /// Receive operation blocks until the full amount of data can be
+ /// returned. The function may return smaller amount of data if a signal
+ /// is caught, an error or disconnect occurs.
+ MSG_WAITALL;
/// Enables nonblocking operation; if the operation would block,
/// `EAGAIN` or `EWOULDBLOCK` is returned. This provides similar
/// behavior to setting the `O_NONBLOCK` flag