aboutsummaryrefslogtreecommitdiff
path: root/usr.sbin/ypserv/yp_access.c
diff options
context:
space:
mode:
authorDag-Erling Smørgrav <des@FreeBSD.org>2002-02-06 15:26:07 +0000
committerDag-Erling Smørgrav <des@FreeBSD.org>2002-02-06 15:26:07 +0000
commitdc584ddbc5eb111cdb9863e2652621d7b5e9ba76 (patch)
tree9c2a46d61c0b1ec2538854e870b6861acfd2ee7a /usr.sbin/ypserv/yp_access.c
parented4d1c46a27632aa553e7c24c969262bfc2d5c97 (diff)
downloadsrc-dc584ddbc5eb111cdb9863e2652621d7b5e9ba76.tar.gz
src-dc584ddbc5eb111cdb9863e2652621d7b5e9ba76.zip
ANSIfy and remove some dead code.
Sponsored by: DARPA, NAI Labs
Notes
Notes: svn path=/head/; revision=90298
Diffstat (limited to 'usr.sbin/ypserv/yp_access.c')
-rw-r--r--usr.sbin/ypserv/yp_access.c21
1 files changed, 10 insertions, 11 deletions
diff --git a/usr.sbin/ypserv/yp_access.c b/usr.sbin/ypserv/yp_access.c
index 610f209a35cb..d5e8f5acb02d 100644
--- a/usr.sbin/ypserv/yp_access.c
+++ b/usr.sbin/ypserv/yp_access.c
@@ -90,7 +90,8 @@ char *yp_procs[] = { "ypoldproc_null",
#ifdef TCP_WRAPPER
-void load_securenets()
+void
+load_securenets(void)
{
}
#else
@@ -109,7 +110,8 @@ struct securenet *securenets;
* list. If the file doesn't exist, we set up a dummy entry that
* allows all hosts to connect.
*/
-void load_securenets()
+void
+load_securenets(void)
{
FILE *fp;
char path[MAXPATHLEN + 2];
@@ -211,15 +213,12 @@ void load_securenets()
*/
#ifdef DB_CACHE
-int yp_access(map, domain, rqstp)
+int
+yp_access(const char *map, const char *domain, const struct svc_req *rqstp)
#else
-int yp_access(map, rqstp)
+int
+yp_access(const char *map, const struct svc_req *rqstp)
#endif
- const char *map;
-#ifdef DB_CACHE
- const char *domain;
-#endif
- const struct svc_req *rqstp;
{
struct sockaddr_in *rqhost;
int status = 0;
@@ -304,8 +303,8 @@ not privileged", map, inet_ntoa(rqhost->sin_addr), ntohs(rqhost->sin_port));
}
-int yp_validdomain(domain)
- const char *domain;
+int
+yp_validdomain(const char *domain)
{
struct stat statbuf;
char dompath[MAXPATHLEN + 2];