diff options
author | rodrigc <rodrigc@FreeBSD.org> | 2015-09-22 15:40:07 +0000 |
---|---|---|
committer | rodrigc <rodrigc@FreeBSD.org> | 2015-09-22 15:40:07 +0000 |
commit | 5200f4be667a336fb2b90bdad8b6dab5d0979aa6 (patch) | |
tree | 2e8901f302dad25f0bd647f68a1d6c9423986c96 /lib/libc/rpc/svc_generic.c | |
parent | 3fa0d9942f4943ada80c76279fcfd99262c878c6 (diff) | |
download | FreeBSD-src-5200f4be667a336fb2b90bdad8b6dab5d0979aa6.zip FreeBSD-src-5200f4be667a336fb2b90bdad8b6dab5d0979aa6.tar.gz |
Use ANSI C prototypes. Eliminates -Wold-style-definition warnings.
Diffstat (limited to 'lib/libc/rpc/svc_generic.c')
-rw-r--r-- | lib/libc/rpc/svc_generic.c | 36 |
1 files changed, 20 insertions, 16 deletions
diff --git a/lib/libc/rpc/svc_generic.c b/lib/libc/rpc/svc_generic.c index 21569c0..d3db612 100644 --- a/lib/libc/rpc/svc_generic.c +++ b/lib/libc/rpc/svc_generic.c @@ -72,13 +72,14 @@ extern int __svc_vc_setflag(SVCXPRT *, int); * It creates a link list of all the handles it could create. * If svc_create() is called multiple times, it uses the handle * created earlier instead of creating a new handle every time. + * + * prognum - Program number + * versnum - Version number + * nettype - Networktype token */ int -svc_create(dispatch, prognum, versnum, nettype) - void (*dispatch)(struct svc_req *, SVCXPRT *); - rpcprog_t prognum; /* Program number */ - rpcvers_t versnum; /* Version number */ - const char *nettype; /* Networktype token */ +svc_create(void (*dispatch)(struct svc_req *, SVCXPRT *), + rpcprog_t prognum, rpcvers_t versnum, const char *nettype) { struct xlist { SVCXPRT *xprt; /* Server handle */ @@ -143,13 +144,14 @@ svc_create(dispatch, prognum, versnum, nettype) * The high level interface to svc_tli_create(). * It tries to create a server for "nconf" and registers the service * with the rpcbind. It calls svc_tli_create(); + * + * prognum - Program number + * versnum - Version number + * ncofn - Netconfig structure for the network */ SVCXPRT * -svc_tp_create(dispatch, prognum, versnum, nconf) - void (*dispatch)(struct svc_req *, SVCXPRT *); - rpcprog_t prognum; /* Program number */ - rpcvers_t versnum; /* Version number */ - const struct netconfig *nconf; /* Netconfig structure for the network */ +svc_tp_create(void (*dispatch)(struct svc_req *, SVCXPRT *), + rpcprog_t prognum, rpcvers_t versnum, const struct netconfig *nconf) { SVCXPRT *xprt; @@ -184,14 +186,16 @@ svc_tp_create(dispatch, prognum, versnum, nconf) * is set to 8. * * If sendsz or recvsz are zero, their default values are chosen. + * + * fd - Connection end point + * nconf - Netconfig struct for nettoken + * bindaddr - Local bind address + * sendsz - Max sendsize + * recvxz - Max recvsize */ SVCXPRT * -svc_tli_create(fd, nconf, bindaddr, sendsz, recvsz) - int fd; /* Connection end point */ - const struct netconfig *nconf; /* Netconfig struct for nettoken */ - const struct t_bind *bindaddr; /* Local bind address */ - u_int sendsz; /* Max sendsize */ - u_int recvsz; /* Max recvsize */ +svc_tli_create(int fd, const struct netconfig *nconf, + const struct t_bind *bindaddr, u_int sendsz, u_int recvsz) { SVCXPRT *xprt = NULL; /* service handle */ bool_t madefd = FALSE; /* whether fd opened here */ |