* include/stdlib.h: Use libc_hidden_proto for wctomb.

* stdlib/wctomb.c: Add libc_hidden_def.

	* include/netdb.h: Use libc_hidden_proto for innetgr, rcmd_af,
	rexec_af, rresvport_af, ruserok_af, iruserok_af, ruserpass, hstrerror.
	* resolv/herror.c: Likewise.
	* inet/rcmd.c: Add libc_hidden_def.
	* inet/ruserpass.c: Likewise.
	* inet/getnetgrent_r.c: Likewise.

	* include/rpc/auth.h: Use libc_hidden_proto for getnetname,
	netname2user, host2netname, user2netname.
	* sunrpc/netname.c: Add libc_hidden_def.

	* include/rpc/svc.h: Use libc_hidden_proto for svc_register,
	svc_unregister, remove *_internal decls.  Use libc_hidden_proto
	for svcerr_auth, svcerr_noprog, svcerr_progvers.
	* sunrpc/svc.c (svc_register, svc_unregister): Change INTDEF to
	libc_hidden_def.
	(svcerr_auth, svcerr_noprog, svcerr_progvers): Add libc_hidden_def.
	* sunrpc/svc_simple.c (registerrpc): Nix INTUSE for svc_register.
This commit is contained in:
Roland McGrath 2002-08-06 05:10:45 +00:00
parent a585ba226b
commit e2ec9b4dc1
12 changed files with 48 additions and 21 deletions

View file

@ -1,5 +1,27 @@
2002-08-05 Roland McGrath <roland@redhat.com>
* include/stdlib.h: Use libc_hidden_proto for wctomb.
* stdlib/wctomb.c: Add libc_hidden_def.
* include/netdb.h: Use libc_hidden_proto for innetgr, rcmd_af,
rexec_af, rresvport_af, ruserok_af, iruserok_af, ruserpass, hstrerror.
* resolv/herror.c: Likewise.
* inet/rcmd.c: Add libc_hidden_def.
* inet/ruserpass.c: Likewise.
* inet/getnetgrent_r.c: Likewise.
* include/rpc/auth.h: Use libc_hidden_proto for getnetname,
netname2user, host2netname, user2netname.
* sunrpc/netname.c: Add libc_hidden_def.
* include/rpc/svc.h: Use libc_hidden_proto for svc_register,
svc_unregister, remove *_internal decls. Use libc_hidden_proto
for svcerr_auth, svcerr_noprog, svcerr_progvers.
* sunrpc/svc.c (svc_register, svc_unregister): Change INTDEF to
libc_hidden_def.
(svcerr_auth, svcerr_noprog, svcerr_progvers): Add libc_hidden_def.
* sunrpc/svc_simple.c (registerrpc): Nix INTUSE for svc_register.
* sysdeps/posix/system.c (do_system): New function, guts broken out of
__libc_system.
(__libc_system): Call it, putting just the line == NULL test here.
@ -27,15 +49,6 @@
* inet/ether_aton_r.c: Add libc_hidden_def.
* inet/ether_ntoa_r.c: Likewise.
* include/rpc/auth.h: Use libc_hidden_proto for getnetname,
netname2user, host2netname.
* sunrpc/netname.c: Add libc_hidden_def.
* include/netdb.h: Use libc_hidden_proto for innetgr, rcmd_af,
rexec_af, rresvport_af, ruserok_af.
* inet/rcmd.c: Add libc_hidden_def.
* inet/getnetgrent_r.c: Likewise.
* include/rpc/svc.h: Use libc_hidden_proto for xprt_register,
xprt_unregister.
* sunrpc/svc.c: Add libc_hidden_def.

View file

