diff options
author | Theo de Raadt <deraadt@cvs.openbsd.org> | 2002-06-20 03:43:42 +0000 |
---|---|---|
committer | Theo de Raadt <deraadt@cvs.openbsd.org> | 2002-06-20 03:43:42 +0000 |
commit | 628dc4b3a4b3e467cc7a16eb2df8ccd6315e88b3 (patch) | |
tree | e86bbd6b052021215448fff1da3ff00116186ec1 /libexec/rpc.rquotad/rquotad.c | |
parent | a936d9a50f3f1a19d6e206e04aa9686b84f31667 (diff) |
ansi
Diffstat (limited to 'libexec/rpc.rquotad/rquotad.c')
-rw-r--r-- | libexec/rpc.rquotad/rquotad.c | 44 |
1 files changed, 7 insertions, 37 deletions
diff --git a/libexec/rpc.rquotad/rquotad.c b/libexec/rpc.rquotad/rquotad.c index 4ff2caebabf..2f97f00d5dc 100644 --- a/libexec/rpc.rquotad/rquotad.c +++ b/libexec/rpc.rquotad/rquotad.c @@ -1,4 +1,4 @@ -/* $OpenBSD: rquotad.c,v 1.13 2002/06/09 17:42:16 itojun Exp $ */ +/* $OpenBSD: rquotad.c,v 1.14 2002/06/20 03:43:33 deraadt Exp $ */ /* * by Manuel Bouyer (bouyer@ensta.fr). Public domain. @@ -57,9 +57,7 @@ cleanup() } int -main(argc, argv) - int argc; - char *argv[]; +main(int argc, char *argv[]) { SVCXPRT *transp; int sock = 0; @@ -105,9 +103,7 @@ main(argc, argv) } void -rquota_service(request, transp) - struct svc_req *request; - SVCXPRT *transp; +rquota_service(struct svc_req *request, SVCXPRT *transp) { switch (request->rq_proc) { case NULLPROC: @@ -129,9 +125,7 @@ rquota_service(request, transp) /* read quota for the specified id, and send it */ void -sendquota(request, transp) - struct svc_req *request; - SVCXPRT *transp; +sendquota(struct svc_req *request, SVCXPRT *transp) { struct getquota_args getq_args; struct getquota_rslt getq_rslt; @@ -180,28 +174,9 @@ sendquota(request, transp) } } -void -printerr_reply(transp) /* when a reply to a request failed */ - SVCXPRT *transp; -{ - char *name; - struct sockaddr_in *caller; - int save_errno; - - save_errno = errno; - - caller = svc_getcaller(transp); - name = (char *)inet_ntoa(caller->sin_addr); - errno = save_errno; - if (errno == 0) - syslog(LOG_ERR, "couldn't send reply to %s", name); - else - syslog(LOG_ERR, "couldn't send reply to %s: %m", name); -} - /* initialise the fs_tab list from entries in /etc/fstab */ void -initfs() +initfs(void) { struct fs_stat *fs_current = NULL; struct fs_stat *fs_next = NULL; @@ -249,10 +224,7 @@ initfs() * Return 0 if fail, 1 otherwise */ int -getfsquota(id, path, dqblk) - long id; - char *path; - struct dqblk *dqblk; +getfsquota(long id, char *path, struct dqblk *dqblk) { struct stat st_path; struct fs_stat *fs; @@ -308,9 +280,7 @@ getfsquota(id, path, dqblk) * Comes from quota.c, NetBSD 0.9 */ int -hasquota(fs, qfnamep) - struct fstab *fs; - char **qfnamep; +hasquota(struct fstab *fs, char **qfnamep) { static char initname, usrname[100]; static char buf[BUFSIZ]; |