source: trunk/athena/bin/quota/rquotaxdr.c @ 7996

Revision 7996, 1.3 KB checked in by cfields, 29 years ago (diff)
Don't include ufs/quota.h ever.
Line 
1#ifndef lint
2/* @(#)rquotaxdr.c      2.1 86/04/14 NFSSRC */
3static  char sccsid[] = "@(#)rquotaxdr.c 1.1 86/02/05 Copyr 1985 Sun Micro";
4#endif
5
6/*
7 * Copyright (c) 1985 by Sun Microsystems, Inc.
8 */
9
10#include <stdio.h>
11#include <sys/types.h>
12#ifdef _AIX
13#include <sys/select.h>
14#endif
15#include <rpc/rpc.h>
16#include <rpcsvc/rquota.h>
17
18
19bool_t
20xdr_getquota_args(xdrs, gq_argsp)
21        XDR *xdrs;
22        struct getquota_args *gq_argsp;
23{
24        extern bool_t xdr_path();
25
26        return (xdr_path(xdrs, &gq_argsp->gqa_pathp) &&
27            xdr_int(xdrs, &gq_argsp->gqa_uid));
28}
29
30struct xdr_discrim gqr_arms[2] = {
31        { (int)Q_OK, xdr_rquota },
32        { __dontcare__, NULL }
33};
34
35bool_t
36xdr_getquota_rslt(xdrs, gq_rsltp)
37        XDR *xdrs;
38        struct getquota_rslt *gq_rsltp;
39{
40
41        return (xdr_union(xdrs,
42            &gq_rsltp->gqr_status, &gq_rsltp->gqr_rquota,
43            gqr_arms, xdr_void));
44}
45
46bool_t
47xdr_rquota(xdrs, rqp)
48        XDR *xdrs;
49        struct rquota *rqp;
50{
51
52        return (xdr_int(xdrs, &rqp->rq_bsize) &&
53            xdr_bool(xdrs, &rqp->rq_active) &&
54            xdr_u_long(xdrs, &rqp->rq_bhardlimit) &&
55            xdr_u_long(xdrs, &rqp->rq_bsoftlimit) &&
56            xdr_u_long(xdrs, &rqp->rq_curblocks) &&
57            xdr_u_long(xdrs, &rqp->rq_fhardlimit) &&
58            xdr_u_long(xdrs, &rqp->rq_fsoftlimit) &&
59            xdr_u_long(xdrs, &rqp->rq_curfiles) &&
60            xdr_u_long(xdrs, &rqp->rq_btimeleft) &&
61            xdr_u_long(xdrs, &rqp->rq_ftimeleft) );
62}
Note: See TracBrowser for help on using the repository browser.