summaryrefslogtreecommitdiff
path: root/libc/inet/rpc/rcmd.c
diff options
context:
space:
mode:
authorPeter S. Mazinger <ps.m@gmx.net>2005-12-08 14:29:53 +0000
committerPeter S. Mazinger <ps.m@gmx.net>2005-12-08 14:29:53 +0000
commit11b9aee8ff8c9ab70ef6e5b6d68f75cd8a44c4d5 (patch)
tree40fa6c344cdb770bfb6edd104b41417fe6a8ba88 /libc/inet/rpc/rcmd.c
parentab9d3f10ea97362d3c8ed875f2a721bf56c0f0ed (diff)
Again rpc ;-( , all *inet*, *addr*
Diffstat (limited to 'libc/inet/rpc/rcmd.c')
-rw-r--r--libc/inet/rpc/rcmd.c16
1 files changed, 13 insertions, 3 deletions
diff --git a/libc/inet/rpc/rcmd.c b/libc/inet/rpc/rcmd.c
index bbcc7b354..55f9e4042 100644
--- a/libc/inet/rpc/rcmd.c
+++ b/libc/inet/rpc/rcmd.c
@@ -43,6 +43,13 @@ static char sccsid[] = "@(#)rcmd.c 8.3 (Berkeley) 3/26/94";
#define getpwnam_r __getpwnam_r
#define gethostbyname __gethostbyname
#define gethostbyname_r __gethostbyname_r
+#define fileno __fileno
+#define sleep __sleep
+#define inet_addr __inet_addr
+#define inet_ntoa __inet_ntoa
+#define herror __herror
+#define bind __bind
+#define connect __connect
#define __FORCE_GLIBC
#include <features.h>
@@ -67,6 +74,8 @@ static char sccsid[] = "@(#)rcmd.c 8.3 (Berkeley) 3/26/94";
#include <arpa/inet.h>
+extern int __rresvport(int *alport) attribute_hidden;
+
/* some forward declarations */
static int __ivaliduser2(FILE *hostf, u_int32_t raddr,
const char *luser, const char *ruser, const char *rhost);
@@ -144,7 +153,7 @@ int rcmd(ahost, rport, locuser, remuser, cmd, fd2p)
*ahost = hp->h_name;
oldmask = sigblock(sigmask(SIGURG)); /* __sigblock */
for (timo = 1, lport = IPPORT_RESERVED - 1;;) {
- s = rresvport(&lport);
+ s = __rresvport(&lport);
if (s < 0) {
if (errno == EAGAIN)
(void)fprintf(stderr,
@@ -195,7 +204,7 @@ int rcmd(ahost, rport, locuser, remuser, cmd, fd2p)
lport = 0;
} else {
char num[8];
- int s2 = rresvport(&lport), s3;
+ int s2 = __rresvport(&lport), s3;
socklen_t len = sizeof(from);
if (s2 < 0)
@@ -264,7 +273,7 @@ bad:
return -1;
}
-int rresvport(int *alport)
+int attribute_hidden __rresvport(int *alport)
{
struct sockaddr_in sin;
int s;
@@ -292,6 +301,7 @@ int rresvport(int *alport)
return -1;
}
+strong_alias(__rresvport,rresvport)
int __check_rhosts_file = 1;
char *__rcmd_errstr;