Source-Changes-HG archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

[src/trunk]: src/usr.sbin/ypserv/ypserv De-__P(), ANSIfy the one function tha...



details:   https://anonhg.NetBSD.org/src/rev/880daea93064
branches:  trunk
changeset: 533634:880daea93064
user:      wiz <wiz%NetBSD.org@localhost>
date:      Sat Jul 06 00:18:48 2002 +0000

description:
De-__P(), ANSIfy the one function that wasn't, and unifdef __STDC__.

diffstat:

 usr.sbin/ypserv/ypserv/ypserv.c     |  14 ++++-----
 usr.sbin/ypserv/ypserv/ypserv.h     |  51 ++++++++++++++++++------------------
 usr.sbin/ypserv/ypserv/ypserv_db.c  |  17 +++++------
 usr.sbin/ypserv/ypserv/ypserv_xdr.c |   8 ++---
 4 files changed, 42 insertions(+), 48 deletions(-)

diffs (187 lines):

diff -r bc0650295c19 -r 880daea93064 usr.sbin/ypserv/ypserv/ypserv.c
--- a/usr.sbin/ypserv/ypserv/ypserv.c   Fri Jul 05 23:43:28 2002 +0000
+++ b/usr.sbin/ypserv/ypserv/ypserv.c   Sat Jul 06 00:18:48 2002 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: ypserv.c,v 1.15 2001/10/16 01:51:27 itojun Exp $       */
+/*     $NetBSD: ypserv.c,v 1.16 2002/07/06 00:18:48 wiz Exp $  */
 
 /*
  * Copyright (c) 1994 Mats O Jansson <moj%stacken.kth.se@localhost>
@@ -33,7 +33,7 @@
 
 #include <sys/cdefs.h>
 #ifndef lint
-__RCSID("$NetBSD: ypserv.c,v 1.15 2001/10/16 01:51:27 itojun Exp $");
+__RCSID("$NetBSD: ypserv.c,v 1.16 2002/07/06 00:18:48 wiz Exp $");
 #endif
 
 #include <sys/types.h>
@@ -70,9 +70,7 @@
 const char *svcname;
 #endif /* LIBWRAP */
 
-#ifdef __STDC__
 #define SIG_PF void(*)(int)
-#endif
 
 int    usedns;
 #ifdef DEBUG
@@ -85,10 +83,10 @@
 int    lflag;
 #endif
 
-int    main __P((int, char *[]));
-void   usage __P((void));
+int    main(int, char *[]);
+void   usage(void);
 
-void   sighandler __P((int));
+void   sighandler(int);
 
 
 static
@@ -117,7 +115,7 @@
        } argument;
        char *result;
        xdrproc_t xdr_argument, xdr_result;
-       void *(*local) __P((void *, struct svc_req *));
+       void *(*local)(void *, struct svc_req *);
 #ifdef LIBWRAP
        struct request_info req;
        struct sockaddr *caller;
diff -r bc0650295c19 -r 880daea93064 usr.sbin/ypserv/ypserv/ypserv.h
--- a/usr.sbin/ypserv/ypserv/ypserv.h   Fri Jul 05 23:43:28 2002 +0000
+++ b/usr.sbin/ypserv/ypserv/ypserv.h   Sat Jul 06 00:18:48 2002 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: ypserv.h,v 1.4 1999/01/22 02:36:13 thorpej Exp $       */
+/*     $NetBSD: ypserv.h,v 1.5 2002/07/06 00:18:48 wiz Exp $   */
 
 /*-
  * Copyright (c) 1996 The NetBSD Foundation, Inc.
@@ -43,35 +43,34 @@
        } ypresp_all_u;
 };
 
-extern int _yp_invalid_domain __P((const char *));     /* from libc */
-       int _yp_invalid_map __P((const char *));
+extern int _yp_invalid_domain(const char *);   /* from libc */
+       int _yp_invalid_map(const char *);
 
-void   *ypproc_null_2_svc __P((void *, struct svc_req *));
-void   *ypproc_domain_2_svc __P((void *, struct svc_req *));
-void   *ypproc_domain_nonack_2_svc __P((void *, struct svc_req *));
-void   *ypproc_match_2_svc __P((void *, struct svc_req *));
-void   *ypproc_first_2_svc __P((void *, struct svc_req *));
-void   *ypproc_next_2_svc __P((void *, struct svc_req *));
-void   *ypproc_xfr_2_svc __P((void *, struct svc_req *));
-void   *ypproc_clear_2_svc __P((void *, struct svc_req *));
-void   *ypproc_all_2_svc __P((void *, struct svc_req *));
-void   *ypproc_master_2_svc __P((void *, struct svc_req *));
-void   *ypproc_order_2_svc __P((void *, struct svc_req *));
-void   *ypproc_maplist_2_svc __P((void *, struct svc_req *));
+void   *ypproc_null_2_svc(void *, struct svc_req *);
+void   *ypproc_domain_2_svc(void *, struct svc_req *);
+void   *ypproc_domain_nonack_2_svc(void *, struct svc_req *);
+void   *ypproc_match_2_svc(void *, struct svc_req *);
+void   *ypproc_first_2_svc(void *, struct svc_req *);
+void   *ypproc_next_2_svc(void *, struct svc_req *);
+void   *ypproc_xfr_2_svc(void *, struct svc_req *);
+void   *ypproc_clear_2_svc(void *, struct svc_req *);
+void   *ypproc_all_2_svc(void *, struct svc_req *);
+void   *ypproc_master_2_svc(void *, struct svc_req *);
+void   *ypproc_order_2_svc(void *, struct svc_req *);
+void   *ypproc_maplist_2_svc(void *, struct svc_req *);
 
