summaryrefslogtreecommitdiffstats
path: root/source/lib/socket/socket_unix.c
diff options
context:
space:
mode:
authorAndrew Tridgell <tridge@samba.org>2004-10-27 03:45:35 +0000
committerAndrew Tridgell <tridge@samba.org>2004-10-27 03:45:35 +0000
commite87198ad56f5ecca515f5782c0657d3397dec1b1 (patch)
treead39007b47f516838e9fc709fd07277f7697a266 /source/lib/socket/socket_unix.c
parent0c9d43dd21e30048b380ef66bbdd3a4ae291448c (diff)
downloadsamba-e87198ad56f5ecca515f5782c0657d3397dec1b1.tar.gz
samba-e87198ad56f5ecca515f5782c0657d3397dec1b1.tar.xz
samba-e87198ad56f5ecca515f5782c0657d3397dec1b1.zip
r3279: Removed MSG_DONTWAIT flags as many platform don't have it.
If a socket is non-blocking then adding MSG_DONTWAIT is pointless (it does nothing), so all we lose is the ability to set non-blocking on a packet-by-packet basis, which is not a very useful thing to have anyway if the socket is blocking then the code already adds MSG_WAITALL, so MSG_DONTWAIT is also not needed in that case.
Diffstat (limited to 'source/lib/socket/socket_unix.c')
-rw-r--r--source/lib/socket/socket_unix.c9
1 files changed, 0 insertions, 9 deletions
diff --git a/source/lib/socket/socket_unix.c b/source/lib/socket/socket_unix.c
index 90802eae660..eda1597df7d 100644
--- a/source/lib/socket/socket_unix.c
+++ b/source/lib/socket/socket_unix.c
@@ -172,10 +172,6 @@ static NTSTATUS unixdom_recv(struct socket_context *sock, TALLOC_CTX *mem_ctx,
flgs |= MSG_PEEK;
}
- if (!(flags & SOCKET_FLAG_BLOCK)) {
- flgs |= MSG_DONTWAIT;
- }
-
if (flags & SOCKET_FLAG_BLOCK) {
flgs |= MSG_WAITALL;
}
@@ -207,11 +203,6 @@ static NTSTATUS unixdom_send(struct socket_context *sock, TALLOC_CTX *mem_ctx,
*sendlen = 0;
- /* TODO: we need to map all flags here */
- if (!(flags & SOCKET_FLAG_BLOCK)) {
- flgs |= MSG_DONTWAIT;
- }
-
len = send(sock->fd, blob->data, blob->length, flgs);
if (len == -1) {
return unixdom_error(errno);