diff options
author | 2015-10-04 07:17:27 +0000 | |
---|---|---|
committer | 2015-10-04 07:17:27 +0000 | |
commit | bd745da36e53583134d6cc71f94aadc5f8f2d226 (patch) | |
tree | 9930af309b1888c94928f62145370c171baddc99 /lib/libc | |
parent | getpeereid() and sockatmark() are neither used in libc nor in ISO C, so mark (diff) | |
download | wireguard-openbsd-bd745da36e53583134d6cc71f94aadc5f8f2d226.tar.xz wireguard-openbsd-bd745da36e53583134d6cc71f94aadc5f8f2d226.zip |
recv() and send() aren't overriden by libpthread (vs recvfrom() and sendto()!)
so wrap them to make internal calls go direct
Diffstat (limited to 'lib/libc')
-rw-r--r-- | lib/libc/hidden/sys/socket.h | 4 | ||||
-rw-r--r-- | lib/libc/net/recv.c | 3 | ||||
-rw-r--r-- | lib/libc/net/send.c | 3 |
3 files changed, 7 insertions, 3 deletions
diff --git a/lib/libc/hidden/sys/socket.h b/lib/libc/hidden/sys/socket.h index 9d2227d157c..d262e0f3bac 100644 --- a/lib/libc/hidden/sys/socket.h +++ b/lib/libc/hidden/sys/socket.h @@ -1,4 +1,4 @@ -/* $OpenBSD: socket.h,v 1.2 2015/10/04 07:14:48 guenther Exp $ */ +/* $OpenBSD: socket.h,v 1.3 2015/10/04 07:17:27 guenther Exp $ */ /* * Copyright (c) 2015 Philip Guenther <guenther@openbsd.org> * @@ -27,6 +27,8 @@ PROTO_NORMAL(getrtable); PROTO_NORMAL(getsockname); PROTO_NORMAL(getsockopt); PROTO_NORMAL(listen); +PROTO_NORMAL(recv); +PROTO_NORMAL(send); PROTO_NORMAL(setrtable); PROTO_NORMAL(setsockopt); PROTO_NORMAL(shutdown); diff --git a/lib/libc/net/recv.c b/lib/libc/net/recv.c index 6241cc6b12f..365d0e2e193 100644 --- a/lib/libc/net/recv.c +++ b/lib/libc/net/recv.c @@ -1,4 +1,4 @@ -/* $OpenBSD: recv.c,v 1.5 2005/08/06 20:30:03 espie Exp $ */ +/* $OpenBSD: recv.c,v 1.6 2015/10/04 07:17:27 guenther Exp $ */ /* * Copyright (c) 1988, 1993 * The Regents of the University of California. All rights reserved. @@ -38,3 +38,4 @@ recv(int s, void *buf, size_t len, int flags) { return (recvfrom(s, buf, len, flags, NULL, 0)); } +DEF_WEAK(recv); diff --git a/lib/libc/net/send.c b/lib/libc/net/send.c index 1bfc80b87a5..1fad3bd171f 100644 --- a/lib/libc/net/send.c +++ b/lib/libc/net/send.c @@ -1,4 +1,4 @@ -/* $OpenBSD: send.c,v 1.5 2005/08/06 20:30:04 espie Exp $ */ +/* $OpenBSD: send.c,v 1.6 2015/10/04 07:17:27 guenther Exp $ */ /* * Copyright (c) 1988, 1993 * The Regents of the University of California. All rights reserved. @@ -38,3 +38,4 @@ send(int s, const void *msg, size_t len, int flags) { return (sendto(s, msg, len, flags, NULL, 0)); } +DEF_WEAK(send); |