MOUNT: The wrappers for the old MOUNT rpc calls should call the new functions and...
[deb_libnfs.git] / mount / libnfs-raw-mount.c
CommitLineData
763cd6e3
RS
1/*
2 * Please do not edit this file.
3 * It was generated using rpcgen.
4 */
5
6#include "libnfs-zdr.h"
7#include "libnfs-raw-mount.h"
8
9bool_t
10zdr_fhandle3 (ZDR *zdrs, fhandle3 *objp)
11{
12 register int32_t *buf;
9c29b498 13 buf = NULL;
763cd6e3
RS
14
15 if (!zdr_bytes (zdrs, (char **)&objp->fhandle3_val, (u_int *) &objp->fhandle3_len, FHSIZE3))
16 return FALSE;
17 return TRUE;
18}
19
20bool_t
21zdr_dirpath (ZDR *zdrs, dirpath *objp)
22{
23 register int32_t *buf;
9c29b498 24 buf = NULL;
763cd6e3
RS
25
26 if (!zdr_string (zdrs, objp, MNTPATHLEN))
27 return FALSE;
28 return TRUE;
29}
30
31bool_t
32zdr_name (ZDR *zdrs, name *objp)
33{
34 register int32_t *buf;
9c29b498 35 buf = NULL;
763cd6e3
RS
36
37 if (!zdr_string (zdrs, objp, MNTNAMLEN))
38 return FALSE;
39 return TRUE;
40}
41
42bool_t
43zdr_mountstat3 (ZDR *zdrs, mountstat3 *objp)
44{
45 register int32_t *buf;
9c29b498 46 buf = NULL;
763cd6e3
RS
47
48 if (!zdr_enum (zdrs, (enum_t *) objp))
49 return FALSE;
50 return TRUE;
51}
52
53bool_t
54zdr_mountlist (ZDR *zdrs, mountlist *objp)
55{
56 register int32_t *buf;
9c29b498 57 buf = NULL;
763cd6e3
RS
58
59 if (!zdr_pointer (zdrs, (char **)objp, sizeof (struct mountbody), (zdrproc_t) zdr_mountbody))
60 return FALSE;
61 return TRUE;
62}
63
64bool_t
65zdr_mountbody (ZDR *zdrs, mountbody *objp)
66{
67 register int32_t *buf;
9c29b498 68 buf = NULL;
763cd6e3
RS
69
70 if (!zdr_name (zdrs, &objp->ml_hostname))
71 return FALSE;
72 if (!zdr_dirpath (zdrs, &objp->ml_directory))
73 return FALSE;
74 if (!zdr_mountlist (zdrs, &objp->ml_next))
75 return FALSE;
76 return TRUE;
77}
78
79bool_t
80zdr_groups (ZDR *zdrs, groups *objp)
81{
82 register int32_t *buf;
9c29b498 83 buf = NULL;
763cd6e3
RS
84
85 if (!zdr_pointer (zdrs, (char **)objp, sizeof (struct groupnode), (zdrproc_t) zdr_groupnode))
86 return FALSE;
87 return TRUE;
88}
89
90bool_t
91zdr_groupnode (ZDR *zdrs, groupnode *objp)
92{
93 register int32_t *buf;
9c29b498 94 buf = NULL;
763cd6e3
RS
95
96 if (!zdr_name (zdrs, &objp->gr_name))
97 return FALSE;
98 if (!zdr_groups (zdrs, &objp->gr_next))
99 return FALSE;
100 return TRUE;
101}
102
103bool_t
104zdr_exports (ZDR *zdrs, exports *objp)
105{
106 register int32_t *buf;
9c29b498 107 buf = NULL;
763cd6e3
RS
108
109 if (!zdr_pointer (zdrs, (char **)objp, sizeof (struct exportnode), (zdrproc_t) zdr_exportnode))
110 return FALSE;
111 return TRUE;
112}
113
114bool_t
115zdr_exportnode (ZDR *zdrs, exportnode *objp)
116{
117 register int32_t *buf;
9c29b498 118 buf = NULL;
763cd6e3
RS
119
120 if (!zdr_dirpath (zdrs, &objp->ex_dir))
121 return FALSE;
122 if (!zdr_groups (zdrs, &objp->ex_groups))
123 return FALSE;
124 if (!zdr_exports (zdrs, &objp->ex_next))
125 return FALSE;
126 return TRUE;
127}
128
129bool_t
130zdr_mountres3_ok (ZDR *zdrs, mountres3_ok *objp)
131{
132 register int32_t *buf;
9c29b498 133 buf = NULL;
763cd6e3
RS
134
135 if (!zdr_fhandle3 (zdrs, &objp->fhandle))
136 return FALSE;
137 if (!zdr_array (zdrs, (char **)&objp->auth_flavors.auth_flavors_val, (u_int *) &objp->auth_flavors.auth_flavors_len, ~0,
138 sizeof (int), (zdrproc_t) zdr_int))
139 return FALSE;
140 return TRUE;
141}
142
143bool_t
144zdr_mountres3 (ZDR *zdrs, mountres3 *objp)
145{
146 register int32_t *buf;
9c29b498 147 buf = NULL;
763cd6e3
RS
148
149 if (!zdr_mountstat3 (zdrs, &objp->fhs_status))
150 return FALSE;
151 switch (objp->fhs_status) {
152 case MNT3_OK:
153 if (!zdr_mountres3_ok (zdrs, &objp->mountres3_u.mountinfo))
154 return FALSE;
155 break;
156 default:
157 break;
158 }
159 return TRUE;
160}
161
162bool_t
163zdr_mountstat1 (ZDR *zdrs, mountstat1 *objp)
164{
165 register int32_t *buf;
9c29b498 166 buf = NULL;
763cd6e3
RS
167
168 if (!zdr_enum (zdrs, (enum_t *) objp))
169 return FALSE;
170 return TRUE;
171}
172
173bool_t
174zdr_fhandle1 (ZDR *zdrs, fhandle1 objp)
175{
176 register int32_t *buf;
9c29b498 177 buf = NULL;
763cd6e3
RS
178
179 if (!zdr_opaque (zdrs, objp, FHSIZE))
180 return FALSE;
181 return TRUE;
182}
183
184bool_t
185zdr_mountres1_ok (ZDR *zdrs, mountres1_ok *objp)
186{
187 register int32_t *buf;
9c29b498 188 buf = NULL;
763cd6e3
RS
189
190 if (!zdr_fhandle1 (zdrs, objp->fhandle))
191 return FALSE;
192 return TRUE;
193}
194
195bool_t
196zdr_mountres1 (ZDR *zdrs, mountres1 *objp)
197{
198 register int32_t *buf;
9c29b498 199 buf = NULL;
763cd6e3
RS
200
201 if (!zdr_mountstat1 (zdrs, &objp->fhs_status))
202 return FALSE;
203 switch (objp->fhs_status) {
204 case MNT1_OK:
205 if (!zdr_mountres1_ok (zdrs, &objp->mountres1_u.mountinfo))
206 return FALSE;
207 break;
208 default:
209 break;
210 }
211 return TRUE;
212}