summaryrefslogtreecommitdiff
path: root/libc/inet
diff options
context:
space:
mode:
authorPeter S. Mazinger <ps.m@gmx.net>2005-12-08 21:01:23 +0000
committerPeter S. Mazinger <ps.m@gmx.net>2005-12-08 21:01:23 +0000
commit77ccb5b1dca86acdc7c75abc5bb469da41872a20 (patch)
tree13fb13805ef3018a0a12f102f72ce2c61532fde3 /libc/inet
parent7a3dea048d88faa3bbe1c99bcf3fdb98eabae52d (diff)
mmap/mremap/socket/rewind gone
Diffstat (limited to 'libc/inet')
-rw-r--r--libc/inet/getaddrinfo.c2
-rw-r--r--libc/inet/getnetent.c1
-rw-r--r--libc/inet/getproto.c1
-rw-r--r--libc/inet/getservice.c1
-rw-r--r--libc/inet/if_nametoindex.c4
-rw-r--r--libc/inet/resolv.c6
-rw-r--r--libc/inet/rpc/clnt_tcp.c2
-rw-r--r--libc/inet/rpc/clnt_udp.c5
-rw-r--r--libc/inet/rpc/clnt_unix.c4
-rw-r--r--libc/inet/rpc/get_myaddress.c2
-rw-r--r--libc/inet/rpc/getrpcent.c1
-rw-r--r--libc/inet/rpc/pmap_clnt.c2
-rw-r--r--libc/inet/rpc/pmap_rmt.c4
-rw-r--r--libc/inet/rpc/rcmd.c2
-rw-r--r--libc/inet/rpc/rexec.c4
-rw-r--r--libc/inet/rpc/rtime.c4
-rw-r--r--libc/inet/rpc/svc_tcp.c2
-rw-r--r--libc/inet/rpc/svc_udp.c6
-rw-r--r--libc/inet/rpc/svc_unix.c4
19 files changed, 39 insertions, 18 deletions
diff --git a/libc/inet/getaddrinfo.c b/libc/inet/getaddrinfo.c
index 2dd14d78f..a85e2ff5e 100644
--- a/libc/inet/getaddrinfo.c
+++ b/libc/inet/getaddrinfo.c
@@ -159,7 +159,7 @@ static int addrconfig (sa_family_t af)
int s;
int ret;
int saved_errno = errno;
- s = socket(af, SOCK_DGRAM, 0);
+ s = __socket(af, SOCK_DGRAM, 0);
if (s < 0)
ret = (errno == EMFILE) ? 1 : 0;
else
diff --git a/libc/inet/getnetent.c b/libc/inet/getnetent.c
index f2c2cd97d..edbae55b0 100644
--- a/libc/inet/getnetent.c
+++ b/libc/inet/getnetent.c
@@ -16,6 +16,7 @@
*/
#define inet_network __inet_network
+#define rewind __rewind
#define __FORCE_GLIBC
#include <features.h>
diff --git a/libc/inet/getproto.c b/libc/inet/getproto.c
index ec00b5e93..0c0e2c468 100644
--- a/libc/inet/getproto.c
+++ b/libc/inet/getproto.c
@@ -53,6 +53,7 @@
#define strpbrk __strpbrk
#define atoi __atoi
+#define rewind __rewind
#define __FORCE_GLIBC
#define _GNU_SOURCE
diff --git a/libc/inet/getservice.c b/libc/inet/getservice.c
index 6026273b4..79cdf7434 100644
--- a/libc/inet/getservice.c
+++ b/libc/inet/getservice.c
@@ -53,6 +53,7 @@
#define strpbrk __strpbrk
#define atoi __atoi
+#define rewind __rewind
#define __FORCE_GLIBC
#define _GNU_SOURCE
diff --git a/libc/inet/if_nametoindex.c b/libc/inet/if_nametoindex.c
index 909cf503a..f3803e56b 100644
--- a/libc/inet/if_nametoindex.c
+++ b/libc/inet/if_nametoindex.c
@@ -32,10 +32,10 @@ static int __opensock(void)
{
int fd;
#ifdef __UCLIBC_HAS_IPV6__
- fd=socket(AF_INET6,SOCK_DGRAM,0);
+ fd=__socket(AF_INET6,SOCK_DGRAM,0);
if (fd<0)
#endif /* __UCLIBC_HAS_IPV6__ */
- fd=socket(AF_INET,SOCK_DGRAM,0);
+ fd=__socket(AF_INET,SOCK_DGRAM,0);
return(fd);
}
diff --git a/libc/inet/resolv.c b/libc/inet/resolv.c
index 97ed3998f..d93adede8 100644
--- a/libc/inet/resolv.c
+++ b/libc/inet/resolv.c
@@ -146,6 +146,8 @@
#define inet_ntop __inet_ntop
#define connect __connect
#define select __select
+#define recv __recv
+#define send __send
#define __FORCE_GLIBC
#include <features.h>
@@ -770,9 +772,9 @@ int attribute_hidden __dns_lookup(const char *name, int type, int nscount, char
#ifdef __UCLIBC_HAS_IPV6__
v6 = inet_pton(AF_INET6, dns, &sa6.sin6_addr) > 0;
- fd = socket(v6 ? AF_INET6 : AF_INET, SOCK_DGRAM, IPPROTO_UDP);
+ fd = __socket(v6 ? AF_INET6 : AF_INET, SOCK_DGRAM, IPPROTO_UDP);
#else
- fd = socket(AF_INET, SOCK_DGRAM, IPPROTO_UDP);
+ fd = __socket(AF_INET, SOCK_DGRAM, IPPROTO_UDP);
#endif
if (fd < 0) {
retries++;
diff --git a/libc/inet/rpc/clnt_tcp.c b/libc/inet/rpc/clnt_tcp.c
index 50300d591..67892cc4b 100644
--- a/libc/inet/rpc/clnt_tcp.c
+++ b/libc/inet/rpc/clnt_tcp.c
@@ -175,7 +175,7 @@ __clnttcp_create (struct sockaddr_in *raddr, u_long prog, u_long vers,
*/
if (*sockp < 0)
{
- *sockp = socket (AF_INET, SOCK_STREAM, IPPROTO_TCP);
+ *sockp = __socket (AF_INET, SOCK_STREAM, IPPROTO_TCP);
(void) bindresvport (*sockp, (struct sockaddr_in *) 0);
if ((*sockp < 0)
|| (connect (*sockp, (struct sockaddr *) raddr,
diff --git a/libc/inet/rpc/clnt_udp.c b/libc/inet/rpc/clnt_udp.c
index 217650bf5..7855dcb2f 100644
--- a/libc/inet/rpc/clnt_udp.c
+++ b/libc/inet/rpc/clnt_udp.c
@@ -49,6 +49,9 @@ static char sccsid[] = "@(#)clnt_udp.c 1.39 87/08/11 Copyr 1984 Sun Micro";
#define _seterr_reply __seterr_reply
#define setsockopt __setsockopt
#define bindresvport __bindresvport
+#define recvfrom __recvfrom
+#define sendto __sendto
+#define recvmsg __recvmsg
#define __FORCE_GLIBC
#include <features.h>
@@ -197,7 +200,7 @@ __clntudp_bufcreate (struct sockaddr_in *raddr, u_long program, u_long version,
{
int dontblock = 1;
- *sockp = socket (AF_INET, SOCK_DGRAM, IPPROTO_UDP);
+ *sockp = __socket (AF_INET, SOCK_DGRAM, IPPROTO_UDP);
if (*sockp < 0)
{
struct rpc_createerr *ce = &get_rpc_createerr ();
diff --git a/libc/inet/rpc/clnt_unix.c b/libc/inet/rpc/clnt_unix.c
index 23154bab3..56f23b749 100644
--- a/libc/inet/rpc/clnt_unix.c
+++ b/libc/inet/rpc/clnt_unix.c
@@ -59,6 +59,8 @@
#define _seterr_reply __seterr_reply
#define setsockopt __setsockopt
#define connect __connect
+#define recvmsg __recvmsg
+#define sendmsg __sendmsg
#define __FORCE_GLIBC
#include <features.h>
@@ -158,7 +160,7 @@ __clntunix_create (struct sockaddr_un *raddr, u_long prog, u_long vers,
*/
if (*sockp < 0)
{
- *sockp = socket (AF_UNIX, SOCK_STREAM, 0);
+ *sockp = __socket (AF_UNIX, SOCK_STREAM, 0);
len = __strlen (raddr->sun_path) + sizeof (raddr->sun_family) + 1;
if (*sockp < 0
|| connect (*sockp, (struct sockaddr *) raddr, len) < 0)
diff --git a/libc/inet/rpc/get_myaddress.c b/libc/inet/rpc/get_myaddress.c
index 51674656e..bdbafa44d 100644
--- a/libc/inet/rpc/get_myaddress.c
+++ b/libc/inet/rpc/get_myaddress.c
@@ -65,7 +65,7 @@ get_myaddress (struct sockaddr_in *addr)
struct ifreq ifreq, *ifr;
int len, loopback = 0;
- if ((s = socket (AF_INET, SOCK_DGRAM, 0)) < 0)
+ if ((s = __socket (AF_INET, SOCK_DGRAM, 0)) < 0)
{
__perror ("get_myaddress: socket");
exit (1);
diff --git a/libc/inet/rpc/getrpcent.c b/libc/inet/rpc/getrpcent.c
index 90e8b70d4..c2e101510 100644
--- a/libc/inet/rpc/getrpcent.c
+++ b/libc/inet/rpc/getrpcent.c
@@ -34,6 +34,7 @@
*/
#define atoi __atoi
+#define rewind __rewind
#define __FORCE_GLIBC
#include <features.h>
diff --git a/libc/inet/rpc/pmap_clnt.c b/libc/inet/rpc/pmap_clnt.c
index 0abe646a1..49cd93f4b 100644
--- a/libc/inet/rpc/pmap_clnt.c
+++ b/libc/inet/rpc/pmap_clnt.c
@@ -66,7 +66,7 @@ __get_myaddress (struct sockaddr_in *addr)
struct ifreq ifreq, *ifr;
int len, loopback = 1;
- if ((s = socket (AF_INET, SOCK_DGRAM, 0)) < 0)
+ if ((s = __socket (AF_INET, SOCK_DGRAM, 0)) < 0)
{
__perror ("__get_myaddress: socket");
exit (1);
diff --git a/libc/inet/rpc/pmap_rmt.c b/libc/inet/rpc/pmap_rmt.c
index 2a814795a..60821ec6c 100644
--- a/libc/inet/rpc/pmap_rmt.c
+++ b/libc/inet/rpc/pmap_rmt.c
@@ -49,6 +49,8 @@ static char sccsid[] = "@(#)pmap_rmt.c 1.21 87/08/27 Copyr 1984 Sun Micro";
#define inet_netof __inet_netof
#define clntudp_create __clntudp_create
#define setsockopt __setsockopt
+#define recvfrom __recvfrom
+#define sendto __sendto
#define __FORCE_GLIBC
#include <features.h>
@@ -274,7 +276,7 @@ clnt_broadcast (prog, vers, proc, xargs, argsp, xresults, resultsp, eachresult)
* initialization: create a socket, a broadcast address, and
* preserialize the arguments into a send buffer.
*/
- if ((sock = socket (AF_INET, SOCK_DGRAM, IPPROTO_UDP)) < 0)
+ if ((sock = __socket (AF_INET, SOCK_DGRAM, IPPROTO_UDP)) < 0)
{
__perror (_("Cannot create socket for broadcast rpc"));
stat = RPC_CANTSEND;
diff --git a/libc/inet/rpc/rcmd.c b/libc/inet/rpc/rcmd.c
index 55f9e4042..726be44a1 100644
--- a/libc/inet/rpc/rcmd.c
+++ b/libc/inet/rpc/rcmd.c
@@ -280,7 +280,7 @@ int attribute_hidden __rresvport(int *alport)
sin.sin_family = AF_INET;
sin.sin_addr.s_addr = INADDR_ANY;
- s = socket(AF_INET, SOCK_STREAM, 0);
+ s = __socket(AF_INET, SOCK_STREAM, 0);
if (s < 0)
return -1;
for (;;) {
diff --git a/libc/inet/rpc/rexec.c b/libc/inet/rpc/rexec.c
index 6312366eb..cac783cc3 100644
--- a/libc/inet/rpc/rexec.c
+++ b/libc/inet/rpc/rexec.c
@@ -93,7 +93,7 @@ __rexec_af(char **ahost, int rport, const char *name, const char *pass, const ch
}
__ruserpass(res0->ai_canonname, &name, &pass);
retry:
- s = socket(res0->ai_family, res0->ai_socktype, 0);
+ s = __socket(res0->ai_family, res0->ai_socktype, 0);
if (s < 0) {
__perror("rexec: socket");
return (-1);
@@ -115,7 +115,7 @@ retry:
char num[32];
int s2, sa2len;
- s2 = socket(res0->ai_family, res0->ai_socktype, 0);
+ s2 = __socket(res0->ai_family, res0->ai_socktype, 0);
if (s2 < 0) {
(void) __close(s);
return (-1);
diff --git a/libc/inet/rpc/rtime.c b/libc/inet/rpc/rtime.c
index 2e20621f9..728dbab61 100644
--- a/libc/inet/rpc/rtime.c
+++ b/libc/inet/rpc/rtime.c
@@ -44,6 +44,8 @@ static char sccsid[] = "@(#)rtime.c 2.2 88/08/10 4.0 RPCSRC; from 1.8 88/02/08 S
*/
#define connect __connect
+#define recvfrom __recvfrom
+#define sendto __sendto
#define __FORCE_GLIBC
#include <features.h>
@@ -93,7 +95,7 @@ rtime (struct sockaddr_in *addrp, struct rpc_timeval *timep,
else
type = SOCK_DGRAM;
- s = socket (AF_INET, type, 0);
+ s = __socket (AF_INET, type, 0);
if (s < 0)
return (-1);
diff --git a/libc/inet/rpc/svc_tcp.c b/libc/inet/rpc/svc_tcp.c
index b3cd83fa8..2638d55be 100644
--- a/libc/inet/rpc/svc_tcp.c
+++ b/libc/inet/rpc/svc_tcp.c
@@ -166,7 +166,7 @@ svctcp_create (int sock, u_int sendsize, u_int recvsize)
if (sock == RPC_ANYSOCK)
{
- if ((sock = socket (AF_INET, SOCK_STREAM, IPPROTO_TCP)) < 0)
+ if ((sock = __socket (AF_INET, SOCK_STREAM, IPPROTO_TCP)) < 0)
{
__perror (_("svc_tcp.c - tcp socket creation problem"));
return (SVCXPRT *) NULL;
diff --git a/libc/inet/rpc/svc_udp.c b/libc/inet/rpc/svc_udp.c
index 0f731a6ba..62719ee33 100644
--- a/libc/inet/rpc/svc_udp.c
+++ b/libc/inet/rpc/svc_udp.c
@@ -48,6 +48,10 @@ static char sccsid[] = "@(#)svc_udp.c 1.24 87/08/11 Copyr 1984 Sun Micro";
#define setsockopt __setsockopt
#define bind __bind
#define bindresvport __bindresvport
+#define recvfrom __recvfrom
+#define sendto __sendto
+#define recvmsg __recvmsg
+#define sendmsg __sendmsg
#define __FORCE_GLIBC
#define _GNU_SOURCE
@@ -135,7 +139,7 @@ __svcudp_bufcreate (int sock, u_int sendsz, u_int recvsz)
if (sock == RPC_ANYSOCK)
{
- if ((sock = socket (AF_INET, SOCK_DGRAM, IPPROTO_UDP)) < 0)
+ if ((sock = __socket (AF_INET, SOCK_DGRAM, IPPROTO_UDP)) < 0)
{
__perror (_("svcudp_create: socket creation problem"));
return (SVCXPRT *) NULL;
diff --git a/libc/inet/rpc/svc_unix.c b/libc/inet/rpc/svc_unix.c
index 8b1e8b2d5..ed40146eb 100644
--- a/libc/inet/rpc/svc_unix.c
+++ b/libc/inet/rpc/svc_unix.c
@@ -50,6 +50,8 @@
#define getsockname __getsockname
#define setsockopt __setsockopt
#define bind __bind
+#define recvmsg __recvmsg
+#define sendmsg __sendmsg
#define __FORCE_GLIBC
#include <features.h>
@@ -161,7 +163,7 @@ svcunix_create (int sock, u_int sendsize, u_int recvsize, char *path)
if (sock == RPC_ANYSOCK)
{
- if ((sock = socket (AF_UNIX, SOCK_STREAM, 0)) < 0)
+ if ((sock = __socket (AF_UNIX, SOCK_STREAM, 0)) < 0)
{
__perror (_("svc_unix.c - AF_UNIX socket creation problem"));
return (SVCXPRT *) NULL;