File: rquota_clnt.c

package info (click to toggle)
quota 4.09-1
  • links: PTS
  • area: main
  • in suites: forky, sid, trixie
  • size: 2,700 kB
  • sloc: ansic: 12,461; sh: 5,470; perl: 406; makefile: 338; sed: 16
file content (130 lines) | stat: -rw-r--r-- 3,322 bytes parent folder | download | duplicates (4)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
/*
 * Please do not edit this file.
 * It was generated using rpcgen.
 */

#include <memory.h> /* for memset */
#include "rquota.h"

/* Default timeout can be changed using clnt_control() */
static struct timeval TIMEOUT = { 25, 0 };

getquota_rslt *
rquotaproc_getquota_1(getquota_args *argp, CLIENT *clnt)
{
	static getquota_rslt clnt_res;

	memset((char *)&clnt_res, 0, sizeof(clnt_res));
	if (clnt_call (clnt, RQUOTAPROC_GETQUOTA,
		(xdrproc_t) xdr_getquota_args, (caddr_t) argp,
		(xdrproc_t) xdr_getquota_rslt, (caddr_t) &clnt_res,
		TIMEOUT) != RPC_SUCCESS) {
		return (NULL);
	}
	return (&clnt_res);
}

getquota_rslt *
rquotaproc_getactivequota_1(getquota_args *argp, CLIENT *clnt)
{
	static getquota_rslt clnt_res;

	memset((char *)&clnt_res, 0, sizeof(clnt_res));
	if (clnt_call (clnt, RQUOTAPROC_GETACTIVEQUOTA,
		(xdrproc_t) xdr_getquota_args, (caddr_t) argp,
		(xdrproc_t) xdr_getquota_rslt, (caddr_t) &clnt_res,
		TIMEOUT) != RPC_SUCCESS) {
		return (NULL);
	}
	return (&clnt_res);
}

setquota_rslt *
rquotaproc_setquota_1(setquota_args *argp, CLIENT *clnt)
{
	static setquota_rslt clnt_res;

	memset((char *)&clnt_res, 0, sizeof(clnt_res));
	if (clnt_call (clnt, RQUOTAPROC_SETQUOTA,
		(xdrproc_t) xdr_setquota_args, (caddr_t) argp,
		(xdrproc_t) xdr_setquota_rslt, (caddr_t) &clnt_res,
		TIMEOUT) != RPC_SUCCESS) {
		return (NULL);
	}
	return (&clnt_res);
}

setquota_rslt *
rquotaproc_setactivequota_1(setquota_args *argp, CLIENT *clnt)
{
	static setquota_rslt clnt_res;

	memset((char *)&clnt_res, 0, sizeof(clnt_res));
	if (clnt_call (clnt, RQUOTAPROC_SETACTIVEQUOTA,
		(xdrproc_t) xdr_setquota_args, (caddr_t) argp,
		(xdrproc_t) xdr_setquota_rslt, (caddr_t) &clnt_res,
		TIMEOUT) != RPC_SUCCESS) {
		return (NULL);
	}
	return (&clnt_res);
}

getquota_rslt *
rquotaproc_getquota_2(ext_getquota_args *argp, CLIENT *clnt)
{
	static getquota_rslt clnt_res;

	memset((char *)&clnt_res, 0, sizeof(clnt_res));
	if (clnt_call (clnt, RQUOTAPROC_GETQUOTA,
		(xdrproc_t) xdr_ext_getquota_args, (caddr_t) argp,
		(xdrproc_t) xdr_getquota_rslt, (caddr_t) &clnt_res,
		TIMEOUT) != RPC_SUCCESS) {
		return (NULL);
	}
	return (&clnt_res);
}

getquota_rslt *
rquotaproc_getactivequota_2(ext_getquota_args *argp, CLIENT *clnt)
{
	static getquota_rslt clnt_res;

	memset((char *)&clnt_res, 0, sizeof(clnt_res));
	if (clnt_call (clnt, RQUOTAPROC_GETACTIVEQUOTA,
		(xdrproc_t) xdr_ext_getquota_args, (caddr_t) argp,
		(xdrproc_t) xdr_getquota_rslt, (caddr_t) &clnt_res,
		TIMEOUT) != RPC_SUCCESS) {
		return (NULL);
	}
	return (&clnt_res);
}

setquota_rslt *
rquotaproc_setquota_2(ext_setquota_args *argp, CLIENT *clnt)
{
	static setquota_rslt clnt_res;

	memset((char *)&clnt_res, 0, sizeof(clnt_res));
	if (clnt_call (clnt, RQUOTAPROC_SETQUOTA,
		(xdrproc_t) xdr_ext_setquota_args, (caddr_t) argp,
		(xdrproc_t) xdr_setquota_rslt, (caddr_t) &clnt_res,
		TIMEOUT) != RPC_SUCCESS) {
		return (NULL);
	}
	return (&clnt_res);
}

setquota_rslt *
rquotaproc_setactivequota_2(ext_setquota_args *argp, CLIENT *clnt)
{
	static setquota_rslt clnt_res;

	memset((char *)&clnt_res, 0, sizeof(clnt_res));
	if (clnt_call (clnt, RQUOTAPROC_SETACTIVEQUOTA,
		(xdrproc_t) xdr_ext_setquota_args, (caddr_t) argp,
		(xdrproc_t) xdr_setquota_rslt, (caddr_t) &clnt_res,
		TIMEOUT) != RPC_SUCCESS) {
		return (NULL);
	}
	return (&clnt_res);
}