diff options
Diffstat (limited to 'lib/libc/rpc')
-rw-r--r-- | lib/libc/rpc/auth_time.c | 6 | ||||
-rw-r--r-- | lib/libc/rpc/clnt_simple.c | 2 | ||||
-rw-r--r-- | lib/libc/rpc/clnt_tcp.c | 10 | ||||
-rw-r--r-- | lib/libc/rpc/clnt_udp.c | 2 | ||||
-rw-r--r-- | lib/libc/rpc/clnt_unix.c | 6 | ||||
-rw-r--r-- | lib/libc/rpc/get_myaddress.c | 6 | ||||
-rw-r--r-- | lib/libc/rpc/key_call.c | 2 | ||||
-rw-r--r-- | lib/libc/rpc/pmap_clnt.c | 4 | ||||
-rw-r--r-- | lib/libc/rpc/pmap_getmaps.c | 2 | ||||
-rw-r--r-- | lib/libc/rpc/pmap_getport.c | 2 | ||||
-rw-r--r-- | lib/libc/rpc/pmap_rmt.c | 4 | ||||
-rw-r--r-- | lib/libc/rpc/rtime.c | 4 | ||||
-rw-r--r-- | lib/libc/rpc/svc_tcp.c | 14 | ||||
-rw-r--r-- | lib/libc/rpc/svc_udp.c | 4 | ||||
-rw-r--r-- | lib/libc/rpc/svc_unix.c | 4 |
15 files changed, 36 insertions, 36 deletions
diff --git a/lib/libc/rpc/auth_time.c b/lib/libc/rpc/auth_time.c index 47f5212..836a69f 100644 --- a/lib/libc/rpc/auth_time.c +++ b/lib/libc/rpc/auth_time.c @@ -437,7 +437,7 @@ __rpc_get_time_offset(td, srv, thost, uaddr, netid) msg("alarm caught it, must be unreachable."); goto error; } - res = _libc_read(s, (char *)&thetime, sizeof(thetime)); + res = _read(s, (char *)&thetime, sizeof(thetime)); if (res != sizeof(thetime)) { if (saw_alarm) msg("timed out TCP call."); @@ -449,7 +449,7 @@ __rpc_get_time_offset(td, srv, thost, uaddr, netid) time_valid = 1; } save = errno; - (void)_libc_close(s); + (void)_close(s); errno = save; s = RPC_ANYSOCK; @@ -468,7 +468,7 @@ error: */ if (s != RPC_ANYSOCK) - (void)_libc_close(s); + (void)_close(s); if (clnt != NULL) clnt_destroy(clnt); diff --git a/lib/libc/rpc/clnt_simple.c b/lib/libc/rpc/clnt_simple.c index d9623a9..897eab5 100644 --- a/lib/libc/rpc/clnt_simple.c +++ b/lib/libc/rpc/clnt_simple.c @@ -86,7 +86,7 @@ callrpc(host, prognum, versnum, procnum, inproc, in, outproc, out) } else { crp->valid = 0; if (crp->socket != -1) - (void)_libc_close(crp->socket); + (void)_close(crp->socket); crp->socket = RPC_ANYSOCK; if (crp->client) { clnt_destroy(crp->client); diff --git a/lib/libc/rpc/clnt_tcp.c b/lib/libc/rpc/clnt_tcp.c index 6cddb7b..1889694 100644 --- a/lib/libc/rpc/clnt_tcp.c +++ b/lib/libc/rpc/clnt_tcp.c @@ -167,7 +167,7 @@ clnttcp_create(raddr, prog, vers, sockp, sendsz, recvsz) rpc_createerr.cf_stat = RPC_SYSTEMERROR; rpc_createerr.cf_error.re_errno = errno; if (*sockp != -1) - (void)_libc_close(*sockp); + (void)_close(*sockp); goto fooy; } ct->ct_closeit = TRUE; @@ -200,7 +200,7 @@ clnttcp_create(raddr, prog, vers, sockp, sendsz, recvsz) XDR_ENCODE); if (! xdr_callhdr(&(ct->ct_xdrs), &call_msg)) { if (ct->ct_closeit) { - (void)_libc_close(*sockp); + (void)_close(*sockp); } goto fooy; } @@ -474,7 +474,7 @@ clnttcp_destroy(h) (struct ct_data *) h->cl_private; if (ct->ct_closeit) { - (void)_libc_close(ct->ct_sock); + (void)_close(ct->ct_sock); } XDR_DESTROY(&(ct->ct_xdrs)); mem_free((caddr_t)ct, sizeof(struct ct_data)); @@ -544,7 +544,7 @@ readtcp(ct, buf, len) } break; } - switch (len = _libc_read(ct->ct_sock, buf, len)) { + switch (len = _read(ct->ct_sock, buf, len)) { case 0: /* premature eof */ @@ -570,7 +570,7 @@ writetcp(ct, buf, len) register int i, cnt; for (cnt = len; cnt > 0; cnt -= i, buf += i) { - if ((i = _libc_write(ct->ct_sock, buf, cnt)) == -1) { + if ((i = _write(ct->ct_sock, buf, cnt)) == -1) { ct->ct_error.re_errno = errno; ct->ct_error.re_status = RPC_CANTSEND; return (-1); diff --git a/lib/libc/rpc/clnt_udp.c b/lib/libc/rpc/clnt_udp.c index f7f7b50..3dc7710 100644 --- a/lib/libc/rpc/clnt_udp.c +++ b/lib/libc/rpc/clnt_udp.c @@ -559,7 +559,7 @@ clntudp_destroy(cl) register struct cu_data *cu = (struct cu_data *)cl->cl_private; if (cu->cu_closeit) { - (void)_libc_close(cu->cu_sock); + (void)_close(cu->cu_sock); } XDR_DESTROY(&(cu->cu_outxdrs)); mem_free((caddr_t)cu, (sizeof(*cu) + cu->cu_sendsz + cu->cu_recvsz)); diff --git a/lib/libc/rpc/clnt_unix.c b/lib/libc/rpc/clnt_unix.c index 5deb8b0..3b28bf8 100644 --- a/lib/libc/rpc/clnt_unix.c +++ b/lib/libc/rpc/clnt_unix.c @@ -158,7 +158,7 @@ clntunix_create(raddr, prog, vers, sockp, sendsz, recvsz) rpc_createerr.cf_stat = RPC_SYSTEMERROR; rpc_createerr.cf_error.re_errno = errno; if (*sockp != -1) - (void)_libc_close(*sockp); + (void)_close(*sockp); goto fooy; } ct->ct_closeit = TRUE; @@ -191,7 +191,7 @@ clntunix_create(raddr, prog, vers, sockp, sendsz, recvsz) XDR_ENCODE); if (! xdr_callhdr(&(ct->ct_xdrs), &call_msg)) { if (ct->ct_closeit) { - (void)_libc_close(*sockp); + (void)_close(*sockp); } goto fooy; } @@ -465,7 +465,7 @@ clntunix_destroy(h) (struct ct_data *) h->cl_private; if (ct->ct_closeit) { - (void)_libc_close(ct->ct_sock); + (void)_close(ct->ct_sock); } XDR_DESTROY(&(ct->ct_xdrs)); mem_free((caddr_t)ct, sizeof(struct ct_data)); diff --git a/lib/libc/rpc/get_myaddress.c b/lib/libc/rpc/get_myaddress.c index 2c129a4..05fae48 100644 --- a/lib/libc/rpc/get_myaddress.c +++ b/lib/libc/rpc/get_myaddress.c @@ -73,7 +73,7 @@ get_myaddress(addr) ifc.ifc_len = sizeof (buf); ifc.ifc_buf = buf; if (ioctl(s, SIOCGIFCONF, (char *)&ifc) < 0) { - _libc_close(s); + _close(s); return(-1); } again: @@ -83,7 +83,7 @@ again: while (ifr < end) { ifreq = *ifr; if (ioctl(s, SIOCGIFFLAGS, (char *)&ifreq) < 0) { - _libc_close(s); + _close(s); return(-1); } if (((ifreq.ifr_flags & IFF_UP) && @@ -107,6 +107,6 @@ again: loopback = 1; goto again; } - (void)_libc_close(s); + (void)_close(s); return (gotit ? 0 : -1); } diff --git a/lib/libc/rpc/key_call.c b/lib/libc/rpc/key_call.c index bb0d06b..703e038 100644 --- a/lib/libc/rpc/key_call.c +++ b/lib/libc/rpc/key_call.c @@ -369,7 +369,7 @@ int vers; (void) clnt_control(kcp->client, CLSET_RETRY_TIMEOUT, (char *)&wait_time); if (clnt_control(kcp->client, CLGET_FD, (char *)&fd)) - _libc_fcntl(fd, F_SETFD, 1); /* make it "close on exec" */ + _fcntl(fd, F_SETFD, 1); /* make it "close on exec" */ return (kcp->client); } diff --git a/lib/libc/rpc/pmap_clnt.c b/lib/libc/rpc/pmap_clnt.c index f306a78..540187b 100644 --- a/lib/libc/rpc/pmap_clnt.c +++ b/lib/libc/rpc/pmap_clnt.c @@ -102,7 +102,7 @@ pmap_set(program, version, protocol, port) } CLNT_DESTROY(client); if (socket != -1) - (void)_libc_close(socket); + (void)_close(socket); return (rslt); } @@ -144,6 +144,6 @@ pmap_unset(program, version) tottimeout); CLNT_DESTROY(client); if (socket != -1) - (void)_libc_close(socket); + (void)_close(socket); return (rslt); } diff --git a/lib/libc/rpc/pmap_getmaps.c b/lib/libc/rpc/pmap_getmaps.c index 06dabfe..777877b 100644 --- a/lib/libc/rpc/pmap_getmaps.c +++ b/lib/libc/rpc/pmap_getmaps.c @@ -80,7 +80,7 @@ pmap_getmaps(address) CLNT_DESTROY(client); } if (socket != -1) - (void)_libc_close(socket); + (void)_close(socket); address->sin_port = 0; return (head); } diff --git a/lib/libc/rpc/pmap_getport.c b/lib/libc/rpc/pmap_getport.c index 7e4c38b..2d6f5ac 100644 --- a/lib/libc/rpc/pmap_getport.c +++ b/lib/libc/rpc/pmap_getport.c @@ -85,7 +85,7 @@ pmap_getport(address, program, version, protocol) CLNT_DESTROY(client); } if (socket != -1) - (void)_libc_close(socket); + (void)_close(socket); address->sin_port = 0; return (port); } diff --git a/lib/libc/rpc/pmap_rmt.c b/lib/libc/rpc/pmap_rmt.c index da63488..55ddef9 100644 --- a/lib/libc/rpc/pmap_rmt.c +++ b/lib/libc/rpc/pmap_rmt.c @@ -98,7 +98,7 @@ pmap_rmtcall(addr, prog, vers, proc, xdrargs, argsp, xdrres, resp, tout, port_pt stat = RPC_FAILED; } if (socket != -1) - (void)_libc_close(socket); + (void)_close(socket); addr->sin_port = 0; return (stat); } @@ -408,7 +408,7 @@ done_broad: if (fds != &readfds) free(fds); if (sock >= 0) - (void)_libc_close(sock); + (void)_close(sock); AUTH_DESTROY(unix_auth); return (stat); } diff --git a/lib/libc/rpc/rtime.c b/lib/libc/rpc/rtime.c index 25b11ca..0aaf7c0 100644 --- a/lib/libc/rpc/rtime.c +++ b/lib/libc/rpc/rtime.c @@ -129,7 +129,7 @@ rtime(addrp, timep, timeout) do_close(s); return(-1); } - res = _libc_read(s, (char *)&thetime, sizeof(thetime)); + res = _read(s, (char *)&thetime, sizeof(thetime)); do_close(s); if (res < 0) { return(-1); @@ -152,6 +152,6 @@ do_close(s) int save; save = errno; - (void)_libc_close(s); + (void)_close(s); errno = save; } diff --git a/lib/libc/rpc/svc_tcp.c b/lib/libc/rpc/svc_tcp.c index da34518..3e14010 100644 --- a/lib/libc/rpc/svc_tcp.c +++ b/lib/libc/rpc/svc_tcp.c @@ -145,7 +145,7 @@ svctcp_create(sock, sendsize, recvsize) if (ioctl(sock, FIONBIO, &on) < 0) { perror("svc_tcp.c - cannot turn on non-blocking mode"); if (madesock) - (void)_libc_close(sock); + (void)_close(sock); return ((SVCXPRT *)NULL); } memset(&addr, 0, sizeof (addr)); @@ -159,7 +159,7 @@ svctcp_create(sock, sendsize, recvsize) (listen(sock, 2) != 0)) { perror("svctcp_.c - cannot getsockname or listen"); if (madesock) - (void)_libc_close(sock); + (void)_close(sock); return ((SVCXPRT *)NULL); } r = (struct tcp_rendezvous *)mem_alloc(sizeof(*r)); @@ -257,7 +257,7 @@ rendezvous_request(xprt) * Guard against FTP bounce attacks. */ if (addr.sin_port == htons(20)) { - _libc_close(sock); + _close(sock); return (FALSE); } /* @@ -265,7 +265,7 @@ rendezvous_request(xprt) */ off = 0; if (ioctl(sock, FIONBIO, &off) < 0) { - _libc_close(sock); + _close(sock); return (FALSE); } /* @@ -291,7 +291,7 @@ svctcp_destroy(xprt) register struct tcp_conn *cd = (struct tcp_conn *)xprt->xp_p1; xprt_unregister(xprt); - (void)_libc_close(xprt->xp_sock); + (void)_close(xprt->xp_sock); if (xprt->xp_port != 0) { /* a rendezvouser socket */ xprt->xp_port = 0; @@ -376,7 +376,7 @@ readtcp(xprt, buf, len) } } } while (!FD_ISSET(sock, fds)); - if ((len = _libc_read(sock, buf, len)) > 0) { + if ((len = _read(sock, buf, len)) > 0) { if (fds != NULL) free(fds); return (len); @@ -401,7 +401,7 @@ writetcp(xprt, buf, len) register int i, cnt; for (cnt = len; cnt > 0; cnt -= i, buf += i) { - if ((i = _libc_write(xprt->xp_sock, buf, cnt)) < 0) { + if ((i = _write(xprt->xp_sock, buf, cnt)) < 0) { ((struct tcp_conn *)(xprt->xp_p1))->strm_stat = XPRT_DIED; return (-1); diff --git a/lib/libc/rpc/svc_udp.c b/lib/libc/rpc/svc_udp.c index c30d224..9849d53 100644 --- a/lib/libc/rpc/svc_udp.c +++ b/lib/libc/rpc/svc_udp.c @@ -123,7 +123,7 @@ svcudp_bufcreate(sock, sendsz, recvsz) if (getsockname(sock, (struct sockaddr *)&addr, &len) != 0) { perror("svcudp_create - cannot getsockname"); if (madesock) - (void)_libc_close(sock); + (void)_close(sock); return ((SVCXPRT *)NULL); } xprt = (SVCXPRT *)mem_alloc(sizeof(SVCXPRT)); @@ -259,7 +259,7 @@ svcudp_destroy(xprt) register struct svcudp_data *su = su_data(xprt); xprt_unregister(xprt); - (void)_libc_close(xprt->xp_sock); + (void)_close(xprt->xp_sock); XDR_DESTROY(&(su->su_xdrs)); mem_free(rpc_buffer(xprt), su->su_iosz); mem_free((caddr_t)su, sizeof(struct svcudp_data)); diff --git a/lib/libc/rpc/svc_unix.c b/lib/libc/rpc/svc_unix.c index 63a3bad..dc680d0 100644 --- a/lib/libc/rpc/svc_unix.c +++ b/lib/libc/rpc/svc_unix.c @@ -213,7 +213,7 @@ svcunix_create(sock, sendsize, recvsize, path) (listen(sock, 2) != 0)) { perror("svc_unix.c - cannot getsockname or listen"); if (madesock) - (void)_libc_close(sock); + (void)_close(sock); return ((SVCXPRT *)NULL); } r = (struct unix_rendezvous *)mem_alloc(sizeof(*r)); @@ -333,7 +333,7 @@ svcunix_destroy(xprt) register struct unix_conn *cd = (struct unix_conn *)xprt->xp_p1; xprt_unregister(xprt); - (void)_libc_close(xprt->xp_sock); + (void)_close(xprt->xp_sock); if (xprt->xp_port != 0) { /* a rendezvouser socket */ xprt->xp_port = 0; |