summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMiles Bader <miles@gnu.org>1996-01-27 17:37:55 +0000
committerMiles Bader <miles@gnu.org>1996-01-27 17:37:55 +0000
commit15c46a48b066491c30dd950e9e36b4b1c95d8740 (patch)
tree7fbcaf6e77e2df843ad32ab6f37350f8e5e24ad4
parent1ddd0b72af817d67e246aa7fd34b0ffb8aa905fd (diff)
(S_socket_recv):
Test for MSG_OOB in IN_FLAGS, not FLAGS. Return EINVAL if we get MSG_OOB, not EOPNOTSUPP.
-rw-r--r--pflocal/socket.c12
1 files changed, 6 insertions, 6 deletions
diff --git a/pflocal/socket.c b/pflocal/socket.c
index 3779a0b0..0bc72066 100644
--- a/pflocal/socket.c
+++ b/pflocal/socket.c
@@ -361,12 +361,12 @@ S_socket_recv (struct sock_user *user,
if (!user)
return EOPNOTSUPP;
- if (flags & MSG_OOB)
+ if (in_flags & MSG_OOB)
/* BSD local sockets don't support OOB data. */
- return EOPNOTSUPP;
+ return EINVAL; /* XXX */
- flags =
- 0;
+ /* Fill in the pipe FLAGS from any corresponding ones in IN_FLAGS. */
+ flags = 0;
err = sock_acquire_read_pipe (user->sock, &pipe);
if (err == EPIPE)
@@ -401,8 +401,8 @@ S_socket_recv (struct sock_user *user,
*addr = MACH_PORT_NULL;
}
- out_flags =
- 0;
+ /* Fill in OUT_FLAGS from from any corresponding ones in FLAGS. */
+ out_flags = 0;
return err;
}