-bool_t xdr_ypresp_all __P((XDR *, struct ypresp_all *));
+bool_t xdr_ypresp_all(XDR *, struct ypresp_all *);
 
-struct ypresp_val ypdb_get_record __P((const char *, const char *, datum, int));
-struct ypresp_key_val ypdb_get_first __P((const char *, const char *, int));
-struct ypresp_key_val ypdb_get_next __P((const char *, const char *,
-           datum, int));
-struct ypresp_order ypdb_get_order __P((const char *, const char *));
-struct ypresp_master ypdb_get_master __P((const char *, const char *));
+struct ypresp_val ypdb_get_record(const char *, const char *, datum, int);
+struct ypresp_key_val ypdb_get_first(const char *, const char *, int);
+struct ypresp_key_val ypdb_get_next(const char *, const char *, datum, int);
+struct ypresp_order ypdb_get_order(const char *, const char *);
+struct ypresp_master ypdb_get_master(const char *, const char *);
 
-void   ypdb_close_all __P((void));
-void   ypdb_init __P((void));
-int    ypdb_secure __P((const char *, const char *));
-bool_t ypdb_xdr_get_all __P((XDR *, struct ypreq_nokey *));
+void   ypdb_close_all(void);
+void   ypdb_init(void);
+int    ypdb_secure(const char *, const char *);
+bool_t ypdb_xdr_get_all(XDR *, struct ypreq_nokey *);
 
 #ifdef LIBWRAP
 /* from ypserv.c */
diff -r bc0650295c19 -r 880daea93064 usr.sbin/ypserv/ypserv/ypserv_db.c
--- a/usr.sbin/ypserv/ypserv/ypserv_db.c        Fri Jul 05 23:43:28 2002 +0000
+++ b/usr.sbin/ypserv/ypserv/ypserv_db.c        Sat Jul 06 00:18:48 2002 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: ypserv_db.c,v 1.12 2002/06/18 02:57:53 thorpej Exp $   */
+/*     $NetBSD: ypserv_db.c,v 1.13 2002/07/06 00:18:48 wiz Exp $       */
 
 /*
  * Copyright (c) 1994 Mats O Jansson <moj%stacken.kth.se@localhost>
@@ -35,7 +35,7 @@
 
 #include <sys/cdefs.h>
 #ifndef lint
-__RCSID("$NetBSD: ypserv_db.c,v 1.12 2002/06/18 02:57:53 thorpej Exp $");
+__RCSID("$NetBSD: ypserv_db.c,v 1.13 2002/07/06 00:18:48 wiz Exp $");
 #endif
 
 /*
@@ -99,13 +99,12 @@
 
 extern int      usedns;
 
-int    yp_private __P((datum, int));
-void   ypdb_close_db __P((DBM *));
-void   ypdb_close_last __P((void));
-void   ypdb_close_map __P((struct opt_map *));
-DBM    *ypdb_open_db __P((const char *, const char *, int *,
-           struct opt_map **));
-int    lookup_host __P((int, int, DBM *, char *, struct ypresp_val *));
+int    yp_private(datum, int);
+void   ypdb_close_db(DBM *);
+void   ypdb_close_last(void);
+void   ypdb_close_map(struct opt_map *);
+DBM    *ypdb_open_db(const char *, const char *, int *, struct opt_map **);
+int    lookup_host(int, int, DBM *, char *, struct ypresp_val *);
 
 /*
  * ypdb_init: init the queues and lists
diff -r bc0650295c19 -r 880daea93064 usr.sbin/ypserv/ypserv/ypserv_xdr.c
--- a/usr.sbin/ypserv/ypserv/ypserv_xdr.c       Fri Jul 05 23:43:28 2002 +0000
+++ b/usr.sbin/ypserv/ypserv/ypserv_xdr.c       Sat Jul 06 00:18:48 2002 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: ypserv_xdr.c,v 1.2 1997/10/15 05:01:52 lukem Exp $     */
+/*     $NetBSD: ypserv_xdr.c,v 1.3 2002/07/06 00:18:48 wiz Exp $       */
 
 /*
  * This file was originally generated with rpcgen, then modified
@@ -7,7 +7,7 @@
 
 #include <sys/cdefs.h>
 #ifndef lint
-__RCSID("$NetBSD: ypserv_xdr.c,v 1.2 1997/10/15 05:01:52 lukem Exp $");
+__RCSID("$NetBSD: ypserv_xdr.c,v 1.3 2002/07/06 00:18:48 wiz Exp $");
 #endif
 
 #include <sys/types.h>
@@ -19,9 +19,7 @@
 #include "ypserv.h"
 
 bool_t
-xdr_ypresp_all(xdrs, objp)
-       XDR *xdrs;
-       struct ypresp_all *objp;
+xdr_ypresp_all(XDR *xdrs, struct ypresp_all *objp)
 {
 
        if (!xdr_bool(xdrs, &objp->more))



Home | Main Index | Thread Index | Old Index