@ -21,6 +21,7 @@ __set_h_errno (int __err)
# define __set_h_errno(x) (h_errno = (x))
# endif /* _LIBC_REENTRANT */
libc_hidden_proto (hstrerror)
libc_hidden_proto (innetgr)
libc_hidden_proto (rcmd_af)
libc_hidden_proto (rexec_af)
@ -166,6 +167,7 @@ extern int __getnetgrent_r (char **__restrict __hostp,
extern int ruserpass (const char *host, const char **aname,
const char **apass);
libc_hidden_proto (ruserpass)
/* The following declarations and definitions have been removed from

View file

@ -4,6 +4,7 @@
libc_hidden_proto (getnetname)
libc_hidden_proto (netname2user)
libc_hidden_proto (host2netname)
libc_hidden_proto (user2netname)
/* Now define the internal interfaces. */
struct key_netstarg;

View file

@ -3,6 +3,11 @@
libc_hidden_proto (xprt_register)
libc_hidden_proto (xprt_unregister)
libc_hidden_proto (svc_register)
libc_hidden_proto (svc_unregister)
libc_hidden_proto (svcerr_auth)
libc_hidden_proto (svcerr_noprog)
libc_hidden_proto (svcerr_progvers)
/* Now define the internal interfaces. */
extern int registerrpc (u_long prognum, u_long versnum, u_long procnum,
@ -21,12 +26,6 @@ extern void svc_getreq_common_internal (const int __fd) attribute_hidden;
extern void svc_getreqset_internal (fd_set *__readfds) attribute_hidden;
extern void svc_getreq_poll_internal (struct pollfd *,
const int) attribute_hidden;
extern bool_t svc_register_internal (SVCXPRT *__xprt, rpcprog_t __prog,
rpcvers_t __vers,
__dispatch_fn_t __dispatch,
rpcprot_t __protocol) attribute_hidden;
extern void svc_unregister_internal (rpcprog_t __prog,
rpcvers_t __vers) attribute_hidden;
extern SVCXPRT *svcudp_create_internal (int __sock) attribute_hidden;
extern SVCXPRT *svcudp_bufcreate_internal (int __sock, u_int __sendsz,
u_int __recvsz) attribute_hidden;

View file

@ -20,6 +20,7 @@ libc_hidden_proto (fcvt_r)
libc_hidden_proto (qecvt_r)
libc_hidden_proto (qfcvt_r)
libc_hidden_proto (lrand48_r)
libc_hidden_proto (wctomb)
libc_hidden_proto (__secure_getenv)
libc_hidden_proto (__strtof_internal)
libc_hidden_proto (__strtod_internal)

View file

@ -99,6 +99,8 @@ int iruserok_af (const void *raddr, int superuser, const char *ruser,
int iruserok (u_int32_t raddr, int superuser, const char *ruser,
const char *luser);
libc_hidden_proto (iruserok_af)
static char ahostbuf[NI_MAXHOST];
int
@ -662,6 +664,8 @@ iruserok_af (raddr, superuser, ruser, luser, af)
}
return ruserok_sa ((struct sockaddr *)&ra, ralen, superuser, ruser, luser);
}
libc_hidden_def (iruserok_af)
int
iruserok (raddr, superuser, ruser, luser)
u_int32_t raddr;

View file

@ -286,6 +286,7 @@ bad:
(void) fclose(cfile);
return (-1);
}
libc_hidden_def (ruserpass)
static int
token()

View file

@ -1,7 +1,7 @@
/*
* Copyright (c) 1987, 1993
* The Regents of the University of California. All rights reserved.
*
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions
* are met:
@ -13,7 +13,7 @@
* 4. Neither the name of the University nor the names of its contributors
* may be used to endorse or promote products derived from this software
* without specific prior written permission.
*
*
* THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND
* ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
* IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
@ -109,3 +109,4 @@ hstrerror(int err) {
return _(h_errlist[err]);
return _("Unknown resolver error");
}
libc_hidden_def (hstrerror)

View file

@ -52,3 +52,4 @@ wctomb (char *s, wchar_t wchar)
return __wcrtomb (s, wchar, &__no_r_state);
}
libc_hidden_def (wctomb)

View file

@ -55,6 +55,7 @@ user2netname (char netname[MAXNETNAMELEN + 1], const uid_t uid,
netname[i - 1] = '\0';
return 1;
}
libc_hidden_def (user2netname)
int
host2netname (char netname[MAXNETNAMELEN + 1], const char *host,

View file

@ -194,7 +194,7 @@ pmap_it:
return TRUE;
}
INTDEF (svc_register)
libc_hidden_def (svc_register)
/* Remove a service program from the callout list. */
void
@ -216,7 +216,7 @@ svc_unregister (rpcprog_t prog, rpcvers_t vers)
/* now unregister the information with the local binder service */
pmap_unset (prog, vers);
}
INTDEF (svc_unregister)
libc_hidden_def (svc_unregister)
/* ******************* REPLY GENERATION ROUTINES ************ */
@ -289,6 +289,7 @@ svcerr_auth (SVCXPRT *xprt, enum auth_stat why)
rply.rjcted_rply.rj_why = why;
SVC_REPLY (xprt, &rply);
}
libc_hidden_def (svcerr_auth)
/* Auth too weak error reply */
void
@ -309,6 +310,7 @@ svcerr_noprog (register SVCXPRT *xprt)
rply.acpted_rply.ar_stat = PROG_UNAVAIL;
SVC_REPLY (xprt, &rply);
}
libc_hidden_def (svcerr_noprog)
/* Program version mismatch error reply */
void
@ -325,6 +327,7 @@ svcerr_progvers (register SVCXPRT *xprt, rpcvers_t low_vers,
rply.acpted_rply.ar_vers.high = high_vers;
SVC_REPLY (xprt, &rply);
}
libc_hidden_def (svcerr_progvers)
/* ******************* SERVER INPUT STUFF ******************* */

View file

@ -98,8 +98,8 @@ registerrpc (u_long prognum, u_long versnum, u_long procnum,
}
}
(void) pmap_unset ((u_long) prognum, (u_long) versnum);
if (!INTUSE(svc_register) (transp, (u_long) prognum, (u_long) versnum,
universal, IPPROTO_UDP))
if (!svc_register (transp, (u_long) prognum, (u_long) versnum,
universal, IPPROTO_UDP))
{
(void) __asprintf (&buf, _("couldn't register prog %ld vers %ld\n"),
prognum, versnum);