Line data Source code
1 : /* parser auto-generated by pidl */
2 :
3 : #include "includes.h"
4 : #include "bin/default/librpc/gen_ndr/ndr_srvsvc.h"
5 :
6 : #include "librpc/gen_ndr/ndr_misc.h"
7 : #include "librpc/gen_ndr/ndr_security.h"
8 : #include "librpc/gen_ndr/ndr_svcctl.h"
9 0 : static enum ndr_err_code ndr_push_srvsvc_NetCharDevInfo0(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct srvsvc_NetCharDevInfo0 *r)
10 : {
11 0 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
12 0 : if (ndr_flags & NDR_SCALARS) {
13 0 : NDR_CHECK(ndr_push_align(ndr, 5));
14 0 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->device));
15 0 : NDR_CHECK(ndr_push_trailer_align(ndr, 5));
16 : }
17 0 : if (ndr_flags & NDR_BUFFERS) {
18 0 : if (r->device) {
19 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->device, CH_UTF16)));
20 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, 0));
21 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->device, CH_UTF16)));
22 0 : NDR_CHECK(ndr_push_charset(ndr, NDR_SCALARS, r->device, ndr_charset_length(r->device, CH_UTF16), sizeof(uint16_t), CH_UTF16));
23 : }
24 : }
25 0 : return NDR_ERR_SUCCESS;
26 : }
27 :
28 0 : static enum ndr_err_code ndr_pull_srvsvc_NetCharDevInfo0(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct srvsvc_NetCharDevInfo0 *r)
29 : {
30 0 : uint32_t _ptr_device;
31 0 : uint32_t size_device_1 = 0;
32 0 : uint32_t length_device_1 = 0;
33 0 : TALLOC_CTX *_mem_save_device_0 = NULL;
34 0 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
35 0 : if (ndr_flags & NDR_SCALARS) {
36 0 : NDR_CHECK(ndr_pull_align(ndr, 5));
37 0 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_device));
38 0 : if (_ptr_device) {
39 0 : NDR_PULL_ALLOC(ndr, r->device);
40 : } else {
41 0 : r->device = NULL;
42 : }
43 0 : NDR_CHECK(ndr_pull_trailer_align(ndr, 5));
44 : }
45 0 : if (ndr_flags & NDR_BUFFERS) {
46 0 : if (r->device) {
47 0 : _mem_save_device_0 = NDR_PULL_GET_MEM_CTX(ndr);
48 0 : NDR_PULL_SET_MEM_CTX(ndr, r->device, 0);
49 0 : NDR_CHECK(ndr_pull_array_size(ndr, &r->device));
50 0 : NDR_CHECK(ndr_pull_array_length(ndr, &r->device));
51 0 : NDR_CHECK(ndr_steal_array_size(ndr, (void*)&r->device, &size_device_1));
52 0 : NDR_CHECK(ndr_steal_array_length(ndr, (void*)&r->device, &length_device_1));
53 0 : if (length_device_1 > size_device_1) {
54 0 : return ndr_pull_error(ndr, NDR_ERR_ARRAY_SIZE, "Bad array size %"PRIu32": should exceed array length %"PRIu32"", size_device_1, length_device_1);
55 : }
56 0 : NDR_CHECK(ndr_check_string_terminator(ndr, length_device_1, sizeof(uint16_t)));
57 0 : NDR_CHECK(ndr_pull_charset(ndr, NDR_SCALARS, &r->device, length_device_1, sizeof(uint16_t), CH_UTF16));
58 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_device_0, 0);
59 : }
60 : }
61 0 : return NDR_ERR_SUCCESS;
62 : }
63 :
64 0 : _PUBLIC_ void ndr_print_srvsvc_NetCharDevInfo0(struct ndr_print *ndr, const char *name, const struct srvsvc_NetCharDevInfo0 *r)
65 : {
66 0 : ndr_print_struct(ndr, name, "srvsvc_NetCharDevInfo0");
67 0 : if (r == NULL) { ndr_print_null(ndr); return; }
68 0 : ndr->depth++;
69 0 : ndr_print_ptr(ndr, "device", r->device);
70 0 : ndr->depth++;
71 0 : if (r->device) {
72 0 : ndr_print_string(ndr, "device", r->device);
73 : }
74 0 : ndr->depth--;
75 0 : ndr->depth--;
76 : }
77 :
78 13 : static enum ndr_err_code ndr_push_srvsvc_NetCharDevCtr0(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct srvsvc_NetCharDevCtr0 *r)
79 : {
80 0 : uint32_t cntr_array_1;
81 13 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
82 13 : if (ndr_flags & NDR_SCALARS) {
83 13 : NDR_CHECK(ndr_push_align(ndr, 5));
84 13 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->count));
85 13 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->array));
86 13 : NDR_CHECK(ndr_push_trailer_align(ndr, 5));
87 : }
88 13 : if (ndr_flags & NDR_BUFFERS) {
89 13 : if (r->array) {
90 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, r->count));
91 0 : for (cntr_array_1 = 0; cntr_array_1 < (r->count); cntr_array_1++) {
92 0 : NDR_CHECK(ndr_push_srvsvc_NetCharDevInfo0(ndr, NDR_SCALARS, &r->array[cntr_array_1]));
93 : }
94 0 : for (cntr_array_1 = 0; cntr_array_1 < (r->count); cntr_array_1++) {
95 0 : NDR_CHECK(ndr_push_srvsvc_NetCharDevInfo0(ndr, NDR_BUFFERS, &r->array[cntr_array_1]));
96 : }
97 : }
98 : }
99 13 : return NDR_ERR_SUCCESS;
100 : }
101 :
102 12 : static enum ndr_err_code ndr_pull_srvsvc_NetCharDevCtr0(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct srvsvc_NetCharDevCtr0 *r)
103 : {
104 0 : uint32_t _ptr_array;
105 12 : uint32_t size_array_1 = 0;
106 0 : uint32_t cntr_array_1;
107 12 : TALLOC_CTX *_mem_save_array_0 = NULL;
108 12 : TALLOC_CTX *_mem_save_array_1 = NULL;
109 12 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
110 12 : if (ndr_flags & NDR_SCALARS) {
111 12 : NDR_CHECK(ndr_pull_align(ndr, 5));
112 12 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->count));
113 12 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_array));
114 12 : if (_ptr_array) {
115 0 : NDR_PULL_ALLOC(ndr, r->array);
116 : } else {
117 12 : r->array = NULL;
118 : }
119 12 : NDR_CHECK(ndr_pull_trailer_align(ndr, 5));
120 : }
121 12 : if (ndr_flags & NDR_BUFFERS) {
122 12 : if (r->array) {
123 0 : _mem_save_array_0 = NDR_PULL_GET_MEM_CTX(ndr);
124 0 : NDR_PULL_SET_MEM_CTX(ndr, r->array, 0);
125 0 : NDR_CHECK(ndr_pull_array_size(ndr, &r->array));
126 0 : NDR_CHECK(ndr_get_array_size(ndr, (void*)&r->array, &size_array_1));
127 0 : NDR_PULL_ALLOC_N(ndr, r->array, size_array_1);
128 0 : _mem_save_array_1 = NDR_PULL_GET_MEM_CTX(ndr);
129 0 : NDR_PULL_SET_MEM_CTX(ndr, r->array, 0);
130 0 : for (cntr_array_1 = 0; cntr_array_1 < (size_array_1); cntr_array_1++) {
131 0 : NDR_CHECK(ndr_pull_srvsvc_NetCharDevInfo0(ndr, NDR_SCALARS, &r->array[cntr_array_1]));
132 : }
133 0 : for (cntr_array_1 = 0; cntr_array_1 < (size_array_1); cntr_array_1++) {
134 0 : NDR_CHECK(ndr_pull_srvsvc_NetCharDevInfo0(ndr, NDR_BUFFERS, &r->array[cntr_array_1]));
135 : }
136 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_array_1, 0);
137 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_array_0, 0);
138 : }
139 12 : if (r->array) {
140 0 : NDR_CHECK(ndr_check_array_size(ndr, (void*)&r->array, r->count));
141 : }
142 12 : for (cntr_array_1 = 0; cntr_array_1 < (size_array_1); cntr_array_1++) {
143 0 : }
144 : }
145 12 : return NDR_ERR_SUCCESS;
146 : }
147 :
148 2 : _PUBLIC_ void ndr_print_srvsvc_NetCharDevCtr0(struct ndr_print *ndr, const char *name, const struct srvsvc_NetCharDevCtr0 *r)
149 : {
150 0 : uint32_t cntr_array_1;
151 2 : ndr_print_struct(ndr, name, "srvsvc_NetCharDevCtr0");
152 2 : if (r == NULL) { ndr_print_null(ndr); return; }
153 2 : ndr->depth++;
154 2 : ndr_print_uint32(ndr, "count", r->count);
155 2 : ndr_print_ptr(ndr, "array", r->array);
156 2 : ndr->depth++;
157 2 : if (r->array) {
158 0 : ndr->print(ndr, "%s: ARRAY(%"PRIu32")", "array", (uint32_t)(r->count));
159 0 : ndr->depth++;
160 0 : for (cntr_array_1 = 0; cntr_array_1 < (r->count); cntr_array_1++) {
161 0 : ndr_print_srvsvc_NetCharDevInfo0(ndr, "array", &r->array[cntr_array_1]);
162 : }
163 0 : ndr->depth--;
164 : }
165 2 : ndr->depth--;
166 2 : ndr->depth--;
167 : }
168 :
169 0 : static enum ndr_err_code ndr_push_srvsvc_NetCharDevInfo1(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct srvsvc_NetCharDevInfo1 *r)
170 : {
171 0 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
172 0 : if (ndr_flags & NDR_SCALARS) {
173 0 : NDR_CHECK(ndr_push_align(ndr, 5));
174 0 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->device));
175 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->status));
176 0 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->user));
177 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->time));
178 0 : NDR_CHECK(ndr_push_trailer_align(ndr, 5));
179 : }
180 0 : if (ndr_flags & NDR_BUFFERS) {
181 0 : if (r->device) {
182 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->device, CH_UTF16)));
183 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, 0));
184 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->device, CH_UTF16)));
185 0 : NDR_CHECK(ndr_push_charset(ndr, NDR_SCALARS, r->device, ndr_charset_length(r->device, CH_UTF16), sizeof(uint16_t), CH_UTF16));
186 : }
187 0 : if (r->user) {
188 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->user, CH_UTF16)));
189 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, 0));
190 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->user, CH_UTF16)));
191 0 : NDR_CHECK(ndr_push_charset(ndr, NDR_SCALARS, r->user, ndr_charset_length(r->user, CH_UTF16), sizeof(uint16_t), CH_UTF16));
192 : }
193 : }
194 0 : return NDR_ERR_SUCCESS;
195 : }
196 :
197 0 : static enum ndr_err_code ndr_pull_srvsvc_NetCharDevInfo1(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct srvsvc_NetCharDevInfo1 *r)
198 : {
199 0 : uint32_t _ptr_device;
200 0 : uint32_t size_device_1 = 0;
201 0 : uint32_t length_device_1 = 0;
202 0 : TALLOC_CTX *_mem_save_device_0 = NULL;
203 0 : uint32_t _ptr_user;
204 0 : uint32_t size_user_1 = 0;
205 0 : uint32_t length_user_1 = 0;
206 0 : TALLOC_CTX *_mem_save_user_0 = NULL;
207 0 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
208 0 : if (ndr_flags & NDR_SCALARS) {
209 0 : NDR_CHECK(ndr_pull_align(ndr, 5));
210 0 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_device));
211 0 : if (_ptr_device) {
212 0 : NDR_PULL_ALLOC(ndr, r->device);
213 : } else {
214 0 : r->device = NULL;
215 : }
216 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->status));
217 0 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_user));
218 0 : if (_ptr_user) {
219 0 : NDR_PULL_ALLOC(ndr, r->user);
220 : } else {
221 0 : r->user = NULL;
222 : }
223 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->time));
224 0 : NDR_CHECK(ndr_pull_trailer_align(ndr, 5));
225 : }
226 0 : if (ndr_flags & NDR_BUFFERS) {
227 0 : if (r->device) {
228 0 : _mem_save_device_0 = NDR_PULL_GET_MEM_CTX(ndr);
229 0 : NDR_PULL_SET_MEM_CTX(ndr, r->device, 0);
230 0 : NDR_CHECK(ndr_pull_array_size(ndr, &r->device));
231 0 : NDR_CHECK(ndr_pull_array_length(ndr, &r->device));
232 0 : NDR_CHECK(ndr_steal_array_size(ndr, (void*)&r->device, &size_device_1));
233 0 : NDR_CHECK(ndr_steal_array_length(ndr, (void*)&r->device, &length_device_1));
234 0 : if (length_device_1 > size_device_1) {
235 0 : return ndr_pull_error(ndr, NDR_ERR_ARRAY_SIZE, "Bad array size %"PRIu32": should exceed array length %"PRIu32"", size_device_1, length_device_1);
236 : }
237 0 : NDR_CHECK(ndr_check_string_terminator(ndr, length_device_1, sizeof(uint16_t)));
238 0 : NDR_CHECK(ndr_pull_charset(ndr, NDR_SCALARS, &r->device, length_device_1, sizeof(uint16_t), CH_UTF16));
239 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_device_0, 0);
240 : }
241 0 : if (r->user) {
242 0 : _mem_save_user_0 = NDR_PULL_GET_MEM_CTX(ndr);
243 0 : NDR_PULL_SET_MEM_CTX(ndr, r->user, 0);
244 0 : NDR_CHECK(ndr_pull_array_size(ndr, &r->user));
245 0 : NDR_CHECK(ndr_pull_array_length(ndr, &r->user));
246 0 : NDR_CHECK(ndr_steal_array_size(ndr, (void*)&r->user, &size_user_1));
247 0 : NDR_CHECK(ndr_steal_array_length(ndr, (void*)&r->user, &length_user_1));
248 0 : if (length_user_1 > size_user_1) {
249 0 : return ndr_pull_error(ndr, NDR_ERR_ARRAY_SIZE, "Bad array size %"PRIu32": should exceed array length %"PRIu32"", size_user_1, length_user_1);
250 : }
251 0 : NDR_CHECK(ndr_check_string_terminator(ndr, length_user_1, sizeof(uint16_t)));
252 0 : NDR_CHECK(ndr_pull_charset(ndr, NDR_SCALARS, &r->user, length_user_1, sizeof(uint16_t), CH_UTF16));
253 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_user_0, 0);
254 : }
255 : }
256 0 : return NDR_ERR_SUCCESS;
257 : }
258 :
259 0 : _PUBLIC_ void ndr_print_srvsvc_NetCharDevInfo1(struct ndr_print *ndr, const char *name, const struct srvsvc_NetCharDevInfo1 *r)
260 : {
261 0 : ndr_print_struct(ndr, name, "srvsvc_NetCharDevInfo1");
262 0 : if (r == NULL) { ndr_print_null(ndr); return; }
263 0 : ndr->depth++;
264 0 : ndr_print_ptr(ndr, "device", r->device);
265 0 : ndr->depth++;
266 0 : if (r->device) {
267 0 : ndr_print_string(ndr, "device", r->device);
268 : }
269 0 : ndr->depth--;
270 0 : ndr_print_uint32(ndr, "status", r->status);
271 0 : ndr_print_ptr(ndr, "user", r->user);
272 0 : ndr->depth++;
273 0 : if (r->user) {
274 0 : ndr_print_string(ndr, "user", r->user);
275 : }
276 0 : ndr->depth--;
277 0 : ndr_print_uint32(ndr, "time", r->time);
278 0 : ndr->depth--;
279 : }
280 :
281 9 : static enum ndr_err_code ndr_push_srvsvc_NetCharDevCtr1(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct srvsvc_NetCharDevCtr1 *r)
282 : {
283 0 : uint32_t cntr_array_1;
284 9 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
285 9 : if (ndr_flags & NDR_SCALARS) {
286 9 : NDR_CHECK(ndr_push_align(ndr, 5));
287 9 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->count));
288 9 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->array));
289 9 : NDR_CHECK(ndr_push_trailer_align(ndr, 5));
290 : }
291 9 : if (ndr_flags & NDR_BUFFERS) {
292 9 : if (r->array) {
293 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, r->count));
294 0 : for (cntr_array_1 = 0; cntr_array_1 < (r->count); cntr_array_1++) {
295 0 : NDR_CHECK(ndr_push_srvsvc_NetCharDevInfo1(ndr, NDR_SCALARS, &r->array[cntr_array_1]));
296 : }
297 0 : for (cntr_array_1 = 0; cntr_array_1 < (r->count); cntr_array_1++) {
298 0 : NDR_CHECK(ndr_push_srvsvc_NetCharDevInfo1(ndr, NDR_BUFFERS, &r->array[cntr_array_1]));
299 : }
300 : }
301 : }
302 9 : return NDR_ERR_SUCCESS;
303 : }
304 :
305 8 : static enum ndr_err_code ndr_pull_srvsvc_NetCharDevCtr1(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct srvsvc_NetCharDevCtr1 *r)
306 : {
307 0 : uint32_t _ptr_array;
308 8 : uint32_t size_array_1 = 0;
309 0 : uint32_t cntr_array_1;
310 8 : TALLOC_CTX *_mem_save_array_0 = NULL;
311 8 : TALLOC_CTX *_mem_save_array_1 = NULL;
312 8 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
313 8 : if (ndr_flags & NDR_SCALARS) {
314 8 : NDR_CHECK(ndr_pull_align(ndr, 5));
315 8 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->count));
316 8 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_array));
317 8 : if (_ptr_array) {
318 0 : NDR_PULL_ALLOC(ndr, r->array);
319 : } else {
320 8 : r->array = NULL;
321 : }
322 8 : NDR_CHECK(ndr_pull_trailer_align(ndr, 5));
323 : }
324 8 : if (ndr_flags & NDR_BUFFERS) {
325 8 : if (r->array) {
326 0 : _mem_save_array_0 = NDR_PULL_GET_MEM_CTX(ndr);
327 0 : NDR_PULL_SET_MEM_CTX(ndr, r->array, 0);
328 0 : NDR_CHECK(ndr_pull_array_size(ndr, &r->array));
329 0 : NDR_CHECK(ndr_get_array_size(ndr, (void*)&r->array, &size_array_1));
330 0 : NDR_PULL_ALLOC_N(ndr, r->array, size_array_1);
331 0 : _mem_save_array_1 = NDR_PULL_GET_MEM_CTX(ndr);
332 0 : NDR_PULL_SET_MEM_CTX(ndr, r->array, 0);
333 0 : for (cntr_array_1 = 0; cntr_array_1 < (size_array_1); cntr_array_1++) {
334 0 : NDR_CHECK(ndr_pull_srvsvc_NetCharDevInfo1(ndr, NDR_SCALARS, &r->array[cntr_array_1]));
335 : }
336 0 : for (cntr_array_1 = 0; cntr_array_1 < (size_array_1); cntr_array_1++) {
337 0 : NDR_CHECK(ndr_pull_srvsvc_NetCharDevInfo1(ndr, NDR_BUFFERS, &r->array[cntr_array_1]));
338 : }
339 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_array_1, 0);
340 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_array_0, 0);
341 : }
342 8 : if (r->array) {
343 0 : NDR_CHECK(ndr_check_array_size(ndr, (void*)&r->array, r->count));
344 : }
345 8 : for (cntr_array_1 = 0; cntr_array_1 < (size_array_1); cntr_array_1++) {
346 0 : }
347 : }
348 8 : return NDR_ERR_SUCCESS;
349 : }
350 :
351 2 : _PUBLIC_ void ndr_print_srvsvc_NetCharDevCtr1(struct ndr_print *ndr, const char *name, const struct srvsvc_NetCharDevCtr1 *r)
352 : {
353 0 : uint32_t cntr_array_1;
354 2 : ndr_print_struct(ndr, name, "srvsvc_NetCharDevCtr1");
355 2 : if (r == NULL) { ndr_print_null(ndr); return; }
356 2 : ndr->depth++;
357 2 : ndr_print_uint32(ndr, "count", r->count);
358 2 : ndr_print_ptr(ndr, "array", r->array);
359 2 : ndr->depth++;
360 2 : if (r->array) {
361 0 : ndr->print(ndr, "%s: ARRAY(%"PRIu32")", "array", (uint32_t)(r->count));
362 0 : ndr->depth++;
363 0 : for (cntr_array_1 = 0; cntr_array_1 < (r->count); cntr_array_1++) {
364 0 : ndr_print_srvsvc_NetCharDevInfo1(ndr, "array", &r->array[cntr_array_1]);
365 : }
366 0 : ndr->depth--;
367 : }
368 2 : ndr->depth--;
369 2 : ndr->depth--;
370 : }
371 :
372 0 : static enum ndr_err_code ndr_push_srvsvc_NetCharDevInfo(struct ndr_push *ndr, ndr_flags_type ndr_flags, const union srvsvc_NetCharDevInfo *r)
373 : {
374 0 : uint32_t level;
375 0 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
376 0 : if (ndr_flags & NDR_SCALARS) {
377 : /* This token is not used again (except perhaps below in the NDR_BUFFERS case) */
378 0 : NDR_CHECK(ndr_push_steal_switch_value(ndr, r, &level));
379 0 : NDR_CHECK(ndr_push_union_align(ndr, 5));
380 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, level));
381 0 : NDR_CHECK(ndr_push_union_align(ndr, 5));
382 0 : switch (level) {
383 0 : case 0: {
384 0 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->info0));
385 0 : break; }
386 :
387 0 : case 1: {
388 0 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->info1));
389 0 : break; }
390 :
391 0 : default: {
392 0 : break; }
393 :
394 : }
395 : }
396 0 : if (ndr_flags & NDR_BUFFERS) {
397 0 : if (!(ndr_flags & NDR_SCALARS)) {
398 : /* We didn't get it above, and the token is not needed after this. */
399 0 : NDR_CHECK(ndr_push_steal_switch_value(ndr, r, &level));
400 : }
401 0 : switch (level) {
402 0 : case 0:
403 0 : if (r->info0) {
404 0 : NDR_CHECK(ndr_push_srvsvc_NetCharDevInfo0(ndr, NDR_SCALARS|NDR_BUFFERS, r->info0));
405 : }
406 0 : break;
407 :
408 0 : case 1:
409 0 : if (r->info1) {
410 0 : NDR_CHECK(ndr_push_srvsvc_NetCharDevInfo1(ndr, NDR_SCALARS|NDR_BUFFERS, r->info1));
411 : }
412 0 : break;
413 :
414 0 : default:
415 0 : break;
416 :
417 : }
418 : }
419 0 : return NDR_ERR_SUCCESS;
420 : }
421 :
422 0 : static enum ndr_err_code ndr_pull_srvsvc_NetCharDevInfo(struct ndr_pull *ndr, ndr_flags_type ndr_flags, union srvsvc_NetCharDevInfo *r)
423 : {
424 0 : uint32_t level;
425 0 : uint32_t _level;
426 0 : TALLOC_CTX *_mem_save_info0_0 = NULL;
427 0 : uint32_t _ptr_info0;
428 0 : TALLOC_CTX *_mem_save_info1_0 = NULL;
429 0 : uint32_t _ptr_info1;
430 0 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
431 0 : if (ndr_flags & NDR_SCALARS) {
432 : /* This token is not used again (except perhaps below in the NDR_BUFFERS case) */
433 0 : NDR_CHECK(ndr_pull_steal_switch_value(ndr, r, &level));
434 0 : NDR_CHECK(ndr_pull_union_align(ndr, 5));
435 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &_level));
436 0 : if (_level != level) {
437 0 : return ndr_pull_error(ndr, NDR_ERR_BAD_SWITCH, "Bad switch value %"PRIu32" for r at %s", (uint32_t)_level, __location__);
438 : }
439 0 : NDR_CHECK(ndr_pull_union_align(ndr, 5));
440 0 : switch (level) {
441 0 : case 0: {
442 0 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_info0));
443 0 : if (_ptr_info0) {
444 0 : NDR_PULL_ALLOC(ndr, r->info0);
445 : } else {
446 0 : r->info0 = NULL;
447 : }
448 0 : break; }
449 :
450 0 : case 1: {
451 0 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_info1));
452 0 : if (_ptr_info1) {
453 0 : NDR_PULL_ALLOC(ndr, r->info1);
454 : } else {
455 0 : r->info1 = NULL;
456 : }
457 0 : break; }
458 :
459 0 : default: {
460 0 : break; }
461 :
462 : }
463 : }
464 0 : if (ndr_flags & NDR_BUFFERS) {
465 0 : if (!(ndr_flags & NDR_SCALARS)) {
466 : /* We didn't get it above, and the token is not needed after this. */
467 0 : NDR_CHECK(ndr_pull_steal_switch_value(ndr, r, &level));
468 : }
469 0 : switch (level) {
470 0 : case 0:
471 0 : if (r->info0) {
472 0 : _mem_save_info0_0 = NDR_PULL_GET_MEM_CTX(ndr);
473 0 : NDR_PULL_SET_MEM_CTX(ndr, r->info0, 0);
474 0 : NDR_CHECK(ndr_pull_srvsvc_NetCharDevInfo0(ndr, NDR_SCALARS|NDR_BUFFERS, r->info0));
475 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_info0_0, 0);
476 : }
477 0 : break;
478 :
479 0 : case 1:
480 0 : if (r->info1) {
481 0 : _mem_save_info1_0 = NDR_PULL_GET_MEM_CTX(ndr);
482 0 : NDR_PULL_SET_MEM_CTX(ndr, r->info1, 0);
483 0 : NDR_CHECK(ndr_pull_srvsvc_NetCharDevInfo1(ndr, NDR_SCALARS|NDR_BUFFERS, r->info1));
484 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_info1_0, 0);
485 : }
486 0 : break;
487 :
488 0 : default:
489 0 : break;
490 :
491 : }
492 : }
493 0 : return NDR_ERR_SUCCESS;
494 : }
495 :
496 0 : _PUBLIC_ void ndr_print_srvsvc_NetCharDevInfo(struct ndr_print *ndr, const char *name, const union srvsvc_NetCharDevInfo *r)
497 : {
498 0 : uint32_t level;
499 0 : level = ndr_print_steal_switch_value(ndr, r);
500 0 : ndr_print_union(ndr, name, level, "srvsvc_NetCharDevInfo");
501 0 : switch (level) {
502 0 : case 0:
503 0 : ndr_print_ptr(ndr, "info0", r->info0);
504 0 : ndr->depth++;
505 0 : if (r->info0) {
506 0 : ndr_print_srvsvc_NetCharDevInfo0(ndr, "info0", r->info0);
507 : }
508 0 : ndr->depth--;
509 0 : break;
510 :
511 0 : case 1:
512 0 : ndr_print_ptr(ndr, "info1", r->info1);
513 0 : ndr->depth++;
514 0 : if (r->info1) {
515 0 : ndr_print_srvsvc_NetCharDevInfo1(ndr, "info1", r->info1);
516 : }
517 0 : ndr->depth--;
518 0 : break;
519 :
520 0 : default:
521 0 : break;
522 :
523 : }
524 0 : }
525 :
526 44 : static enum ndr_err_code ndr_push_srvsvc_NetCharDevCtr(struct ndr_push *ndr, ndr_flags_type ndr_flags, const union srvsvc_NetCharDevCtr *r)
527 : {
528 0 : uint32_t level;
529 44 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
530 44 : if (ndr_flags & NDR_SCALARS) {
531 : /* This token is not used again (except perhaps below in the NDR_BUFFERS case) */
532 22 : NDR_CHECK(ndr_push_steal_switch_value(ndr, r, &level));
533 22 : NDR_CHECK(ndr_push_union_align(ndr, 5));
534 22 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, level));
535 22 : NDR_CHECK(ndr_push_union_align(ndr, 5));
536 22 : switch (level) {
537 13 : case 0: {
538 13 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->ctr0));
539 13 : break; }
540 :
541 9 : case 1: {
542 9 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->ctr1));
543 9 : break; }
544 :
545 0 : default: {
546 0 : break; }
547 :
548 : }
549 : }
550 44 : if (ndr_flags & NDR_BUFFERS) {
551 22 : if (!(ndr_flags & NDR_SCALARS)) {
552 : /* We didn't get it above, and the token is not needed after this. */
553 22 : NDR_CHECK(ndr_push_steal_switch_value(ndr, r, &level));
554 : }
555 22 : switch (level) {
556 13 : case 0:
557 13 : if (r->ctr0) {
558 13 : NDR_CHECK(ndr_push_srvsvc_NetCharDevCtr0(ndr, NDR_SCALARS|NDR_BUFFERS, r->ctr0));
559 : }
560 13 : break;
561 :
562 9 : case 1:
563 9 : if (r->ctr1) {
564 9 : NDR_CHECK(ndr_push_srvsvc_NetCharDevCtr1(ndr, NDR_SCALARS|NDR_BUFFERS, r->ctr1));
565 : }
566 9 : break;
567 :
568 0 : default:
569 0 : break;
570 :
571 : }
572 : }
573 44 : return NDR_ERR_SUCCESS;
574 : }
575 :
576 40 : static enum ndr_err_code ndr_pull_srvsvc_NetCharDevCtr(struct ndr_pull *ndr, ndr_flags_type ndr_flags, union srvsvc_NetCharDevCtr *r)
577 : {
578 0 : uint32_t level;
579 0 : uint32_t _level;
580 40 : TALLOC_CTX *_mem_save_ctr0_0 = NULL;
581 0 : uint32_t _ptr_ctr0;
582 40 : TALLOC_CTX *_mem_save_ctr1_0 = NULL;
583 0 : uint32_t _ptr_ctr1;
584 40 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
585 40 : if (ndr_flags & NDR_SCALARS) {
586 : /* This token is not used again (except perhaps below in the NDR_BUFFERS case) */
587 20 : NDR_CHECK(ndr_pull_steal_switch_value(ndr, r, &level));
588 20 : NDR_CHECK(ndr_pull_union_align(ndr, 5));
589 20 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &_level));
590 20 : if (_level != level) {
591 0 : return ndr_pull_error(ndr, NDR_ERR_BAD_SWITCH, "Bad switch value %"PRIu32" for r at %s", (uint32_t)_level, __location__);
592 : }
593 20 : NDR_CHECK(ndr_pull_union_align(ndr, 5));
594 20 : switch (level) {
595 12 : case 0: {
596 12 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_ctr0));
597 12 : if (_ptr_ctr0) {
598 12 : NDR_PULL_ALLOC(ndr, r->ctr0);
599 : } else {
600 0 : r->ctr0 = NULL;
601 : }
602 12 : break; }
603 :
604 8 : case 1: {
605 8 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_ctr1));
606 8 : if (_ptr_ctr1) {
607 8 : NDR_PULL_ALLOC(ndr, r->ctr1);
608 : } else {
609 0 : r->ctr1 = NULL;
610 : }
611 8 : break; }
612 :
613 0 : default: {
614 0 : break; }
615 :
616 : }
617 : }
618 40 : if (ndr_flags & NDR_BUFFERS) {
619 20 : if (!(ndr_flags & NDR_SCALARS)) {
620 : /* We didn't get it above, and the token is not needed after this. */
621 20 : NDR_CHECK(ndr_pull_steal_switch_value(ndr, r, &level));
622 : }
623 20 : switch (level) {
624 12 : case 0:
625 12 : if (r->ctr0) {
626 12 : _mem_save_ctr0_0 = NDR_PULL_GET_MEM_CTX(ndr);
627 12 : NDR_PULL_SET_MEM_CTX(ndr, r->ctr0, 0);
628 12 : NDR_CHECK(ndr_pull_srvsvc_NetCharDevCtr0(ndr, NDR_SCALARS|NDR_BUFFERS, r->ctr0));
629 12 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_ctr0_0, 0);
630 : }
631 12 : break;
632 :
633 8 : case 1:
634 8 : if (r->ctr1) {
635 8 : _mem_save_ctr1_0 = NDR_PULL_GET_MEM_CTX(ndr);
636 8 : NDR_PULL_SET_MEM_CTX(ndr, r->ctr1, 0);
637 8 : NDR_CHECK(ndr_pull_srvsvc_NetCharDevCtr1(ndr, NDR_SCALARS|NDR_BUFFERS, r->ctr1));
638 8 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_ctr1_0, 0);
639 : }
640 8 : break;
641 :
642 0 : default:
643 0 : break;
644 :
645 : }
646 : }
647 40 : return NDR_ERR_SUCCESS;
648 : }
649 :
650 4 : _PUBLIC_ void ndr_print_srvsvc_NetCharDevCtr(struct ndr_print *ndr, const char *name, const union srvsvc_NetCharDevCtr *r)
651 : {
652 0 : uint32_t level;
653 4 : level = ndr_print_steal_switch_value(ndr, r);
654 4 : ndr_print_union(ndr, name, level, "srvsvc_NetCharDevCtr");
655 4 : switch (level) {
656 2 : case 0:
657 2 : ndr_print_ptr(ndr, "ctr0", r->ctr0);
658 2 : ndr->depth++;
659 2 : if (r->ctr0) {
660 2 : ndr_print_srvsvc_NetCharDevCtr0(ndr, "ctr0", r->ctr0);
661 : }
662 2 : ndr->depth--;
663 2 : break;
664 :
665 2 : case 1:
666 2 : ndr_print_ptr(ndr, "ctr1", r->ctr1);
667 2 : ndr->depth++;
668 2 : if (r->ctr1) {
669 2 : ndr_print_srvsvc_NetCharDevCtr1(ndr, "ctr1", r->ctr1);
670 : }
671 2 : ndr->depth--;
672 2 : break;
673 :
674 0 : default:
675 0 : break;
676 :
677 : }
678 4 : }
679 :
680 22 : static enum ndr_err_code ndr_push_srvsvc_NetCharDevInfoCtr(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct srvsvc_NetCharDevInfoCtr *r)
681 : {
682 22 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
683 22 : if (ndr_flags & NDR_SCALARS) {
684 22 : NDR_CHECK(ndr_push_align(ndr, 5));
685 22 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->level));
686 22 : NDR_CHECK(ndr_push_set_switch_value(ndr, &r->ctr, r->level));
687 22 : NDR_CHECK(ndr_push_srvsvc_NetCharDevCtr(ndr, NDR_SCALARS, &r->ctr));
688 22 : NDR_CHECK(ndr_push_trailer_align(ndr, 5));
689 : }
690 22 : if (ndr_flags & NDR_BUFFERS) {
691 22 : NDR_CHECK(ndr_push_set_switch_value(ndr, &r->ctr, r->level));
692 22 : NDR_CHECK(ndr_push_srvsvc_NetCharDevCtr(ndr, NDR_BUFFERS, &r->ctr));
693 : }
694 22 : return NDR_ERR_SUCCESS;
695 : }
696 :
697 20 : static enum ndr_err_code ndr_pull_srvsvc_NetCharDevInfoCtr(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct srvsvc_NetCharDevInfoCtr *r)
698 : {
699 20 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
700 20 : if (ndr_flags & NDR_SCALARS) {
701 20 : NDR_CHECK(ndr_pull_align(ndr, 5));
702 20 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->level));
703 20 : NDR_CHECK(ndr_pull_set_switch_value(ndr, &r->ctr, r->level));
704 20 : NDR_CHECK(ndr_pull_srvsvc_NetCharDevCtr(ndr, NDR_SCALARS, &r->ctr));
705 20 : NDR_CHECK(ndr_pull_trailer_align(ndr, 5));
706 : }
707 20 : if (ndr_flags & NDR_BUFFERS) {
708 20 : NDR_CHECK(ndr_pull_set_switch_value(ndr, &r->ctr, r->level));
709 20 : NDR_CHECK(ndr_pull_srvsvc_NetCharDevCtr(ndr, NDR_BUFFERS, &r->ctr));
710 : }
711 20 : return NDR_ERR_SUCCESS;
712 : }
713 :
714 4 : _PUBLIC_ void ndr_print_srvsvc_NetCharDevInfoCtr(struct ndr_print *ndr, const char *name, const struct srvsvc_NetCharDevInfoCtr *r)
715 : {
716 4 : ndr_print_struct(ndr, name, "srvsvc_NetCharDevInfoCtr");
717 4 : if (r == NULL) { ndr_print_null(ndr); return; }
718 4 : ndr->depth++;
719 4 : ndr_print_uint32(ndr, "level", r->level);
720 4 : ndr_print_set_switch_value(ndr, &r->ctr, r->level);
721 4 : ndr_print_srvsvc_NetCharDevCtr(ndr, "ctr", &r->ctr);
722 4 : ndr->depth--;
723 : }
724 :
725 0 : static enum ndr_err_code ndr_push_srvsvc_NetCharDevQInfo0(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct srvsvc_NetCharDevQInfo0 *r)
726 : {
727 0 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
728 0 : if (ndr_flags & NDR_SCALARS) {
729 0 : NDR_CHECK(ndr_push_align(ndr, 5));
730 0 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->device));
731 0 : NDR_CHECK(ndr_push_trailer_align(ndr, 5));
732 : }
733 0 : if (ndr_flags & NDR_BUFFERS) {
734 0 : if (r->device) {
735 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->device, CH_UTF16)));
736 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, 0));
737 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->device, CH_UTF16)));
738 0 : NDR_CHECK(ndr_push_charset(ndr, NDR_SCALARS, r->device, ndr_charset_length(r->device, CH_UTF16), sizeof(uint16_t), CH_UTF16));
739 : }
740 : }
741 0 : return NDR_ERR_SUCCESS;
742 : }
743 :
744 0 : static enum ndr_err_code ndr_pull_srvsvc_NetCharDevQInfo0(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct srvsvc_NetCharDevQInfo0 *r)
745 : {
746 0 : uint32_t _ptr_device;
747 0 : uint32_t size_device_1 = 0;
748 0 : uint32_t length_device_1 = 0;
749 0 : TALLOC_CTX *_mem_save_device_0 = NULL;
750 0 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
751 0 : if (ndr_flags & NDR_SCALARS) {
752 0 : NDR_CHECK(ndr_pull_align(ndr, 5));
753 0 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_device));
754 0 : if (_ptr_device) {
755 0 : NDR_PULL_ALLOC(ndr, r->device);
756 : } else {
757 0 : r->device = NULL;
758 : }
759 0 : NDR_CHECK(ndr_pull_trailer_align(ndr, 5));
760 : }
761 0 : if (ndr_flags & NDR_BUFFERS) {
762 0 : if (r->device) {
763 0 : _mem_save_device_0 = NDR_PULL_GET_MEM_CTX(ndr);
764 0 : NDR_PULL_SET_MEM_CTX(ndr, r->device, 0);
765 0 : NDR_CHECK(ndr_pull_array_size(ndr, &r->device));
766 0 : NDR_CHECK(ndr_pull_array_length(ndr, &r->device));
767 0 : NDR_CHECK(ndr_steal_array_size(ndr, (void*)&r->device, &size_device_1));
768 0 : NDR_CHECK(ndr_steal_array_length(ndr, (void*)&r->device, &length_device_1));
769 0 : if (length_device_1 > size_device_1) {
770 0 : return ndr_pull_error(ndr, NDR_ERR_ARRAY_SIZE, "Bad array size %"PRIu32": should exceed array length %"PRIu32"", size_device_1, length_device_1);
771 : }
772 0 : NDR_CHECK(ndr_check_string_terminator(ndr, length_device_1, sizeof(uint16_t)));
773 0 : NDR_CHECK(ndr_pull_charset(ndr, NDR_SCALARS, &r->device, length_device_1, sizeof(uint16_t), CH_UTF16));
774 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_device_0, 0);
775 : }
776 : }
777 0 : return NDR_ERR_SUCCESS;
778 : }
779 :
780 0 : _PUBLIC_ void ndr_print_srvsvc_NetCharDevQInfo0(struct ndr_print *ndr, const char *name, const struct srvsvc_NetCharDevQInfo0 *r)
781 : {
782 0 : ndr_print_struct(ndr, name, "srvsvc_NetCharDevQInfo0");
783 0 : if (r == NULL) { ndr_print_null(ndr); return; }
784 0 : ndr->depth++;
785 0 : ndr_print_ptr(ndr, "device", r->device);
786 0 : ndr->depth++;
787 0 : if (r->device) {
788 0 : ndr_print_string(ndr, "device", r->device);
789 : }
790 0 : ndr->depth--;
791 0 : ndr->depth--;
792 : }
793 :
794 13 : static enum ndr_err_code ndr_push_srvsvc_NetCharDevQCtr0(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct srvsvc_NetCharDevQCtr0 *r)
795 : {
796 0 : uint32_t cntr_array_1;
797 13 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
798 13 : if (ndr_flags & NDR_SCALARS) {
799 13 : NDR_CHECK(ndr_push_align(ndr, 5));
800 13 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->count));
801 13 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->array));
802 13 : NDR_CHECK(ndr_push_trailer_align(ndr, 5));
803 : }
804 13 : if (ndr_flags & NDR_BUFFERS) {
805 13 : if (r->array) {
806 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, r->count));
807 0 : for (cntr_array_1 = 0; cntr_array_1 < (r->count); cntr_array_1++) {
808 0 : NDR_CHECK(ndr_push_srvsvc_NetCharDevQInfo0(ndr, NDR_SCALARS, &r->array[cntr_array_1]));
809 : }
810 0 : for (cntr_array_1 = 0; cntr_array_1 < (r->count); cntr_array_1++) {
811 0 : NDR_CHECK(ndr_push_srvsvc_NetCharDevQInfo0(ndr, NDR_BUFFERS, &r->array[cntr_array_1]));
812 : }
813 : }
814 : }
815 13 : return NDR_ERR_SUCCESS;
816 : }
817 :
818 12 : static enum ndr_err_code ndr_pull_srvsvc_NetCharDevQCtr0(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct srvsvc_NetCharDevQCtr0 *r)
819 : {
820 0 : uint32_t _ptr_array;
821 12 : uint32_t size_array_1 = 0;
822 0 : uint32_t cntr_array_1;
823 12 : TALLOC_CTX *_mem_save_array_0 = NULL;
824 12 : TALLOC_CTX *_mem_save_array_1 = NULL;
825 12 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
826 12 : if (ndr_flags & NDR_SCALARS) {
827 12 : NDR_CHECK(ndr_pull_align(ndr, 5));
828 12 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->count));
829 12 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_array));
830 12 : if (_ptr_array) {
831 0 : NDR_PULL_ALLOC(ndr, r->array);
832 : } else {
833 12 : r->array = NULL;
834 : }
835 12 : NDR_CHECK(ndr_pull_trailer_align(ndr, 5));
836 : }
837 12 : if (ndr_flags & NDR_BUFFERS) {
838 12 : if (r->array) {
839 0 : _mem_save_array_0 = NDR_PULL_GET_MEM_CTX(ndr);
840 0 : NDR_PULL_SET_MEM_CTX(ndr, r->array, 0);
841 0 : NDR_CHECK(ndr_pull_array_size(ndr, &r->array));
842 0 : NDR_CHECK(ndr_get_array_size(ndr, (void*)&r->array, &size_array_1));
843 0 : NDR_PULL_ALLOC_N(ndr, r->array, size_array_1);
844 0 : _mem_save_array_1 = NDR_PULL_GET_MEM_CTX(ndr);
845 0 : NDR_PULL_SET_MEM_CTX(ndr, r->array, 0);
846 0 : for (cntr_array_1 = 0; cntr_array_1 < (size_array_1); cntr_array_1++) {
847 0 : NDR_CHECK(ndr_pull_srvsvc_NetCharDevQInfo0(ndr, NDR_SCALARS, &r->array[cntr_array_1]));
848 : }
849 0 : for (cntr_array_1 = 0; cntr_array_1 < (size_array_1); cntr_array_1++) {
850 0 : NDR_CHECK(ndr_pull_srvsvc_NetCharDevQInfo0(ndr, NDR_BUFFERS, &r->array[cntr_array_1]));
851 : }
852 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_array_1, 0);
853 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_array_0, 0);
854 : }
855 12 : if (r->array) {
856 0 : NDR_CHECK(ndr_check_array_size(ndr, (void*)&r->array, r->count));
857 : }
858 12 : for (cntr_array_1 = 0; cntr_array_1 < (size_array_1); cntr_array_1++) {
859 0 : }
860 : }
861 12 : return NDR_ERR_SUCCESS;
862 : }
863 :
864 2 : _PUBLIC_ void ndr_print_srvsvc_NetCharDevQCtr0(struct ndr_print *ndr, const char *name, const struct srvsvc_NetCharDevQCtr0 *r)
865 : {
866 0 : uint32_t cntr_array_1;
867 2 : ndr_print_struct(ndr, name, "srvsvc_NetCharDevQCtr0");
868 2 : if (r == NULL) { ndr_print_null(ndr); return; }
869 2 : ndr->depth++;
870 2 : ndr_print_uint32(ndr, "count", r->count);
871 2 : ndr_print_ptr(ndr, "array", r->array);
872 2 : ndr->depth++;
873 2 : if (r->array) {
874 0 : ndr->print(ndr, "%s: ARRAY(%"PRIu32")", "array", (uint32_t)(r->count));
875 0 : ndr->depth++;
876 0 : for (cntr_array_1 = 0; cntr_array_1 < (r->count); cntr_array_1++) {
877 0 : ndr_print_srvsvc_NetCharDevQInfo0(ndr, "array", &r->array[cntr_array_1]);
878 : }
879 0 : ndr->depth--;
880 : }
881 2 : ndr->depth--;
882 2 : ndr->depth--;
883 : }
884 :
885 0 : static enum ndr_err_code ndr_push_srvsvc_NetCharDevQInfo1(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct srvsvc_NetCharDevQInfo1 *r)
886 : {
887 0 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
888 0 : if (ndr_flags & NDR_SCALARS) {
889 0 : NDR_CHECK(ndr_push_align(ndr, 5));
890 0 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->device));
891 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->priority));
892 0 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->devices));
893 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->users));
894 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->num_ahead));
895 0 : NDR_CHECK(ndr_push_trailer_align(ndr, 5));
896 : }
897 0 : if (ndr_flags & NDR_BUFFERS) {
898 0 : if (r->device) {
899 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->device, CH_UTF16)));
900 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, 0));
901 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->device, CH_UTF16)));
902 0 : NDR_CHECK(ndr_push_charset(ndr, NDR_SCALARS, r->device, ndr_charset_length(r->device, CH_UTF16), sizeof(uint16_t), CH_UTF16));
903 : }
904 0 : if (r->devices) {
905 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->devices, CH_UTF16)));
906 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, 0));
907 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->devices, CH_UTF16)));
908 0 : NDR_CHECK(ndr_push_charset(ndr, NDR_SCALARS, r->devices, ndr_charset_length(r->devices, CH_UTF16), sizeof(uint16_t), CH_UTF16));
909 : }
910 : }
911 0 : return NDR_ERR_SUCCESS;
912 : }
913 :
914 0 : static enum ndr_err_code ndr_pull_srvsvc_NetCharDevQInfo1(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct srvsvc_NetCharDevQInfo1 *r)
915 : {
916 0 : uint32_t _ptr_device;
917 0 : uint32_t size_device_1 = 0;
918 0 : uint32_t length_device_1 = 0;
919 0 : TALLOC_CTX *_mem_save_device_0 = NULL;
920 0 : uint32_t _ptr_devices;
921 0 : uint32_t size_devices_1 = 0;
922 0 : uint32_t length_devices_1 = 0;
923 0 : TALLOC_CTX *_mem_save_devices_0 = NULL;
924 0 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
925 0 : if (ndr_flags & NDR_SCALARS) {
926 0 : NDR_CHECK(ndr_pull_align(ndr, 5));
927 0 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_device));
928 0 : if (_ptr_device) {
929 0 : NDR_PULL_ALLOC(ndr, r->device);
930 : } else {
931 0 : r->device = NULL;
932 : }
933 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->priority));
934 0 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_devices));
935 0 : if (_ptr_devices) {
936 0 : NDR_PULL_ALLOC(ndr, r->devices);
937 : } else {
938 0 : r->devices = NULL;
939 : }
940 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->users));
941 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->num_ahead));
942 0 : NDR_CHECK(ndr_pull_trailer_align(ndr, 5));
943 : }
944 0 : if (ndr_flags & NDR_BUFFERS) {
945 0 : if (r->device) {
946 0 : _mem_save_device_0 = NDR_PULL_GET_MEM_CTX(ndr);
947 0 : NDR_PULL_SET_MEM_CTX(ndr, r->device, 0);
948 0 : NDR_CHECK(ndr_pull_array_size(ndr, &r->device));
949 0 : NDR_CHECK(ndr_pull_array_length(ndr, &r->device));
950 0 : NDR_CHECK(ndr_steal_array_size(ndr, (void*)&r->device, &size_device_1));
951 0 : NDR_CHECK(ndr_steal_array_length(ndr, (void*)&r->device, &length_device_1));
952 0 : if (length_device_1 > size_device_1) {
953 0 : return ndr_pull_error(ndr, NDR_ERR_ARRAY_SIZE, "Bad array size %"PRIu32": should exceed array length %"PRIu32"", size_device_1, length_device_1);
954 : }
955 0 : NDR_CHECK(ndr_check_string_terminator(ndr, length_device_1, sizeof(uint16_t)));
956 0 : NDR_CHECK(ndr_pull_charset(ndr, NDR_SCALARS, &r->device, length_device_1, sizeof(uint16_t), CH_UTF16));
957 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_device_0, 0);
958 : }
959 0 : if (r->devices) {
960 0 : _mem_save_devices_0 = NDR_PULL_GET_MEM_CTX(ndr);
961 0 : NDR_PULL_SET_MEM_CTX(ndr, r->devices, 0);
962 0 : NDR_CHECK(ndr_pull_array_size(ndr, &r->devices));
963 0 : NDR_CHECK(ndr_pull_array_length(ndr, &r->devices));
964 0 : NDR_CHECK(ndr_steal_array_size(ndr, (void*)&r->devices, &size_devices_1));
965 0 : NDR_CHECK(ndr_steal_array_length(ndr, (void*)&r->devices, &length_devices_1));
966 0 : if (length_devices_1 > size_devices_1) {
967 0 : return ndr_pull_error(ndr, NDR_ERR_ARRAY_SIZE, "Bad array size %"PRIu32": should exceed array length %"PRIu32"", size_devices_1, length_devices_1);
968 : }
969 0 : NDR_CHECK(ndr_check_string_terminator(ndr, length_devices_1, sizeof(uint16_t)));
970 0 : NDR_CHECK(ndr_pull_charset(ndr, NDR_SCALARS, &r->devices, length_devices_1, sizeof(uint16_t), CH_UTF16));
971 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_devices_0, 0);
972 : }
973 : }
974 0 : return NDR_ERR_SUCCESS;
975 : }
976 :
977 0 : _PUBLIC_ void ndr_print_srvsvc_NetCharDevQInfo1(struct ndr_print *ndr, const char *name, const struct srvsvc_NetCharDevQInfo1 *r)
978 : {
979 0 : ndr_print_struct(ndr, name, "srvsvc_NetCharDevQInfo1");
980 0 : if (r == NULL) { ndr_print_null(ndr); return; }
981 0 : ndr->depth++;
982 0 : ndr_print_ptr(ndr, "device", r->device);
983 0 : ndr->depth++;
984 0 : if (r->device) {
985 0 : ndr_print_string(ndr, "device", r->device);
986 : }
987 0 : ndr->depth--;
988 0 : ndr_print_uint32(ndr, "priority", r->priority);
989 0 : ndr_print_ptr(ndr, "devices", r->devices);
990 0 : ndr->depth++;
991 0 : if (r->devices) {
992 0 : ndr_print_string(ndr, "devices", r->devices);
993 : }
994 0 : ndr->depth--;
995 0 : ndr_print_uint32(ndr, "users", r->users);
996 0 : ndr_print_uint32(ndr, "num_ahead", r->num_ahead);
997 0 : ndr->depth--;
998 : }
999 :
1000 9 : static enum ndr_err_code ndr_push_srvsvc_NetCharDevQCtr1(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct srvsvc_NetCharDevQCtr1 *r)
1001 : {
1002 0 : uint32_t cntr_array_1;
1003 9 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
1004 9 : if (ndr_flags & NDR_SCALARS) {
1005 9 : NDR_CHECK(ndr_push_align(ndr, 5));
1006 9 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->count));
1007 9 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->array));
1008 9 : NDR_CHECK(ndr_push_trailer_align(ndr, 5));
1009 : }
1010 9 : if (ndr_flags & NDR_BUFFERS) {
1011 9 : if (r->array) {
1012 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, r->count));
1013 0 : for (cntr_array_1 = 0; cntr_array_1 < (r->count); cntr_array_1++) {
1014 0 : NDR_CHECK(ndr_push_srvsvc_NetCharDevQInfo1(ndr, NDR_SCALARS, &r->array[cntr_array_1]));
1015 : }
1016 0 : for (cntr_array_1 = 0; cntr_array_1 < (r->count); cntr_array_1++) {
1017 0 : NDR_CHECK(ndr_push_srvsvc_NetCharDevQInfo1(ndr, NDR_BUFFERS, &r->array[cntr_array_1]));
1018 : }
1019 : }
1020 : }
1021 9 : return NDR_ERR_SUCCESS;
1022 : }
1023 :
1024 8 : static enum ndr_err_code ndr_pull_srvsvc_NetCharDevQCtr1(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct srvsvc_NetCharDevQCtr1 *r)
1025 : {
1026 0 : uint32_t _ptr_array;
1027 8 : uint32_t size_array_1 = 0;
1028 0 : uint32_t cntr_array_1;
1029 8 : TALLOC_CTX *_mem_save_array_0 = NULL;
1030 8 : TALLOC_CTX *_mem_save_array_1 = NULL;
1031 8 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
1032 8 : if (ndr_flags & NDR_SCALARS) {
1033 8 : NDR_CHECK(ndr_pull_align(ndr, 5));
1034 8 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->count));
1035 8 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_array));
1036 8 : if (_ptr_array) {
1037 0 : NDR_PULL_ALLOC(ndr, r->array);
1038 : } else {
1039 8 : r->array = NULL;
1040 : }
1041 8 : NDR_CHECK(ndr_pull_trailer_align(ndr, 5));
1042 : }
1043 8 : if (ndr_flags & NDR_BUFFERS) {
1044 8 : if (r->array) {
1045 0 : _mem_save_array_0 = NDR_PULL_GET_MEM_CTX(ndr);
1046 0 : NDR_PULL_SET_MEM_CTX(ndr, r->array, 0);
1047 0 : NDR_CHECK(ndr_pull_array_size(ndr, &r->array));
1048 0 : NDR_CHECK(ndr_get_array_size(ndr, (void*)&r->array, &size_array_1));
1049 0 : NDR_PULL_ALLOC_N(ndr, r->array, size_array_1);
1050 0 : _mem_save_array_1 = NDR_PULL_GET_MEM_CTX(ndr);
1051 0 : NDR_PULL_SET_MEM_CTX(ndr, r->array, 0);
1052 0 : for (cntr_array_1 = 0; cntr_array_1 < (size_array_1); cntr_array_1++) {
1053 0 : NDR_CHECK(ndr_pull_srvsvc_NetCharDevQInfo1(ndr, NDR_SCALARS, &r->array[cntr_array_1]));
1054 : }
1055 0 : for (cntr_array_1 = 0; cntr_array_1 < (size_array_1); cntr_array_1++) {
1056 0 : NDR_CHECK(ndr_pull_srvsvc_NetCharDevQInfo1(ndr, NDR_BUFFERS, &r->array[cntr_array_1]));
1057 : }
1058 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_array_1, 0);
1059 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_array_0, 0);
1060 : }
1061 8 : if (r->array) {
1062 0 : NDR_CHECK(ndr_check_array_size(ndr, (void*)&r->array, r->count));
1063 : }
1064 8 : for (cntr_array_1 = 0; cntr_array_1 < (size_array_1); cntr_array_1++) {
1065 0 : }
1066 : }
1067 8 : return NDR_ERR_SUCCESS;
1068 : }
1069 :
1070 2 : _PUBLIC_ void ndr_print_srvsvc_NetCharDevQCtr1(struct ndr_print *ndr, const char *name, const struct srvsvc_NetCharDevQCtr1 *r)
1071 : {
1072 0 : uint32_t cntr_array_1;
1073 2 : ndr_print_struct(ndr, name, "srvsvc_NetCharDevQCtr1");
1074 2 : if (r == NULL) { ndr_print_null(ndr); return; }
1075 2 : ndr->depth++;
1076 2 : ndr_print_uint32(ndr, "count", r->count);
1077 2 : ndr_print_ptr(ndr, "array", r->array);
1078 2 : ndr->depth++;
1079 2 : if (r->array) {
1080 0 : ndr->print(ndr, "%s: ARRAY(%"PRIu32")", "array", (uint32_t)(r->count));
1081 0 : ndr->depth++;
1082 0 : for (cntr_array_1 = 0; cntr_array_1 < (r->count); cntr_array_1++) {
1083 0 : ndr_print_srvsvc_NetCharDevQInfo1(ndr, "array", &r->array[cntr_array_1]);
1084 : }
1085 0 : ndr->depth--;
1086 : }
1087 2 : ndr->depth--;
1088 2 : ndr->depth--;
1089 : }
1090 :
1091 0 : static enum ndr_err_code ndr_push_srvsvc_NetCharDevQInfo(struct ndr_push *ndr, ndr_flags_type ndr_flags, const union srvsvc_NetCharDevQInfo *r)
1092 : {
1093 0 : uint32_t level;
1094 0 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
1095 0 : if (ndr_flags & NDR_SCALARS) {
1096 : /* This token is not used again (except perhaps below in the NDR_BUFFERS case) */
1097 0 : NDR_CHECK(ndr_push_steal_switch_value(ndr, r, &level));
1098 0 : NDR_CHECK(ndr_push_union_align(ndr, 5));
1099 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, level));
1100 0 : NDR_CHECK(ndr_push_union_align(ndr, 5));
1101 0 : switch (level) {
1102 0 : case 0: {
1103 0 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->info0));
1104 0 : break; }
1105 :
1106 0 : case 1: {
1107 0 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->info1));
1108 0 : break; }
1109 :
1110 0 : default: {
1111 0 : break; }
1112 :
1113 : }
1114 : }
1115 0 : if (ndr_flags & NDR_BUFFERS) {
1116 0 : if (!(ndr_flags & NDR_SCALARS)) {
1117 : /* We didn't get it above, and the token is not needed after this. */
1118 0 : NDR_CHECK(ndr_push_steal_switch_value(ndr, r, &level));
1119 : }
1120 0 : switch (level) {
1121 0 : case 0:
1122 0 : if (r->info0) {
1123 0 : NDR_CHECK(ndr_push_srvsvc_NetCharDevQInfo0(ndr, NDR_SCALARS|NDR_BUFFERS, r->info0));
1124 : }
1125 0 : break;
1126 :
1127 0 : case 1:
1128 0 : if (r->info1) {
1129 0 : NDR_CHECK(ndr_push_srvsvc_NetCharDevQInfo1(ndr, NDR_SCALARS|NDR_BUFFERS, r->info1));
1130 : }
1131 0 : break;
1132 :
1133 0 : default:
1134 0 : break;
1135 :
1136 : }
1137 : }
1138 0 : return NDR_ERR_SUCCESS;
1139 : }
1140 :
1141 0 : static enum ndr_err_code ndr_pull_srvsvc_NetCharDevQInfo(struct ndr_pull *ndr, ndr_flags_type ndr_flags, union srvsvc_NetCharDevQInfo *r)
1142 : {
1143 0 : uint32_t level;
1144 0 : uint32_t _level;
1145 0 : TALLOC_CTX *_mem_save_info0_0 = NULL;
1146 0 : uint32_t _ptr_info0;
1147 0 : TALLOC_CTX *_mem_save_info1_0 = NULL;
1148 0 : uint32_t _ptr_info1;
1149 0 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
1150 0 : if (ndr_flags & NDR_SCALARS) {
1151 : /* This token is not used again (except perhaps below in the NDR_BUFFERS case) */
1152 0 : NDR_CHECK(ndr_pull_steal_switch_value(ndr, r, &level));
1153 0 : NDR_CHECK(ndr_pull_union_align(ndr, 5));
1154 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &_level));
1155 0 : if (_level != level) {
1156 0 : return ndr_pull_error(ndr, NDR_ERR_BAD_SWITCH, "Bad switch value %"PRIu32" for r at %s", (uint32_t)_level, __location__);
1157 : }
1158 0 : NDR_CHECK(ndr_pull_union_align(ndr, 5));
1159 0 : switch (level) {
1160 0 : case 0: {
1161 0 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_info0));
1162 0 : if (_ptr_info0) {
1163 0 : NDR_PULL_ALLOC(ndr, r->info0);
1164 : } else {
1165 0 : r->info0 = NULL;
1166 : }
1167 0 : break; }
1168 :
1169 0 : case 1: {
1170 0 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_info1));
1171 0 : if (_ptr_info1) {
1172 0 : NDR_PULL_ALLOC(ndr, r->info1);
1173 : } else {
1174 0 : r->info1 = NULL;
1175 : }
1176 0 : break; }
1177 :
1178 0 : default: {
1179 0 : break; }
1180 :
1181 : }
1182 : }
1183 0 : if (ndr_flags & NDR_BUFFERS) {
1184 0 : if (!(ndr_flags & NDR_SCALARS)) {
1185 : /* We didn't get it above, and the token is not needed after this. */
1186 0 : NDR_CHECK(ndr_pull_steal_switch_value(ndr, r, &level));
1187 : }
1188 0 : switch (level) {
1189 0 : case 0:
1190 0 : if (r->info0) {
1191 0 : _mem_save_info0_0 = NDR_PULL_GET_MEM_CTX(ndr);
1192 0 : NDR_PULL_SET_MEM_CTX(ndr, r->info0, 0);
1193 0 : NDR_CHECK(ndr_pull_srvsvc_NetCharDevQInfo0(ndr, NDR_SCALARS|NDR_BUFFERS, r->info0));
1194 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_info0_0, 0);
1195 : }
1196 0 : break;
1197 :
1198 0 : case 1:
1199 0 : if (r->info1) {
1200 0 : _mem_save_info1_0 = NDR_PULL_GET_MEM_CTX(ndr);
1201 0 : NDR_PULL_SET_MEM_CTX(ndr, r->info1, 0);
1202 0 : NDR_CHECK(ndr_pull_srvsvc_NetCharDevQInfo1(ndr, NDR_SCALARS|NDR_BUFFERS, r->info1));
1203 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_info1_0, 0);
1204 : }
1205 0 : break;
1206 :
1207 0 : default:
1208 0 : break;
1209 :
1210 : }
1211 : }
1212 0 : return NDR_ERR_SUCCESS;
1213 : }
1214 :
1215 0 : _PUBLIC_ void ndr_print_srvsvc_NetCharDevQInfo(struct ndr_print *ndr, const char *name, const union srvsvc_NetCharDevQInfo *r)
1216 : {
1217 0 : uint32_t level;
1218 0 : level = ndr_print_steal_switch_value(ndr, r);
1219 0 : ndr_print_union(ndr, name, level, "srvsvc_NetCharDevQInfo");
1220 0 : switch (level) {
1221 0 : case 0:
1222 0 : ndr_print_ptr(ndr, "info0", r->info0);
1223 0 : ndr->depth++;
1224 0 : if (r->info0) {
1225 0 : ndr_print_srvsvc_NetCharDevQInfo0(ndr, "info0", r->info0);
1226 : }
1227 0 : ndr->depth--;
1228 0 : break;
1229 :
1230 0 : case 1:
1231 0 : ndr_print_ptr(ndr, "info1", r->info1);
1232 0 : ndr->depth++;
1233 0 : if (r->info1) {
1234 0 : ndr_print_srvsvc_NetCharDevQInfo1(ndr, "info1", r->info1);
1235 : }
1236 0 : ndr->depth--;
1237 0 : break;
1238 :
1239 0 : default:
1240 0 : break;
1241 :
1242 : }
1243 0 : }
1244 :
1245 44 : static enum ndr_err_code ndr_push_srvsvc_NetCharDevQCtr(struct ndr_push *ndr, ndr_flags_type ndr_flags, const union srvsvc_NetCharDevQCtr *r)
1246 : {
1247 0 : uint32_t level;
1248 44 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
1249 44 : if (ndr_flags & NDR_SCALARS) {
1250 : /* This token is not used again (except perhaps below in the NDR_BUFFERS case) */
1251 22 : NDR_CHECK(ndr_push_steal_switch_value(ndr, r, &level));
1252 22 : NDR_CHECK(ndr_push_union_align(ndr, 5));
1253 22 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, level));
1254 22 : NDR_CHECK(ndr_push_union_align(ndr, 5));
1255 22 : switch (level) {
1256 13 : case 0: {
1257 13 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->ctr0));
1258 13 : break; }
1259 :
1260 9 : case 1: {
1261 9 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->ctr1));
1262 9 : break; }
1263 :
1264 0 : default: {
1265 0 : break; }
1266 :
1267 : }
1268 : }
1269 44 : if (ndr_flags & NDR_BUFFERS) {
1270 22 : if (!(ndr_flags & NDR_SCALARS)) {
1271 : /* We didn't get it above, and the token is not needed after this. */
1272 22 : NDR_CHECK(ndr_push_steal_switch_value(ndr, r, &level));
1273 : }
1274 22 : switch (level) {
1275 13 : case 0:
1276 13 : if (r->ctr0) {
1277 13 : NDR_CHECK(ndr_push_srvsvc_NetCharDevQCtr0(ndr, NDR_SCALARS|NDR_BUFFERS, r->ctr0));
1278 : }
1279 13 : break;
1280 :
1281 9 : case 1:
1282 9 : if (r->ctr1) {
1283 9 : NDR_CHECK(ndr_push_srvsvc_NetCharDevQCtr1(ndr, NDR_SCALARS|NDR_BUFFERS, r->ctr1));
1284 : }
1285 9 : break;
1286 :
1287 0 : default:
1288 0 : break;
1289 :
1290 : }
1291 : }
1292 44 : return NDR_ERR_SUCCESS;
1293 : }
1294 :
1295 40 : static enum ndr_err_code ndr_pull_srvsvc_NetCharDevQCtr(struct ndr_pull *ndr, ndr_flags_type ndr_flags, union srvsvc_NetCharDevQCtr *r)
1296 : {
1297 0 : uint32_t level;
1298 0 : uint32_t _level;
1299 40 : TALLOC_CTX *_mem_save_ctr0_0 = NULL;
1300 0 : uint32_t _ptr_ctr0;
1301 40 : TALLOC_CTX *_mem_save_ctr1_0 = NULL;
1302 0 : uint32_t _ptr_ctr1;
1303 40 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
1304 40 : if (ndr_flags & NDR_SCALARS) {
1305 : /* This token is not used again (except perhaps below in the NDR_BUFFERS case) */
1306 20 : NDR_CHECK(ndr_pull_steal_switch_value(ndr, r, &level));
1307 20 : NDR_CHECK(ndr_pull_union_align(ndr, 5));
1308 20 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &_level));
1309 20 : if (_level != level) {
1310 0 : return ndr_pull_error(ndr, NDR_ERR_BAD_SWITCH, "Bad switch value %"PRIu32" for r at %s", (uint32_t)_level, __location__);
1311 : }
1312 20 : NDR_CHECK(ndr_pull_union_align(ndr, 5));
1313 20 : switch (level) {
1314 12 : case 0: {
1315 12 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_ctr0));
1316 12 : if (_ptr_ctr0) {
1317 12 : NDR_PULL_ALLOC(ndr, r->ctr0);
1318 : } else {
1319 0 : r->ctr0 = NULL;
1320 : }
1321 12 : break; }
1322 :
1323 8 : case 1: {
1324 8 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_ctr1));
1325 8 : if (_ptr_ctr1) {
1326 8 : NDR_PULL_ALLOC(ndr, r->ctr1);
1327 : } else {
1328 0 : r->ctr1 = NULL;
1329 : }
1330 8 : break; }
1331 :
1332 0 : default: {
1333 0 : break; }
1334 :
1335 : }
1336 : }
1337 40 : if (ndr_flags & NDR_BUFFERS) {
1338 20 : if (!(ndr_flags & NDR_SCALARS)) {
1339 : /* We didn't get it above, and the token is not needed after this. */
1340 20 : NDR_CHECK(ndr_pull_steal_switch_value(ndr, r, &level));
1341 : }
1342 20 : switch (level) {
1343 12 : case 0:
1344 12 : if (r->ctr0) {
1345 12 : _mem_save_ctr0_0 = NDR_PULL_GET_MEM_CTX(ndr);
1346 12 : NDR_PULL_SET_MEM_CTX(ndr, r->ctr0, 0);
1347 12 : NDR_CHECK(ndr_pull_srvsvc_NetCharDevQCtr0(ndr, NDR_SCALARS|NDR_BUFFERS, r->ctr0));
1348 12 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_ctr0_0, 0);
1349 : }
1350 12 : break;
1351 :
1352 8 : case 1:
1353 8 : if (r->ctr1) {
1354 8 : _mem_save_ctr1_0 = NDR_PULL_GET_MEM_CTX(ndr);
1355 8 : NDR_PULL_SET_MEM_CTX(ndr, r->ctr1, 0);
1356 8 : NDR_CHECK(ndr_pull_srvsvc_NetCharDevQCtr1(ndr, NDR_SCALARS|NDR_BUFFERS, r->ctr1));
1357 8 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_ctr1_0, 0);
1358 : }
1359 8 : break;
1360 :
1361 0 : default:
1362 0 : break;
1363 :
1364 : }
1365 : }
1366 40 : return NDR_ERR_SUCCESS;
1367 : }
1368 :
1369 4 : _PUBLIC_ void ndr_print_srvsvc_NetCharDevQCtr(struct ndr_print *ndr, const char *name, const union srvsvc_NetCharDevQCtr *r)
1370 : {
1371 0 : uint32_t level;
1372 4 : level = ndr_print_steal_switch_value(ndr, r);
1373 4 : ndr_print_union(ndr, name, level, "srvsvc_NetCharDevQCtr");
1374 4 : switch (level) {
1375 2 : case 0:
1376 2 : ndr_print_ptr(ndr, "ctr0", r->ctr0);
1377 2 : ndr->depth++;
1378 2 : if (r->ctr0) {
1379 2 : ndr_print_srvsvc_NetCharDevQCtr0(ndr, "ctr0", r->ctr0);
1380 : }
1381 2 : ndr->depth--;
1382 2 : break;
1383 :
1384 2 : case 1:
1385 2 : ndr_print_ptr(ndr, "ctr1", r->ctr1);
1386 2 : ndr->depth++;
1387 2 : if (r->ctr1) {
1388 2 : ndr_print_srvsvc_NetCharDevQCtr1(ndr, "ctr1", r->ctr1);
1389 : }
1390 2 : ndr->depth--;
1391 2 : break;
1392 :
1393 0 : default:
1394 0 : break;
1395 :
1396 : }
1397 4 : }
1398 :
1399 22 : static enum ndr_err_code ndr_push_srvsvc_NetCharDevQInfoCtr(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct srvsvc_NetCharDevQInfoCtr *r)
1400 : {
1401 22 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
1402 22 : if (ndr_flags & NDR_SCALARS) {
1403 22 : NDR_CHECK(ndr_push_align(ndr, 5));
1404 22 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->level));
1405 22 : NDR_CHECK(ndr_push_set_switch_value(ndr, &r->ctr, r->level));
1406 22 : NDR_CHECK(ndr_push_srvsvc_NetCharDevQCtr(ndr, NDR_SCALARS, &r->ctr));
1407 22 : NDR_CHECK(ndr_push_trailer_align(ndr, 5));
1408 : }
1409 22 : if (ndr_flags & NDR_BUFFERS) {
1410 22 : NDR_CHECK(ndr_push_set_switch_value(ndr, &r->ctr, r->level));
1411 22 : NDR_CHECK(ndr_push_srvsvc_NetCharDevQCtr(ndr, NDR_BUFFERS, &r->ctr));
1412 : }
1413 22 : return NDR_ERR_SUCCESS;
1414 : }
1415 :
1416 20 : static enum ndr_err_code ndr_pull_srvsvc_NetCharDevQInfoCtr(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct srvsvc_NetCharDevQInfoCtr *r)
1417 : {
1418 20 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
1419 20 : if (ndr_flags & NDR_SCALARS) {
1420 20 : NDR_CHECK(ndr_pull_align(ndr, 5));
1421 20 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->level));
1422 20 : NDR_CHECK(ndr_pull_set_switch_value(ndr, &r->ctr, r->level));
1423 20 : NDR_CHECK(ndr_pull_srvsvc_NetCharDevQCtr(ndr, NDR_SCALARS, &r->ctr));
1424 20 : NDR_CHECK(ndr_pull_trailer_align(ndr, 5));
1425 : }
1426 20 : if (ndr_flags & NDR_BUFFERS) {
1427 20 : NDR_CHECK(ndr_pull_set_switch_value(ndr, &r->ctr, r->level));
1428 20 : NDR_CHECK(ndr_pull_srvsvc_NetCharDevQCtr(ndr, NDR_BUFFERS, &r->ctr));
1429 : }
1430 20 : return NDR_ERR_SUCCESS;
1431 : }
1432 :
1433 4 : _PUBLIC_ void ndr_print_srvsvc_NetCharDevQInfoCtr(struct ndr_print *ndr, const char *name, const struct srvsvc_NetCharDevQInfoCtr *r)
1434 : {
1435 4 : ndr_print_struct(ndr, name, "srvsvc_NetCharDevQInfoCtr");
1436 4 : if (r == NULL) { ndr_print_null(ndr); return; }
1437 4 : ndr->depth++;
1438 4 : ndr_print_uint32(ndr, "level", r->level);
1439 4 : ndr_print_set_switch_value(ndr, &r->ctr, r->level);
1440 4 : ndr_print_srvsvc_NetCharDevQCtr(ndr, "ctr", &r->ctr);
1441 4 : ndr->depth--;
1442 : }
1443 :
1444 4 : static enum ndr_err_code ndr_push_srvsvc_NetConnInfo0(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct srvsvc_NetConnInfo0 *r)
1445 : {
1446 4 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
1447 4 : if (ndr_flags & NDR_SCALARS) {
1448 4 : NDR_CHECK(ndr_push_align(ndr, 4));
1449 4 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->conn_id));
1450 4 : NDR_CHECK(ndr_push_trailer_align(ndr, 4));
1451 : }
1452 4 : if (ndr_flags & NDR_BUFFERS) {
1453 0 : }
1454 4 : return NDR_ERR_SUCCESS;
1455 : }
1456 :
1457 4 : static enum ndr_err_code ndr_pull_srvsvc_NetConnInfo0(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct srvsvc_NetConnInfo0 *r)
1458 : {
1459 4 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
1460 4 : if (ndr_flags & NDR_SCALARS) {
1461 4 : NDR_CHECK(ndr_pull_align(ndr, 4));
1462 4 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->conn_id));
1463 4 : NDR_CHECK(ndr_pull_trailer_align(ndr, 4));
1464 : }
1465 4 : if (ndr_flags & NDR_BUFFERS) {
1466 0 : }
1467 4 : return NDR_ERR_SUCCESS;
1468 : }
1469 :
1470 0 : _PUBLIC_ void ndr_print_srvsvc_NetConnInfo0(struct ndr_print *ndr, const char *name, const struct srvsvc_NetConnInfo0 *r)
1471 : {
1472 0 : ndr_print_struct(ndr, name, "srvsvc_NetConnInfo0");
1473 0 : if (r == NULL) { ndr_print_null(ndr); return; }
1474 0 : ndr->depth++;
1475 0 : ndr_print_uint32(ndr, "conn_id", r->conn_id);
1476 0 : ndr->depth--;
1477 : }
1478 :
1479 17 : static enum ndr_err_code ndr_push_srvsvc_NetConnCtr0(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct srvsvc_NetConnCtr0 *r)
1480 : {
1481 0 : uint32_t cntr_array_1;
1482 17 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
1483 17 : if (ndr_flags & NDR_SCALARS) {
1484 17 : NDR_CHECK(ndr_push_align(ndr, 5));
1485 17 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->count));
1486 17 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->array));
1487 17 : NDR_CHECK(ndr_push_trailer_align(ndr, 5));
1488 : }
1489 17 : if (ndr_flags & NDR_BUFFERS) {
1490 17 : if (r->array) {
1491 4 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, r->count));
1492 8 : for (cntr_array_1 = 0; cntr_array_1 < (r->count); cntr_array_1++) {
1493 4 : NDR_CHECK(ndr_push_srvsvc_NetConnInfo0(ndr, NDR_SCALARS, &r->array[cntr_array_1]));
1494 : }
1495 : }
1496 : }
1497 17 : return NDR_ERR_SUCCESS;
1498 : }
1499 :
1500 16 : static enum ndr_err_code ndr_pull_srvsvc_NetConnCtr0(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct srvsvc_NetConnCtr0 *r)
1501 : {
1502 0 : uint32_t _ptr_array;
1503 16 : uint32_t size_array_1 = 0;
1504 0 : uint32_t cntr_array_1;
1505 16 : TALLOC_CTX *_mem_save_array_0 = NULL;
1506 16 : TALLOC_CTX *_mem_save_array_1 = NULL;
1507 16 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
1508 16 : if (ndr_flags & NDR_SCALARS) {
1509 16 : NDR_CHECK(ndr_pull_align(ndr, 5));
1510 16 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->count));
1511 16 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_array));
1512 16 : if (_ptr_array) {
1513 4 : NDR_PULL_ALLOC(ndr, r->array);
1514 : } else {
1515 12 : r->array = NULL;
1516 : }
1517 16 : NDR_CHECK(ndr_pull_trailer_align(ndr, 5));
1518 : }
1519 16 : if (ndr_flags & NDR_BUFFERS) {
1520 16 : if (r->array) {
1521 4 : _mem_save_array_0 = NDR_PULL_GET_MEM_CTX(ndr);
1522 4 : NDR_PULL_SET_MEM_CTX(ndr, r->array, 0);
1523 4 : NDR_CHECK(ndr_pull_array_size(ndr, &r->array));
1524 4 : NDR_CHECK(ndr_get_array_size(ndr, (void*)&r->array, &size_array_1));
1525 4 : NDR_PULL_ALLOC_N(ndr, r->array, size_array_1);
1526 4 : _mem_save_array_1 = NDR_PULL_GET_MEM_CTX(ndr);
1527 4 : NDR_PULL_SET_MEM_CTX(ndr, r->array, 0);
1528 8 : for (cntr_array_1 = 0; cntr_array_1 < (size_array_1); cntr_array_1++) {
1529 4 : NDR_CHECK(ndr_pull_srvsvc_NetConnInfo0(ndr, NDR_SCALARS, &r->array[cntr_array_1]));
1530 : }
1531 4 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_array_1, 0);
1532 4 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_array_0, 0);
1533 : }
1534 16 : if (r->array) {
1535 4 : NDR_CHECK(ndr_check_steal_array_size(ndr, (void*)&r->array, r->count));
1536 : }
1537 : }
1538 16 : return NDR_ERR_SUCCESS;
1539 : }
1540 :
1541 2 : _PUBLIC_ void ndr_print_srvsvc_NetConnCtr0(struct ndr_print *ndr, const char *name, const struct srvsvc_NetConnCtr0 *r)
1542 : {
1543 0 : uint32_t cntr_array_1;
1544 2 : ndr_print_struct(ndr, name, "srvsvc_NetConnCtr0");
1545 2 : if (r == NULL) { ndr_print_null(ndr); return; }
1546 2 : ndr->depth++;
1547 2 : ndr_print_uint32(ndr, "count", r->count);
1548 2 : ndr_print_ptr(ndr, "array", r->array);
1549 2 : ndr->depth++;
1550 2 : if (r->array) {
1551 0 : ndr->print(ndr, "%s: ARRAY(%"PRIu32")", "array", (uint32_t)(r->count));
1552 0 : ndr->depth++;
1553 0 : for (cntr_array_1 = 0; cntr_array_1 < (r->count); cntr_array_1++) {
1554 0 : ndr_print_srvsvc_NetConnInfo0(ndr, "array", &r->array[cntr_array_1]);
1555 : }
1556 0 : ndr->depth--;
1557 : }
1558 2 : ndr->depth--;
1559 2 : ndr->depth--;
1560 : }
1561 :
1562 8 : static enum ndr_err_code ndr_push_srvsvc_NetConnInfo1(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct srvsvc_NetConnInfo1 *r)
1563 : {
1564 8 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
1565 8 : if (ndr_flags & NDR_SCALARS) {
1566 4 : NDR_CHECK(ndr_push_align(ndr, 5));
1567 4 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->conn_id));
1568 4 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->conn_type));
1569 4 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->num_open));
1570 4 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->num_users));
1571 4 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->conn_time));
1572 4 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->user));
1573 4 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->share));
1574 4 : NDR_CHECK(ndr_push_trailer_align(ndr, 5));
1575 : }
1576 8 : if (ndr_flags & NDR_BUFFERS) {
1577 4 : if (r->user) {
1578 4 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->user, CH_UTF16)));
1579 4 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, 0));
1580 4 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->user, CH_UTF16)));
1581 4 : NDR_CHECK(ndr_push_charset(ndr, NDR_SCALARS, r->user, ndr_charset_length(r->user, CH_UTF16), sizeof(uint16_t), CH_UTF16));
1582 : }
1583 4 : if (r->share) {
1584 4 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->share, CH_UTF16)));
1585 4 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, 0));
1586 4 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->share, CH_UTF16)));
1587 4 : NDR_CHECK(ndr_push_charset(ndr, NDR_SCALARS, r->share, ndr_charset_length(r->share, CH_UTF16), sizeof(uint16_t), CH_UTF16));
1588 : }
1589 : }
1590 8 : return NDR_ERR_SUCCESS;
1591 : }
1592 :
1593 8 : static enum ndr_err_code ndr_pull_srvsvc_NetConnInfo1(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct srvsvc_NetConnInfo1 *r)
1594 : {
1595 0 : uint32_t _ptr_user;
1596 8 : uint32_t size_user_1 = 0;
1597 8 : uint32_t length_user_1 = 0;
1598 8 : TALLOC_CTX *_mem_save_user_0 = NULL;
1599 0 : uint32_t _ptr_share;
1600 8 : uint32_t size_share_1 = 0;
1601 8 : uint32_t length_share_1 = 0;
1602 8 : TALLOC_CTX *_mem_save_share_0 = NULL;
1603 8 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
1604 8 : if (ndr_flags & NDR_SCALARS) {
1605 4 : NDR_CHECK(ndr_pull_align(ndr, 5));
1606 4 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->conn_id));
1607 4 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->conn_type));
1608 4 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->num_open));
1609 4 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->num_users));
1610 4 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->conn_time));
1611 4 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_user));
1612 4 : if (_ptr_user) {
1613 4 : NDR_PULL_ALLOC(ndr, r->user);
1614 : } else {
1615 0 : r->user = NULL;
1616 : }
1617 4 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_share));
1618 4 : if (_ptr_share) {
1619 4 : NDR_PULL_ALLOC(ndr, r->share);
1620 : } else {
1621 0 : r->share = NULL;
1622 : }
1623 4 : NDR_CHECK(ndr_pull_trailer_align(ndr, 5));
1624 : }
1625 8 : if (ndr_flags & NDR_BUFFERS) {
1626 4 : if (r->user) {
1627 4 : _mem_save_user_0 = NDR_PULL_GET_MEM_CTX(ndr);
1628 4 : NDR_PULL_SET_MEM_CTX(ndr, r->user, 0);
1629 4 : NDR_CHECK(ndr_pull_array_size(ndr, &r->user));
1630 4 : NDR_CHECK(ndr_pull_array_length(ndr, &r->user));
1631 4 : NDR_CHECK(ndr_steal_array_size(ndr, (void*)&r->user, &size_user_1));
1632 4 : NDR_CHECK(ndr_steal_array_length(ndr, (void*)&r->user, &length_user_1));
1633 4 : if (length_user_1 > size_user_1) {
1634 0 : return ndr_pull_error(ndr, NDR_ERR_ARRAY_SIZE, "Bad array size %"PRIu32": should exceed array length %"PRIu32"", size_user_1, length_user_1);
1635 : }
1636 4 : NDR_CHECK(ndr_check_string_terminator(ndr, length_user_1, sizeof(uint16_t)));
1637 4 : NDR_CHECK(ndr_pull_charset(ndr, NDR_SCALARS, &r->user, length_user_1, sizeof(uint16_t), CH_UTF16));
1638 4 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_user_0, 0);
1639 : }
1640 4 : if (r->share) {
1641 4 : _mem_save_share_0 = NDR_PULL_GET_MEM_CTX(ndr);
1642 4 : NDR_PULL_SET_MEM_CTX(ndr, r->share, 0);
1643 4 : NDR_CHECK(ndr_pull_array_size(ndr, &r->share));
1644 4 : NDR_CHECK(ndr_pull_array_length(ndr, &r->share));
1645 4 : NDR_CHECK(ndr_steal_array_size(ndr, (void*)&r->share, &size_share_1));
1646 4 : NDR_CHECK(ndr_steal_array_length(ndr, (void*)&r->share, &length_share_1));
1647 4 : if (length_share_1 > size_share_1) {
1648 0 : return ndr_pull_error(ndr, NDR_ERR_ARRAY_SIZE, "Bad array size %"PRIu32": should exceed array length %"PRIu32"", size_share_1, length_share_1);
1649 : }
1650 4 : NDR_CHECK(ndr_check_string_terminator(ndr, length_share_1, sizeof(uint16_t)));
1651 4 : NDR_CHECK(ndr_pull_charset(ndr, NDR_SCALARS, &r->share, length_share_1, sizeof(uint16_t), CH_UTF16));
1652 4 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_share_0, 0);
1653 : }
1654 : }
1655 8 : return NDR_ERR_SUCCESS;
1656 : }
1657 :
1658 0 : _PUBLIC_ void ndr_print_srvsvc_NetConnInfo1(struct ndr_print *ndr, const char *name, const struct srvsvc_NetConnInfo1 *r)
1659 : {
1660 0 : ndr_print_struct(ndr, name, "srvsvc_NetConnInfo1");
1661 0 : if (r == NULL) { ndr_print_null(ndr); return; }
1662 0 : ndr->depth++;
1663 0 : ndr_print_uint32(ndr, "conn_id", r->conn_id);
1664 0 : ndr_print_uint32(ndr, "conn_type", r->conn_type);
1665 0 : ndr_print_uint32(ndr, "num_open", r->num_open);
1666 0 : ndr_print_uint32(ndr, "num_users", r->num_users);
1667 0 : ndr_print_uint32(ndr, "conn_time", r->conn_time);
1668 0 : ndr_print_ptr(ndr, "user", r->user);
1669 0 : ndr->depth++;
1670 0 : if (r->user) {
1671 0 : ndr_print_string(ndr, "user", r->user);
1672 : }
1673 0 : ndr->depth--;
1674 0 : ndr_print_ptr(ndr, "share", r->share);
1675 0 : ndr->depth++;
1676 0 : if (r->share) {
1677 0 : ndr_print_string(ndr, "share", r->share);
1678 : }
1679 0 : ndr->depth--;
1680 0 : ndr->depth--;
1681 : }
1682 :
1683 17 : static enum ndr_err_code ndr_push_srvsvc_NetConnCtr1(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct srvsvc_NetConnCtr1 *r)
1684 : {
1685 0 : uint32_t cntr_array_1;
1686 17 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
1687 17 : if (ndr_flags & NDR_SCALARS) {
1688 17 : NDR_CHECK(ndr_push_align(ndr, 5));
1689 17 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->count));
1690 17 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->array));
1691 17 : NDR_CHECK(ndr_push_trailer_align(ndr, 5));
1692 : }
1693 17 : if (ndr_flags & NDR_BUFFERS) {
1694 17 : if (r->array) {
1695 4 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, r->count));
1696 8 : for (cntr_array_1 = 0; cntr_array_1 < (r->count); cntr_array_1++) {
1697 4 : NDR_CHECK(ndr_push_srvsvc_NetConnInfo1(ndr, NDR_SCALARS, &r->array[cntr_array_1]));
1698 : }
1699 8 : for (cntr_array_1 = 0; cntr_array_1 < (r->count); cntr_array_1++) {
1700 4 : NDR_CHECK(ndr_push_srvsvc_NetConnInfo1(ndr, NDR_BUFFERS, &r->array[cntr_array_1]));
1701 : }
1702 : }
1703 : }
1704 17 : return NDR_ERR_SUCCESS;
1705 : }
1706 :
1707 16 : static enum ndr_err_code ndr_pull_srvsvc_NetConnCtr1(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct srvsvc_NetConnCtr1 *r)
1708 : {
1709 0 : uint32_t _ptr_array;
1710 16 : uint32_t size_array_1 = 0;
1711 0 : uint32_t cntr_array_1;
1712 16 : TALLOC_CTX *_mem_save_array_0 = NULL;
1713 16 : TALLOC_CTX *_mem_save_array_1 = NULL;
1714 16 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
1715 16 : if (ndr_flags & NDR_SCALARS) {
1716 16 : NDR_CHECK(ndr_pull_align(ndr, 5));
1717 16 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->count));
1718 16 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_array));
1719 16 : if (_ptr_array) {
1720 4 : NDR_PULL_ALLOC(ndr, r->array);
1721 : } else {
1722 12 : r->array = NULL;
1723 : }
1724 16 : NDR_CHECK(ndr_pull_trailer_align(ndr, 5));
1725 : }
1726 16 : if (ndr_flags & NDR_BUFFERS) {
1727 16 : if (r->array) {
1728 4 : _mem_save_array_0 = NDR_PULL_GET_MEM_CTX(ndr);
1729 4 : NDR_PULL_SET_MEM_CTX(ndr, r->array, 0);
1730 4 : NDR_CHECK(ndr_pull_array_size(ndr, &r->array));
1731 4 : NDR_CHECK(ndr_get_array_size(ndr, (void*)&r->array, &size_array_1));
1732 4 : NDR_PULL_ALLOC_N(ndr, r->array, size_array_1);
1733 4 : _mem_save_array_1 = NDR_PULL_GET_MEM_CTX(ndr);
1734 4 : NDR_PULL_SET_MEM_CTX(ndr, r->array, 0);
1735 8 : for (cntr_array_1 = 0; cntr_array_1 < (size_array_1); cntr_array_1++) {
1736 4 : NDR_CHECK(ndr_pull_srvsvc_NetConnInfo1(ndr, NDR_SCALARS, &r->array[cntr_array_1]));
1737 : }
1738 8 : for (cntr_array_1 = 0; cntr_array_1 < (size_array_1); cntr_array_1++) {
1739 4 : NDR_CHECK(ndr_pull_srvsvc_NetConnInfo1(ndr, NDR_BUFFERS, &r->array[cntr_array_1]));
1740 : }
1741 4 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_array_1, 0);
1742 4 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_array_0, 0);
1743 : }
1744 16 : if (r->array) {
1745 4 : NDR_CHECK(ndr_check_array_size(ndr, (void*)&r->array, r->count));
1746 : }
1747 20 : for (cntr_array_1 = 0; cntr_array_1 < (size_array_1); cntr_array_1++) {
1748 0 : }
1749 : }
1750 16 : return NDR_ERR_SUCCESS;
1751 : }
1752 :
1753 2 : _PUBLIC_ void ndr_print_srvsvc_NetConnCtr1(struct ndr_print *ndr, const char *name, const struct srvsvc_NetConnCtr1 *r)
1754 : {
1755 0 : uint32_t cntr_array_1;
1756 2 : ndr_print_struct(ndr, name, "srvsvc_NetConnCtr1");
1757 2 : if (r == NULL) { ndr_print_null(ndr); return; }
1758 2 : ndr->depth++;
1759 2 : ndr_print_uint32(ndr, "count", r->count);
1760 2 : ndr_print_ptr(ndr, "array", r->array);
1761 2 : ndr->depth++;
1762 2 : if (r->array) {
1763 0 : ndr->print(ndr, "%s: ARRAY(%"PRIu32")", "array", (uint32_t)(r->count));
1764 0 : ndr->depth++;
1765 0 : for (cntr_array_1 = 0; cntr_array_1 < (r->count); cntr_array_1++) {
1766 0 : ndr_print_srvsvc_NetConnInfo1(ndr, "array", &r->array[cntr_array_1]);
1767 : }
1768 0 : ndr->depth--;
1769 : }
1770 2 : ndr->depth--;
1771 2 : ndr->depth--;
1772 : }
1773 :
1774 68 : static enum ndr_err_code ndr_push_srvsvc_NetConnCtr(struct ndr_push *ndr, ndr_flags_type ndr_flags, const union srvsvc_NetConnCtr *r)
1775 : {
1776 0 : uint32_t level;
1777 68 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
1778 68 : if (ndr_flags & NDR_SCALARS) {
1779 : /* This token is not used again (except perhaps below in the NDR_BUFFERS case) */
1780 34 : NDR_CHECK(ndr_push_steal_switch_value(ndr, r, &level));
1781 34 : NDR_CHECK(ndr_push_union_align(ndr, 5));
1782 34 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, level));
1783 34 : NDR_CHECK(ndr_push_union_align(ndr, 5));
1784 34 : switch (level) {
1785 17 : case 0: {
1786 17 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->ctr0));
1787 17 : break; }
1788 :
1789 17 : case 1: {
1790 17 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->ctr1));
1791 17 : break; }
1792 :
1793 0 : default: {
1794 0 : break; }
1795 :
1796 : }
1797 : }
1798 68 : if (ndr_flags & NDR_BUFFERS) {
1799 34 : if (!(ndr_flags & NDR_SCALARS)) {
1800 : /* We didn't get it above, and the token is not needed after this. */
1801 34 : NDR_CHECK(ndr_push_steal_switch_value(ndr, r, &level));
1802 : }
1803 34 : switch (level) {
1804 17 : case 0:
1805 17 : if (r->ctr0) {
1806 17 : NDR_CHECK(ndr_push_srvsvc_NetConnCtr0(ndr, NDR_SCALARS|NDR_BUFFERS, r->ctr0));
1807 : }
1808 17 : break;
1809 :
1810 17 : case 1:
1811 17 : if (r->ctr1) {
1812 17 : NDR_CHECK(ndr_push_srvsvc_NetConnCtr1(ndr, NDR_SCALARS|NDR_BUFFERS, r->ctr1));
1813 : }
1814 17 : break;
1815 :
1816 0 : default:
1817 0 : break;
1818 :
1819 : }
1820 : }
1821 68 : return NDR_ERR_SUCCESS;
1822 : }
1823 :
1824 64 : static enum ndr_err_code ndr_pull_srvsvc_NetConnCtr(struct ndr_pull *ndr, ndr_flags_type ndr_flags, union srvsvc_NetConnCtr *r)
1825 : {
1826 0 : uint32_t level;
1827 0 : uint32_t _level;
1828 64 : TALLOC_CTX *_mem_save_ctr0_0 = NULL;
1829 0 : uint32_t _ptr_ctr0;
1830 64 : TALLOC_CTX *_mem_save_ctr1_0 = NULL;
1831 0 : uint32_t _ptr_ctr1;
1832 64 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
1833 64 : if (ndr_flags & NDR_SCALARS) {
1834 : /* This token is not used again (except perhaps below in the NDR_BUFFERS case) */
1835 32 : NDR_CHECK(ndr_pull_steal_switch_value(ndr, r, &level));
1836 32 : NDR_CHECK(ndr_pull_union_align(ndr, 5));
1837 32 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &_level));
1838 32 : if (_level != level) {
1839 0 : return ndr_pull_error(ndr, NDR_ERR_BAD_SWITCH, "Bad switch value %"PRIu32" for r at %s", (uint32_t)_level, __location__);
1840 : }
1841 32 : NDR_CHECK(ndr_pull_union_align(ndr, 5));
1842 32 : switch (level) {
1843 16 : case 0: {
1844 16 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_ctr0));
1845 16 : if (_ptr_ctr0) {
1846 16 : NDR_PULL_ALLOC(ndr, r->ctr0);
1847 : } else {
1848 0 : r->ctr0 = NULL;
1849 : }
1850 16 : break; }
1851 :
1852 16 : case 1: {
1853 16 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_ctr1));
1854 16 : if (_ptr_ctr1) {
1855 16 : NDR_PULL_ALLOC(ndr, r->ctr1);
1856 : } else {
1857 0 : r->ctr1 = NULL;
1858 : }
1859 16 : break; }
1860 :
1861 0 : default: {
1862 0 : break; }
1863 :
1864 : }
1865 : }
1866 64 : if (ndr_flags & NDR_BUFFERS) {
1867 32 : if (!(ndr_flags & NDR_SCALARS)) {
1868 : /* We didn't get it above, and the token is not needed after this. */
1869 32 : NDR_CHECK(ndr_pull_steal_switch_value(ndr, r, &level));
1870 : }
1871 32 : switch (level) {
1872 16 : case 0:
1873 16 : if (r->ctr0) {
1874 16 : _mem_save_ctr0_0 = NDR_PULL_GET_MEM_CTX(ndr);
1875 16 : NDR_PULL_SET_MEM_CTX(ndr, r->ctr0, 0);
1876 16 : NDR_CHECK(ndr_pull_srvsvc_NetConnCtr0(ndr, NDR_SCALARS|NDR_BUFFERS, r->ctr0));
1877 16 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_ctr0_0, 0);
1878 : }
1879 16 : break;
1880 :
1881 16 : case 1:
1882 16 : if (r->ctr1) {
1883 16 : _mem_save_ctr1_0 = NDR_PULL_GET_MEM_CTX(ndr);
1884 16 : NDR_PULL_SET_MEM_CTX(ndr, r->ctr1, 0);
1885 16 : NDR_CHECK(ndr_pull_srvsvc_NetConnCtr1(ndr, NDR_SCALARS|NDR_BUFFERS, r->ctr1));
1886 16 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_ctr1_0, 0);
1887 : }
1888 16 : break;
1889 :
1890 0 : default:
1891 0 : break;
1892 :
1893 : }
1894 : }
1895 64 : return NDR_ERR_SUCCESS;
1896 : }
1897 :
1898 4 : _PUBLIC_ void ndr_print_srvsvc_NetConnCtr(struct ndr_print *ndr, const char *name, const union srvsvc_NetConnCtr *r)
1899 : {
1900 0 : uint32_t level;
1901 4 : level = ndr_print_steal_switch_value(ndr, r);
1902 4 : ndr_print_union(ndr, name, level, "srvsvc_NetConnCtr");
1903 4 : switch (level) {
1904 2 : case 0:
1905 2 : ndr_print_ptr(ndr, "ctr0", r->ctr0);
1906 2 : ndr->depth++;
1907 2 : if (r->ctr0) {
1908 2 : ndr_print_srvsvc_NetConnCtr0(ndr, "ctr0", r->ctr0);
1909 : }
1910 2 : ndr->depth--;
1911 2 : break;
1912 :
1913 2 : case 1:
1914 2 : ndr_print_ptr(ndr, "ctr1", r->ctr1);
1915 2 : ndr->depth++;
1916 2 : if (r->ctr1) {
1917 2 : ndr_print_srvsvc_NetConnCtr1(ndr, "ctr1", r->ctr1);
1918 : }
1919 2 : ndr->depth--;
1920 2 : break;
1921 :
1922 0 : default:
1923 0 : break;
1924 :
1925 : }
1926 4 : }
1927 :
1928 34 : static enum ndr_err_code ndr_push_srvsvc_NetConnInfoCtr(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct srvsvc_NetConnInfoCtr *r)
1929 : {
1930 34 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
1931 34 : if (ndr_flags & NDR_SCALARS) {
1932 34 : NDR_CHECK(ndr_push_align(ndr, 5));
1933 34 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->level));
1934 34 : NDR_CHECK(ndr_push_set_switch_value(ndr, &r->ctr, r->level));
1935 34 : NDR_CHECK(ndr_push_srvsvc_NetConnCtr(ndr, NDR_SCALARS, &r->ctr));
1936 34 : NDR_CHECK(ndr_push_trailer_align(ndr, 5));
1937 : }
1938 34 : if (ndr_flags & NDR_BUFFERS) {
1939 34 : NDR_CHECK(ndr_push_set_switch_value(ndr, &r->ctr, r->level));
1940 34 : NDR_CHECK(ndr_push_srvsvc_NetConnCtr(ndr, NDR_BUFFERS, &r->ctr));
1941 : }
1942 34 : return NDR_ERR_SUCCESS;
1943 : }
1944 :
1945 32 : static enum ndr_err_code ndr_pull_srvsvc_NetConnInfoCtr(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct srvsvc_NetConnInfoCtr *r)
1946 : {
1947 32 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
1948 32 : if (ndr_flags & NDR_SCALARS) {
1949 32 : NDR_CHECK(ndr_pull_align(ndr, 5));
1950 32 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->level));
1951 32 : NDR_CHECK(ndr_pull_set_switch_value(ndr, &r->ctr, r->level));
1952 32 : NDR_CHECK(ndr_pull_srvsvc_NetConnCtr(ndr, NDR_SCALARS, &r->ctr));
1953 32 : NDR_CHECK(ndr_pull_trailer_align(ndr, 5));
1954 : }
1955 32 : if (ndr_flags & NDR_BUFFERS) {
1956 32 : NDR_CHECK(ndr_pull_set_switch_value(ndr, &r->ctr, r->level));
1957 32 : NDR_CHECK(ndr_pull_srvsvc_NetConnCtr(ndr, NDR_BUFFERS, &r->ctr));
1958 : }
1959 32 : return NDR_ERR_SUCCESS;
1960 : }
1961 :
1962 4 : _PUBLIC_ void ndr_print_srvsvc_NetConnInfoCtr(struct ndr_print *ndr, const char *name, const struct srvsvc_NetConnInfoCtr *r)
1963 : {
1964 4 : ndr_print_struct(ndr, name, "srvsvc_NetConnInfoCtr");
1965 4 : if (r == NULL) { ndr_print_null(ndr); return; }
1966 4 : ndr->depth++;
1967 4 : ndr_print_uint32(ndr, "level", r->level);
1968 4 : ndr_print_set_switch_value(ndr, &r->ctr, r->level);
1969 4 : ndr_print_srvsvc_NetConnCtr(ndr, "ctr", &r->ctr);
1970 4 : ndr->depth--;
1971 : }
1972 :
1973 0 : static enum ndr_err_code ndr_push_srvsvc_NetFileInfo2(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct srvsvc_NetFileInfo2 *r)
1974 : {
1975 0 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
1976 0 : if (ndr_flags & NDR_SCALARS) {
1977 0 : NDR_CHECK(ndr_push_align(ndr, 4));
1978 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->fid));
1979 0 : NDR_CHECK(ndr_push_trailer_align(ndr, 4));
1980 : }
1981 0 : if (ndr_flags & NDR_BUFFERS) {
1982 0 : }
1983 0 : return NDR_ERR_SUCCESS;
1984 : }
1985 :
1986 0 : static enum ndr_err_code ndr_pull_srvsvc_NetFileInfo2(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct srvsvc_NetFileInfo2 *r)
1987 : {
1988 0 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
1989 0 : if (ndr_flags & NDR_SCALARS) {
1990 0 : NDR_CHECK(ndr_pull_align(ndr, 4));
1991 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->fid));
1992 0 : NDR_CHECK(ndr_pull_trailer_align(ndr, 4));
1993 : }
1994 0 : if (ndr_flags & NDR_BUFFERS) {
1995 0 : }
1996 0 : return NDR_ERR_SUCCESS;
1997 : }
1998 :
1999 0 : _PUBLIC_ void ndr_print_srvsvc_NetFileInfo2(struct ndr_print *ndr, const char *name, const struct srvsvc_NetFileInfo2 *r)
2000 : {
2001 0 : ndr_print_struct(ndr, name, "srvsvc_NetFileInfo2");
2002 0 : if (r == NULL) { ndr_print_null(ndr); return; }
2003 0 : ndr->depth++;
2004 0 : ndr_print_uint32(ndr, "fid", r->fid);
2005 0 : ndr->depth--;
2006 : }
2007 :
2008 17 : static enum ndr_err_code ndr_push_srvsvc_NetFileCtr2(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct srvsvc_NetFileCtr2 *r)
2009 : {
2010 0 : uint32_t cntr_array_1;
2011 17 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
2012 17 : if (ndr_flags & NDR_SCALARS) {
2013 17 : NDR_CHECK(ndr_push_align(ndr, 5));
2014 17 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->count));
2015 17 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->array));
2016 17 : NDR_CHECK(ndr_push_trailer_align(ndr, 5));
2017 : }
2018 17 : if (ndr_flags & NDR_BUFFERS) {
2019 17 : if (r->array) {
2020 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, r->count));
2021 0 : for (cntr_array_1 = 0; cntr_array_1 < (r->count); cntr_array_1++) {
2022 0 : NDR_CHECK(ndr_push_srvsvc_NetFileInfo2(ndr, NDR_SCALARS, &r->array[cntr_array_1]));
2023 : }
2024 : }
2025 : }
2026 17 : return NDR_ERR_SUCCESS;
2027 : }
2028 :
2029 16 : static enum ndr_err_code ndr_pull_srvsvc_NetFileCtr2(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct srvsvc_NetFileCtr2 *r)
2030 : {
2031 0 : uint32_t _ptr_array;
2032 16 : uint32_t size_array_1 = 0;
2033 0 : uint32_t cntr_array_1;
2034 16 : TALLOC_CTX *_mem_save_array_0 = NULL;
2035 16 : TALLOC_CTX *_mem_save_array_1 = NULL;
2036 16 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
2037 16 : if (ndr_flags & NDR_SCALARS) {
2038 16 : NDR_CHECK(ndr_pull_align(ndr, 5));
2039 16 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->count));
2040 16 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_array));
2041 16 : if (_ptr_array) {
2042 0 : NDR_PULL_ALLOC(ndr, r->array);
2043 : } else {
2044 16 : r->array = NULL;
2045 : }
2046 16 : NDR_CHECK(ndr_pull_trailer_align(ndr, 5));
2047 : }
2048 16 : if (ndr_flags & NDR_BUFFERS) {
2049 16 : if (r->array) {
2050 0 : _mem_save_array_0 = NDR_PULL_GET_MEM_CTX(ndr);
2051 0 : NDR_PULL_SET_MEM_CTX(ndr, r->array, 0);
2052 0 : NDR_CHECK(ndr_pull_array_size(ndr, &r->array));
2053 0 : NDR_CHECK(ndr_get_array_size(ndr, (void*)&r->array, &size_array_1));
2054 0 : NDR_PULL_ALLOC_N(ndr, r->array, size_array_1);
2055 0 : _mem_save_array_1 = NDR_PULL_GET_MEM_CTX(ndr);
2056 0 : NDR_PULL_SET_MEM_CTX(ndr, r->array, 0);
2057 0 : for (cntr_array_1 = 0; cntr_array_1 < (size_array_1); cntr_array_1++) {
2058 0 : NDR_CHECK(ndr_pull_srvsvc_NetFileInfo2(ndr, NDR_SCALARS, &r->array[cntr_array_1]));
2059 : }
2060 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_array_1, 0);
2061 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_array_0, 0);
2062 : }
2063 16 : if (r->array) {
2064 0 : NDR_CHECK(ndr_check_steal_array_size(ndr, (void*)&r->array, r->count));
2065 : }
2066 : }
2067 16 : return NDR_ERR_SUCCESS;
2068 : }
2069 :
2070 2 : _PUBLIC_ void ndr_print_srvsvc_NetFileCtr2(struct ndr_print *ndr, const char *name, const struct srvsvc_NetFileCtr2 *r)
2071 : {
2072 0 : uint32_t cntr_array_1;
2073 2 : ndr_print_struct(ndr, name, "srvsvc_NetFileCtr2");
2074 2 : if (r == NULL) { ndr_print_null(ndr); return; }
2075 2 : ndr->depth++;
2076 2 : ndr_print_uint32(ndr, "count", r->count);
2077 2 : ndr_print_ptr(ndr, "array", r->array);
2078 2 : ndr->depth++;
2079 2 : if (r->array) {
2080 0 : ndr->print(ndr, "%s: ARRAY(%"PRIu32")", "array", (uint32_t)(r->count));
2081 0 : ndr->depth++;
2082 0 : for (cntr_array_1 = 0; cntr_array_1 < (r->count); cntr_array_1++) {
2083 0 : ndr_print_srvsvc_NetFileInfo2(ndr, "array", &r->array[cntr_array_1]);
2084 : }
2085 0 : ndr->depth--;
2086 : }
2087 2 : ndr->depth--;
2088 2 : ndr->depth--;
2089 : }
2090 :
2091 4 : static enum ndr_err_code ndr_push_srvsvc_NetFileInfo3(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct srvsvc_NetFileInfo3 *r)
2092 : {
2093 4 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
2094 4 : if (ndr_flags & NDR_SCALARS) {
2095 2 : NDR_CHECK(ndr_push_align(ndr, 5));
2096 2 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->fid));
2097 2 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->permissions));
2098 2 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->num_locks));
2099 2 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->path));
2100 2 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->user));
2101 2 : NDR_CHECK(ndr_push_trailer_align(ndr, 5));
2102 : }
2103 4 : if (ndr_flags & NDR_BUFFERS) {
2104 2 : if (r->path) {
2105 2 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->path, CH_UTF16)));
2106 2 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, 0));
2107 2 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->path, CH_UTF16)));
2108 2 : NDR_CHECK(ndr_push_charset(ndr, NDR_SCALARS, r->path, ndr_charset_length(r->path, CH_UTF16), sizeof(uint16_t), CH_UTF16));
2109 : }
2110 2 : if (r->user) {
2111 2 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->user, CH_UTF16)));
2112 2 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, 0));
2113 2 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->user, CH_UTF16)));
2114 2 : NDR_CHECK(ndr_push_charset(ndr, NDR_SCALARS, r->user, ndr_charset_length(r->user, CH_UTF16), sizeof(uint16_t), CH_UTF16));
2115 : }
2116 : }
2117 4 : return NDR_ERR_SUCCESS;
2118 : }
2119 :
2120 4 : static enum ndr_err_code ndr_pull_srvsvc_NetFileInfo3(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct srvsvc_NetFileInfo3 *r)
2121 : {
2122 0 : uint32_t _ptr_path;
2123 4 : uint32_t size_path_1 = 0;
2124 4 : uint32_t length_path_1 = 0;
2125 4 : TALLOC_CTX *_mem_save_path_0 = NULL;
2126 0 : uint32_t _ptr_user;
2127 4 : uint32_t size_user_1 = 0;
2128 4 : uint32_t length_user_1 = 0;
2129 4 : TALLOC_CTX *_mem_save_user_0 = NULL;
2130 4 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
2131 4 : if (ndr_flags & NDR_SCALARS) {
2132 2 : NDR_CHECK(ndr_pull_align(ndr, 5));
2133 2 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->fid));
2134 2 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->permissions));
2135 2 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->num_locks));
2136 2 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_path));
2137 2 : if (_ptr_path) {
2138 2 : NDR_PULL_ALLOC(ndr, r->path);
2139 : } else {
2140 0 : r->path = NULL;
2141 : }
2142 2 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_user));
2143 2 : if (_ptr_user) {
2144 2 : NDR_PULL_ALLOC(ndr, r->user);
2145 : } else {
2146 0 : r->user = NULL;
2147 : }
2148 2 : NDR_CHECK(ndr_pull_trailer_align(ndr, 5));
2149 : }
2150 4 : if (ndr_flags & NDR_BUFFERS) {
2151 2 : if (r->path) {
2152 2 : _mem_save_path_0 = NDR_PULL_GET_MEM_CTX(ndr);
2153 2 : NDR_PULL_SET_MEM_CTX(ndr, r->path, 0);
2154 2 : NDR_CHECK(ndr_pull_array_size(ndr, &r->path));
2155 2 : NDR_CHECK(ndr_pull_array_length(ndr, &r->path));
2156 2 : NDR_CHECK(ndr_steal_array_size(ndr, (void*)&r->path, &size_path_1));
2157 2 : NDR_CHECK(ndr_steal_array_length(ndr, (void*)&r->path, &length_path_1));
2158 2 : if (length_path_1 > size_path_1) {
2159 0 : return ndr_pull_error(ndr, NDR_ERR_ARRAY_SIZE, "Bad array size %"PRIu32": should exceed array length %"PRIu32"", size_path_1, length_path_1);
2160 : }
2161 2 : NDR_CHECK(ndr_check_string_terminator(ndr, length_path_1, sizeof(uint16_t)));
2162 2 : NDR_CHECK(ndr_pull_charset(ndr, NDR_SCALARS, &r->path, length_path_1, sizeof(uint16_t), CH_UTF16));
2163 2 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_path_0, 0);
2164 : }
2165 2 : if (r->user) {
2166 2 : _mem_save_user_0 = NDR_PULL_GET_MEM_CTX(ndr);
2167 2 : NDR_PULL_SET_MEM_CTX(ndr, r->user, 0);
2168 2 : NDR_CHECK(ndr_pull_array_size(ndr, &r->user));
2169 2 : NDR_CHECK(ndr_pull_array_length(ndr, &r->user));
2170 2 : NDR_CHECK(ndr_steal_array_size(ndr, (void*)&r->user, &size_user_1));
2171 2 : NDR_CHECK(ndr_steal_array_length(ndr, (void*)&r->user, &length_user_1));
2172 2 : if (length_user_1 > size_user_1) {
2173 0 : return ndr_pull_error(ndr, NDR_ERR_ARRAY_SIZE, "Bad array size %"PRIu32": should exceed array length %"PRIu32"", size_user_1, length_user_1);
2174 : }
2175 2 : NDR_CHECK(ndr_check_string_terminator(ndr, length_user_1, sizeof(uint16_t)));
2176 2 : NDR_CHECK(ndr_pull_charset(ndr, NDR_SCALARS, &r->user, length_user_1, sizeof(uint16_t), CH_UTF16));
2177 2 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_user_0, 0);
2178 : }
2179 : }
2180 4 : return NDR_ERR_SUCCESS;
2181 : }
2182 :
2183 0 : _PUBLIC_ void ndr_print_srvsvc_NetFileInfo3(struct ndr_print *ndr, const char *name, const struct srvsvc_NetFileInfo3 *r)
2184 : {
2185 0 : ndr_print_struct(ndr, name, "srvsvc_NetFileInfo3");
2186 0 : if (r == NULL) { ndr_print_null(ndr); return; }
2187 0 : ndr->depth++;
2188 0 : ndr_print_uint32(ndr, "fid", r->fid);
2189 0 : ndr_print_uint32(ndr, "permissions", r->permissions);
2190 0 : ndr_print_uint32(ndr, "num_locks", r->num_locks);
2191 0 : ndr_print_ptr(ndr, "path", r->path);
2192 0 : ndr->depth++;
2193 0 : if (r->path) {
2194 0 : ndr_print_string(ndr, "path", r->path);
2195 : }
2196 0 : ndr->depth--;
2197 0 : ndr_print_ptr(ndr, "user", r->user);
2198 0 : ndr->depth++;
2199 0 : if (r->user) {
2200 0 : ndr_print_string(ndr, "user", r->user);
2201 : }
2202 0 : ndr->depth--;
2203 0 : ndr->depth--;
2204 : }
2205 :
2206 21 : static enum ndr_err_code ndr_push_srvsvc_NetFileCtr3(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct srvsvc_NetFileCtr3 *r)
2207 : {
2208 0 : uint32_t cntr_array_1;
2209 21 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
2210 21 : if (ndr_flags & NDR_SCALARS) {
2211 21 : NDR_CHECK(ndr_push_align(ndr, 5));
2212 21 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->count));
2213 21 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->array));
2214 21 : NDR_CHECK(ndr_push_trailer_align(ndr, 5));
2215 : }
2216 21 : if (ndr_flags & NDR_BUFFERS) {
2217 21 : if (r->array) {
2218 2 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, r->count));
2219 4 : for (cntr_array_1 = 0; cntr_array_1 < (r->count); cntr_array_1++) {
2220 2 : NDR_CHECK(ndr_push_srvsvc_NetFileInfo3(ndr, NDR_SCALARS, &r->array[cntr_array_1]));
2221 : }
2222 4 : for (cntr_array_1 = 0; cntr_array_1 < (r->count); cntr_array_1++) {
2223 2 : NDR_CHECK(ndr_push_srvsvc_NetFileInfo3(ndr, NDR_BUFFERS, &r->array[cntr_array_1]));
2224 : }
2225 : }
2226 : }
2227 21 : return NDR_ERR_SUCCESS;
2228 : }
2229 :
2230 20 : static enum ndr_err_code ndr_pull_srvsvc_NetFileCtr3(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct srvsvc_NetFileCtr3 *r)
2231 : {
2232 0 : uint32_t _ptr_array;
2233 20 : uint32_t size_array_1 = 0;
2234 0 : uint32_t cntr_array_1;
2235 20 : TALLOC_CTX *_mem_save_array_0 = NULL;
2236 20 : TALLOC_CTX *_mem_save_array_1 = NULL;
2237 20 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
2238 20 : if (ndr_flags & NDR_SCALARS) {
2239 20 : NDR_CHECK(ndr_pull_align(ndr, 5));
2240 20 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->count));
2241 20 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_array));
2242 20 : if (_ptr_array) {
2243 2 : NDR_PULL_ALLOC(ndr, r->array);
2244 : } else {
2245 18 : r->array = NULL;
2246 : }
2247 20 : NDR_CHECK(ndr_pull_trailer_align(ndr, 5));
2248 : }
2249 20 : if (ndr_flags & NDR_BUFFERS) {
2250 20 : if (r->array) {
2251 2 : _mem_save_array_0 = NDR_PULL_GET_MEM_CTX(ndr);
2252 2 : NDR_PULL_SET_MEM_CTX(ndr, r->array, 0);
2253 2 : NDR_CHECK(ndr_pull_array_size(ndr, &r->array));
2254 2 : NDR_CHECK(ndr_get_array_size(ndr, (void*)&r->array, &size_array_1));
2255 2 : NDR_PULL_ALLOC_N(ndr, r->array, size_array_1);
2256 2 : _mem_save_array_1 = NDR_PULL_GET_MEM_CTX(ndr);
2257 2 : NDR_PULL_SET_MEM_CTX(ndr, r->array, 0);
2258 4 : for (cntr_array_1 = 0; cntr_array_1 < (size_array_1); cntr_array_1++) {
2259 2 : NDR_CHECK(ndr_pull_srvsvc_NetFileInfo3(ndr, NDR_SCALARS, &r->array[cntr_array_1]));
2260 : }
2261 4 : for (cntr_array_1 = 0; cntr_array_1 < (size_array_1); cntr_array_1++) {
2262 2 : NDR_CHECK(ndr_pull_srvsvc_NetFileInfo3(ndr, NDR_BUFFERS, &r->array[cntr_array_1]));
2263 : }
2264 2 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_array_1, 0);
2265 2 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_array_0, 0);
2266 : }
2267 20 : if (r->array) {
2268 2 : NDR_CHECK(ndr_check_array_size(ndr, (void*)&r->array, r->count));
2269 : }
2270 22 : for (cntr_array_1 = 0; cntr_array_1 < (size_array_1); cntr_array_1++) {
2271 0 : }
2272 : }
2273 20 : return NDR_ERR_SUCCESS;
2274 : }
2275 :
2276 2 : _PUBLIC_ void ndr_print_srvsvc_NetFileCtr3(struct ndr_print *ndr, const char *name, const struct srvsvc_NetFileCtr3 *r)
2277 : {
2278 0 : uint32_t cntr_array_1;
2279 2 : ndr_print_struct(ndr, name, "srvsvc_NetFileCtr3");
2280 2 : if (r == NULL) { ndr_print_null(ndr); return; }
2281 2 : ndr->depth++;
2282 2 : ndr_print_uint32(ndr, "count", r->count);
2283 2 : ndr_print_ptr(ndr, "array", r->array);
2284 2 : ndr->depth++;
2285 2 : if (r->array) {
2286 0 : ndr->print(ndr, "%s: ARRAY(%"PRIu32")", "array", (uint32_t)(r->count));
2287 0 : ndr->depth++;
2288 0 : for (cntr_array_1 = 0; cntr_array_1 < (r->count); cntr_array_1++) {
2289 0 : ndr_print_srvsvc_NetFileInfo3(ndr, "array", &r->array[cntr_array_1]);
2290 : }
2291 0 : ndr->depth--;
2292 : }
2293 2 : ndr->depth--;
2294 2 : ndr->depth--;
2295 : }
2296 :
2297 0 : static enum ndr_err_code ndr_push_srvsvc_NetFileInfo(struct ndr_push *ndr, ndr_flags_type ndr_flags, const union srvsvc_NetFileInfo *r)
2298 : {
2299 0 : uint32_t level;
2300 0 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
2301 0 : if (ndr_flags & NDR_SCALARS) {
2302 : /* This token is not used again (except perhaps below in the NDR_BUFFERS case) */
2303 0 : NDR_CHECK(ndr_push_steal_switch_value(ndr, r, &level));
2304 0 : NDR_CHECK(ndr_push_union_align(ndr, 5));
2305 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, level));
2306 0 : NDR_CHECK(ndr_push_union_align(ndr, 5));
2307 0 : switch (level) {
2308 0 : case 2: {
2309 0 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->info2));
2310 0 : break; }
2311 :
2312 0 : case 3: {
2313 0 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->info3));
2314 0 : break; }
2315 :
2316 0 : default: {
2317 0 : break; }
2318 :
2319 : }
2320 : }
2321 0 : if (ndr_flags & NDR_BUFFERS) {
2322 0 : if (!(ndr_flags & NDR_SCALARS)) {
2323 : /* We didn't get it above, and the token is not needed after this. */
2324 0 : NDR_CHECK(ndr_push_steal_switch_value(ndr, r, &level));
2325 : }
2326 0 : switch (level) {
2327 0 : case 2:
2328 0 : if (r->info2) {
2329 0 : NDR_CHECK(ndr_push_srvsvc_NetFileInfo2(ndr, NDR_SCALARS, r->info2));
2330 : }
2331 0 : break;
2332 :
2333 0 : case 3:
2334 0 : if (r->info3) {
2335 0 : NDR_CHECK(ndr_push_srvsvc_NetFileInfo3(ndr, NDR_SCALARS|NDR_BUFFERS, r->info3));
2336 : }
2337 0 : break;
2338 :
2339 0 : default:
2340 0 : break;
2341 :
2342 : }
2343 : }
2344 0 : return NDR_ERR_SUCCESS;
2345 : }
2346 :
2347 0 : static enum ndr_err_code ndr_pull_srvsvc_NetFileInfo(struct ndr_pull *ndr, ndr_flags_type ndr_flags, union srvsvc_NetFileInfo *r)
2348 : {
2349 0 : uint32_t level;
2350 0 : uint32_t _level;
2351 0 : TALLOC_CTX *_mem_save_info2_0 = NULL;
2352 0 : uint32_t _ptr_info2;
2353 0 : TALLOC_CTX *_mem_save_info3_0 = NULL;
2354 0 : uint32_t _ptr_info3;
2355 0 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
2356 0 : if (ndr_flags & NDR_SCALARS) {
2357 : /* This token is not used again (except perhaps below in the NDR_BUFFERS case) */
2358 0 : NDR_CHECK(ndr_pull_steal_switch_value(ndr, r, &level));
2359 0 : NDR_CHECK(ndr_pull_union_align(ndr, 5));
2360 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &_level));
2361 0 : if (_level != level) {
2362 0 : return ndr_pull_error(ndr, NDR_ERR_BAD_SWITCH, "Bad switch value %"PRIu32" for r at %s", (uint32_t)_level, __location__);
2363 : }
2364 0 : NDR_CHECK(ndr_pull_union_align(ndr, 5));
2365 0 : switch (level) {
2366 0 : case 2: {
2367 0 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_info2));
2368 0 : if (_ptr_info2) {
2369 0 : NDR_PULL_ALLOC(ndr, r->info2);
2370 : } else {
2371 0 : r->info2 = NULL;
2372 : }
2373 0 : break; }
2374 :
2375 0 : case 3: {
2376 0 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_info3));
2377 0 : if (_ptr_info3) {
2378 0 : NDR_PULL_ALLOC(ndr, r->info3);
2379 : } else {
2380 0 : r->info3 = NULL;
2381 : }
2382 0 : break; }
2383 :
2384 0 : default: {
2385 0 : break; }
2386 :
2387 : }
2388 : }
2389 0 : if (ndr_flags & NDR_BUFFERS) {
2390 0 : if (!(ndr_flags & NDR_SCALARS)) {
2391 : /* We didn't get it above, and the token is not needed after this. */
2392 0 : NDR_CHECK(ndr_pull_steal_switch_value(ndr, r, &level));
2393 : }
2394 0 : switch (level) {
2395 0 : case 2:
2396 0 : if (r->info2) {
2397 0 : _mem_save_info2_0 = NDR_PULL_GET_MEM_CTX(ndr);
2398 0 : NDR_PULL_SET_MEM_CTX(ndr, r->info2, 0);
2399 0 : NDR_CHECK(ndr_pull_srvsvc_NetFileInfo2(ndr, NDR_SCALARS, r->info2));
2400 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_info2_0, 0);
2401 : }
2402 0 : break;
2403 :
2404 0 : case 3:
2405 0 : if (r->info3) {
2406 0 : _mem_save_info3_0 = NDR_PULL_GET_MEM_CTX(ndr);
2407 0 : NDR_PULL_SET_MEM_CTX(ndr, r->info3, 0);
2408 0 : NDR_CHECK(ndr_pull_srvsvc_NetFileInfo3(ndr, NDR_SCALARS|NDR_BUFFERS, r->info3));
2409 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_info3_0, 0);
2410 : }
2411 0 : break;
2412 :
2413 0 : default:
2414 0 : break;
2415 :
2416 : }
2417 : }
2418 0 : return NDR_ERR_SUCCESS;
2419 : }
2420 :
2421 0 : _PUBLIC_ void ndr_print_srvsvc_NetFileInfo(struct ndr_print *ndr, const char *name, const union srvsvc_NetFileInfo *r)
2422 : {
2423 0 : uint32_t level;
2424 0 : level = ndr_print_steal_switch_value(ndr, r);
2425 0 : ndr_print_union(ndr, name, level, "srvsvc_NetFileInfo");
2426 0 : switch (level) {
2427 0 : case 2:
2428 0 : ndr_print_ptr(ndr, "info2", r->info2);
2429 0 : ndr->depth++;
2430 0 : if (r->info2) {
2431 0 : ndr_print_srvsvc_NetFileInfo2(ndr, "info2", r->info2);
2432 : }
2433 0 : ndr->depth--;
2434 0 : break;
2435 :
2436 0 : case 3:
2437 0 : ndr_print_ptr(ndr, "info3", r->info3);
2438 0 : ndr->depth++;
2439 0 : if (r->info3) {
2440 0 : ndr_print_srvsvc_NetFileInfo3(ndr, "info3", r->info3);
2441 : }
2442 0 : ndr->depth--;
2443 0 : break;
2444 :
2445 0 : default:
2446 0 : break;
2447 :
2448 : }
2449 0 : }
2450 :
2451 76 : static enum ndr_err_code ndr_push_srvsvc_NetFileCtr(struct ndr_push *ndr, ndr_flags_type ndr_flags, const union srvsvc_NetFileCtr *r)
2452 : {
2453 0 : uint32_t level;
2454 76 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
2455 76 : if (ndr_flags & NDR_SCALARS) {
2456 : /* This token is not used again (except perhaps below in the NDR_BUFFERS case) */
2457 38 : NDR_CHECK(ndr_push_steal_switch_value(ndr, r, &level));
2458 38 : NDR_CHECK(ndr_push_union_align(ndr, 5));
2459 38 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, level));
2460 38 : NDR_CHECK(ndr_push_union_align(ndr, 5));
2461 38 : switch (level) {
2462 17 : case 2: {
2463 17 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->ctr2));
2464 17 : break; }
2465 :
2466 21 : case 3: {
2467 21 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->ctr3));
2468 21 : break; }
2469 :
2470 0 : default: {
2471 0 : break; }
2472 :
2473 : }
2474 : }
2475 76 : if (ndr_flags & NDR_BUFFERS) {
2476 38 : if (!(ndr_flags & NDR_SCALARS)) {
2477 : /* We didn't get it above, and the token is not needed after this. */
2478 38 : NDR_CHECK(ndr_push_steal_switch_value(ndr, r, &level));
2479 : }
2480 38 : switch (level) {
2481 17 : case 2:
2482 17 : if (r->ctr2) {
2483 17 : NDR_CHECK(ndr_push_srvsvc_NetFileCtr2(ndr, NDR_SCALARS|NDR_BUFFERS, r->ctr2));
2484 : }
2485 17 : break;
2486 :
2487 21 : case 3:
2488 21 : if (r->ctr3) {
2489 21 : NDR_CHECK(ndr_push_srvsvc_NetFileCtr3(ndr, NDR_SCALARS|NDR_BUFFERS, r->ctr3));
2490 : }
2491 21 : break;
2492 :
2493 0 : default:
2494 0 : break;
2495 :
2496 : }
2497 : }
2498 76 : return NDR_ERR_SUCCESS;
2499 : }
2500 :
2501 72 : static enum ndr_err_code ndr_pull_srvsvc_NetFileCtr(struct ndr_pull *ndr, ndr_flags_type ndr_flags, union srvsvc_NetFileCtr *r)
2502 : {
2503 0 : uint32_t level;
2504 0 : uint32_t _level;
2505 72 : TALLOC_CTX *_mem_save_ctr2_0 = NULL;
2506 0 : uint32_t _ptr_ctr2;
2507 72 : TALLOC_CTX *_mem_save_ctr3_0 = NULL;
2508 0 : uint32_t _ptr_ctr3;
2509 72 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
2510 72 : if (ndr_flags & NDR_SCALARS) {
2511 : /* This token is not used again (except perhaps below in the NDR_BUFFERS case) */
2512 36 : NDR_CHECK(ndr_pull_steal_switch_value(ndr, r, &level));
2513 36 : NDR_CHECK(ndr_pull_union_align(ndr, 5));
2514 36 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &_level));
2515 36 : if (_level != level) {
2516 0 : return ndr_pull_error(ndr, NDR_ERR_BAD_SWITCH, "Bad switch value %"PRIu32" for r at %s", (uint32_t)_level, __location__);
2517 : }
2518 36 : NDR_CHECK(ndr_pull_union_align(ndr, 5));
2519 36 : switch (level) {
2520 16 : case 2: {
2521 16 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_ctr2));
2522 16 : if (_ptr_ctr2) {
2523 16 : NDR_PULL_ALLOC(ndr, r->ctr2);
2524 : } else {
2525 0 : r->ctr2 = NULL;
2526 : }
2527 16 : break; }
2528 :
2529 20 : case 3: {
2530 20 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_ctr3));
2531 20 : if (_ptr_ctr3) {
2532 20 : NDR_PULL_ALLOC(ndr, r->ctr3);
2533 : } else {
2534 0 : r->ctr3 = NULL;
2535 : }
2536 20 : break; }
2537 :
2538 0 : default: {
2539 0 : break; }
2540 :
2541 : }
2542 : }
2543 72 : if (ndr_flags & NDR_BUFFERS) {
2544 36 : if (!(ndr_flags & NDR_SCALARS)) {
2545 : /* We didn't get it above, and the token is not needed after this. */
2546 36 : NDR_CHECK(ndr_pull_steal_switch_value(ndr, r, &level));
2547 : }
2548 36 : switch (level) {
2549 16 : case 2:
2550 16 : if (r->ctr2) {
2551 16 : _mem_save_ctr2_0 = NDR_PULL_GET_MEM_CTX(ndr);
2552 16 : NDR_PULL_SET_MEM_CTX(ndr, r->ctr2, 0);
2553 16 : NDR_CHECK(ndr_pull_srvsvc_NetFileCtr2(ndr, NDR_SCALARS|NDR_BUFFERS, r->ctr2));
2554 16 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_ctr2_0, 0);
2555 : }
2556 16 : break;
2557 :
2558 20 : case 3:
2559 20 : if (r->ctr3) {
2560 20 : _mem_save_ctr3_0 = NDR_PULL_GET_MEM_CTX(ndr);
2561 20 : NDR_PULL_SET_MEM_CTX(ndr, r->ctr3, 0);
2562 20 : NDR_CHECK(ndr_pull_srvsvc_NetFileCtr3(ndr, NDR_SCALARS|NDR_BUFFERS, r->ctr3));
2563 20 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_ctr3_0, 0);
2564 : }
2565 20 : break;
2566 :
2567 0 : default:
2568 0 : break;
2569 :
2570 : }
2571 : }
2572 72 : return NDR_ERR_SUCCESS;
2573 : }
2574 :
2575 4 : _PUBLIC_ void ndr_print_srvsvc_NetFileCtr(struct ndr_print *ndr, const char *name, const union srvsvc_NetFileCtr *r)
2576 : {
2577 0 : uint32_t level;
2578 4 : level = ndr_print_steal_switch_value(ndr, r);
2579 4 : ndr_print_union(ndr, name, level, "srvsvc_NetFileCtr");
2580 4 : switch (level) {
2581 2 : case 2:
2582 2 : ndr_print_ptr(ndr, "ctr2", r->ctr2);
2583 2 : ndr->depth++;
2584 2 : if (r->ctr2) {
2585 2 : ndr_print_srvsvc_NetFileCtr2(ndr, "ctr2", r->ctr2);
2586 : }
2587 2 : ndr->depth--;
2588 2 : break;
2589 :
2590 2 : case 3:
2591 2 : ndr_print_ptr(ndr, "ctr3", r->ctr3);
2592 2 : ndr->depth++;
2593 2 : if (r->ctr3) {
2594 2 : ndr_print_srvsvc_NetFileCtr3(ndr, "ctr3", r->ctr3);
2595 : }
2596 2 : ndr->depth--;
2597 2 : break;
2598 :
2599 0 : default:
2600 0 : break;
2601 :
2602 : }
2603 4 : }
2604 :
2605 38 : static enum ndr_err_code ndr_push_srvsvc_NetFileInfoCtr(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct srvsvc_NetFileInfoCtr *r)
2606 : {
2607 38 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
2608 38 : if (ndr_flags & NDR_SCALARS) {
2609 38 : NDR_CHECK(ndr_push_align(ndr, 5));
2610 38 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->level));
2611 38 : NDR_CHECK(ndr_push_set_switch_value(ndr, &r->ctr, r->level));
2612 38 : NDR_CHECK(ndr_push_srvsvc_NetFileCtr(ndr, NDR_SCALARS, &r->ctr));
2613 38 : NDR_CHECK(ndr_push_trailer_align(ndr, 5));
2614 : }
2615 38 : if (ndr_flags & NDR_BUFFERS) {
2616 38 : NDR_CHECK(ndr_push_set_switch_value(ndr, &r->ctr, r->level));
2617 38 : NDR_CHECK(ndr_push_srvsvc_NetFileCtr(ndr, NDR_BUFFERS, &r->ctr));
2618 : }
2619 38 : return NDR_ERR_SUCCESS;
2620 : }
2621 :
2622 36 : static enum ndr_err_code ndr_pull_srvsvc_NetFileInfoCtr(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct srvsvc_NetFileInfoCtr *r)
2623 : {
2624 36 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
2625 36 : if (ndr_flags & NDR_SCALARS) {
2626 36 : NDR_CHECK(ndr_pull_align(ndr, 5));
2627 36 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->level));
2628 36 : NDR_CHECK(ndr_pull_set_switch_value(ndr, &r->ctr, r->level));
2629 36 : NDR_CHECK(ndr_pull_srvsvc_NetFileCtr(ndr, NDR_SCALARS, &r->ctr));
2630 36 : NDR_CHECK(ndr_pull_trailer_align(ndr, 5));
2631 : }
2632 36 : if (ndr_flags & NDR_BUFFERS) {
2633 36 : NDR_CHECK(ndr_pull_set_switch_value(ndr, &r->ctr, r->level));
2634 36 : NDR_CHECK(ndr_pull_srvsvc_NetFileCtr(ndr, NDR_BUFFERS, &r->ctr));
2635 : }
2636 36 : return NDR_ERR_SUCCESS;
2637 : }
2638 :
2639 4 : _PUBLIC_ void ndr_print_srvsvc_NetFileInfoCtr(struct ndr_print *ndr, const char *name, const struct srvsvc_NetFileInfoCtr *r)
2640 : {
2641 4 : ndr_print_struct(ndr, name, "srvsvc_NetFileInfoCtr");
2642 4 : if (r == NULL) { ndr_print_null(ndr); return; }
2643 4 : ndr->depth++;
2644 4 : ndr_print_uint32(ndr, "level", r->level);
2645 4 : ndr_print_set_switch_value(ndr, &r->ctr, r->level);
2646 4 : ndr_print_srvsvc_NetFileCtr(ndr, "ctr", &r->ctr);
2647 4 : ndr->depth--;
2648 : }
2649 :
2650 8 : static enum ndr_err_code ndr_push_srvsvc_NetSessInfo0(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct srvsvc_NetSessInfo0 *r)
2651 : {
2652 8 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
2653 8 : if (ndr_flags & NDR_SCALARS) {
2654 4 : NDR_CHECK(ndr_push_align(ndr, 5));
2655 4 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->client));
2656 4 : NDR_CHECK(ndr_push_trailer_align(ndr, 5));
2657 : }
2658 8 : if (ndr_flags & NDR_BUFFERS) {
2659 4 : if (r->client) {
2660 4 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->client, CH_UTF16)));
2661 4 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, 0));
2662 4 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->client, CH_UTF16)));
2663 4 : NDR_CHECK(ndr_push_charset(ndr, NDR_SCALARS, r->client, ndr_charset_length(r->client, CH_UTF16), sizeof(uint16_t), CH_UTF16));
2664 : }
2665 : }
2666 8 : return NDR_ERR_SUCCESS;
2667 : }
2668 :
2669 8 : static enum ndr_err_code ndr_pull_srvsvc_NetSessInfo0(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct srvsvc_NetSessInfo0 *r)
2670 : {
2671 0 : uint32_t _ptr_client;
2672 8 : uint32_t size_client_1 = 0;
2673 8 : uint32_t length_client_1 = 0;
2674 8 : TALLOC_CTX *_mem_save_client_0 = NULL;
2675 8 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
2676 8 : if (ndr_flags & NDR_SCALARS) {
2677 4 : NDR_CHECK(ndr_pull_align(ndr, 5));
2678 4 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_client));
2679 4 : if (_ptr_client) {
2680 4 : NDR_PULL_ALLOC(ndr, r->client);
2681 : } else {
2682 0 : r->client = NULL;
2683 : }
2684 4 : NDR_CHECK(ndr_pull_trailer_align(ndr, 5));
2685 : }
2686 8 : if (ndr_flags & NDR_BUFFERS) {
2687 4 : if (r->client) {
2688 4 : _mem_save_client_0 = NDR_PULL_GET_MEM_CTX(ndr);
2689 4 : NDR_PULL_SET_MEM_CTX(ndr, r->client, 0);
2690 4 : NDR_CHECK(ndr_pull_array_size(ndr, &r->client));
2691 4 : NDR_CHECK(ndr_pull_array_length(ndr, &r->client));
2692 4 : NDR_CHECK(ndr_steal_array_size(ndr, (void*)&r->client, &size_client_1));
2693 4 : NDR_CHECK(ndr_steal_array_length(ndr, (void*)&r->client, &length_client_1));
2694 4 : if (length_client_1 > size_client_1) {
2695 0 : return ndr_pull_error(ndr, NDR_ERR_ARRAY_SIZE, "Bad array size %"PRIu32": should exceed array length %"PRIu32"", size_client_1, length_client_1);
2696 : }
2697 4 : NDR_CHECK(ndr_check_string_terminator(ndr, length_client_1, sizeof(uint16_t)));
2698 4 : NDR_CHECK(ndr_pull_charset(ndr, NDR_SCALARS, &r->client, length_client_1, sizeof(uint16_t), CH_UTF16));
2699 4 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_client_0, 0);
2700 : }
2701 : }
2702 8 : return NDR_ERR_SUCCESS;
2703 : }
2704 :
2705 0 : _PUBLIC_ void ndr_print_srvsvc_NetSessInfo0(struct ndr_print *ndr, const char *name, const struct srvsvc_NetSessInfo0 *r)
2706 : {
2707 0 : ndr_print_struct(ndr, name, "srvsvc_NetSessInfo0");
2708 0 : if (r == NULL) { ndr_print_null(ndr); return; }
2709 0 : ndr->depth++;
2710 0 : ndr_print_ptr(ndr, "client", r->client);
2711 0 : ndr->depth++;
2712 0 : if (r->client) {
2713 0 : ndr_print_string(ndr, "client", r->client);
2714 : }
2715 0 : ndr->depth--;
2716 0 : ndr->depth--;
2717 : }
2718 :
2719 17 : static enum ndr_err_code ndr_push_srvsvc_NetSessCtr0(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct srvsvc_NetSessCtr0 *r)
2720 : {
2721 0 : uint32_t cntr_array_1;
2722 17 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
2723 17 : if (ndr_flags & NDR_SCALARS) {
2724 17 : NDR_CHECK(ndr_push_align(ndr, 5));
2725 17 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->count));
2726 17 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->array));
2727 17 : NDR_CHECK(ndr_push_trailer_align(ndr, 5));
2728 : }
2729 17 : if (ndr_flags & NDR_BUFFERS) {
2730 17 : if (r->array) {
2731 4 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, r->count));
2732 8 : for (cntr_array_1 = 0; cntr_array_1 < (r->count); cntr_array_1++) {
2733 4 : NDR_CHECK(ndr_push_srvsvc_NetSessInfo0(ndr, NDR_SCALARS, &r->array[cntr_array_1]));
2734 : }
2735 8 : for (cntr_array_1 = 0; cntr_array_1 < (r->count); cntr_array_1++) {
2736 4 : NDR_CHECK(ndr_push_srvsvc_NetSessInfo0(ndr, NDR_BUFFERS, &r->array[cntr_array_1]));
2737 : }
2738 : }
2739 : }
2740 17 : return NDR_ERR_SUCCESS;
2741 : }
2742 :
2743 16 : static enum ndr_err_code ndr_pull_srvsvc_NetSessCtr0(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct srvsvc_NetSessCtr0 *r)
2744 : {
2745 0 : uint32_t _ptr_array;
2746 16 : uint32_t size_array_1 = 0;
2747 0 : uint32_t cntr_array_1;
2748 16 : TALLOC_CTX *_mem_save_array_0 = NULL;
2749 16 : TALLOC_CTX *_mem_save_array_1 = NULL;
2750 16 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
2751 16 : if (ndr_flags & NDR_SCALARS) {
2752 16 : NDR_CHECK(ndr_pull_align(ndr, 5));
2753 16 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->count));
2754 16 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_array));
2755 16 : if (_ptr_array) {
2756 4 : NDR_PULL_ALLOC(ndr, r->array);
2757 : } else {
2758 12 : r->array = NULL;
2759 : }
2760 16 : NDR_CHECK(ndr_pull_trailer_align(ndr, 5));
2761 : }
2762 16 : if (ndr_flags & NDR_BUFFERS) {
2763 16 : if (r->array) {
2764 4 : _mem_save_array_0 = NDR_PULL_GET_MEM_CTX(ndr);
2765 4 : NDR_PULL_SET_MEM_CTX(ndr, r->array, 0);
2766 4 : NDR_CHECK(ndr_pull_array_size(ndr, &r->array));
2767 4 : NDR_CHECK(ndr_get_array_size(ndr, (void*)&r->array, &size_array_1));
2768 4 : NDR_PULL_ALLOC_N(ndr, r->array, size_array_1);
2769 4 : _mem_save_array_1 = NDR_PULL_GET_MEM_CTX(ndr);
2770 4 : NDR_PULL_SET_MEM_CTX(ndr, r->array, 0);
2771 8 : for (cntr_array_1 = 0; cntr_array_1 < (size_array_1); cntr_array_1++) {
2772 4 : NDR_CHECK(ndr_pull_srvsvc_NetSessInfo0(ndr, NDR_SCALARS, &r->array[cntr_array_1]));
2773 : }
2774 8 : for (cntr_array_1 = 0; cntr_array_1 < (size_array_1); cntr_array_1++) {
2775 4 : NDR_CHECK(ndr_pull_srvsvc_NetSessInfo0(ndr, NDR_BUFFERS, &r->array[cntr_array_1]));
2776 : }
2777 4 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_array_1, 0);
2778 4 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_array_0, 0);
2779 : }
2780 16 : if (r->array) {
2781 4 : NDR_CHECK(ndr_check_array_size(ndr, (void*)&r->array, r->count));
2782 : }
2783 20 : for (cntr_array_1 = 0; cntr_array_1 < (size_array_1); cntr_array_1++) {
2784 0 : }
2785 : }
2786 16 : return NDR_ERR_SUCCESS;
2787 : }
2788 :
2789 2 : _PUBLIC_ void ndr_print_srvsvc_NetSessCtr0(struct ndr_print *ndr, const char *name, const struct srvsvc_NetSessCtr0 *r)
2790 : {
2791 0 : uint32_t cntr_array_1;
2792 2 : ndr_print_struct(ndr, name, "srvsvc_NetSessCtr0");
2793 2 : if (r == NULL) { ndr_print_null(ndr); return; }
2794 2 : ndr->depth++;
2795 2 : ndr_print_uint32(ndr, "count", r->count);
2796 2 : ndr_print_ptr(ndr, "array", r->array);
2797 2 : ndr->depth++;
2798 2 : if (r->array) {
2799 0 : ndr->print(ndr, "%s: ARRAY(%"PRIu32")", "array", (uint32_t)(r->count));
2800 0 : ndr->depth++;
2801 0 : for (cntr_array_1 = 0; cntr_array_1 < (r->count); cntr_array_1++) {
2802 0 : ndr_print_srvsvc_NetSessInfo0(ndr, "array", &r->array[cntr_array_1]);
2803 : }
2804 0 : ndr->depth--;
2805 : }
2806 2 : ndr->depth--;
2807 2 : ndr->depth--;
2808 : }
2809 :
2810 28 : static enum ndr_err_code ndr_push_srvsvc_NetSessInfo1(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct srvsvc_NetSessInfo1 *r)
2811 : {
2812 28 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
2813 28 : if (ndr_flags & NDR_SCALARS) {
2814 14 : NDR_CHECK(ndr_push_align(ndr, 5));
2815 14 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->client));
2816 14 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->user));
2817 14 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->num_open));
2818 14 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->time));
2819 14 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->idle_time));
2820 14 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->user_flags));
2821 14 : NDR_CHECK(ndr_push_trailer_align(ndr, 5));
2822 : }
2823 28 : if (ndr_flags & NDR_BUFFERS) {
2824 14 : if (r->client) {
2825 14 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->client, CH_UTF16)));
2826 14 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, 0));
2827 14 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->client, CH_UTF16)));
2828 14 : NDR_CHECK(ndr_push_charset(ndr, NDR_SCALARS, r->client, ndr_charset_length(r->client, CH_UTF16), sizeof(uint16_t), CH_UTF16));
2829 : }
2830 14 : if (r->user) {
2831 14 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->user, CH_UTF16)));
2832 14 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, 0));
2833 14 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->user, CH_UTF16)));
2834 14 : NDR_CHECK(ndr_push_charset(ndr, NDR_SCALARS, r->user, ndr_charset_length(r->user, CH_UTF16), sizeof(uint16_t), CH_UTF16));
2835 : }
2836 : }
2837 28 : return NDR_ERR_SUCCESS;
2838 : }
2839 :
2840 28 : static enum ndr_err_code ndr_pull_srvsvc_NetSessInfo1(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct srvsvc_NetSessInfo1 *r)
2841 : {
2842 0 : uint32_t _ptr_client;
2843 28 : uint32_t size_client_1 = 0;
2844 28 : uint32_t length_client_1 = 0;
2845 28 : TALLOC_CTX *_mem_save_client_0 = NULL;
2846 0 : uint32_t _ptr_user;
2847 28 : uint32_t size_user_1 = 0;
2848 28 : uint32_t length_user_1 = 0;
2849 28 : TALLOC_CTX *_mem_save_user_0 = NULL;
2850 28 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
2851 28 : if (ndr_flags & NDR_SCALARS) {
2852 14 : NDR_CHECK(ndr_pull_align(ndr, 5));
2853 14 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_client));
2854 14 : if (_ptr_client) {
2855 14 : NDR_PULL_ALLOC(ndr, r->client);
2856 : } else {
2857 0 : r->client = NULL;
2858 : }
2859 14 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_user));
2860 14 : if (_ptr_user) {
2861 14 : NDR_PULL_ALLOC(ndr, r->user);
2862 : } else {
2863 0 : r->user = NULL;
2864 : }
2865 14 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->num_open));
2866 14 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->time));
2867 14 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->idle_time));
2868 14 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->user_flags));
2869 14 : NDR_CHECK(ndr_pull_trailer_align(ndr, 5));
2870 : }
2871 28 : if (ndr_flags & NDR_BUFFERS) {
2872 14 : if (r->client) {
2873 14 : _mem_save_client_0 = NDR_PULL_GET_MEM_CTX(ndr);
2874 14 : NDR_PULL_SET_MEM_CTX(ndr, r->client, 0);
2875 14 : NDR_CHECK(ndr_pull_array_size(ndr, &r->client));
2876 14 : NDR_CHECK(ndr_pull_array_length(ndr, &r->client));
2877 14 : NDR_CHECK(ndr_steal_array_size(ndr, (void*)&r->client, &size_client_1));
2878 14 : NDR_CHECK(ndr_steal_array_length(ndr, (void*)&r->client, &length_client_1));
2879 14 : if (length_client_1 > size_client_1) {
2880 0 : return ndr_pull_error(ndr, NDR_ERR_ARRAY_SIZE, "Bad array size %"PRIu32": should exceed array length %"PRIu32"", size_client_1, length_client_1);
2881 : }
2882 14 : NDR_CHECK(ndr_check_string_terminator(ndr, length_client_1, sizeof(uint16_t)));
2883 14 : NDR_CHECK(ndr_pull_charset(ndr, NDR_SCALARS, &r->client, length_client_1, sizeof(uint16_t), CH_UTF16));
2884 14 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_client_0, 0);
2885 : }
2886 14 : if (r->user) {
2887 14 : _mem_save_user_0 = NDR_PULL_GET_MEM_CTX(ndr);
2888 14 : NDR_PULL_SET_MEM_CTX(ndr, r->user, 0);
2889 14 : NDR_CHECK(ndr_pull_array_size(ndr, &r->user));
2890 14 : NDR_CHECK(ndr_pull_array_length(ndr, &r->user));
2891 14 : NDR_CHECK(ndr_steal_array_size(ndr, (void*)&r->user, &size_user_1));
2892 14 : NDR_CHECK(ndr_steal_array_length(ndr, (void*)&r->user, &length_user_1));
2893 14 : if (length_user_1 > size_user_1) {
2894 0 : return ndr_pull_error(ndr, NDR_ERR_ARRAY_SIZE, "Bad array size %"PRIu32": should exceed array length %"PRIu32"", size_user_1, length_user_1);
2895 : }
2896 14 : NDR_CHECK(ndr_check_string_terminator(ndr, length_user_1, sizeof(uint16_t)));
2897 14 : NDR_CHECK(ndr_pull_charset(ndr, NDR_SCALARS, &r->user, length_user_1, sizeof(uint16_t), CH_UTF16));
2898 14 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_user_0, 0);
2899 : }
2900 : }
2901 28 : return NDR_ERR_SUCCESS;
2902 : }
2903 :
2904 0 : _PUBLIC_ void ndr_print_srvsvc_NetSessInfo1(struct ndr_print *ndr, const char *name, const struct srvsvc_NetSessInfo1 *r)
2905 : {
2906 0 : ndr_print_struct(ndr, name, "srvsvc_NetSessInfo1");
2907 0 : if (r == NULL) { ndr_print_null(ndr); return; }
2908 0 : ndr->depth++;
2909 0 : ndr_print_ptr(ndr, "client", r->client);
2910 0 : ndr->depth++;
2911 0 : if (r->client) {
2912 0 : ndr_print_string(ndr, "client", r->client);
2913 : }
2914 0 : ndr->depth--;
2915 0 : ndr_print_ptr(ndr, "user", r->user);
2916 0 : ndr->depth++;
2917 0 : if (r->user) {
2918 0 : ndr_print_string(ndr, "user", r->user);
2919 : }
2920 0 : ndr->depth--;
2921 0 : ndr_print_uint32(ndr, "num_open", r->num_open);
2922 0 : ndr_print_uint32(ndr, "time", r->time);
2923 0 : ndr_print_uint32(ndr, "idle_time", r->idle_time);
2924 0 : ndr_print_uint32(ndr, "user_flags", r->user_flags);
2925 0 : ndr->depth--;
2926 : }
2927 :
2928 45 : static enum ndr_err_code ndr_push_srvsvc_NetSessCtr1(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct srvsvc_NetSessCtr1 *r)
2929 : {
2930 0 : uint32_t cntr_array_1;
2931 45 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
2932 45 : if (ndr_flags & NDR_SCALARS) {
2933 45 : NDR_CHECK(ndr_push_align(ndr, 5));
2934 45 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->count));
2935 45 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->array));
2936 45 : NDR_CHECK(ndr_push_trailer_align(ndr, 5));
2937 : }
2938 45 : if (ndr_flags & NDR_BUFFERS) {
2939 45 : if (r->array) {
2940 14 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, r->count));
2941 28 : for (cntr_array_1 = 0; cntr_array_1 < (r->count); cntr_array_1++) {
2942 14 : NDR_CHECK(ndr_push_srvsvc_NetSessInfo1(ndr, NDR_SCALARS, &r->array[cntr_array_1]));
2943 : }
2944 28 : for (cntr_array_1 = 0; cntr_array_1 < (r->count); cntr_array_1++) {
2945 14 : NDR_CHECK(ndr_push_srvsvc_NetSessInfo1(ndr, NDR_BUFFERS, &r->array[cntr_array_1]));
2946 : }
2947 : }
2948 : }
2949 45 : return NDR_ERR_SUCCESS;
2950 : }
2951 :
2952 44 : static enum ndr_err_code ndr_pull_srvsvc_NetSessCtr1(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct srvsvc_NetSessCtr1 *r)
2953 : {
2954 0 : uint32_t _ptr_array;
2955 44 : uint32_t size_array_1 = 0;
2956 0 : uint32_t cntr_array_1;
2957 44 : TALLOC_CTX *_mem_save_array_0 = NULL;
2958 44 : TALLOC_CTX *_mem_save_array_1 = NULL;
2959 44 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
2960 44 : if (ndr_flags & NDR_SCALARS) {
2961 44 : NDR_CHECK(ndr_pull_align(ndr, 5));
2962 44 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->count));
2963 44 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_array));
2964 44 : if (_ptr_array) {
2965 14 : NDR_PULL_ALLOC(ndr, r->array);
2966 : } else {
2967 30 : r->array = NULL;
2968 : }
2969 44 : NDR_CHECK(ndr_pull_trailer_align(ndr, 5));
2970 : }
2971 44 : if (ndr_flags & NDR_BUFFERS) {
2972 44 : if (r->array) {
2973 14 : _mem_save_array_0 = NDR_PULL_GET_MEM_CTX(ndr);
2974 14 : NDR_PULL_SET_MEM_CTX(ndr, r->array, 0);
2975 14 : NDR_CHECK(ndr_pull_array_size(ndr, &r->array));
2976 14 : NDR_CHECK(ndr_get_array_size(ndr, (void*)&r->array, &size_array_1));
2977 14 : NDR_PULL_ALLOC_N(ndr, r->array, size_array_1);
2978 14 : _mem_save_array_1 = NDR_PULL_GET_MEM_CTX(ndr);
2979 14 : NDR_PULL_SET_MEM_CTX(ndr, r->array, 0);
2980 28 : for (cntr_array_1 = 0; cntr_array_1 < (size_array_1); cntr_array_1++) {
2981 14 : NDR_CHECK(ndr_pull_srvsvc_NetSessInfo1(ndr, NDR_SCALARS, &r->array[cntr_array_1]));
2982 : }
2983 28 : for (cntr_array_1 = 0; cntr_array_1 < (size_array_1); cntr_array_1++) {
2984 14 : NDR_CHECK(ndr_pull_srvsvc_NetSessInfo1(ndr, NDR_BUFFERS, &r->array[cntr_array_1]));
2985 : }
2986 14 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_array_1, 0);
2987 14 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_array_0, 0);
2988 : }
2989 44 : if (r->array) {
2990 14 : NDR_CHECK(ndr_check_array_size(ndr, (void*)&r->array, r->count));
2991 : }
2992 58 : for (cntr_array_1 = 0; cntr_array_1 < (size_array_1); cntr_array_1++) {
2993 0 : }
2994 : }
2995 44 : return NDR_ERR_SUCCESS;
2996 : }
2997 :
2998 2 : _PUBLIC_ void ndr_print_srvsvc_NetSessCtr1(struct ndr_print *ndr, const char *name, const struct srvsvc_NetSessCtr1 *r)
2999 : {
3000 0 : uint32_t cntr_array_1;
3001 2 : ndr_print_struct(ndr, name, "srvsvc_NetSessCtr1");
3002 2 : if (r == NULL) { ndr_print_null(ndr); return; }
3003 2 : ndr->depth++;
3004 2 : ndr_print_uint32(ndr, "count", r->count);
3005 2 : ndr_print_ptr(ndr, "array", r->array);
3006 2 : ndr->depth++;
3007 2 : if (r->array) {
3008 0 : ndr->print(ndr, "%s: ARRAY(%"PRIu32")", "array", (uint32_t)(r->count));
3009 0 : ndr->depth++;
3010 0 : for (cntr_array_1 = 0; cntr_array_1 < (r->count); cntr_array_1++) {
3011 0 : ndr_print_srvsvc_NetSessInfo1(ndr, "array", &r->array[cntr_array_1]);
3012 : }
3013 0 : ndr->depth--;
3014 : }
3015 2 : ndr->depth--;
3016 2 : ndr->depth--;
3017 : }
3018 :
3019 0 : static enum ndr_err_code ndr_push_srvsvc_NetSessInfo2(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct srvsvc_NetSessInfo2 *r)
3020 : {
3021 0 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
3022 0 : if (ndr_flags & NDR_SCALARS) {
3023 0 : NDR_CHECK(ndr_push_align(ndr, 5));
3024 0 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->client));
3025 0 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->user));
3026 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->num_open));
3027 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->time));
3028 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->idle_time));
3029 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->user_flags));
3030 0 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->client_type));
3031 0 : NDR_CHECK(ndr_push_trailer_align(ndr, 5));
3032 : }
3033 0 : if (ndr_flags & NDR_BUFFERS) {
3034 0 : if (r->client) {
3035 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->client, CH_UTF16)));
3036 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, 0));
3037 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->client, CH_UTF16)));
3038 0 : NDR_CHECK(ndr_push_charset(ndr, NDR_SCALARS, r->client, ndr_charset_length(r->client, CH_UTF16), sizeof(uint16_t), CH_UTF16));
3039 : }
3040 0 : if (r->user) {
3041 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->user, CH_UTF16)));
3042 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, 0));
3043 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->user, CH_UTF16)));
3044 0 : NDR_CHECK(ndr_push_charset(ndr, NDR_SCALARS, r->user, ndr_charset_length(r->user, CH_UTF16), sizeof(uint16_t), CH_UTF16));
3045 : }
3046 0 : if (r->client_type) {
3047 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->client_type, CH_UTF16)));
3048 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, 0));
3049 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->client_type, CH_UTF16)));
3050 0 : NDR_CHECK(ndr_push_charset(ndr, NDR_SCALARS, r->client_type, ndr_charset_length(r->client_type, CH_UTF16), sizeof(uint16_t), CH_UTF16));
3051 : }
3052 : }
3053 0 : return NDR_ERR_SUCCESS;
3054 : }
3055 :
3056 0 : static enum ndr_err_code ndr_pull_srvsvc_NetSessInfo2(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct srvsvc_NetSessInfo2 *r)
3057 : {
3058 0 : uint32_t _ptr_client;
3059 0 : uint32_t size_client_1 = 0;
3060 0 : uint32_t length_client_1 = 0;
3061 0 : TALLOC_CTX *_mem_save_client_0 = NULL;
3062 0 : uint32_t _ptr_user;
3063 0 : uint32_t size_user_1 = 0;
3064 0 : uint32_t length_user_1 = 0;
3065 0 : TALLOC_CTX *_mem_save_user_0 = NULL;
3066 0 : uint32_t _ptr_client_type;
3067 0 : uint32_t size_client_type_1 = 0;
3068 0 : uint32_t length_client_type_1 = 0;
3069 0 : TALLOC_CTX *_mem_save_client_type_0 = NULL;
3070 0 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
3071 0 : if (ndr_flags & NDR_SCALARS) {
3072 0 : NDR_CHECK(ndr_pull_align(ndr, 5));
3073 0 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_client));
3074 0 : if (_ptr_client) {
3075 0 : NDR_PULL_ALLOC(ndr, r->client);
3076 : } else {
3077 0 : r->client = NULL;
3078 : }
3079 0 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_user));
3080 0 : if (_ptr_user) {
3081 0 : NDR_PULL_ALLOC(ndr, r->user);
3082 : } else {
3083 0 : r->user = NULL;
3084 : }
3085 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->num_open));
3086 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->time));
3087 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->idle_time));
3088 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->user_flags));
3089 0 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_client_type));
3090 0 : if (_ptr_client_type) {
3091 0 : NDR_PULL_ALLOC(ndr, r->client_type);
3092 : } else {
3093 0 : r->client_type = NULL;
3094 : }
3095 0 : NDR_CHECK(ndr_pull_trailer_align(ndr, 5));
3096 : }
3097 0 : if (ndr_flags & NDR_BUFFERS) {
3098 0 : if (r->client) {
3099 0 : _mem_save_client_0 = NDR_PULL_GET_MEM_CTX(ndr);
3100 0 : NDR_PULL_SET_MEM_CTX(ndr, r->client, 0);
3101 0 : NDR_CHECK(ndr_pull_array_size(ndr, &r->client));
3102 0 : NDR_CHECK(ndr_pull_array_length(ndr, &r->client));
3103 0 : NDR_CHECK(ndr_steal_array_size(ndr, (void*)&r->client, &size_client_1));
3104 0 : NDR_CHECK(ndr_steal_array_length(ndr, (void*)&r->client, &length_client_1));
3105 0 : if (length_client_1 > size_client_1) {
3106 0 : return ndr_pull_error(ndr, NDR_ERR_ARRAY_SIZE, "Bad array size %"PRIu32": should exceed array length %"PRIu32"", size_client_1, length_client_1);
3107 : }
3108 0 : NDR_CHECK(ndr_check_string_terminator(ndr, length_client_1, sizeof(uint16_t)));
3109 0 : NDR_CHECK(ndr_pull_charset(ndr, NDR_SCALARS, &r->client, length_client_1, sizeof(uint16_t), CH_UTF16));
3110 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_client_0, 0);
3111 : }
3112 0 : if (r->user) {
3113 0 : _mem_save_user_0 = NDR_PULL_GET_MEM_CTX(ndr);
3114 0 : NDR_PULL_SET_MEM_CTX(ndr, r->user, 0);
3115 0 : NDR_CHECK(ndr_pull_array_size(ndr, &r->user));
3116 0 : NDR_CHECK(ndr_pull_array_length(ndr, &r->user));
3117 0 : NDR_CHECK(ndr_steal_array_size(ndr, (void*)&r->user, &size_user_1));
3118 0 : NDR_CHECK(ndr_steal_array_length(ndr, (void*)&r->user, &length_user_1));
3119 0 : if (length_user_1 > size_user_1) {
3120 0 : return ndr_pull_error(ndr, NDR_ERR_ARRAY_SIZE, "Bad array size %"PRIu32": should exceed array length %"PRIu32"", size_user_1, length_user_1);
3121 : }
3122 0 : NDR_CHECK(ndr_check_string_terminator(ndr, length_user_1, sizeof(uint16_t)));
3123 0 : NDR_CHECK(ndr_pull_charset(ndr, NDR_SCALARS, &r->user, length_user_1, sizeof(uint16_t), CH_UTF16));
3124 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_user_0, 0);
3125 : }
3126 0 : if (r->client_type) {
3127 0 : _mem_save_client_type_0 = NDR_PULL_GET_MEM_CTX(ndr);
3128 0 : NDR_PULL_SET_MEM_CTX(ndr, r->client_type, 0);
3129 0 : NDR_CHECK(ndr_pull_array_size(ndr, &r->client_type));
3130 0 : NDR_CHECK(ndr_pull_array_length(ndr, &r->client_type));
3131 0 : NDR_CHECK(ndr_steal_array_size(ndr, (void*)&r->client_type, &size_client_type_1));
3132 0 : NDR_CHECK(ndr_steal_array_length(ndr, (void*)&r->client_type, &length_client_type_1));
3133 0 : if (length_client_type_1 > size_client_type_1) {
3134 0 : return ndr_pull_error(ndr, NDR_ERR_ARRAY_SIZE, "Bad array size %"PRIu32": should exceed array length %"PRIu32"", size_client_type_1, length_client_type_1);
3135 : }
3136 0 : NDR_CHECK(ndr_check_string_terminator(ndr, length_client_type_1, sizeof(uint16_t)));
3137 0 : NDR_CHECK(ndr_pull_charset(ndr, NDR_SCALARS, &r->client_type, length_client_type_1, sizeof(uint16_t), CH_UTF16));
3138 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_client_type_0, 0);
3139 : }
3140 : }
3141 0 : return NDR_ERR_SUCCESS;
3142 : }
3143 :
3144 0 : _PUBLIC_ void ndr_print_srvsvc_NetSessInfo2(struct ndr_print *ndr, const char *name, const struct srvsvc_NetSessInfo2 *r)
3145 : {
3146 0 : ndr_print_struct(ndr, name, "srvsvc_NetSessInfo2");
3147 0 : if (r == NULL) { ndr_print_null(ndr); return; }
3148 0 : ndr->depth++;
3149 0 : ndr_print_ptr(ndr, "client", r->client);
3150 0 : ndr->depth++;
3151 0 : if (r->client) {
3152 0 : ndr_print_string(ndr, "client", r->client);
3153 : }
3154 0 : ndr->depth--;
3155 0 : ndr_print_ptr(ndr, "user", r->user);
3156 0 : ndr->depth++;
3157 0 : if (r->user) {
3158 0 : ndr_print_string(ndr, "user", r->user);
3159 : }
3160 0 : ndr->depth--;
3161 0 : ndr_print_uint32(ndr, "num_open", r->num_open);
3162 0 : ndr_print_uint32(ndr, "time", r->time);
3163 0 : ndr_print_uint32(ndr, "idle_time", r->idle_time);
3164 0 : ndr_print_uint32(ndr, "user_flags", r->user_flags);
3165 0 : ndr_print_ptr(ndr, "client_type", r->client_type);
3166 0 : ndr->depth++;
3167 0 : if (r->client_type) {
3168 0 : ndr_print_string(ndr, "client_type", r->client_type);
3169 : }
3170 0 : ndr->depth--;
3171 0 : ndr->depth--;
3172 : }
3173 :
3174 17 : static enum ndr_err_code ndr_push_srvsvc_NetSessCtr2(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct srvsvc_NetSessCtr2 *r)
3175 : {
3176 0 : uint32_t cntr_array_1;
3177 17 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
3178 17 : if (ndr_flags & NDR_SCALARS) {
3179 17 : NDR_CHECK(ndr_push_align(ndr, 5));
3180 17 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->count));
3181 17 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->array));
3182 17 : NDR_CHECK(ndr_push_trailer_align(ndr, 5));
3183 : }
3184 17 : if (ndr_flags & NDR_BUFFERS) {
3185 17 : if (r->array) {
3186 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, r->count));
3187 0 : for (cntr_array_1 = 0; cntr_array_1 < (r->count); cntr_array_1++) {
3188 0 : NDR_CHECK(ndr_push_srvsvc_NetSessInfo2(ndr, NDR_SCALARS, &r->array[cntr_array_1]));
3189 : }
3190 0 : for (cntr_array_1 = 0; cntr_array_1 < (r->count); cntr_array_1++) {
3191 0 : NDR_CHECK(ndr_push_srvsvc_NetSessInfo2(ndr, NDR_BUFFERS, &r->array[cntr_array_1]));
3192 : }
3193 : }
3194 : }
3195 17 : return NDR_ERR_SUCCESS;
3196 : }
3197 :
3198 16 : static enum ndr_err_code ndr_pull_srvsvc_NetSessCtr2(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct srvsvc_NetSessCtr2 *r)
3199 : {
3200 0 : uint32_t _ptr_array;
3201 16 : uint32_t size_array_1 = 0;
3202 0 : uint32_t cntr_array_1;
3203 16 : TALLOC_CTX *_mem_save_array_0 = NULL;
3204 16 : TALLOC_CTX *_mem_save_array_1 = NULL;
3205 16 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
3206 16 : if (ndr_flags & NDR_SCALARS) {
3207 16 : NDR_CHECK(ndr_pull_align(ndr, 5));
3208 16 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->count));
3209 16 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_array));
3210 16 : if (_ptr_array) {
3211 0 : NDR_PULL_ALLOC(ndr, r->array);
3212 : } else {
3213 16 : r->array = NULL;
3214 : }
3215 16 : NDR_CHECK(ndr_pull_trailer_align(ndr, 5));
3216 : }
3217 16 : if (ndr_flags & NDR_BUFFERS) {
3218 16 : if (r->array) {
3219 0 : _mem_save_array_0 = NDR_PULL_GET_MEM_CTX(ndr);
3220 0 : NDR_PULL_SET_MEM_CTX(ndr, r->array, 0);
3221 0 : NDR_CHECK(ndr_pull_array_size(ndr, &r->array));
3222 0 : NDR_CHECK(ndr_get_array_size(ndr, (void*)&r->array, &size_array_1));
3223 0 : NDR_PULL_ALLOC_N(ndr, r->array, size_array_1);
3224 0 : _mem_save_array_1 = NDR_PULL_GET_MEM_CTX(ndr);
3225 0 : NDR_PULL_SET_MEM_CTX(ndr, r->array, 0);
3226 0 : for (cntr_array_1 = 0; cntr_array_1 < (size_array_1); cntr_array_1++) {
3227 0 : NDR_CHECK(ndr_pull_srvsvc_NetSessInfo2(ndr, NDR_SCALARS, &r->array[cntr_array_1]));
3228 : }
3229 0 : for (cntr_array_1 = 0; cntr_array_1 < (size_array_1); cntr_array_1++) {
3230 0 : NDR_CHECK(ndr_pull_srvsvc_NetSessInfo2(ndr, NDR_BUFFERS, &r->array[cntr_array_1]));
3231 : }
3232 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_array_1, 0);
3233 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_array_0, 0);
3234 : }
3235 16 : if (r->array) {
3236 0 : NDR_CHECK(ndr_check_array_size(ndr, (void*)&r->array, r->count));
3237 : }
3238 16 : for (cntr_array_1 = 0; cntr_array_1 < (size_array_1); cntr_array_1++) {
3239 0 : }
3240 : }
3241 16 : return NDR_ERR_SUCCESS;
3242 : }
3243 :
3244 2 : _PUBLIC_ void ndr_print_srvsvc_NetSessCtr2(struct ndr_print *ndr, const char *name, const struct srvsvc_NetSessCtr2 *r)
3245 : {
3246 0 : uint32_t cntr_array_1;
3247 2 : ndr_print_struct(ndr, name, "srvsvc_NetSessCtr2");
3248 2 : if (r == NULL) { ndr_print_null(ndr); return; }
3249 2 : ndr->depth++;
3250 2 : ndr_print_uint32(ndr, "count", r->count);
3251 2 : ndr_print_ptr(ndr, "array", r->array);
3252 2 : ndr->depth++;
3253 2 : if (r->array) {
3254 0 : ndr->print(ndr, "%s: ARRAY(%"PRIu32")", "array", (uint32_t)(r->count));
3255 0 : ndr->depth++;
3256 0 : for (cntr_array_1 = 0; cntr_array_1 < (r->count); cntr_array_1++) {
3257 0 : ndr_print_srvsvc_NetSessInfo2(ndr, "array", &r->array[cntr_array_1]);
3258 : }
3259 0 : ndr->depth--;
3260 : }
3261 2 : ndr->depth--;
3262 2 : ndr->depth--;
3263 : }
3264 :
3265 0 : static enum ndr_err_code ndr_push_srvsvc_NetSessInfo10(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct srvsvc_NetSessInfo10 *r)
3266 : {
3267 0 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
3268 0 : if (ndr_flags & NDR_SCALARS) {
3269 0 : NDR_CHECK(ndr_push_align(ndr, 5));
3270 0 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->client));
3271 0 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->user));
3272 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->time));
3273 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->idle_time));
3274 0 : NDR_CHECK(ndr_push_trailer_align(ndr, 5));
3275 : }
3276 0 : if (ndr_flags & NDR_BUFFERS) {
3277 0 : if (r->client) {
3278 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->client, CH_UTF16)));
3279 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, 0));
3280 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->client, CH_UTF16)));
3281 0 : NDR_CHECK(ndr_push_charset(ndr, NDR_SCALARS, r->client, ndr_charset_length(r->client, CH_UTF16), sizeof(uint16_t), CH_UTF16));
3282 : }
3283 0 : if (r->user) {
3284 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->user, CH_UTF16)));
3285 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, 0));
3286 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->user, CH_UTF16)));
3287 0 : NDR_CHECK(ndr_push_charset(ndr, NDR_SCALARS, r->user, ndr_charset_length(r->user, CH_UTF16), sizeof(uint16_t), CH_UTF16));
3288 : }
3289 : }
3290 0 : return NDR_ERR_SUCCESS;
3291 : }
3292 :
3293 0 : static enum ndr_err_code ndr_pull_srvsvc_NetSessInfo10(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct srvsvc_NetSessInfo10 *r)
3294 : {
3295 0 : uint32_t _ptr_client;
3296 0 : uint32_t size_client_1 = 0;
3297 0 : uint32_t length_client_1 = 0;
3298 0 : TALLOC_CTX *_mem_save_client_0 = NULL;
3299 0 : uint32_t _ptr_user;
3300 0 : uint32_t size_user_1 = 0;
3301 0 : uint32_t length_user_1 = 0;
3302 0 : TALLOC_CTX *_mem_save_user_0 = NULL;
3303 0 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
3304 0 : if (ndr_flags & NDR_SCALARS) {
3305 0 : NDR_CHECK(ndr_pull_align(ndr, 5));
3306 0 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_client));
3307 0 : if (_ptr_client) {
3308 0 : NDR_PULL_ALLOC(ndr, r->client);
3309 : } else {
3310 0 : r->client = NULL;
3311 : }
3312 0 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_user));
3313 0 : if (_ptr_user) {
3314 0 : NDR_PULL_ALLOC(ndr, r->user);
3315 : } else {
3316 0 : r->user = NULL;
3317 : }
3318 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->time));
3319 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->idle_time));
3320 0 : NDR_CHECK(ndr_pull_trailer_align(ndr, 5));
3321 : }
3322 0 : if (ndr_flags & NDR_BUFFERS) {
3323 0 : if (r->client) {
3324 0 : _mem_save_client_0 = NDR_PULL_GET_MEM_CTX(ndr);
3325 0 : NDR_PULL_SET_MEM_CTX(ndr, r->client, 0);
3326 0 : NDR_CHECK(ndr_pull_array_size(ndr, &r->client));
3327 0 : NDR_CHECK(ndr_pull_array_length(ndr, &r->client));
3328 0 : NDR_CHECK(ndr_steal_array_size(ndr, (void*)&r->client, &size_client_1));
3329 0 : NDR_CHECK(ndr_steal_array_length(ndr, (void*)&r->client, &length_client_1));
3330 0 : if (length_client_1 > size_client_1) {
3331 0 : return ndr_pull_error(ndr, NDR_ERR_ARRAY_SIZE, "Bad array size %"PRIu32": should exceed array length %"PRIu32"", size_client_1, length_client_1);
3332 : }
3333 0 : NDR_CHECK(ndr_check_string_terminator(ndr, length_client_1, sizeof(uint16_t)));
3334 0 : NDR_CHECK(ndr_pull_charset(ndr, NDR_SCALARS, &r->client, length_client_1, sizeof(uint16_t), CH_UTF16));
3335 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_client_0, 0);
3336 : }
3337 0 : if (r->user) {
3338 0 : _mem_save_user_0 = NDR_PULL_GET_MEM_CTX(ndr);
3339 0 : NDR_PULL_SET_MEM_CTX(ndr, r->user, 0);
3340 0 : NDR_CHECK(ndr_pull_array_size(ndr, &r->user));
3341 0 : NDR_CHECK(ndr_pull_array_length(ndr, &r->user));
3342 0 : NDR_CHECK(ndr_steal_array_size(ndr, (void*)&r->user, &size_user_1));
3343 0 : NDR_CHECK(ndr_steal_array_length(ndr, (void*)&r->user, &length_user_1));
3344 0 : if (length_user_1 > size_user_1) {
3345 0 : return ndr_pull_error(ndr, NDR_ERR_ARRAY_SIZE, "Bad array size %"PRIu32": should exceed array length %"PRIu32"", size_user_1, length_user_1);
3346 : }
3347 0 : NDR_CHECK(ndr_check_string_terminator(ndr, length_user_1, sizeof(uint16_t)));
3348 0 : NDR_CHECK(ndr_pull_charset(ndr, NDR_SCALARS, &r->user, length_user_1, sizeof(uint16_t), CH_UTF16));
3349 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_user_0, 0);
3350 : }
3351 : }
3352 0 : return NDR_ERR_SUCCESS;
3353 : }
3354 :
3355 0 : _PUBLIC_ void ndr_print_srvsvc_NetSessInfo10(struct ndr_print *ndr, const char *name, const struct srvsvc_NetSessInfo10 *r)
3356 : {
3357 0 : ndr_print_struct(ndr, name, "srvsvc_NetSessInfo10");
3358 0 : if (r == NULL) { ndr_print_null(ndr); return; }
3359 0 : ndr->depth++;
3360 0 : ndr_print_ptr(ndr, "client", r->client);
3361 0 : ndr->depth++;
3362 0 : if (r->client) {
3363 0 : ndr_print_string(ndr, "client", r->client);
3364 : }
3365 0 : ndr->depth--;
3366 0 : ndr_print_ptr(ndr, "user", r->user);
3367 0 : ndr->depth++;
3368 0 : if (r->user) {
3369 0 : ndr_print_string(ndr, "user", r->user);
3370 : }
3371 0 : ndr->depth--;
3372 0 : ndr_print_uint32(ndr, "time", r->time);
3373 0 : ndr_print_uint32(ndr, "idle_time", r->idle_time);
3374 0 : ndr->depth--;
3375 : }
3376 :
3377 17 : static enum ndr_err_code ndr_push_srvsvc_NetSessCtr10(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct srvsvc_NetSessCtr10 *r)
3378 : {
3379 0 : uint32_t cntr_array_1;
3380 17 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
3381 17 : if (ndr_flags & NDR_SCALARS) {
3382 17 : NDR_CHECK(ndr_push_align(ndr, 5));
3383 17 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->count));
3384 17 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->array));
3385 17 : NDR_CHECK(ndr_push_trailer_align(ndr, 5));
3386 : }
3387 17 : if (ndr_flags & NDR_BUFFERS) {
3388 17 : if (r->array) {
3389 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, r->count));
3390 0 : for (cntr_array_1 = 0; cntr_array_1 < (r->count); cntr_array_1++) {
3391 0 : NDR_CHECK(ndr_push_srvsvc_NetSessInfo10(ndr, NDR_SCALARS, &r->array[cntr_array_1]));
3392 : }
3393 0 : for (cntr_array_1 = 0; cntr_array_1 < (r->count); cntr_array_1++) {
3394 0 : NDR_CHECK(ndr_push_srvsvc_NetSessInfo10(ndr, NDR_BUFFERS, &r->array[cntr_array_1]));
3395 : }
3396 : }
3397 : }
3398 17 : return NDR_ERR_SUCCESS;
3399 : }
3400 :
3401 16 : static enum ndr_err_code ndr_pull_srvsvc_NetSessCtr10(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct srvsvc_NetSessCtr10 *r)
3402 : {
3403 0 : uint32_t _ptr_array;
3404 16 : uint32_t size_array_1 = 0;
3405 0 : uint32_t cntr_array_1;
3406 16 : TALLOC_CTX *_mem_save_array_0 = NULL;
3407 16 : TALLOC_CTX *_mem_save_array_1 = NULL;
3408 16 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
3409 16 : if (ndr_flags & NDR_SCALARS) {
3410 16 : NDR_CHECK(ndr_pull_align(ndr, 5));
3411 16 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->count));
3412 16 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_array));
3413 16 : if (_ptr_array) {
3414 0 : NDR_PULL_ALLOC(ndr, r->array);
3415 : } else {
3416 16 : r->array = NULL;
3417 : }
3418 16 : NDR_CHECK(ndr_pull_trailer_align(ndr, 5));
3419 : }
3420 16 : if (ndr_flags & NDR_BUFFERS) {
3421 16 : if (r->array) {
3422 0 : _mem_save_array_0 = NDR_PULL_GET_MEM_CTX(ndr);
3423 0 : NDR_PULL_SET_MEM_CTX(ndr, r->array, 0);
3424 0 : NDR_CHECK(ndr_pull_array_size(ndr, &r->array));
3425 0 : NDR_CHECK(ndr_get_array_size(ndr, (void*)&r->array, &size_array_1));
3426 0 : NDR_PULL_ALLOC_N(ndr, r->array, size_array_1);
3427 0 : _mem_save_array_1 = NDR_PULL_GET_MEM_CTX(ndr);
3428 0 : NDR_PULL_SET_MEM_CTX(ndr, r->array, 0);
3429 0 : for (cntr_array_1 = 0; cntr_array_1 < (size_array_1); cntr_array_1++) {
3430 0 : NDR_CHECK(ndr_pull_srvsvc_NetSessInfo10(ndr, NDR_SCALARS, &r->array[cntr_array_1]));
3431 : }
3432 0 : for (cntr_array_1 = 0; cntr_array_1 < (size_array_1); cntr_array_1++) {
3433 0 : NDR_CHECK(ndr_pull_srvsvc_NetSessInfo10(ndr, NDR_BUFFERS, &r->array[cntr_array_1]));
3434 : }
3435 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_array_1, 0);
3436 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_array_0, 0);
3437 : }
3438 16 : if (r->array) {
3439 0 : NDR_CHECK(ndr_check_array_size(ndr, (void*)&r->array, r->count));
3440 : }
3441 16 : for (cntr_array_1 = 0; cntr_array_1 < (size_array_1); cntr_array_1++) {
3442 0 : }
3443 : }
3444 16 : return NDR_ERR_SUCCESS;
3445 : }
3446 :
3447 2 : _PUBLIC_ void ndr_print_srvsvc_NetSessCtr10(struct ndr_print *ndr, const char *name, const struct srvsvc_NetSessCtr10 *r)
3448 : {
3449 0 : uint32_t cntr_array_1;
3450 2 : ndr_print_struct(ndr, name, "srvsvc_NetSessCtr10");
3451 2 : if (r == NULL) { ndr_print_null(ndr); return; }
3452 2 : ndr->depth++;
3453 2 : ndr_print_uint32(ndr, "count", r->count);
3454 2 : ndr_print_ptr(ndr, "array", r->array);
3455 2 : ndr->depth++;
3456 2 : if (r->array) {
3457 0 : ndr->print(ndr, "%s: ARRAY(%"PRIu32")", "array", (uint32_t)(r->count));
3458 0 : ndr->depth++;
3459 0 : for (cntr_array_1 = 0; cntr_array_1 < (r->count); cntr_array_1++) {
3460 0 : ndr_print_srvsvc_NetSessInfo10(ndr, "array", &r->array[cntr_array_1]);
3461 : }
3462 0 : ndr->depth--;
3463 : }
3464 2 : ndr->depth--;
3465 2 : ndr->depth--;
3466 : }
3467 :
3468 0 : static enum ndr_err_code ndr_push_srvsvc_NetSessInfo502(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct srvsvc_NetSessInfo502 *r)
3469 : {
3470 0 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
3471 0 : if (ndr_flags & NDR_SCALARS) {
3472 0 : NDR_CHECK(ndr_push_align(ndr, 5));
3473 0 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->client));
3474 0 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->user));
3475 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->num_open));
3476 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->time));
3477 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->idle_time));
3478 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->user_flags));
3479 0 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->client_type));
3480 0 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->transport));
3481 0 : NDR_CHECK(ndr_push_trailer_align(ndr, 5));
3482 : }
3483 0 : if (ndr_flags & NDR_BUFFERS) {
3484 0 : if (r->client) {
3485 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->client, CH_UTF16)));
3486 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, 0));
3487 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->client, CH_UTF16)));
3488 0 : NDR_CHECK(ndr_push_charset(ndr, NDR_SCALARS, r->client, ndr_charset_length(r->client, CH_UTF16), sizeof(uint16_t), CH_UTF16));
3489 : }
3490 0 : if (r->user) {
3491 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->user, CH_UTF16)));
3492 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, 0));
3493 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->user, CH_UTF16)));
3494 0 : NDR_CHECK(ndr_push_charset(ndr, NDR_SCALARS, r->user, ndr_charset_length(r->user, CH_UTF16), sizeof(uint16_t), CH_UTF16));
3495 : }
3496 0 : if (r->client_type) {
3497 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->client_type, CH_UTF16)));
3498 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, 0));
3499 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->client_type, CH_UTF16)));
3500 0 : NDR_CHECK(ndr_push_charset(ndr, NDR_SCALARS, r->client_type, ndr_charset_length(r->client_type, CH_UTF16), sizeof(uint16_t), CH_UTF16));
3501 : }
3502 0 : if (r->transport) {
3503 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->transport, CH_UTF16)));
3504 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, 0));
3505 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->transport, CH_UTF16)));
3506 0 : NDR_CHECK(ndr_push_charset(ndr, NDR_SCALARS, r->transport, ndr_charset_length(r->transport, CH_UTF16), sizeof(uint16_t), CH_UTF16));
3507 : }
3508 : }
3509 0 : return NDR_ERR_SUCCESS;
3510 : }
3511 :
3512 0 : static enum ndr_err_code ndr_pull_srvsvc_NetSessInfo502(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct srvsvc_NetSessInfo502 *r)
3513 : {
3514 0 : uint32_t _ptr_client;
3515 0 : uint32_t size_client_1 = 0;
3516 0 : uint32_t length_client_1 = 0;
3517 0 : TALLOC_CTX *_mem_save_client_0 = NULL;
3518 0 : uint32_t _ptr_user;
3519 0 : uint32_t size_user_1 = 0;
3520 0 : uint32_t length_user_1 = 0;
3521 0 : TALLOC_CTX *_mem_save_user_0 = NULL;
3522 0 : uint32_t _ptr_client_type;
3523 0 : uint32_t size_client_type_1 = 0;
3524 0 : uint32_t length_client_type_1 = 0;
3525 0 : TALLOC_CTX *_mem_save_client_type_0 = NULL;
3526 0 : uint32_t _ptr_transport;
3527 0 : uint32_t size_transport_1 = 0;
3528 0 : uint32_t length_transport_1 = 0;
3529 0 : TALLOC_CTX *_mem_save_transport_0 = NULL;
3530 0 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
3531 0 : if (ndr_flags & NDR_SCALARS) {
3532 0 : NDR_CHECK(ndr_pull_align(ndr, 5));
3533 0 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_client));
3534 0 : if (_ptr_client) {
3535 0 : NDR_PULL_ALLOC(ndr, r->client);
3536 : } else {
3537 0 : r->client = NULL;
3538 : }
3539 0 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_user));
3540 0 : if (_ptr_user) {
3541 0 : NDR_PULL_ALLOC(ndr, r->user);
3542 : } else {
3543 0 : r->user = NULL;
3544 : }
3545 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->num_open));
3546 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->time));
3547 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->idle_time));
3548 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->user_flags));
3549 0 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_client_type));
3550 0 : if (_ptr_client_type) {
3551 0 : NDR_PULL_ALLOC(ndr, r->client_type);
3552 : } else {
3553 0 : r->client_type = NULL;
3554 : }
3555 0 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_transport));
3556 0 : if (_ptr_transport) {
3557 0 : NDR_PULL_ALLOC(ndr, r->transport);
3558 : } else {
3559 0 : r->transport = NULL;
3560 : }
3561 0 : NDR_CHECK(ndr_pull_trailer_align(ndr, 5));
3562 : }
3563 0 : if (ndr_flags & NDR_BUFFERS) {
3564 0 : if (r->client) {
3565 0 : _mem_save_client_0 = NDR_PULL_GET_MEM_CTX(ndr);
3566 0 : NDR_PULL_SET_MEM_CTX(ndr, r->client, 0);
3567 0 : NDR_CHECK(ndr_pull_array_size(ndr, &r->client));
3568 0 : NDR_CHECK(ndr_pull_array_length(ndr, &r->client));
3569 0 : NDR_CHECK(ndr_steal_array_size(ndr, (void*)&r->client, &size_client_1));
3570 0 : NDR_CHECK(ndr_steal_array_length(ndr, (void*)&r->client, &length_client_1));
3571 0 : if (length_client_1 > size_client_1) {
3572 0 : return ndr_pull_error(ndr, NDR_ERR_ARRAY_SIZE, "Bad array size %"PRIu32": should exceed array length %"PRIu32"", size_client_1, length_client_1);
3573 : }
3574 0 : NDR_CHECK(ndr_check_string_terminator(ndr, length_client_1, sizeof(uint16_t)));
3575 0 : NDR_CHECK(ndr_pull_charset(ndr, NDR_SCALARS, &r->client, length_client_1, sizeof(uint16_t), CH_UTF16));
3576 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_client_0, 0);
3577 : }
3578 0 : if (r->user) {
3579 0 : _mem_save_user_0 = NDR_PULL_GET_MEM_CTX(ndr);
3580 0 : NDR_PULL_SET_MEM_CTX(ndr, r->user, 0);
3581 0 : NDR_CHECK(ndr_pull_array_size(ndr, &r->user));
3582 0 : NDR_CHECK(ndr_pull_array_length(ndr, &r->user));
3583 0 : NDR_CHECK(ndr_steal_array_size(ndr, (void*)&r->user, &size_user_1));
3584 0 : NDR_CHECK(ndr_steal_array_length(ndr, (void*)&r->user, &length_user_1));
3585 0 : if (length_user_1 > size_user_1) {
3586 0 : return ndr_pull_error(ndr, NDR_ERR_ARRAY_SIZE, "Bad array size %"PRIu32": should exceed array length %"PRIu32"", size_user_1, length_user_1);
3587 : }
3588 0 : NDR_CHECK(ndr_check_string_terminator(ndr, length_user_1, sizeof(uint16_t)));
3589 0 : NDR_CHECK(ndr_pull_charset(ndr, NDR_SCALARS, &r->user, length_user_1, sizeof(uint16_t), CH_UTF16));
3590 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_user_0, 0);
3591 : }
3592 0 : if (r->client_type) {
3593 0 : _mem_save_client_type_0 = NDR_PULL_GET_MEM_CTX(ndr);
3594 0 : NDR_PULL_SET_MEM_CTX(ndr, r->client_type, 0);
3595 0 : NDR_CHECK(ndr_pull_array_size(ndr, &r->client_type));
3596 0 : NDR_CHECK(ndr_pull_array_length(ndr, &r->client_type));
3597 0 : NDR_CHECK(ndr_steal_array_size(ndr, (void*)&r->client_type, &size_client_type_1));
3598 0 : NDR_CHECK(ndr_steal_array_length(ndr, (void*)&r->client_type, &length_client_type_1));
3599 0 : if (length_client_type_1 > size_client_type_1) {
3600 0 : return ndr_pull_error(ndr, NDR_ERR_ARRAY_SIZE, "Bad array size %"PRIu32": should exceed array length %"PRIu32"", size_client_type_1, length_client_type_1);
3601 : }
3602 0 : NDR_CHECK(ndr_check_string_terminator(ndr, length_client_type_1, sizeof(uint16_t)));
3603 0 : NDR_CHECK(ndr_pull_charset(ndr, NDR_SCALARS, &r->client_type, length_client_type_1, sizeof(uint16_t), CH_UTF16));
3604 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_client_type_0, 0);
3605 : }
3606 0 : if (r->transport) {
3607 0 : _mem_save_transport_0 = NDR_PULL_GET_MEM_CTX(ndr);
3608 0 : NDR_PULL_SET_MEM_CTX(ndr, r->transport, 0);
3609 0 : NDR_CHECK(ndr_pull_array_size(ndr, &r->transport));
3610 0 : NDR_CHECK(ndr_pull_array_length(ndr, &r->transport));
3611 0 : NDR_CHECK(ndr_steal_array_size(ndr, (void*)&r->transport, &size_transport_1));
3612 0 : NDR_CHECK(ndr_steal_array_length(ndr, (void*)&r->transport, &length_transport_1));
3613 0 : if (length_transport_1 > size_transport_1) {
3614 0 : return ndr_pull_error(ndr, NDR_ERR_ARRAY_SIZE, "Bad array size %"PRIu32": should exceed array length %"PRIu32"", size_transport_1, length_transport_1);
3615 : }
3616 0 : NDR_CHECK(ndr_check_string_terminator(ndr, length_transport_1, sizeof(uint16_t)));
3617 0 : NDR_CHECK(ndr_pull_charset(ndr, NDR_SCALARS, &r->transport, length_transport_1, sizeof(uint16_t), CH_UTF16));
3618 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_transport_0, 0);
3619 : }
3620 : }
3621 0 : return NDR_ERR_SUCCESS;
3622 : }
3623 :
3624 0 : _PUBLIC_ void ndr_print_srvsvc_NetSessInfo502(struct ndr_print *ndr, const char *name, const struct srvsvc_NetSessInfo502 *r)
3625 : {
3626 0 : ndr_print_struct(ndr, name, "srvsvc_NetSessInfo502");
3627 0 : if (r == NULL) { ndr_print_null(ndr); return; }
3628 0 : ndr->depth++;
3629 0 : ndr_print_ptr(ndr, "client", r->client);
3630 0 : ndr->depth++;
3631 0 : if (r->client) {
3632 0 : ndr_print_string(ndr, "client", r->client);
3633 : }
3634 0 : ndr->depth--;
3635 0 : ndr_print_ptr(ndr, "user", r->user);
3636 0 : ndr->depth++;
3637 0 : if (r->user) {
3638 0 : ndr_print_string(ndr, "user", r->user);
3639 : }
3640 0 : ndr->depth--;
3641 0 : ndr_print_uint32(ndr, "num_open", r->num_open);
3642 0 : ndr_print_uint32(ndr, "time", r->time);
3643 0 : ndr_print_uint32(ndr, "idle_time", r->idle_time);
3644 0 : ndr_print_uint32(ndr, "user_flags", r->user_flags);
3645 0 : ndr_print_ptr(ndr, "client_type", r->client_type);
3646 0 : ndr->depth++;
3647 0 : if (r->client_type) {
3648 0 : ndr_print_string(ndr, "client_type", r->client_type);
3649 : }
3650 0 : ndr->depth--;
3651 0 : ndr_print_ptr(ndr, "transport", r->transport);
3652 0 : ndr->depth++;
3653 0 : if (r->transport) {
3654 0 : ndr_print_string(ndr, "transport", r->transport);
3655 : }
3656 0 : ndr->depth--;
3657 0 : ndr->depth--;
3658 : }
3659 :
3660 17 : static enum ndr_err_code ndr_push_srvsvc_NetSessCtr502(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct srvsvc_NetSessCtr502 *r)
3661 : {
3662 0 : uint32_t cntr_array_1;
3663 17 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
3664 17 : if (ndr_flags & NDR_SCALARS) {
3665 17 : NDR_CHECK(ndr_push_align(ndr, 5));
3666 17 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->count));
3667 17 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->array));
3668 17 : NDR_CHECK(ndr_push_trailer_align(ndr, 5));
3669 : }
3670 17 : if (ndr_flags & NDR_BUFFERS) {
3671 17 : if (r->array) {
3672 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, r->count));
3673 0 : for (cntr_array_1 = 0; cntr_array_1 < (r->count); cntr_array_1++) {
3674 0 : NDR_CHECK(ndr_push_srvsvc_NetSessInfo502(ndr, NDR_SCALARS, &r->array[cntr_array_1]));
3675 : }
3676 0 : for (cntr_array_1 = 0; cntr_array_1 < (r->count); cntr_array_1++) {
3677 0 : NDR_CHECK(ndr_push_srvsvc_NetSessInfo502(ndr, NDR_BUFFERS, &r->array[cntr_array_1]));
3678 : }
3679 : }
3680 : }
3681 17 : return NDR_ERR_SUCCESS;
3682 : }
3683 :
3684 16 : static enum ndr_err_code ndr_pull_srvsvc_NetSessCtr502(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct srvsvc_NetSessCtr502 *r)
3685 : {
3686 0 : uint32_t _ptr_array;
3687 16 : uint32_t size_array_1 = 0;
3688 0 : uint32_t cntr_array_1;
3689 16 : TALLOC_CTX *_mem_save_array_0 = NULL;
3690 16 : TALLOC_CTX *_mem_save_array_1 = NULL;
3691 16 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
3692 16 : if (ndr_flags & NDR_SCALARS) {
3693 16 : NDR_CHECK(ndr_pull_align(ndr, 5));
3694 16 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->count));
3695 16 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_array));
3696 16 : if (_ptr_array) {
3697 0 : NDR_PULL_ALLOC(ndr, r->array);
3698 : } else {
3699 16 : r->array = NULL;
3700 : }
3701 16 : NDR_CHECK(ndr_pull_trailer_align(ndr, 5));
3702 : }
3703 16 : if (ndr_flags & NDR_BUFFERS) {
3704 16 : if (r->array) {
3705 0 : _mem_save_array_0 = NDR_PULL_GET_MEM_CTX(ndr);
3706 0 : NDR_PULL_SET_MEM_CTX(ndr, r->array, 0);
3707 0 : NDR_CHECK(ndr_pull_array_size(ndr, &r->array));
3708 0 : NDR_CHECK(ndr_get_array_size(ndr, (void*)&r->array, &size_array_1));
3709 0 : NDR_PULL_ALLOC_N(ndr, r->array, size_array_1);
3710 0 : _mem_save_array_1 = NDR_PULL_GET_MEM_CTX(ndr);
3711 0 : NDR_PULL_SET_MEM_CTX(ndr, r->array, 0);
3712 0 : for (cntr_array_1 = 0; cntr_array_1 < (size_array_1); cntr_array_1++) {
3713 0 : NDR_CHECK(ndr_pull_srvsvc_NetSessInfo502(ndr, NDR_SCALARS, &r->array[cntr_array_1]));
3714 : }
3715 0 : for (cntr_array_1 = 0; cntr_array_1 < (size_array_1); cntr_array_1++) {
3716 0 : NDR_CHECK(ndr_pull_srvsvc_NetSessInfo502(ndr, NDR_BUFFERS, &r->array[cntr_array_1]));
3717 : }
3718 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_array_1, 0);
3719 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_array_0, 0);
3720 : }
3721 16 : if (r->array) {
3722 0 : NDR_CHECK(ndr_check_array_size(ndr, (void*)&r->array, r->count));
3723 : }
3724 16 : for (cntr_array_1 = 0; cntr_array_1 < (size_array_1); cntr_array_1++) {
3725 0 : }
3726 : }
3727 16 : return NDR_ERR_SUCCESS;
3728 : }
3729 :
3730 2 : _PUBLIC_ void ndr_print_srvsvc_NetSessCtr502(struct ndr_print *ndr, const char *name, const struct srvsvc_NetSessCtr502 *r)
3731 : {
3732 0 : uint32_t cntr_array_1;
3733 2 : ndr_print_struct(ndr, name, "srvsvc_NetSessCtr502");
3734 2 : if (r == NULL) { ndr_print_null(ndr); return; }
3735 2 : ndr->depth++;
3736 2 : ndr_print_uint32(ndr, "count", r->count);
3737 2 : ndr_print_ptr(ndr, "array", r->array);
3738 2 : ndr->depth++;
3739 2 : if (r->array) {
3740 0 : ndr->print(ndr, "%s: ARRAY(%"PRIu32")", "array", (uint32_t)(r->count));
3741 0 : ndr->depth++;
3742 0 : for (cntr_array_1 = 0; cntr_array_1 < (r->count); cntr_array_1++) {
3743 0 : ndr_print_srvsvc_NetSessInfo502(ndr, "array", &r->array[cntr_array_1]);
3744 : }
3745 0 : ndr->depth--;
3746 : }
3747 2 : ndr->depth--;
3748 2 : ndr->depth--;
3749 : }
3750 :
3751 226 : static enum ndr_err_code ndr_push_srvsvc_NetSessCtr(struct ndr_push *ndr, ndr_flags_type ndr_flags, const union srvsvc_NetSessCtr *r)
3752 : {
3753 0 : uint32_t level;
3754 226 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
3755 226 : if (ndr_flags & NDR_SCALARS) {
3756 : /* This token is not used again (except perhaps below in the NDR_BUFFERS case) */
3757 113 : NDR_CHECK(ndr_push_steal_switch_value(ndr, r, &level));
3758 113 : NDR_CHECK(ndr_push_union_align(ndr, 5));
3759 113 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, level));
3760 113 : NDR_CHECK(ndr_push_union_align(ndr, 5));
3761 113 : switch (level) {
3762 17 : case 0: {
3763 17 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->ctr0));
3764 17 : break; }
3765 :
3766 45 : case 1: {
3767 45 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->ctr1));
3768 45 : break; }
3769 :
3770 17 : case 2: {
3771 17 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->ctr2));
3772 17 : break; }
3773 :
3774 17 : case 10: {
3775 17 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->ctr10));
3776 17 : break; }
3777 :
3778 17 : case 502: {
3779 17 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->ctr502));
3780 17 : break; }
3781 :
3782 0 : default: {
3783 0 : break; }
3784 :
3785 : }
3786 : }
3787 226 : if (ndr_flags & NDR_BUFFERS) {
3788 113 : if (!(ndr_flags & NDR_SCALARS)) {
3789 : /* We didn't get it above, and the token is not needed after this. */
3790 113 : NDR_CHECK(ndr_push_steal_switch_value(ndr, r, &level));
3791 : }
3792 113 : switch (level) {
3793 17 : case 0:
3794 17 : if (r->ctr0) {
3795 17 : NDR_CHECK(ndr_push_srvsvc_NetSessCtr0(ndr, NDR_SCALARS|NDR_BUFFERS, r->ctr0));
3796 : }
3797 17 : break;
3798 :
3799 45 : case 1:
3800 45 : if (r->ctr1) {
3801 45 : NDR_CHECK(ndr_push_srvsvc_NetSessCtr1(ndr, NDR_SCALARS|NDR_BUFFERS, r->ctr1));
3802 : }
3803 45 : break;
3804 :
3805 17 : case 2:
3806 17 : if (r->ctr2) {
3807 17 : NDR_CHECK(ndr_push_srvsvc_NetSessCtr2(ndr, NDR_SCALARS|NDR_BUFFERS, r->ctr2));
3808 : }
3809 17 : break;
3810 :
3811 17 : case 10:
3812 17 : if (r->ctr10) {
3813 17 : NDR_CHECK(ndr_push_srvsvc_NetSessCtr10(ndr, NDR_SCALARS|NDR_BUFFERS, r->ctr10));
3814 : }
3815 17 : break;
3816 :
3817 17 : case 502:
3818 17 : if (r->ctr502) {
3819 17 : NDR_CHECK(ndr_push_srvsvc_NetSessCtr502(ndr, NDR_SCALARS|NDR_BUFFERS, r->ctr502));
3820 : }
3821 17 : break;
3822 :
3823 0 : default:
3824 0 : break;
3825 :
3826 : }
3827 : }
3828 226 : return NDR_ERR_SUCCESS;
3829 : }
3830 :
3831 216 : static enum ndr_err_code ndr_pull_srvsvc_NetSessCtr(struct ndr_pull *ndr, ndr_flags_type ndr_flags, union srvsvc_NetSessCtr *r)
3832 : {
3833 0 : uint32_t level;
3834 0 : uint32_t _level;
3835 216 : TALLOC_CTX *_mem_save_ctr0_0 = NULL;
3836 0 : uint32_t _ptr_ctr0;
3837 216 : TALLOC_CTX *_mem_save_ctr1_0 = NULL;
3838 0 : uint32_t _ptr_ctr1;
3839 216 : TALLOC_CTX *_mem_save_ctr2_0 = NULL;
3840 0 : uint32_t _ptr_ctr2;
3841 216 : TALLOC_CTX *_mem_save_ctr10_0 = NULL;
3842 0 : uint32_t _ptr_ctr10;
3843 216 : TALLOC_CTX *_mem_save_ctr502_0 = NULL;
3844 0 : uint32_t _ptr_ctr502;
3845 216 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
3846 216 : if (ndr_flags & NDR_SCALARS) {
3847 : /* This token is not used again (except perhaps below in the NDR_BUFFERS case) */
3848 108 : NDR_CHECK(ndr_pull_steal_switch_value(ndr, r, &level));
3849 108 : NDR_CHECK(ndr_pull_union_align(ndr, 5));
3850 108 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &_level));
3851 108 : if (_level != level) {
3852 0 : return ndr_pull_error(ndr, NDR_ERR_BAD_SWITCH, "Bad switch value %"PRIu32" for r at %s", (uint32_t)_level, __location__);
3853 : }
3854 108 : NDR_CHECK(ndr_pull_union_align(ndr, 5));
3855 108 : switch (level) {
3856 16 : case 0: {
3857 16 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_ctr0));
3858 16 : if (_ptr_ctr0) {
3859 16 : NDR_PULL_ALLOC(ndr, r->ctr0);
3860 : } else {
3861 0 : r->ctr0 = NULL;
3862 : }
3863 16 : break; }
3864 :
3865 44 : case 1: {
3866 44 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_ctr1));
3867 44 : if (_ptr_ctr1) {
3868 44 : NDR_PULL_ALLOC(ndr, r->ctr1);
3869 : } else {
3870 0 : r->ctr1 = NULL;
3871 : }
3872 44 : break; }
3873 :
3874 16 : case 2: {
3875 16 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_ctr2));
3876 16 : if (_ptr_ctr2) {
3877 16 : NDR_PULL_ALLOC(ndr, r->ctr2);
3878 : } else {
3879 0 : r->ctr2 = NULL;
3880 : }
3881 16 : break; }
3882 :
3883 16 : case 10: {
3884 16 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_ctr10));
3885 16 : if (_ptr_ctr10) {
3886 16 : NDR_PULL_ALLOC(ndr, r->ctr10);
3887 : } else {
3888 0 : r->ctr10 = NULL;
3889 : }
3890 16 : break; }
3891 :
3892 16 : case 502: {
3893 16 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_ctr502));
3894 16 : if (_ptr_ctr502) {
3895 16 : NDR_PULL_ALLOC(ndr, r->ctr502);
3896 : } else {
3897 0 : r->ctr502 = NULL;
3898 : }
3899 16 : break; }
3900 :
3901 0 : default: {
3902 0 : break; }
3903 :
3904 : }
3905 : }
3906 216 : if (ndr_flags & NDR_BUFFERS) {
3907 108 : if (!(ndr_flags & NDR_SCALARS)) {
3908 : /* We didn't get it above, and the token is not needed after this. */
3909 108 : NDR_CHECK(ndr_pull_steal_switch_value(ndr, r, &level));
3910 : }
3911 108 : switch (level) {
3912 16 : case 0:
3913 16 : if (r->ctr0) {
3914 16 : _mem_save_ctr0_0 = NDR_PULL_GET_MEM_CTX(ndr);
3915 16 : NDR_PULL_SET_MEM_CTX(ndr, r->ctr0, 0);
3916 16 : NDR_CHECK(ndr_pull_srvsvc_NetSessCtr0(ndr, NDR_SCALARS|NDR_BUFFERS, r->ctr0));
3917 16 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_ctr0_0, 0);
3918 : }
3919 16 : break;
3920 :
3921 44 : case 1:
3922 44 : if (r->ctr1) {
3923 44 : _mem_save_ctr1_0 = NDR_PULL_GET_MEM_CTX(ndr);
3924 44 : NDR_PULL_SET_MEM_CTX(ndr, r->ctr1, 0);
3925 44 : NDR_CHECK(ndr_pull_srvsvc_NetSessCtr1(ndr, NDR_SCALARS|NDR_BUFFERS, r->ctr1));
3926 44 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_ctr1_0, 0);
3927 : }
3928 44 : break;
3929 :
3930 16 : case 2:
3931 16 : if (r->ctr2) {
3932 16 : _mem_save_ctr2_0 = NDR_PULL_GET_MEM_CTX(ndr);
3933 16 : NDR_PULL_SET_MEM_CTX(ndr, r->ctr2, 0);
3934 16 : NDR_CHECK(ndr_pull_srvsvc_NetSessCtr2(ndr, NDR_SCALARS|NDR_BUFFERS, r->ctr2));
3935 16 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_ctr2_0, 0);
3936 : }
3937 16 : break;
3938 :
3939 16 : case 10:
3940 16 : if (r->ctr10) {
3941 16 : _mem_save_ctr10_0 = NDR_PULL_GET_MEM_CTX(ndr);
3942 16 : NDR_PULL_SET_MEM_CTX(ndr, r->ctr10, 0);
3943 16 : NDR_CHECK(ndr_pull_srvsvc_NetSessCtr10(ndr, NDR_SCALARS|NDR_BUFFERS, r->ctr10));
3944 16 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_ctr10_0, 0);
3945 : }
3946 16 : break;
3947 :
3948 16 : case 502:
3949 16 : if (r->ctr502) {
3950 16 : _mem_save_ctr502_0 = NDR_PULL_GET_MEM_CTX(ndr);
3951 16 : NDR_PULL_SET_MEM_CTX(ndr, r->ctr502, 0);
3952 16 : NDR_CHECK(ndr_pull_srvsvc_NetSessCtr502(ndr, NDR_SCALARS|NDR_BUFFERS, r->ctr502));
3953 16 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_ctr502_0, 0);
3954 : }
3955 16 : break;
3956 :
3957 0 : default:
3958 0 : break;
3959 :
3960 : }
3961 : }
3962 216 : return NDR_ERR_SUCCESS;
3963 : }
3964 :
3965 10 : _PUBLIC_ void ndr_print_srvsvc_NetSessCtr(struct ndr_print *ndr, const char *name, const union srvsvc_NetSessCtr *r)
3966 : {
3967 0 : uint32_t level;
3968 10 : level = ndr_print_steal_switch_value(ndr, r);
3969 10 : ndr_print_union(ndr, name, level, "srvsvc_NetSessCtr");
3970 10 : switch (level) {
3971 2 : case 0:
3972 2 : ndr_print_ptr(ndr, "ctr0", r->ctr0);
3973 2 : ndr->depth++;
3974 2 : if (r->ctr0) {
3975 2 : ndr_print_srvsvc_NetSessCtr0(ndr, "ctr0", r->ctr0);
3976 : }
3977 2 : ndr->depth--;
3978 2 : break;
3979 :
3980 2 : case 1:
3981 2 : ndr_print_ptr(ndr, "ctr1", r->ctr1);
3982 2 : ndr->depth++;
3983 2 : if (r->ctr1) {
3984 2 : ndr_print_srvsvc_NetSessCtr1(ndr, "ctr1", r->ctr1);
3985 : }
3986 2 : ndr->depth--;
3987 2 : break;
3988 :
3989 2 : case 2:
3990 2 : ndr_print_ptr(ndr, "ctr2", r->ctr2);
3991 2 : ndr->depth++;
3992 2 : if (r->ctr2) {
3993 2 : ndr_print_srvsvc_NetSessCtr2(ndr, "ctr2", r->ctr2);
3994 : }
3995 2 : ndr->depth--;
3996 2 : break;
3997 :
3998 2 : case 10:
3999 2 : ndr_print_ptr(ndr, "ctr10", r->ctr10);
4000 2 : ndr->depth++;
4001 2 : if (r->ctr10) {
4002 2 : ndr_print_srvsvc_NetSessCtr10(ndr, "ctr10", r->ctr10);
4003 : }
4004 2 : ndr->depth--;
4005 2 : break;
4006 :
4007 2 : case 502:
4008 2 : ndr_print_ptr(ndr, "ctr502", r->ctr502);
4009 2 : ndr->depth++;
4010 2 : if (r->ctr502) {
4011 2 : ndr_print_srvsvc_NetSessCtr502(ndr, "ctr502", r->ctr502);
4012 : }
4013 2 : ndr->depth--;
4014 2 : break;
4015 :
4016 0 : default:
4017 0 : break;
4018 :
4019 : }
4020 10 : }
4021 :
4022 113 : static enum ndr_err_code ndr_push_srvsvc_NetSessInfoCtr(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct srvsvc_NetSessInfoCtr *r)
4023 : {
4024 113 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
4025 113 : if (ndr_flags & NDR_SCALARS) {
4026 113 : NDR_CHECK(ndr_push_align(ndr, 5));
4027 113 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->level));
4028 113 : NDR_CHECK(ndr_push_set_switch_value(ndr, &r->ctr, r->level));
4029 113 : NDR_CHECK(ndr_push_srvsvc_NetSessCtr(ndr, NDR_SCALARS, &r->ctr));
4030 113 : NDR_CHECK(ndr_push_trailer_align(ndr, 5));
4031 : }
4032 113 : if (ndr_flags & NDR_BUFFERS) {
4033 113 : NDR_CHECK(ndr_push_set_switch_value(ndr, &r->ctr, r->level));
4034 113 : NDR_CHECK(ndr_push_srvsvc_NetSessCtr(ndr, NDR_BUFFERS, &r->ctr));
4035 : }
4036 113 : return NDR_ERR_SUCCESS;
4037 : }
4038 :
4039 108 : static enum ndr_err_code ndr_pull_srvsvc_NetSessInfoCtr(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct srvsvc_NetSessInfoCtr *r)
4040 : {
4041 108 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
4042 108 : if (ndr_flags & NDR_SCALARS) {
4043 108 : NDR_CHECK(ndr_pull_align(ndr, 5));
4044 108 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->level));
4045 108 : NDR_CHECK(ndr_pull_set_switch_value(ndr, &r->ctr, r->level));
4046 108 : NDR_CHECK(ndr_pull_srvsvc_NetSessCtr(ndr, NDR_SCALARS, &r->ctr));
4047 108 : NDR_CHECK(ndr_pull_trailer_align(ndr, 5));
4048 : }
4049 108 : if (ndr_flags & NDR_BUFFERS) {
4050 108 : NDR_CHECK(ndr_pull_set_switch_value(ndr, &r->ctr, r->level));
4051 108 : NDR_CHECK(ndr_pull_srvsvc_NetSessCtr(ndr, NDR_BUFFERS, &r->ctr));
4052 : }
4053 108 : return NDR_ERR_SUCCESS;
4054 : }
4055 :
4056 10 : _PUBLIC_ void ndr_print_srvsvc_NetSessInfoCtr(struct ndr_print *ndr, const char *name, const struct srvsvc_NetSessInfoCtr *r)
4057 : {
4058 10 : ndr_print_struct(ndr, name, "srvsvc_NetSessInfoCtr");
4059 10 : if (r == NULL) { ndr_print_null(ndr); return; }
4060 10 : ndr->depth++;
4061 10 : ndr_print_uint32(ndr, "level", r->level);
4062 10 : ndr_print_set_switch_value(ndr, &r->ctr, r->level);
4063 10 : ndr_print_srvsvc_NetSessCtr(ndr, "ctr", &r->ctr);
4064 10 : ndr->depth--;
4065 : }
4066 :
4067 17288 : static enum ndr_err_code ndr_push_srvsvc_ShareType(struct ndr_push *ndr, ndr_flags_type ndr_flags, enum srvsvc_ShareType r)
4068 : {
4069 : {
4070 17288 : libndr_flags _flags_save_ENUM = ndr->flags;
4071 17288 : ndr_set_flags(&ndr->flags, LIBNDR_PRINT_ARRAY_HEX);
4072 17288 : NDR_CHECK(ndr_push_enum_uint32(ndr, NDR_SCALARS, r));
4073 17288 : ndr->flags = _flags_save_ENUM;
4074 : }
4075 17288 : return NDR_ERR_SUCCESS;
4076 : }
4077 :
4078 20853 : static enum ndr_err_code ndr_pull_srvsvc_ShareType(struct ndr_pull *ndr, ndr_flags_type ndr_flags, enum srvsvc_ShareType *r)
4079 : {
4080 0 : uint32_t v;
4081 : {
4082 20853 : libndr_flags _flags_save_ENUM = ndr->flags;
4083 20853 : ndr_set_flags(&ndr->flags, LIBNDR_PRINT_ARRAY_HEX);
4084 20853 : NDR_CHECK(ndr_pull_enum_uint32(ndr, NDR_SCALARS, &v));
4085 20853 : *r = v;
4086 20853 : ndr->flags = _flags_save_ENUM;
4087 : }
4088 20853 : return NDR_ERR_SUCCESS;
4089 : }
4090 :
4091 370 : _PUBLIC_ void ndr_print_srvsvc_ShareType(struct ndr_print *ndr, const char *name, enum srvsvc_ShareType r)
4092 : {
4093 370 : const char *val = NULL;
4094 :
4095 : {
4096 370 : libndr_flags _flags_save_ENUM = ndr->flags;
4097 370 : ndr_set_flags(&ndr->flags, LIBNDR_PRINT_ARRAY_HEX);
4098 370 : switch (r) {
4099 336 : case STYPE_DISKTREE: val = "STYPE_DISKTREE"; break;
4100 0 : case STYPE_DISKTREE_TEMPORARY: val = "STYPE_DISKTREE_TEMPORARY"; break;
4101 0 : case STYPE_DISKTREE_HIDDEN: val = "STYPE_DISKTREE_HIDDEN"; break;
4102 0 : case STYPE_PRINTQ: val = "STYPE_PRINTQ"; break;
4103 0 : case STYPE_PRINTQ_TEMPORARY: val = "STYPE_PRINTQ_TEMPORARY"; break;
4104 0 : case STYPE_PRINTQ_HIDDEN: val = "STYPE_PRINTQ_HIDDEN"; break;
4105 0 : case STYPE_DEVICE: val = "STYPE_DEVICE"; break;
4106 0 : case STYPE_DEVICE_TEMPORARY: val = "STYPE_DEVICE_TEMPORARY"; break;
4107 0 : case STYPE_DEVICE_HIDDEN: val = "STYPE_DEVICE_HIDDEN"; break;
4108 4 : case STYPE_IPC: val = "STYPE_IPC"; break;
4109 0 : case STYPE_IPC_TEMPORARY: val = "STYPE_IPC_TEMPORARY"; break;
4110 30 : case STYPE_IPC_HIDDEN: val = "STYPE_IPC_HIDDEN"; break;
4111 0 : case STYPE_CLUSTER_FS: val = "STYPE_CLUSTER_FS"; break;
4112 0 : case STYPE_CLUSTER_FS_TEMPORARY: val = "STYPE_CLUSTER_FS_TEMPORARY"; break;
4113 0 : case STYPE_CLUSTER_FS_HIDDEN: val = "STYPE_CLUSTER_FS_HIDDEN"; break;
4114 0 : case STYPE_CLUSTER_SOFS: val = "STYPE_CLUSTER_SOFS"; break;
4115 0 : case STYPE_CLUSTER_SOFS_TEMPORARY: val = "STYPE_CLUSTER_SOFS_TEMPORARY"; break;
4116 0 : case STYPE_CLUSTER_SOFS_HIDDEN: val = "STYPE_CLUSTER_SOFS_HIDDEN"; break;
4117 0 : case STYPE_CLUSTER_DFS: val = "STYPE_CLUSTER_DFS"; break;
4118 0 : case STYPE_CLUSTER_DFS_TEMPORARY: val = "STYPE_CLUSTER_DFS_TEMPORARY"; break;
4119 0 : case STYPE_CLUSTER_DFS_HIDDEN: val = "STYPE_CLUSTER_DFS_HIDDEN"; break;
4120 : }
4121 370 : ndr_print_enum(ndr, name, "ENUM", val, r);
4122 370 : ndr->flags = _flags_save_ENUM;
4123 : }
4124 370 : }
4125 :
4126 3823 : static enum ndr_err_code ndr_push_srvsvc_NetShareInfo0(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct srvsvc_NetShareInfo0 *r)
4127 : {
4128 3823 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
4129 3823 : if (ndr_flags & NDR_SCALARS) {
4130 1957 : NDR_CHECK(ndr_push_align(ndr, 5));
4131 1957 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->name));
4132 1957 : NDR_CHECK(ndr_push_trailer_align(ndr, 5));
4133 : }
4134 3823 : if (ndr_flags & NDR_BUFFERS) {
4135 1957 : if (r->name) {
4136 1957 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->name, CH_UTF16)));
4137 1957 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, 0));
4138 1957 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->name, CH_UTF16)));
4139 1957 : NDR_CHECK(ndr_push_charset(ndr, NDR_SCALARS, r->name, ndr_charset_length(r->name, CH_UTF16), sizeof(uint16_t), CH_UTF16));
4140 : }
4141 : }
4142 3823 : return NDR_ERR_SUCCESS;
4143 : }
4144 :
4145 3708 : static enum ndr_err_code ndr_pull_srvsvc_NetShareInfo0(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct srvsvc_NetShareInfo0 *r)
4146 : {
4147 0 : uint32_t _ptr_name;
4148 3708 : uint32_t size_name_1 = 0;
4149 3708 : uint32_t length_name_1 = 0;
4150 3708 : TALLOC_CTX *_mem_save_name_0 = NULL;
4151 3708 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
4152 3708 : if (ndr_flags & NDR_SCALARS) {
4153 1892 : NDR_CHECK(ndr_pull_align(ndr, 5));
4154 1892 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_name));
4155 1892 : if (_ptr_name) {
4156 1892 : NDR_PULL_ALLOC(ndr, r->name);
4157 : } else {
4158 0 : r->name = NULL;
4159 : }
4160 1892 : NDR_CHECK(ndr_pull_trailer_align(ndr, 5));
4161 : }
4162 3708 : if (ndr_flags & NDR_BUFFERS) {
4163 1892 : if (r->name) {
4164 1892 : _mem_save_name_0 = NDR_PULL_GET_MEM_CTX(ndr);
4165 1892 : NDR_PULL_SET_MEM_CTX(ndr, r->name, 0);
4166 1892 : NDR_CHECK(ndr_pull_array_size(ndr, &r->name));
4167 1892 : NDR_CHECK(ndr_pull_array_length(ndr, &r->name));
4168 1892 : NDR_CHECK(ndr_steal_array_size(ndr, (void*)&r->name, &size_name_1));
4169 1892 : NDR_CHECK(ndr_steal_array_length(ndr, (void*)&r->name, &length_name_1));
4170 1892 : if (length_name_1 > size_name_1) {
4171 0 : return ndr_pull_error(ndr, NDR_ERR_ARRAY_SIZE, "Bad array size %"PRIu32": should exceed array length %"PRIu32"", size_name_1, length_name_1);
4172 : }
4173 1892 : NDR_CHECK(ndr_check_string_terminator(ndr, length_name_1, sizeof(uint16_t)));
4174 1892 : NDR_CHECK(ndr_pull_charset(ndr, NDR_SCALARS, &r->name, length_name_1, sizeof(uint16_t), CH_UTF16));
4175 1892 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_name_0, 0);
4176 : }
4177 : }
4178 3708 : return NDR_ERR_SUCCESS;
4179 : }
4180 :
4181 130 : _PUBLIC_ void ndr_print_srvsvc_NetShareInfo0(struct ndr_print *ndr, const char *name, const struct srvsvc_NetShareInfo0 *r)
4182 : {
4183 130 : ndr_print_struct(ndr, name, "srvsvc_NetShareInfo0");
4184 130 : if (r == NULL) { ndr_print_null(ndr); return; }
4185 130 : ndr->depth++;
4186 130 : ndr_print_ptr(ndr, "name", r->name);
4187 130 : ndr->depth++;
4188 130 : if (r->name) {
4189 130 : ndr_print_string(ndr, "name", r->name);
4190 : }
4191 130 : ndr->depth--;
4192 130 : ndr->depth--;
4193 : }
4194 :
4195 78 : static enum ndr_err_code ndr_push_srvsvc_NetShareCtr0(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct srvsvc_NetShareCtr0 *r)
4196 : {
4197 0 : uint32_t cntr_array_1;
4198 78 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
4199 78 : if (ndr_flags & NDR_SCALARS) {
4200 78 : NDR_CHECK(ndr_push_align(ndr, 5));
4201 78 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->count));
4202 78 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->array));
4203 78 : NDR_CHECK(ndr_push_trailer_align(ndr, 5));
4204 : }
4205 78 : if (ndr_flags & NDR_BUFFERS) {
4206 78 : if (r->array) {
4207 41 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, r->count));
4208 1907 : for (cntr_array_1 = 0; cntr_array_1 < (r->count); cntr_array_1++) {
4209 1866 : NDR_CHECK(ndr_push_srvsvc_NetShareInfo0(ndr, NDR_SCALARS, &r->array[cntr_array_1]));
4210 : }
4211 1907 : for (cntr_array_1 = 0; cntr_array_1 < (r->count); cntr_array_1++) {
4212 1866 : NDR_CHECK(ndr_push_srvsvc_NetShareInfo0(ndr, NDR_BUFFERS, &r->array[cntr_array_1]));
4213 : }
4214 : }
4215 : }
4216 78 : return NDR_ERR_SUCCESS;
4217 : }
4218 :
4219 74 : static enum ndr_err_code ndr_pull_srvsvc_NetShareCtr0(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct srvsvc_NetShareCtr0 *r)
4220 : {
4221 0 : uint32_t _ptr_array;
4222 74 : uint32_t size_array_1 = 0;
4223 0 : uint32_t cntr_array_1;
4224 74 : TALLOC_CTX *_mem_save_array_0 = NULL;
4225 74 : TALLOC_CTX *_mem_save_array_1 = NULL;
4226 74 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
4227 74 : if (ndr_flags & NDR_SCALARS) {
4228 74 : NDR_CHECK(ndr_pull_align(ndr, 5));
4229 74 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->count));
4230 74 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_array));
4231 74 : if (_ptr_array) {
4232 37 : NDR_PULL_ALLOC(ndr, r->array);
4233 : } else {
4234 37 : r->array = NULL;
4235 : }
4236 74 : NDR_CHECK(ndr_pull_trailer_align(ndr, 5));
4237 : }
4238 74 : if (ndr_flags & NDR_BUFFERS) {
4239 74 : if (r->array) {
4240 37 : _mem_save_array_0 = NDR_PULL_GET_MEM_CTX(ndr);
4241 37 : NDR_PULL_SET_MEM_CTX(ndr, r->array, 0);
4242 37 : NDR_CHECK(ndr_pull_array_size(ndr, &r->array));
4243 37 : NDR_CHECK(ndr_get_array_size(ndr, (void*)&r->array, &size_array_1));
4244 37 : NDR_PULL_ALLOC_N(ndr, r->array, size_array_1);
4245 37 : _mem_save_array_1 = NDR_PULL_GET_MEM_CTX(ndr);
4246 37 : NDR_PULL_SET_MEM_CTX(ndr, r->array, 0);
4247 1853 : for (cntr_array_1 = 0; cntr_array_1 < (size_array_1); cntr_array_1++) {
4248 1816 : NDR_CHECK(ndr_pull_srvsvc_NetShareInfo0(ndr, NDR_SCALARS, &r->array[cntr_array_1]));
4249 : }
4250 1853 : for (cntr_array_1 = 0; cntr_array_1 < (size_array_1); cntr_array_1++) {
4251 1816 : NDR_CHECK(ndr_pull_srvsvc_NetShareInfo0(ndr, NDR_BUFFERS, &r->array[cntr_array_1]));
4252 : }
4253 37 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_array_1, 0);
4254 37 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_array_0, 0);
4255 : }
4256 74 : if (r->array) {
4257 37 : NDR_CHECK(ndr_check_array_size(ndr, (void*)&r->array, r->count));
4258 : }
4259 1890 : for (cntr_array_1 = 0; cntr_array_1 < (size_array_1); cntr_array_1++) {
4260 0 : }
4261 : }
4262 74 : return NDR_ERR_SUCCESS;
4263 : }
4264 :
4265 8 : _PUBLIC_ void ndr_print_srvsvc_NetShareCtr0(struct ndr_print *ndr, const char *name, const struct srvsvc_NetShareCtr0 *r)
4266 : {
4267 0 : uint32_t cntr_array_1;
4268 8 : ndr_print_struct(ndr, name, "srvsvc_NetShareCtr0");
4269 8 : if (r == NULL) { ndr_print_null(ndr); return; }
4270 8 : ndr->depth++;
4271 8 : ndr_print_uint32(ndr, "count", r->count);
4272 8 : ndr_print_ptr(ndr, "array", r->array);
4273 8 : ndr->depth++;
4274 8 : if (r->array) {
4275 8 : ndr->print(ndr, "%s: ARRAY(%"PRIu32")", "array", (uint32_t)(r->count));
4276 8 : ndr->depth++;
4277 108 : for (cntr_array_1 = 0; cntr_array_1 < (r->count); cntr_array_1++) {
4278 100 : ndr_print_srvsvc_NetShareInfo0(ndr, "array", &r->array[cntr_array_1]);
4279 : }
4280 8 : ndr->depth--;
4281 : }
4282 8 : ndr->depth--;
4283 8 : ndr->depth--;
4284 : }
4285 :
4286 22882 : static enum ndr_err_code ndr_push_srvsvc_NetShareInfo1(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct srvsvc_NetShareInfo1 *r)
4287 : {
4288 22882 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
4289 22882 : if (ndr_flags & NDR_SCALARS) {
4290 11487 : NDR_CHECK(ndr_push_align(ndr, 5));
4291 11487 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->name));
4292 11487 : NDR_CHECK(ndr_push_srvsvc_ShareType(ndr, NDR_SCALARS, r->type));
4293 11487 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->comment));
4294 11487 : NDR_CHECK(ndr_push_trailer_align(ndr, 5));
4295 : }
4296 22882 : if (ndr_flags & NDR_BUFFERS) {
4297 11487 : if (r->name) {
4298 11487 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->name, CH_UTF16)));
4299 11487 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, 0));
4300 11487 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->name, CH_UTF16)));
4301 11487 : NDR_CHECK(ndr_push_charset(ndr, NDR_SCALARS, r->name, ndr_charset_length(r->name, CH_UTF16), sizeof(uint16_t), CH_UTF16));
4302 : }
4303 11487 : if (r->comment) {
4304 11487 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->comment, CH_UTF16)));
4305 11487 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, 0));
4306 11487 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->comment, CH_UTF16)));
4307 11487 : NDR_CHECK(ndr_push_charset(ndr, NDR_SCALARS, r->comment, ndr_charset_length(r->comment, CH_UTF16), sizeof(uint16_t), CH_UTF16));
4308 : }
4309 : }
4310 22882 : return NDR_ERR_SUCCESS;
4311 : }
4312 :
4313 27837 : static enum ndr_err_code ndr_pull_srvsvc_NetShareInfo1(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct srvsvc_NetShareInfo1 *r)
4314 : {
4315 0 : uint32_t _ptr_name;
4316 27837 : uint32_t size_name_1 = 0;
4317 27837 : uint32_t length_name_1 = 0;
4318 27837 : TALLOC_CTX *_mem_save_name_0 = NULL;
4319 0 : uint32_t _ptr_comment;
4320 27837 : uint32_t size_comment_1 = 0;
4321 27837 : uint32_t length_comment_1 = 0;
4322 27837 : TALLOC_CTX *_mem_save_comment_0 = NULL;
4323 27837 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
4324 27837 : if (ndr_flags & NDR_SCALARS) {
4325 13957 : NDR_CHECK(ndr_pull_align(ndr, 5));
4326 13957 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_name));
4327 13957 : if (_ptr_name) {
4328 13957 : NDR_PULL_ALLOC(ndr, r->name);
4329 : } else {
4330 0 : r->name = NULL;
4331 : }
4332 13957 : NDR_CHECK(ndr_pull_srvsvc_ShareType(ndr, NDR_SCALARS, &r->type));
4333 13957 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_comment));
4334 13957 : if (_ptr_comment) {
4335 13957 : NDR_PULL_ALLOC(ndr, r->comment);
4336 : } else {
4337 0 : r->comment = NULL;
4338 : }
4339 13957 : NDR_CHECK(ndr_pull_trailer_align(ndr, 5));
4340 : }
4341 27837 : if (ndr_flags & NDR_BUFFERS) {
4342 13957 : if (r->name) {
4343 13957 : _mem_save_name_0 = NDR_PULL_GET_MEM_CTX(ndr);
4344 13957 : NDR_PULL_SET_MEM_CTX(ndr, r->name, 0);
4345 13957 : NDR_CHECK(ndr_pull_array_size(ndr, &r->name));
4346 13957 : NDR_CHECK(ndr_pull_array_length(ndr, &r->name));
4347 13957 : NDR_CHECK(ndr_steal_array_size(ndr, (void*)&r->name, &size_name_1));
4348 13957 : NDR_CHECK(ndr_steal_array_length(ndr, (void*)&r->name, &length_name_1));
4349 13957 : if (length_name_1 > size_name_1) {
4350 0 : return ndr_pull_error(ndr, NDR_ERR_ARRAY_SIZE, "Bad array size %"PRIu32": should exceed array length %"PRIu32"", size_name_1, length_name_1);
4351 : }
4352 13957 : NDR_CHECK(ndr_check_string_terminator(ndr, length_name_1, sizeof(uint16_t)));
4353 13957 : NDR_CHECK(ndr_pull_charset(ndr, NDR_SCALARS, &r->name, length_name_1, sizeof(uint16_t), CH_UTF16));
4354 13957 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_name_0, 0);
4355 : }
4356 13957 : if (r->comment) {
4357 13957 : _mem_save_comment_0 = NDR_PULL_GET_MEM_CTX(ndr);
4358 13957 : NDR_PULL_SET_MEM_CTX(ndr, r->comment, 0);
4359 13957 : NDR_CHECK(ndr_pull_array_size(ndr, &r->comment));
4360 13957 : NDR_CHECK(ndr_pull_array_length(ndr, &r->comment));
4361 13957 : NDR_CHECK(ndr_steal_array_size(ndr, (void*)&r->comment, &size_comment_1));
4362 13957 : NDR_CHECK(ndr_steal_array_length(ndr, (void*)&r->comment, &length_comment_1));
4363 13957 : if (length_comment_1 > size_comment_1) {
4364 0 : return ndr_pull_error(ndr, NDR_ERR_ARRAY_SIZE, "Bad array size %"PRIu32": should exceed array length %"PRIu32"", size_comment_1, length_comment_1);
4365 : }
4366 13957 : NDR_CHECK(ndr_check_string_terminator(ndr, length_comment_1, sizeof(uint16_t)));
4367 13957 : NDR_CHECK(ndr_pull_charset(ndr, NDR_SCALARS, &r->comment, length_comment_1, sizeof(uint16_t), CH_UTF16));
4368 13957 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_comment_0, 0);
4369 : }
4370 : }
4371 27837 : return NDR_ERR_SUCCESS;
4372 : }
4373 :
4374 130 : _PUBLIC_ void ndr_print_srvsvc_NetShareInfo1(struct ndr_print *ndr, const char *name, const struct srvsvc_NetShareInfo1 *r)
4375 : {
4376 130 : ndr_print_struct(ndr, name, "srvsvc_NetShareInfo1");
4377 130 : if (r == NULL) { ndr_print_null(ndr); return; }
4378 130 : ndr->depth++;
4379 130 : ndr_print_ptr(ndr, "name", r->name);
4380 130 : ndr->depth++;
4381 130 : if (r->name) {
4382 130 : ndr_print_string(ndr, "name", r->name);
4383 : }
4384 130 : ndr->depth--;
4385 130 : ndr_print_srvsvc_ShareType(ndr, "type", r->type);
4386 130 : ndr_print_ptr(ndr, "comment", r->comment);
4387 130 : ndr->depth++;
4388 130 : if (r->comment) {
4389 130 : ndr_print_string(ndr, "comment", r->comment);
4390 : }
4391 130 : ndr->depth--;
4392 130 : ndr->depth--;
4393 : }
4394 :
4395 276 : static enum ndr_err_code ndr_push_srvsvc_NetShareCtr1(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct srvsvc_NetShareCtr1 *r)
4396 : {
4397 0 : uint32_t cntr_array_1;
4398 276 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
4399 276 : if (ndr_flags & NDR_SCALARS) {
4400 276 : NDR_CHECK(ndr_push_align(ndr, 5));
4401 276 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->count));
4402 276 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->array));
4403 276 : NDR_CHECK(ndr_push_trailer_align(ndr, 5));
4404 : }
4405 276 : if (ndr_flags & NDR_BUFFERS) {
4406 276 : if (r->array) {
4407 132 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, r->count));
4408 11527 : for (cntr_array_1 = 0; cntr_array_1 < (r->count); cntr_array_1++) {
4409 11395 : NDR_CHECK(ndr_push_srvsvc_NetShareInfo1(ndr, NDR_SCALARS, &r->array[cntr_array_1]));
4410 : }
4411 11527 : for (cntr_array_1 = 0; cntr_array_1 < (r->count); cntr_array_1++) {
4412 11395 : NDR_CHECK(ndr_push_srvsvc_NetShareInfo1(ndr, NDR_BUFFERS, &r->array[cntr_array_1]));
4413 : }
4414 : }
4415 : }
4416 276 : return NDR_ERR_SUCCESS;
4417 : }
4418 :
4419 272 : static enum ndr_err_code ndr_pull_srvsvc_NetShareCtr1(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct srvsvc_NetShareCtr1 *r)
4420 : {
4421 0 : uint32_t _ptr_array;
4422 272 : uint32_t size_array_1 = 0;
4423 0 : uint32_t cntr_array_1;
4424 272 : TALLOC_CTX *_mem_save_array_0 = NULL;
4425 272 : TALLOC_CTX *_mem_save_array_1 = NULL;
4426 272 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
4427 272 : if (ndr_flags & NDR_SCALARS) {
4428 272 : NDR_CHECK(ndr_pull_align(ndr, 5));
4429 272 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->count));
4430 272 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_array));
4431 272 : if (_ptr_array) {
4432 144 : NDR_PULL_ALLOC(ndr, r->array);
4433 : } else {
4434 128 : r->array = NULL;
4435 : }
4436 272 : NDR_CHECK(ndr_pull_trailer_align(ndr, 5));
4437 : }
4438 272 : if (ndr_flags & NDR_BUFFERS) {
4439 272 : if (r->array) {
4440 144 : _mem_save_array_0 = NDR_PULL_GET_MEM_CTX(ndr);
4441 144 : NDR_PULL_SET_MEM_CTX(ndr, r->array, 0);
4442 144 : NDR_CHECK(ndr_pull_array_size(ndr, &r->array));
4443 144 : NDR_CHECK(ndr_get_array_size(ndr, (void*)&r->array, &size_array_1));
4444 144 : NDR_PULL_ALLOC_N(ndr, r->array, size_array_1);
4445 144 : _mem_save_array_1 = NDR_PULL_GET_MEM_CTX(ndr);
4446 144 : NDR_PULL_SET_MEM_CTX(ndr, r->array, 0);
4447 14024 : for (cntr_array_1 = 0; cntr_array_1 < (size_array_1); cntr_array_1++) {
4448 13880 : NDR_CHECK(ndr_pull_srvsvc_NetShareInfo1(ndr, NDR_SCALARS, &r->array[cntr_array_1]));
4449 : }
4450 14024 : for (cntr_array_1 = 0; cntr_array_1 < (size_array_1); cntr_array_1++) {
4451 13880 : NDR_CHECK(ndr_pull_srvsvc_NetShareInfo1(ndr, NDR_BUFFERS, &r->array[cntr_array_1]));
4452 : }
4453 144 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_array_1, 0);
4454 144 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_array_0, 0);
4455 : }
4456 272 : if (r->array) {
4457 144 : NDR_CHECK(ndr_check_array_size(ndr, (void*)&r->array, r->count));
4458 : }
4459 14152 : for (cntr_array_1 = 0; cntr_array_1 < (size_array_1); cntr_array_1++) {
4460 0 : }
4461 : }
4462 272 : return NDR_ERR_SUCCESS;
4463 : }
4464 :
4465 8 : _PUBLIC_ void ndr_print_srvsvc_NetShareCtr1(struct ndr_print *ndr, const char *name, const struct srvsvc_NetShareCtr1 *r)
4466 : {
4467 0 : uint32_t cntr_array_1;
4468 8 : ndr_print_struct(ndr, name, "srvsvc_NetShareCtr1");
4469 8 : if (r == NULL) { ndr_print_null(ndr); return; }
4470 8 : ndr->depth++;
4471 8 : ndr_print_uint32(ndr, "count", r->count);
4472 8 : ndr_print_ptr(ndr, "array", r->array);
4473 8 : ndr->depth++;
4474 8 : if (r->array) {
4475 8 : ndr->print(ndr, "%s: ARRAY(%"PRIu32")", "array", (uint32_t)(r->count));
4476 8 : ndr->depth++;
4477 108 : for (cntr_array_1 = 0; cntr_array_1 < (r->count); cntr_array_1++) {
4478 100 : ndr_print_srvsvc_NetShareInfo1(ndr, "array", &r->array[cntr_array_1]);
4479 : }
4480 8 : ndr->depth--;
4481 : }
4482 8 : ndr->depth--;
4483 8 : ndr->depth--;
4484 : }
4485 :
4486 8166 : static enum ndr_err_code ndr_push_srvsvc_NetShareInfo2(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct srvsvc_NetShareInfo2 *r)
4487 : {
4488 8166 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
4489 8166 : if (ndr_flags & NDR_SCALARS) {
4490 4127 : NDR_CHECK(ndr_push_align(ndr, 5));
4491 4127 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->name));
4492 4127 : NDR_CHECK(ndr_push_srvsvc_ShareType(ndr, NDR_SCALARS, r->type));
4493 4127 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->comment));
4494 4127 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->permissions));
4495 4127 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->max_users));
4496 4127 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->current_users));
4497 4127 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->path));
4498 4127 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->password));
4499 4127 : NDR_CHECK(ndr_push_trailer_align(ndr, 5));
4500 : }
4501 8166 : if (ndr_flags & NDR_BUFFERS) {
4502 4127 : if (r->name) {
4503 4127 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->name, CH_UTF16)));
4504 4127 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, 0));
4505 4127 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->name, CH_UTF16)));
4506 4127 : NDR_CHECK(ndr_push_charset(ndr, NDR_SCALARS, r->name, ndr_charset_length(r->name, CH_UTF16), sizeof(uint16_t), CH_UTF16));
4507 : }
4508 4127 : if (r->comment) {
4509 4127 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->comment, CH_UTF16)));
4510 4127 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, 0));
4511 4127 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->comment, CH_UTF16)));
4512 4127 : NDR_CHECK(ndr_push_charset(ndr, NDR_SCALARS, r->comment, ndr_charset_length(r->comment, CH_UTF16), sizeof(uint16_t), CH_UTF16));
4513 : }
4514 4127 : if (r->path) {
4515 4127 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->path, CH_UTF16)));
4516 4127 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, 0));
4517 4127 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->path, CH_UTF16)));
4518 4127 : NDR_CHECK(ndr_push_charset(ndr, NDR_SCALARS, r->path, ndr_charset_length(r->path, CH_UTF16), sizeof(uint16_t), CH_UTF16));
4519 : }
4520 4127 : if (r->password) {
4521 3930 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->password, CH_UTF16)));
4522 3930 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, 0));
4523 3930 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->password, CH_UTF16)));
4524 3930 : NDR_CHECK(ndr_push_charset(ndr, NDR_SCALARS, r->password, ndr_charset_length(r->password, CH_UTF16), sizeof(uint16_t), CH_UTF16));
4525 : }
4526 : }
4527 8166 : return NDR_ERR_SUCCESS;
4528 : }
4529 :
4530 8102 : static enum ndr_err_code ndr_pull_srvsvc_NetShareInfo2(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct srvsvc_NetShareInfo2 *r)
4531 : {
4532 0 : uint32_t _ptr_name;
4533 8102 : uint32_t size_name_1 = 0;
4534 8102 : uint32_t length_name_1 = 0;
4535 8102 : TALLOC_CTX *_mem_save_name_0 = NULL;
4536 0 : uint32_t _ptr_comment;
4537 8102 : uint32_t size_comment_1 = 0;
4538 8102 : uint32_t length_comment_1 = 0;
4539 8102 : TALLOC_CTX *_mem_save_comment_0 = NULL;
4540 0 : uint32_t _ptr_path;
4541 8102 : uint32_t size_path_1 = 0;
4542 8102 : uint32_t length_path_1 = 0;
4543 8102 : TALLOC_CTX *_mem_save_path_0 = NULL;
4544 0 : uint32_t _ptr_password;
4545 8102 : uint32_t size_password_1 = 0;
4546 8102 : uint32_t length_password_1 = 0;
4547 8102 : TALLOC_CTX *_mem_save_password_0 = NULL;
4548 8102 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
4549 8102 : if (ndr_flags & NDR_SCALARS) {
4550 4088 : NDR_CHECK(ndr_pull_align(ndr, 5));
4551 4088 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_name));
4552 4088 : if (_ptr_name) {
4553 4088 : NDR_PULL_ALLOC(ndr, r->name);
4554 : } else {
4555 0 : r->name = NULL;
4556 : }
4557 4088 : NDR_CHECK(ndr_pull_srvsvc_ShareType(ndr, NDR_SCALARS, &r->type));
4558 4088 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_comment));
4559 4088 : if (_ptr_comment) {
4560 4088 : NDR_PULL_ALLOC(ndr, r->comment);
4561 : } else {
4562 0 : r->comment = NULL;
4563 : }
4564 4088 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->permissions));
4565 4088 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->max_users));
4566 4088 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->current_users));
4567 4088 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_path));
4568 4088 : if (_ptr_path) {
4569 4088 : NDR_PULL_ALLOC(ndr, r->path);
4570 : } else {
4571 0 : r->path = NULL;
4572 : }
4573 4088 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_password));
4574 4088 : if (_ptr_password) {
4575 3930 : NDR_PULL_ALLOC(ndr, r->password);
4576 : } else {
4577 158 : r->password = NULL;
4578 : }
4579 4088 : NDR_CHECK(ndr_pull_trailer_align(ndr, 5));
4580 : }
4581 8102 : if (ndr_flags & NDR_BUFFERS) {
4582 4088 : if (r->name) {
4583 4088 : _mem_save_name_0 = NDR_PULL_GET_MEM_CTX(ndr);
4584 4088 : NDR_PULL_SET_MEM_CTX(ndr, r->name, 0);
4585 4088 : NDR_CHECK(ndr_pull_array_size(ndr, &r->name));
4586 4088 : NDR_CHECK(ndr_pull_array_length(ndr, &r->name));
4587 4088 : NDR_CHECK(ndr_steal_array_size(ndr, (void*)&r->name, &size_name_1));
4588 4088 : NDR_CHECK(ndr_steal_array_length(ndr, (void*)&r->name, &length_name_1));
4589 4088 : if (length_name_1 > size_name_1) {
4590 0 : return ndr_pull_error(ndr, NDR_ERR_ARRAY_SIZE, "Bad array size %"PRIu32": should exceed array length %"PRIu32"", size_name_1, length_name_1);
4591 : }
4592 4088 : NDR_CHECK(ndr_check_string_terminator(ndr, length_name_1, sizeof(uint16_t)));
4593 4088 : NDR_CHECK(ndr_pull_charset(ndr, NDR_SCALARS, &r->name, length_name_1, sizeof(uint16_t), CH_UTF16));
4594 4088 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_name_0, 0);
4595 : }
4596 4088 : if (r->comment) {
4597 4088 : _mem_save_comment_0 = NDR_PULL_GET_MEM_CTX(ndr);
4598 4088 : NDR_PULL_SET_MEM_CTX(ndr, r->comment, 0);
4599 4088 : NDR_CHECK(ndr_pull_array_size(ndr, &r->comment));
4600 4088 : NDR_CHECK(ndr_pull_array_length(ndr, &r->comment));
4601 4088 : NDR_CHECK(ndr_steal_array_size(ndr, (void*)&r->comment, &size_comment_1));
4602 4088 : NDR_CHECK(ndr_steal_array_length(ndr, (void*)&r->comment, &length_comment_1));
4603 4088 : if (length_comment_1 > size_comment_1) {
4604 0 : return ndr_pull_error(ndr, NDR_ERR_ARRAY_SIZE, "Bad array size %"PRIu32": should exceed array length %"PRIu32"", size_comment_1, length_comment_1);
4605 : }
4606 4088 : NDR_CHECK(ndr_check_string_terminator(ndr, length_comment_1, sizeof(uint16_t)));
4607 4088 : NDR_CHECK(ndr_pull_charset(ndr, NDR_SCALARS, &r->comment, length_comment_1, sizeof(uint16_t), CH_UTF16));
4608 4088 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_comment_0, 0);
4609 : }
4610 4088 : if (r->path) {
4611 4088 : _mem_save_path_0 = NDR_PULL_GET_MEM_CTX(ndr);
4612 4088 : NDR_PULL_SET_MEM_CTX(ndr, r->path, 0);
4613 4088 : NDR_CHECK(ndr_pull_array_size(ndr, &r->path));
4614 4088 : NDR_CHECK(ndr_pull_array_length(ndr, &r->path));
4615 4088 : NDR_CHECK(ndr_steal_array_size(ndr, (void*)&r->path, &size_path_1));
4616 4088 : NDR_CHECK(ndr_steal_array_length(ndr, (void*)&r->path, &length_path_1));
4617 4088 : if (length_path_1 > size_path_1) {
4618 0 : return ndr_pull_error(ndr, NDR_ERR_ARRAY_SIZE, "Bad array size %"PRIu32": should exceed array length %"PRIu32"", size_path_1, length_path_1);
4619 : }
4620 4088 : NDR_CHECK(ndr_check_string_terminator(ndr, length_path_1, sizeof(uint16_t)));
4621 4088 : NDR_CHECK(ndr_pull_charset(ndr, NDR_SCALARS, &r->path, length_path_1, sizeof(uint16_t), CH_UTF16));
4622 4088 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_path_0, 0);
4623 : }
4624 4088 : if (r->password) {
4625 3930 : _mem_save_password_0 = NDR_PULL_GET_MEM_CTX(ndr);
4626 3930 : NDR_PULL_SET_MEM_CTX(ndr, r->password, 0);
4627 3930 : NDR_CHECK(ndr_pull_array_size(ndr, &r->password));
4628 3930 : NDR_CHECK(ndr_pull_array_length(ndr, &r->password));
4629 3930 : NDR_CHECK(ndr_steal_array_size(ndr, (void*)&r->password, &size_password_1));
4630 3930 : NDR_CHECK(ndr_steal_array_length(ndr, (void*)&r->password, &length_password_1));
4631 3930 : if (length_password_1 > size_password_1) {
4632 0 : return ndr_pull_error(ndr, NDR_ERR_ARRAY_SIZE, "Bad array size %"PRIu32": should exceed array length %"PRIu32"", size_password_1, length_password_1);
4633 : }
4634 3930 : NDR_CHECK(ndr_check_string_terminator(ndr, length_password_1, sizeof(uint16_t)));
4635 3930 : NDR_CHECK(ndr_pull_charset(ndr, NDR_SCALARS, &r->password, length_password_1, sizeof(uint16_t), CH_UTF16));
4636 3930 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_password_0, 0);
4637 : }
4638 : }
4639 8102 : return NDR_ERR_SUCCESS;
4640 : }
4641 :
4642 78 : _PUBLIC_ void ndr_print_srvsvc_NetShareInfo2(struct ndr_print *ndr, const char *name, const struct srvsvc_NetShareInfo2 *r)
4643 : {
4644 78 : ndr_print_struct(ndr, name, "srvsvc_NetShareInfo2");
4645 78 : if (r == NULL) { ndr_print_null(ndr); return; }
4646 78 : ndr->depth++;
4647 78 : ndr_print_ptr(ndr, "name", r->name);
4648 78 : ndr->depth++;
4649 78 : if (r->name) {
4650 78 : ndr_print_string(ndr, "name", r->name);
4651 : }
4652 78 : ndr->depth--;
4653 78 : ndr_print_srvsvc_ShareType(ndr, "type", r->type);
4654 78 : ndr_print_ptr(ndr, "comment", r->comment);
4655 78 : ndr->depth++;
4656 78 : if (r->comment) {
4657 78 : ndr_print_string(ndr, "comment", r->comment);
4658 : }
4659 78 : ndr->depth--;
4660 78 : ndr_print_uint32(ndr, "permissions", r->permissions);
4661 78 : ndr_print_uint32(ndr, "max_users", r->max_users);
4662 78 : ndr_print_uint32(ndr, "current_users", r->current_users);
4663 78 : ndr_print_ptr(ndr, "path", r->path);
4664 78 : ndr->depth++;
4665 78 : if (r->path) {
4666 78 : ndr_print_string(ndr, "path", r->path);
4667 : }
4668 78 : ndr->depth--;
4669 78 : ndr_print_ptr(ndr, "password", r->password);
4670 78 : ndr->depth++;
4671 78 : if (r->password) {
4672 0 : ndr_print_string(ndr, "password", r->password);
4673 : }
4674 78 : ndr->depth--;
4675 78 : ndr->depth--;
4676 : }
4677 :
4678 114 : static enum ndr_err_code ndr_push_srvsvc_NetShareCtr2(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct srvsvc_NetShareCtr2 *r)
4679 : {
4680 0 : uint32_t cntr_array_1;
4681 114 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
4682 114 : if (ndr_flags & NDR_SCALARS) {
4683 114 : NDR_CHECK(ndr_push_align(ndr, 5));
4684 114 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->count));
4685 114 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->array));
4686 114 : NDR_CHECK(ndr_push_trailer_align(ndr, 5));
4687 : }
4688 114 : if (ndr_flags & NDR_BUFFERS) {
4689 114 : if (r->array) {
4690 49 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, r->count));
4691 4088 : for (cntr_array_1 = 0; cntr_array_1 < (r->count); cntr_array_1++) {
4692 4039 : NDR_CHECK(ndr_push_srvsvc_NetShareInfo2(ndr, NDR_SCALARS, &r->array[cntr_array_1]));
4693 : }
4694 4088 : for (cntr_array_1 = 0; cntr_array_1 < (r->count); cntr_array_1++) {
4695 4039 : NDR_CHECK(ndr_push_srvsvc_NetShareInfo2(ndr, NDR_BUFFERS, &r->array[cntr_array_1]));
4696 : }
4697 : }
4698 : }
4699 114 : return NDR_ERR_SUCCESS;
4700 : }
4701 :
4702 110 : static enum ndr_err_code ndr_pull_srvsvc_NetShareCtr2(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct srvsvc_NetShareCtr2 *r)
4703 : {
4704 0 : uint32_t _ptr_array;
4705 110 : uint32_t size_array_1 = 0;
4706 0 : uint32_t cntr_array_1;
4707 110 : TALLOC_CTX *_mem_save_array_0 = NULL;
4708 110 : TALLOC_CTX *_mem_save_array_1 = NULL;
4709 110 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
4710 110 : if (ndr_flags & NDR_SCALARS) {
4711 110 : NDR_CHECK(ndr_pull_align(ndr, 5));
4712 110 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->count));
4713 110 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_array));
4714 110 : if (_ptr_array) {
4715 47 : NDR_PULL_ALLOC(ndr, r->array);
4716 : } else {
4717 63 : r->array = NULL;
4718 : }
4719 110 : NDR_CHECK(ndr_pull_trailer_align(ndr, 5));
4720 : }
4721 110 : if (ndr_flags & NDR_BUFFERS) {
4722 110 : if (r->array) {
4723 47 : _mem_save_array_0 = NDR_PULL_GET_MEM_CTX(ndr);
4724 47 : NDR_PULL_SET_MEM_CTX(ndr, r->array, 0);
4725 47 : NDR_CHECK(ndr_pull_array_size(ndr, &r->array));
4726 47 : NDR_CHECK(ndr_get_array_size(ndr, (void*)&r->array, &size_array_1));
4727 47 : NDR_PULL_ALLOC_N(ndr, r->array, size_array_1);
4728 47 : _mem_save_array_1 = NDR_PULL_GET_MEM_CTX(ndr);
4729 47 : NDR_PULL_SET_MEM_CTX(ndr, r->array, 0);
4730 4061 : for (cntr_array_1 = 0; cntr_array_1 < (size_array_1); cntr_array_1++) {
4731 4014 : NDR_CHECK(ndr_pull_srvsvc_NetShareInfo2(ndr, NDR_SCALARS, &r->array[cntr_array_1]));
4732 : }
4733 4061 : for (cntr_array_1 = 0; cntr_array_1 < (size_array_1); cntr_array_1++) {
4734 4014 : NDR_CHECK(ndr_pull_srvsvc_NetShareInfo2(ndr, NDR_BUFFERS, &r->array[cntr_array_1]));
4735 : }
4736 47 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_array_1, 0);
4737 47 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_array_0, 0);
4738 : }
4739 110 : if (r->array) {
4740 47 : NDR_CHECK(ndr_check_array_size(ndr, (void*)&r->array, r->count));
4741 : }
4742 4124 : for (cntr_array_1 = 0; cntr_array_1 < (size_array_1); cntr_array_1++) {
4743 0 : }
4744 : }
4745 110 : return NDR_ERR_SUCCESS;
4746 : }
4747 :
4748 8 : _PUBLIC_ void ndr_print_srvsvc_NetShareCtr2(struct ndr_print *ndr, const char *name, const struct srvsvc_NetShareCtr2 *r)
4749 : {
4750 0 : uint32_t cntr_array_1;
4751 8 : ndr_print_struct(ndr, name, "srvsvc_NetShareCtr2");
4752 8 : if (r == NULL) { ndr_print_null(ndr); return; }
4753 8 : ndr->depth++;
4754 8 : ndr_print_uint32(ndr, "count", r->count);
4755 8 : ndr_print_ptr(ndr, "array", r->array);
4756 8 : ndr->depth++;
4757 8 : if (r->array) {
4758 4 : ndr->print(ndr, "%s: ARRAY(%"PRIu32")", "array", (uint32_t)(r->count));
4759 4 : ndr->depth++;
4760 54 : for (cntr_array_1 = 0; cntr_array_1 < (r->count); cntr_array_1++) {
4761 50 : ndr_print_srvsvc_NetShareInfo2(ndr, "array", &r->array[cntr_array_1]);
4762 : }
4763 4 : ndr->depth--;
4764 : }
4765 8 : ndr->depth--;
4766 8 : ndr->depth--;
4767 : }
4768 :
4769 1729 : static enum ndr_err_code ndr_push_srvsvc_NetShareInfo501(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct srvsvc_NetShareInfo501 *r)
4770 : {
4771 1729 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
4772 1729 : if (ndr_flags & NDR_SCALARS) {
4773 904 : NDR_CHECK(ndr_push_align(ndr, 5));
4774 904 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->name));
4775 904 : NDR_CHECK(ndr_push_srvsvc_ShareType(ndr, NDR_SCALARS, r->type));
4776 904 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->comment));
4777 904 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->csc_policy));
4778 904 : NDR_CHECK(ndr_push_trailer_align(ndr, 5));
4779 : }
4780 1729 : if (ndr_flags & NDR_BUFFERS) {
4781 904 : if (r->name) {
4782 904 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->name, CH_UTF16)));
4783 904 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, 0));
4784 904 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->name, CH_UTF16)));
4785 904 : NDR_CHECK(ndr_push_charset(ndr, NDR_SCALARS, r->name, ndr_charset_length(r->name, CH_UTF16), sizeof(uint16_t), CH_UTF16));
4786 : }
4787 904 : if (r->comment) {
4788 904 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->comment, CH_UTF16)));
4789 904 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, 0));
4790 904 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->comment, CH_UTF16)));
4791 904 : NDR_CHECK(ndr_push_charset(ndr, NDR_SCALARS, r->comment, ndr_charset_length(r->comment, CH_UTF16), sizeof(uint16_t), CH_UTF16));
4792 : }
4793 : }
4794 1729 : return NDR_ERR_SUCCESS;
4795 : }
4796 :
4797 1688 : static enum ndr_err_code ndr_pull_srvsvc_NetShareInfo501(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct srvsvc_NetShareInfo501 *r)
4798 : {
4799 0 : uint32_t _ptr_name;
4800 1688 : uint32_t size_name_1 = 0;
4801 1688 : uint32_t length_name_1 = 0;
4802 1688 : TALLOC_CTX *_mem_save_name_0 = NULL;
4803 0 : uint32_t _ptr_comment;
4804 1688 : uint32_t size_comment_1 = 0;
4805 1688 : uint32_t length_comment_1 = 0;
4806 1688 : TALLOC_CTX *_mem_save_comment_0 = NULL;
4807 1688 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
4808 1688 : if (ndr_flags & NDR_SCALARS) {
4809 876 : NDR_CHECK(ndr_pull_align(ndr, 5));
4810 876 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_name));
4811 876 : if (_ptr_name) {
4812 876 : NDR_PULL_ALLOC(ndr, r->name);
4813 : } else {
4814 0 : r->name = NULL;
4815 : }
4816 876 : NDR_CHECK(ndr_pull_srvsvc_ShareType(ndr, NDR_SCALARS, &r->type));
4817 876 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_comment));
4818 876 : if (_ptr_comment) {
4819 876 : NDR_PULL_ALLOC(ndr, r->comment);
4820 : } else {
4821 0 : r->comment = NULL;
4822 : }
4823 876 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->csc_policy));
4824 876 : NDR_CHECK(ndr_pull_trailer_align(ndr, 5));
4825 : }
4826 1688 : if (ndr_flags & NDR_BUFFERS) {
4827 876 : if (r->name) {
4828 876 : _mem_save_name_0 = NDR_PULL_GET_MEM_CTX(ndr);
4829 876 : NDR_PULL_SET_MEM_CTX(ndr, r->name, 0);
4830 876 : NDR_CHECK(ndr_pull_array_size(ndr, &r->name));
4831 876 : NDR_CHECK(ndr_pull_array_length(ndr, &r->name));
4832 876 : NDR_CHECK(ndr_steal_array_size(ndr, (void*)&r->name, &size_name_1));
4833 876 : NDR_CHECK(ndr_steal_array_length(ndr, (void*)&r->name, &length_name_1));
4834 876 : if (length_name_1 > size_name_1) {
4835 0 : return ndr_pull_error(ndr, NDR_ERR_ARRAY_SIZE, "Bad array size %"PRIu32": should exceed array length %"PRIu32"", size_name_1, length_name_1);
4836 : }
4837 876 : NDR_CHECK(ndr_check_string_terminator(ndr, length_name_1, sizeof(uint16_t)));
4838 876 : NDR_CHECK(ndr_pull_charset(ndr, NDR_SCALARS, &r->name, length_name_1, sizeof(uint16_t), CH_UTF16));
4839 876 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_name_0, 0);
4840 : }
4841 876 : if (r->comment) {
4842 876 : _mem_save_comment_0 = NDR_PULL_GET_MEM_CTX(ndr);
4843 876 : NDR_PULL_SET_MEM_CTX(ndr, r->comment, 0);
4844 876 : NDR_CHECK(ndr_pull_array_size(ndr, &r->comment));
4845 876 : NDR_CHECK(ndr_pull_array_length(ndr, &r->comment));
4846 876 : NDR_CHECK(ndr_steal_array_size(ndr, (void*)&r->comment, &size_comment_1));
4847 876 : NDR_CHECK(ndr_steal_array_length(ndr, (void*)&r->comment, &length_comment_1));
4848 876 : if (length_comment_1 > size_comment_1) {
4849 0 : return ndr_pull_error(ndr, NDR_ERR_ARRAY_SIZE, "Bad array size %"PRIu32": should exceed array length %"PRIu32"", size_comment_1, length_comment_1);
4850 : }
4851 876 : NDR_CHECK(ndr_check_string_terminator(ndr, length_comment_1, sizeof(uint16_t)));
4852 876 : NDR_CHECK(ndr_pull_charset(ndr, NDR_SCALARS, &r->comment, length_comment_1, sizeof(uint16_t), CH_UTF16));
4853 876 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_comment_0, 0);
4854 : }
4855 : }
4856 1688 : return NDR_ERR_SUCCESS;
4857 : }
4858 :
4859 56 : _PUBLIC_ void ndr_print_srvsvc_NetShareInfo501(struct ndr_print *ndr, const char *name, const struct srvsvc_NetShareInfo501 *r)
4860 : {
4861 56 : ndr_print_struct(ndr, name, "srvsvc_NetShareInfo501");
4862 56 : if (r == NULL) { ndr_print_null(ndr); return; }
4863 56 : ndr->depth++;
4864 56 : ndr_print_ptr(ndr, "name", r->name);
4865 56 : ndr->depth++;
4866 56 : if (r->name) {
4867 56 : ndr_print_string(ndr, "name", r->name);
4868 : }
4869 56 : ndr->depth--;
4870 56 : ndr_print_srvsvc_ShareType(ndr, "type", r->type);
4871 56 : ndr_print_ptr(ndr, "comment", r->comment);
4872 56 : ndr->depth++;
4873 56 : if (r->comment) {
4874 56 : ndr_print_string(ndr, "comment", r->comment);
4875 : }
4876 56 : ndr->depth--;
4877 56 : ndr_print_uint32(ndr, "csc_policy", r->csc_policy);
4878 56 : ndr->depth--;
4879 : }
4880 :
4881 54 : static enum ndr_err_code ndr_push_srvsvc_NetShareCtr501(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct srvsvc_NetShareCtr501 *r)
4882 : {
4883 0 : uint32_t cntr_array_1;
4884 54 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
4885 54 : if (ndr_flags & NDR_SCALARS) {
4886 54 : NDR_CHECK(ndr_push_align(ndr, 5));
4887 54 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->count));
4888 54 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->array));
4889 54 : NDR_CHECK(ndr_push_trailer_align(ndr, 5));
4890 : }
4891 54 : if (ndr_flags & NDR_BUFFERS) {
4892 54 : if (r->array) {
4893 14 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, r->count));
4894 839 : for (cntr_array_1 = 0; cntr_array_1 < (r->count); cntr_array_1++) {
4895 825 : NDR_CHECK(ndr_push_srvsvc_NetShareInfo501(ndr, NDR_SCALARS, &r->array[cntr_array_1]));
4896 : }
4897 839 : for (cntr_array_1 = 0; cntr_array_1 < (r->count); cntr_array_1++) {
4898 825 : NDR_CHECK(ndr_push_srvsvc_NetShareInfo501(ndr, NDR_BUFFERS, &r->array[cntr_array_1]));
4899 : }
4900 : }
4901 : }
4902 54 : return NDR_ERR_SUCCESS;
4903 : }
4904 :
4905 50 : static enum ndr_err_code ndr_pull_srvsvc_NetShareCtr501(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct srvsvc_NetShareCtr501 *r)
4906 : {
4907 0 : uint32_t _ptr_array;
4908 50 : uint32_t size_array_1 = 0;
4909 0 : uint32_t cntr_array_1;
4910 50 : TALLOC_CTX *_mem_save_array_0 = NULL;
4911 50 : TALLOC_CTX *_mem_save_array_1 = NULL;
4912 50 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
4913 50 : if (ndr_flags & NDR_SCALARS) {
4914 50 : NDR_CHECK(ndr_pull_align(ndr, 5));
4915 50 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->count));
4916 50 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_array));
4917 50 : if (_ptr_array) {
4918 13 : NDR_PULL_ALLOC(ndr, r->array);
4919 : } else {
4920 37 : r->array = NULL;
4921 : }
4922 50 : NDR_CHECK(ndr_pull_trailer_align(ndr, 5));
4923 : }
4924 50 : if (ndr_flags & NDR_BUFFERS) {
4925 50 : if (r->array) {
4926 13 : _mem_save_array_0 = NDR_PULL_GET_MEM_CTX(ndr);
4927 13 : NDR_PULL_SET_MEM_CTX(ndr, r->array, 0);
4928 13 : NDR_CHECK(ndr_pull_array_size(ndr, &r->array));
4929 13 : NDR_CHECK(ndr_get_array_size(ndr, (void*)&r->array, &size_array_1));
4930 13 : NDR_PULL_ALLOC_N(ndr, r->array, size_array_1);
4931 13 : _mem_save_array_1 = NDR_PULL_GET_MEM_CTX(ndr);
4932 13 : NDR_PULL_SET_MEM_CTX(ndr, r->array, 0);
4933 825 : for (cntr_array_1 = 0; cntr_array_1 < (size_array_1); cntr_array_1++) {
4934 812 : NDR_CHECK(ndr_pull_srvsvc_NetShareInfo501(ndr, NDR_SCALARS, &r->array[cntr_array_1]));
4935 : }
4936 825 : for (cntr_array_1 = 0; cntr_array_1 < (size_array_1); cntr_array_1++) {
4937 812 : NDR_CHECK(ndr_pull_srvsvc_NetShareInfo501(ndr, NDR_BUFFERS, &r->array[cntr_array_1]));
4938 : }
4939 13 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_array_1, 0);
4940 13 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_array_0, 0);
4941 : }
4942 50 : if (r->array) {
4943 13 : NDR_CHECK(ndr_check_array_size(ndr, (void*)&r->array, r->count));
4944 : }
4945 862 : for (cntr_array_1 = 0; cntr_array_1 < (size_array_1); cntr_array_1++) {
4946 0 : }
4947 : }
4948 50 : return NDR_ERR_SUCCESS;
4949 : }
4950 :
4951 8 : _PUBLIC_ void ndr_print_srvsvc_NetShareCtr501(struct ndr_print *ndr, const char *name, const struct srvsvc_NetShareCtr501 *r)
4952 : {
4953 0 : uint32_t cntr_array_1;
4954 8 : ndr_print_struct(ndr, name, "srvsvc_NetShareCtr501");
4955 8 : if (r == NULL) { ndr_print_null(ndr); return; }
4956 8 : ndr->depth++;
4957 8 : ndr_print_uint32(ndr, "count", r->count);
4958 8 : ndr_print_ptr(ndr, "array", r->array);
4959 8 : ndr->depth++;
4960 8 : if (r->array) {
4961 2 : ndr->print(ndr, "%s: ARRAY(%"PRIu32")", "array", (uint32_t)(r->count));
4962 2 : ndr->depth++;
4963 28 : for (cntr_array_1 = 0; cntr_array_1 < (r->count); cntr_array_1++) {
4964 26 : ndr_print_srvsvc_NetShareInfo501(ndr, "array", &r->array[cntr_array_1]);
4965 : }
4966 2 : ndr->depth--;
4967 : }
4968 8 : ndr->depth--;
4969 8 : ndr->depth--;
4970 : }
4971 :
4972 1305 : static enum ndr_err_code ndr_push_srvsvc_NetShareInfo502(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct srvsvc_NetShareInfo502 *r)
4973 : {
4974 1305 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
4975 1305 : if (ndr_flags & NDR_SCALARS) {
4976 700 : NDR_CHECK(ndr_push_align(ndr, 5));
4977 700 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->name));
4978 700 : NDR_CHECK(ndr_push_srvsvc_ShareType(ndr, NDR_SCALARS, r->type));
4979 700 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->comment));
4980 700 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->permissions));
4981 700 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->max_users));
4982 700 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->current_users));
4983 700 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->path));
4984 700 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->password));
4985 700 : NDR_CHECK(ndr_push_sec_desc_buf(ndr, NDR_SCALARS, &r->sd_buf));
4986 700 : NDR_CHECK(ndr_push_trailer_align(ndr, 5));
4987 : }
4988 1305 : if (ndr_flags & NDR_BUFFERS) {
4989 700 : if (r->name) {
4990 700 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->name, CH_UTF16)));
4991 700 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, 0));
4992 700 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->name, CH_UTF16)));
4993 700 : NDR_CHECK(ndr_push_charset(ndr, NDR_SCALARS, r->name, ndr_charset_length(r->name, CH_UTF16), sizeof(uint16_t), CH_UTF16));
4994 : }
4995 700 : if (r->comment) {
4996 700 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->comment, CH_UTF16)));
4997 700 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, 0));
4998 700 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->comment, CH_UTF16)));
4999 700 : NDR_CHECK(ndr_push_charset(ndr, NDR_SCALARS, r->comment, ndr_charset_length(r->comment, CH_UTF16), sizeof(uint16_t), CH_UTF16));
5000 : }
5001 700 : if (r->path) {
5002 700 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->path, CH_UTF16)));
5003 700 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, 0));
5004 700 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->path, CH_UTF16)));
5005 700 : NDR_CHECK(ndr_push_charset(ndr, NDR_SCALARS, r->path, ndr_charset_length(r->path, CH_UTF16), sizeof(uint16_t), CH_UTF16));
5006 : }
5007 700 : if (r->password) {
5008 502 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->password, CH_UTF16)));
5009 502 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, 0));
5010 502 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->password, CH_UTF16)));
5011 502 : NDR_CHECK(ndr_push_charset(ndr, NDR_SCALARS, r->password, ndr_charset_length(r->password, CH_UTF16), sizeof(uint16_t), CH_UTF16));
5012 : }
5013 700 : NDR_CHECK(ndr_push_sec_desc_buf(ndr, NDR_BUFFERS, &r->sd_buf));
5014 : }
5015 1305 : return NDR_ERR_SUCCESS;
5016 : }
5017 :
5018 2456 : static enum ndr_err_code ndr_pull_srvsvc_NetShareInfo502(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct srvsvc_NetShareInfo502 *r)
5019 : {
5020 0 : uint32_t _ptr_name;
5021 2456 : uint32_t size_name_1 = 0;
5022 2456 : uint32_t length_name_1 = 0;
5023 2456 : TALLOC_CTX *_mem_save_name_0 = NULL;
5024 0 : uint32_t _ptr_comment;
5025 2456 : uint32_t size_comment_1 = 0;
5026 2456 : uint32_t length_comment_1 = 0;
5027 2456 : TALLOC_CTX *_mem_save_comment_0 = NULL;
5028 0 : uint32_t _ptr_path;
5029 2456 : uint32_t size_path_1 = 0;
5030 2456 : uint32_t length_path_1 = 0;
5031 2456 : TALLOC_CTX *_mem_save_path_0 = NULL;
5032 0 : uint32_t _ptr_password;
5033 2456 : uint32_t size_password_1 = 0;
5034 2456 : uint32_t length_password_1 = 0;
5035 2456 : TALLOC_CTX *_mem_save_password_0 = NULL;
5036 2456 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
5037 2456 : if (ndr_flags & NDR_SCALARS) {
5038 1876 : NDR_CHECK(ndr_pull_align(ndr, 5));
5039 1876 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_name));
5040 1876 : if (_ptr_name) {
5041 1876 : NDR_PULL_ALLOC(ndr, r->name);
5042 : } else {
5043 0 : r->name = NULL;
5044 : }
5045 1876 : NDR_CHECK(ndr_pull_srvsvc_ShareType(ndr, NDR_SCALARS, &r->type));
5046 1876 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_comment));
5047 1876 : if (_ptr_comment) {
5048 1876 : NDR_PULL_ALLOC(ndr, r->comment);
5049 : } else {
5050 0 : r->comment = NULL;
5051 : }
5052 1876 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->permissions));
5053 1876 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->max_users));
5054 1876 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->current_users));
5055 1876 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_path));
5056 1876 : if (_ptr_path) {
5057 1876 : NDR_PULL_ALLOC(ndr, r->path);
5058 : } else {
5059 0 : r->path = NULL;
5060 : }
5061 1876 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_password));
5062 1876 : if (_ptr_password) {
5063 1718 : NDR_PULL_ALLOC(ndr, r->password);
5064 : } else {
5065 158 : r->password = NULL;
5066 : }
5067 1876 : NDR_CHECK(ndr_pull_sec_desc_buf(ndr, NDR_SCALARS, &r->sd_buf));
5068 1876 : NDR_CHECK(ndr_pull_trailer_align(ndr, 5));
5069 : }
5070 2456 : if (ndr_flags & NDR_BUFFERS) {
5071 1876 : if (r->name) {
5072 1876 : _mem_save_name_0 = NDR_PULL_GET_MEM_CTX(ndr);
5073 1876 : NDR_PULL_SET_MEM_CTX(ndr, r->name, 0);
5074 1876 : NDR_CHECK(ndr_pull_array_size(ndr, &r->name));
5075 1876 : NDR_CHECK(ndr_pull_array_length(ndr, &r->name));
5076 1876 : NDR_CHECK(ndr_steal_array_size(ndr, (void*)&r->name, &size_name_1));
5077 1876 : NDR_CHECK(ndr_steal_array_length(ndr, (void*)&r->name, &length_name_1));
5078 1876 : if (length_name_1 > size_name_1) {
5079 0 : return ndr_pull_error(ndr, NDR_ERR_ARRAY_SIZE, "Bad array size %"PRIu32": should exceed array length %"PRIu32"", size_name_1, length_name_1);
5080 : }
5081 1876 : NDR_CHECK(ndr_check_string_terminator(ndr, length_name_1, sizeof(uint16_t)));
5082 1876 : NDR_CHECK(ndr_pull_charset(ndr, NDR_SCALARS, &r->name, length_name_1, sizeof(uint16_t), CH_UTF16));
5083 1876 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_name_0, 0);
5084 : }
5085 1876 : if (r->comment) {
5086 1876 : _mem_save_comment_0 = NDR_PULL_GET_MEM_CTX(ndr);
5087 1876 : NDR_PULL_SET_MEM_CTX(ndr, r->comment, 0);
5088 1876 : NDR_CHECK(ndr_pull_array_size(ndr, &r->comment));
5089 1876 : NDR_CHECK(ndr_pull_array_length(ndr, &r->comment));
5090 1876 : NDR_CHECK(ndr_steal_array_size(ndr, (void*)&r->comment, &size_comment_1));
5091 1876 : NDR_CHECK(ndr_steal_array_length(ndr, (void*)&r->comment, &length_comment_1));
5092 1876 : if (length_comment_1 > size_comment_1) {
5093 0 : return ndr_pull_error(ndr, NDR_ERR_ARRAY_SIZE, "Bad array size %"PRIu32": should exceed array length %"PRIu32"", size_comment_1, length_comment_1);
5094 : }
5095 1876 : NDR_CHECK(ndr_check_string_terminator(ndr, length_comment_1, sizeof(uint16_t)));
5096 1876 : NDR_CHECK(ndr_pull_charset(ndr, NDR_SCALARS, &r->comment, length_comment_1, sizeof(uint16_t), CH_UTF16));
5097 1876 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_comment_0, 0);
5098 : }
5099 1876 : if (r->path) {
5100 1876 : _mem_save_path_0 = NDR_PULL_GET_MEM_CTX(ndr);
5101 1876 : NDR_PULL_SET_MEM_CTX(ndr, r->path, 0);
5102 1876 : NDR_CHECK(ndr_pull_array_size(ndr, &r->path));
5103 1876 : NDR_CHECK(ndr_pull_array_length(ndr, &r->path));
5104 1876 : NDR_CHECK(ndr_steal_array_size(ndr, (void*)&r->path, &size_path_1));
5105 1876 : NDR_CHECK(ndr_steal_array_length(ndr, (void*)&r->path, &length_path_1));
5106 1876 : if (length_path_1 > size_path_1) {
5107 0 : return ndr_pull_error(ndr, NDR_ERR_ARRAY_SIZE, "Bad array size %"PRIu32": should exceed array length %"PRIu32"", size_path_1, length_path_1);
5108 : }
5109 1876 : NDR_CHECK(ndr_check_string_terminator(ndr, length_path_1, sizeof(uint16_t)));
5110 1876 : NDR_CHECK(ndr_pull_charset(ndr, NDR_SCALARS, &r->path, length_path_1, sizeof(uint16_t), CH_UTF16));
5111 1876 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_path_0, 0);
5112 : }
5113 1876 : if (r->password) {
5114 1718 : _mem_save_password_0 = NDR_PULL_GET_MEM_CTX(ndr);
5115 1718 : NDR_PULL_SET_MEM_CTX(ndr, r->password, 0);
5116 1718 : NDR_CHECK(ndr_pull_array_size(ndr, &r->password));
5117 1718 : NDR_CHECK(ndr_pull_array_length(ndr, &r->password));
5118 1718 : NDR_CHECK(ndr_steal_array_size(ndr, (void*)&r->password, &size_password_1));
5119 1718 : NDR_CHECK(ndr_steal_array_length(ndr, (void*)&r->password, &length_password_1));
5120 1718 : if (length_password_1 > size_password_1) {
5121 0 : return ndr_pull_error(ndr, NDR_ERR_ARRAY_SIZE, "Bad array size %"PRIu32": should exceed array length %"PRIu32"", size_password_1, length_password_1);
5122 : }
5123 1718 : NDR_CHECK(ndr_check_string_terminator(ndr, length_password_1, sizeof(uint16_t)));
5124 1718 : NDR_CHECK(ndr_pull_charset(ndr, NDR_SCALARS, &r->password, length_password_1, sizeof(uint16_t), CH_UTF16));
5125 1718 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_password_0, 0);
5126 : }
5127 1876 : NDR_CHECK(ndr_pull_sec_desc_buf(ndr, NDR_BUFFERS, &r->sd_buf));
5128 : }
5129 2456 : return NDR_ERR_SUCCESS;
5130 : }
5131 :
5132 78 : _PUBLIC_ void ndr_print_srvsvc_NetShareInfo502(struct ndr_print *ndr, const char *name, const struct srvsvc_NetShareInfo502 *r)
5133 : {
5134 78 : ndr_print_struct(ndr, name, "srvsvc_NetShareInfo502");
5135 78 : if (r == NULL) { ndr_print_null(ndr); return; }
5136 78 : ndr->depth++;
5137 78 : ndr_print_ptr(ndr, "name", r->name);
5138 78 : ndr->depth++;
5139 78 : if (r->name) {
5140 78 : ndr_print_string(ndr, "name", r->name);
5141 : }
5142 78 : ndr->depth--;
5143 78 : ndr_print_srvsvc_ShareType(ndr, "type", r->type);
5144 78 : ndr_print_ptr(ndr, "comment", r->comment);
5145 78 : ndr->depth++;
5146 78 : if (r->comment) {
5147 78 : ndr_print_string(ndr, "comment", r->comment);
5148 : }
5149 78 : ndr->depth--;
5150 78 : ndr_print_uint32(ndr, "permissions", r->permissions);
5151 78 : ndr_print_uint32(ndr, "max_users", r->max_users);
5152 78 : ndr_print_uint32(ndr, "current_users", r->current_users);
5153 78 : ndr_print_ptr(ndr, "path", r->path);
5154 78 : ndr->depth++;
5155 78 : if (r->path) {
5156 78 : ndr_print_string(ndr, "path", r->path);
5157 : }
5158 78 : ndr->depth--;
5159 78 : ndr_print_ptr(ndr, "password", r->password);
5160 78 : ndr->depth++;
5161 78 : if (r->password) {
5162 0 : ndr_print_string(ndr, "password", r->password);
5163 : }
5164 78 : ndr->depth--;
5165 78 : ndr_print_sec_desc_buf(ndr, "sd_buf", &r->sd_buf);
5166 78 : ndr->depth--;
5167 : }
5168 :
5169 46 : static enum ndr_err_code ndr_push_srvsvc_NetShareCtr502(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct srvsvc_NetShareCtr502 *r)
5170 : {
5171 0 : uint32_t cntr_array_1;
5172 46 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
5173 46 : if (ndr_flags & NDR_SCALARS) {
5174 46 : NDR_CHECK(ndr_push_align(ndr, 5));
5175 46 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->count));
5176 46 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->array));
5177 46 : NDR_CHECK(ndr_push_trailer_align(ndr, 5));
5178 : }
5179 46 : if (ndr_flags & NDR_BUFFERS) {
5180 46 : if (r->array) {
5181 15 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, r->count));
5182 620 : for (cntr_array_1 = 0; cntr_array_1 < (r->count); cntr_array_1++) {
5183 605 : NDR_CHECK(ndr_push_srvsvc_NetShareInfo502(ndr, NDR_SCALARS, &r->array[cntr_array_1]));
5184 : }
5185 620 : for (cntr_array_1 = 0; cntr_array_1 < (r->count); cntr_array_1++) {
5186 605 : NDR_CHECK(ndr_push_srvsvc_NetShareInfo502(ndr, NDR_BUFFERS, &r->array[cntr_array_1]));
5187 : }
5188 : }
5189 : }
5190 46 : return NDR_ERR_SUCCESS;
5191 : }
5192 :
5193 42 : static enum ndr_err_code ndr_pull_srvsvc_NetShareCtr502(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct srvsvc_NetShareCtr502 *r)
5194 : {
5195 0 : uint32_t _ptr_array;
5196 42 : uint32_t size_array_1 = 0;
5197 0 : uint32_t cntr_array_1;
5198 42 : TALLOC_CTX *_mem_save_array_0 = NULL;
5199 42 : TALLOC_CTX *_mem_save_array_1 = NULL;
5200 42 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
5201 42 : if (ndr_flags & NDR_SCALARS) {
5202 42 : NDR_CHECK(ndr_pull_align(ndr, 5));
5203 42 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->count));
5204 42 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_array));
5205 42 : if (_ptr_array) {
5206 13 : NDR_PULL_ALLOC(ndr, r->array);
5207 : } else {
5208 29 : r->array = NULL;
5209 : }
5210 42 : NDR_CHECK(ndr_pull_trailer_align(ndr, 5));
5211 : }
5212 42 : if (ndr_flags & NDR_BUFFERS) {
5213 42 : if (r->array) {
5214 13 : _mem_save_array_0 = NDR_PULL_GET_MEM_CTX(ndr);
5215 13 : NDR_PULL_SET_MEM_CTX(ndr, r->array, 0);
5216 13 : NDR_CHECK(ndr_pull_array_size(ndr, &r->array));
5217 13 : NDR_CHECK(ndr_get_array_size(ndr, (void*)&r->array, &size_array_1));
5218 13 : NDR_PULL_ALLOC_N(ndr, r->array, size_array_1);
5219 13 : _mem_save_array_1 = NDR_PULL_GET_MEM_CTX(ndr);
5220 13 : NDR_PULL_SET_MEM_CTX(ndr, r->array, 0);
5221 593 : for (cntr_array_1 = 0; cntr_array_1 < (size_array_1); cntr_array_1++) {
5222 580 : NDR_CHECK(ndr_pull_srvsvc_NetShareInfo502(ndr, NDR_SCALARS, &r->array[cntr_array_1]));
5223 : }
5224 593 : for (cntr_array_1 = 0; cntr_array_1 < (size_array_1); cntr_array_1++) {
5225 580 : NDR_CHECK(ndr_pull_srvsvc_NetShareInfo502(ndr, NDR_BUFFERS, &r->array[cntr_array_1]));
5226 : }
5227 13 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_array_1, 0);
5228 13 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_array_0, 0);
5229 : }
5230 42 : if (r->array) {
5231 13 : NDR_CHECK(ndr_check_array_size(ndr, (void*)&r->array, r->count));
5232 : }
5233 622 : for (cntr_array_1 = 0; cntr_array_1 < (size_array_1); cntr_array_1++) {
5234 0 : }
5235 : }
5236 42 : return NDR_ERR_SUCCESS;
5237 : }
5238 :
5239 8 : _PUBLIC_ void ndr_print_srvsvc_NetShareCtr502(struct ndr_print *ndr, const char *name, const struct srvsvc_NetShareCtr502 *r)
5240 : {
5241 0 : uint32_t cntr_array_1;
5242 8 : ndr_print_struct(ndr, name, "srvsvc_NetShareCtr502");
5243 8 : if (r == NULL) { ndr_print_null(ndr); return; }
5244 8 : ndr->depth++;
5245 8 : ndr_print_uint32(ndr, "count", r->count);
5246 8 : ndr_print_ptr(ndr, "array", r->array);
5247 8 : ndr->depth++;
5248 8 : if (r->array) {
5249 4 : ndr->print(ndr, "%s: ARRAY(%"PRIu32")", "array", (uint32_t)(r->count));
5250 4 : ndr->depth++;
5251 54 : for (cntr_array_1 = 0; cntr_array_1 < (r->count); cntr_array_1++) {
5252 50 : ndr_print_srvsvc_NetShareInfo502(ndr, "array", &r->array[cntr_array_1]);
5253 : }
5254 4 : ndr->depth--;
5255 : }
5256 8 : ndr->depth--;
5257 8 : ndr->depth--;
5258 : }
5259 :
5260 916 : static enum ndr_err_code ndr_push_srvsvc_NetShareInfo1004(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct srvsvc_NetShareInfo1004 *r)
5261 : {
5262 916 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
5263 916 : if (ndr_flags & NDR_SCALARS) {
5264 460 : NDR_CHECK(ndr_push_align(ndr, 5));
5265 460 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->comment));
5266 460 : NDR_CHECK(ndr_push_trailer_align(ndr, 5));
5267 : }
5268 916 : if (ndr_flags & NDR_BUFFERS) {
5269 460 : if (r->comment) {
5270 460 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->comment, CH_UTF16)));
5271 460 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, 0));
5272 460 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->comment, CH_UTF16)));
5273 460 : NDR_CHECK(ndr_push_charset(ndr, NDR_SCALARS, r->comment, ndr_charset_length(r->comment, CH_UTF16), sizeof(uint16_t), CH_UTF16));
5274 : }
5275 : }
5276 916 : return NDR_ERR_SUCCESS;
5277 : }
5278 :
5279 916 : static enum ndr_err_code ndr_pull_srvsvc_NetShareInfo1004(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct srvsvc_NetShareInfo1004 *r)
5280 : {
5281 0 : uint32_t _ptr_comment;
5282 916 : uint32_t size_comment_1 = 0;
5283 916 : uint32_t length_comment_1 = 0;
5284 916 : TALLOC_CTX *_mem_save_comment_0 = NULL;
5285 916 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
5286 916 : if (ndr_flags & NDR_SCALARS) {
5287 460 : NDR_CHECK(ndr_pull_align(ndr, 5));
5288 460 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_comment));
5289 460 : if (_ptr_comment) {
5290 460 : NDR_PULL_ALLOC(ndr, r->comment);
5291 : } else {
5292 0 : r->comment = NULL;
5293 : }
5294 460 : NDR_CHECK(ndr_pull_trailer_align(ndr, 5));
5295 : }
5296 916 : if (ndr_flags & NDR_BUFFERS) {
5297 460 : if (r->comment) {
5298 460 : _mem_save_comment_0 = NDR_PULL_GET_MEM_CTX(ndr);
5299 460 : NDR_PULL_SET_MEM_CTX(ndr, r->comment, 0);
5300 460 : NDR_CHECK(ndr_pull_array_size(ndr, &r->comment));
5301 460 : NDR_CHECK(ndr_pull_array_length(ndr, &r->comment));
5302 460 : NDR_CHECK(ndr_steal_array_size(ndr, (void*)&r->comment, &size_comment_1));
5303 460 : NDR_CHECK(ndr_steal_array_length(ndr, (void*)&r->comment, &length_comment_1));
5304 460 : if (length_comment_1 > size_comment_1) {
5305 0 : return ndr_pull_error(ndr, NDR_ERR_ARRAY_SIZE, "Bad array size %"PRIu32": should exceed array length %"PRIu32"", size_comment_1, length_comment_1);
5306 : }
5307 460 : NDR_CHECK(ndr_check_string_terminator(ndr, length_comment_1, sizeof(uint16_t)));
5308 460 : NDR_CHECK(ndr_pull_charset(ndr, NDR_SCALARS, &r->comment, length_comment_1, sizeof(uint16_t), CH_UTF16));
5309 460 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_comment_0, 0);
5310 : }
5311 : }
5312 916 : return NDR_ERR_SUCCESS;
5313 : }
5314 :
5315 0 : _PUBLIC_ void ndr_print_srvsvc_NetShareInfo1004(struct ndr_print *ndr, const char *name, const struct srvsvc_NetShareInfo1004 *r)
5316 : {
5317 0 : ndr_print_struct(ndr, name, "srvsvc_NetShareInfo1004");
5318 0 : if (r == NULL) { ndr_print_null(ndr); return; }
5319 0 : ndr->depth++;
5320 0 : ndr_print_ptr(ndr, "comment", r->comment);
5321 0 : ndr->depth++;
5322 0 : if (r->comment) {
5323 0 : ndr_print_string(ndr, "comment", r->comment);
5324 : }
5325 0 : ndr->depth--;
5326 0 : ndr->depth--;
5327 : }
5328 :
5329 8 : static enum ndr_err_code ndr_push_srvsvc_NetShareCtr1004(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct srvsvc_NetShareCtr1004 *r)
5330 : {
5331 0 : uint32_t cntr_array_1;
5332 8 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
5333 8 : if (ndr_flags & NDR_SCALARS) {
5334 8 : NDR_CHECK(ndr_push_align(ndr, 5));
5335 8 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->count));
5336 8 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->array));
5337 8 : NDR_CHECK(ndr_push_trailer_align(ndr, 5));
5338 : }
5339 8 : if (ndr_flags & NDR_BUFFERS) {
5340 8 : if (r->array) {
5341 4 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, r->count));
5342 460 : for (cntr_array_1 = 0; cntr_array_1 < (r->count); cntr_array_1++) {
5343 456 : NDR_CHECK(ndr_push_srvsvc_NetShareInfo1004(ndr, NDR_SCALARS, &r->array[cntr_array_1]));
5344 : }
5345 460 : for (cntr_array_1 = 0; cntr_array_1 < (r->count); cntr_array_1++) {
5346 456 : NDR_CHECK(ndr_push_srvsvc_NetShareInfo1004(ndr, NDR_BUFFERS, &r->array[cntr_array_1]));
5347 : }
5348 : }
5349 : }
5350 8 : return NDR_ERR_SUCCESS;
5351 : }
5352 :
5353 8 : static enum ndr_err_code ndr_pull_srvsvc_NetShareCtr1004(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct srvsvc_NetShareCtr1004 *r)
5354 : {
5355 0 : uint32_t _ptr_array;
5356 8 : uint32_t size_array_1 = 0;
5357 0 : uint32_t cntr_array_1;
5358 8 : TALLOC_CTX *_mem_save_array_0 = NULL;
5359 8 : TALLOC_CTX *_mem_save_array_1 = NULL;
5360 8 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
5361 8 : if (ndr_flags & NDR_SCALARS) {
5362 8 : NDR_CHECK(ndr_pull_align(ndr, 5));
5363 8 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->count));
5364 8 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_array));
5365 8 : if (_ptr_array) {
5366 4 : NDR_PULL_ALLOC(ndr, r->array);
5367 : } else {
5368 4 : r->array = NULL;
5369 : }
5370 8 : NDR_CHECK(ndr_pull_trailer_align(ndr, 5));
5371 : }
5372 8 : if (ndr_flags & NDR_BUFFERS) {
5373 8 : if (r->array) {
5374 4 : _mem_save_array_0 = NDR_PULL_GET_MEM_CTX(ndr);
5375 4 : NDR_PULL_SET_MEM_CTX(ndr, r->array, 0);
5376 4 : NDR_CHECK(ndr_pull_array_size(ndr, &r->array));
5377 4 : NDR_CHECK(ndr_get_array_size(ndr, (void*)&r->array, &size_array_1));
5378 4 : NDR_PULL_ALLOC_N(ndr, r->array, size_array_1);
5379 4 : _mem_save_array_1 = NDR_PULL_GET_MEM_CTX(ndr);
5380 4 : NDR_PULL_SET_MEM_CTX(ndr, r->array, 0);
5381 460 : for (cntr_array_1 = 0; cntr_array_1 < (size_array_1); cntr_array_1++) {
5382 456 : NDR_CHECK(ndr_pull_srvsvc_NetShareInfo1004(ndr, NDR_SCALARS, &r->array[cntr_array_1]));
5383 : }
5384 460 : for (cntr_array_1 = 0; cntr_array_1 < (size_array_1); cntr_array_1++) {
5385 456 : NDR_CHECK(ndr_pull_srvsvc_NetShareInfo1004(ndr, NDR_BUFFERS, &r->array[cntr_array_1]));
5386 : }
5387 4 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_array_1, 0);
5388 4 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_array_0, 0);
5389 : }
5390 8 : if (r->array) {
5391 4 : NDR_CHECK(ndr_check_array_size(ndr, (void*)&r->array, r->count));
5392 : }
5393 464 : for (cntr_array_1 = 0; cntr_array_1 < (size_array_1); cntr_array_1++) {
5394 0 : }
5395 : }
5396 8 : return NDR_ERR_SUCCESS;
5397 : }
5398 :
5399 0 : _PUBLIC_ void ndr_print_srvsvc_NetShareCtr1004(struct ndr_print *ndr, const char *name, const struct srvsvc_NetShareCtr1004 *r)
5400 : {
5401 0 : uint32_t cntr_array_1;
5402 0 : ndr_print_struct(ndr, name, "srvsvc_NetShareCtr1004");
5403 0 : if (r == NULL) { ndr_print_null(ndr); return; }
5404 0 : ndr->depth++;
5405 0 : ndr_print_uint32(ndr, "count", r->count);
5406 0 : ndr_print_ptr(ndr, "array", r->array);
5407 0 : ndr->depth++;
5408 0 : if (r->array) {
5409 0 : ndr->print(ndr, "%s: ARRAY(%"PRIu32")", "array", (uint32_t)(r->count));
5410 0 : ndr->depth++;
5411 0 : for (cntr_array_1 = 0; cntr_array_1 < (r->count); cntr_array_1++) {
5412 0 : ndr_print_srvsvc_NetShareInfo1004(ndr, "array", &r->array[cntr_array_1]);
5413 : }
5414 0 : ndr->depth--;
5415 : }
5416 0 : ndr->depth--;
5417 0 : ndr->depth--;
5418 : }
5419 :
5420 542 : static enum ndr_err_code ndr_push_NetShareInfo1005Flags(struct ndr_push *ndr, ndr_flags_type ndr_flags, uint32_t r)
5421 : {
5422 542 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r));
5423 542 : return NDR_ERR_SUCCESS;
5424 : }
5425 :
5426 528 : static enum ndr_err_code ndr_pull_NetShareInfo1005Flags(struct ndr_pull *ndr, ndr_flags_type ndr_flags, uint32_t *r)
5427 : {
5428 0 : uint32_t v;
5429 528 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &v));
5430 528 : *r = v;
5431 528 : return NDR_ERR_SUCCESS;
5432 : }
5433 :
5434 30 : _PUBLIC_ void ndr_print_NetShareInfo1005Flags(struct ndr_print *ndr, const char *name, uint32_t r)
5435 : {
5436 30 : ndr_print_uint32(ndr, name, r);
5437 30 : ndr->depth++;
5438 30 : ndr_print_bitmap_flag(ndr, sizeof(uint32_t), "SHARE_1005_IN_DFS", SHARE_1005_IN_DFS, r);
5439 30 : ndr_print_bitmap_flag(ndr, sizeof(uint32_t), "SHARE_1005_DFS_ROOT", SHARE_1005_DFS_ROOT, r);
5440 30 : ndr_print_bitmap_flag(ndr, sizeof(uint32_t), "SHARE_1005_CSC_CACHE_AUTO_REINT", SHARE_1005_CSC_CACHE_AUTO_REINT, r);
5441 30 : ndr_print_bitmap_flag(ndr, sizeof(uint32_t), "SHARE_1005_CSC_CACHE_VDO", SHARE_1005_CSC_CACHE_VDO, r);
5442 30 : ndr_print_bitmap_flag(ndr, sizeof(uint32_t), "SHARE_1005_CSC_CACHE_NONE", SHARE_1005_CSC_CACHE_NONE, r);
5443 30 : ndr_print_bitmap_flag(ndr, sizeof(uint32_t), "SHARE_1005_RESTRICT_EXCLUSIVE_OPENS", SHARE_1005_RESTRICT_EXCLUSIVE_OPENS, r);
5444 30 : ndr_print_bitmap_flag(ndr, sizeof(uint32_t), "SHARE_1005_FORCE_SHARED_DELETE", SHARE_1005_FORCE_SHARED_DELETE, r);
5445 30 : ndr_print_bitmap_flag(ndr, sizeof(uint32_t), "SHARE_1005_ALLOW_NAMESPACE_CACHING", SHARE_1005_ALLOW_NAMESPACE_CACHING, r);
5446 30 : ndr_print_bitmap_flag(ndr, sizeof(uint32_t), "SHARE_1005_ACCESS_BASED_DIRECTORY_ENUM", SHARE_1005_ACCESS_BASED_DIRECTORY_ENUM, r);
5447 30 : ndr_print_bitmap_flag(ndr, sizeof(uint32_t), "SHARE_1005_FORCE_LEVELII_OPLOCK", SHARE_1005_FORCE_LEVELII_OPLOCK, r);
5448 30 : ndr_print_bitmap_flag(ndr, sizeof(uint32_t), "SHARE_1005_ENABLE_HASH", SHARE_1005_ENABLE_HASH, r);
5449 30 : ndr_print_bitmap_flag(ndr, sizeof(uint32_t), "SHARE_1005_ENABLE_CA", SHARE_1005_ENABLE_CA, r);
5450 30 : ndr_print_bitmap_flag(ndr, sizeof(uint32_t), "SHARE_1005_ENCRYPT_DATA", SHARE_1005_ENCRYPT_DATA, r);
5451 30 : ndr->depth--;
5452 30 : }
5453 :
5454 542 : static enum ndr_err_code ndr_push_srvsvc_NetShareInfo1005(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct srvsvc_NetShareInfo1005 *r)
5455 : {
5456 542 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
5457 542 : if (ndr_flags & NDR_SCALARS) {
5458 542 : NDR_CHECK(ndr_push_align(ndr, 4));
5459 542 : NDR_CHECK(ndr_push_NetShareInfo1005Flags(ndr, NDR_SCALARS, r->dfs_flags));
5460 542 : NDR_CHECK(ndr_push_trailer_align(ndr, 4));
5461 : }
5462 542 : if (ndr_flags & NDR_BUFFERS) {
5463 0 : }
5464 542 : return NDR_ERR_SUCCESS;
5465 : }
5466 :
5467 528 : static enum ndr_err_code ndr_pull_srvsvc_NetShareInfo1005(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct srvsvc_NetShareInfo1005 *r)
5468 : {
5469 528 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
5470 528 : if (ndr_flags & NDR_SCALARS) {
5471 528 : NDR_CHECK(ndr_pull_align(ndr, 4));
5472 528 : NDR_CHECK(ndr_pull_NetShareInfo1005Flags(ndr, NDR_SCALARS, &r->dfs_flags));
5473 528 : NDR_CHECK(ndr_pull_trailer_align(ndr, 4));
5474 : }
5475 528 : if (ndr_flags & NDR_BUFFERS) {
5476 0 : }
5477 528 : return NDR_ERR_SUCCESS;
5478 : }
5479 :
5480 30 : _PUBLIC_ void ndr_print_srvsvc_NetShareInfo1005(struct ndr_print *ndr, const char *name, const struct srvsvc_NetShareInfo1005 *r)
5481 : {
5482 30 : ndr_print_struct(ndr, name, "srvsvc_NetShareInfo1005");
5483 30 : if (r == NULL) { ndr_print_null(ndr); return; }
5484 30 : ndr->depth++;
5485 30 : ndr_print_NetShareInfo1005Flags(ndr, "dfs_flags", r->dfs_flags);
5486 30 : ndr->depth--;
5487 : }
5488 :
5489 8 : static enum ndr_err_code ndr_push_srvsvc_NetShareCtr1005(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct srvsvc_NetShareCtr1005 *r)
5490 : {
5491 0 : uint32_t cntr_array_1;
5492 8 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
5493 8 : if (ndr_flags & NDR_SCALARS) {
5494 8 : NDR_CHECK(ndr_push_align(ndr, 5));
5495 8 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->count));
5496 8 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->array));
5497 8 : NDR_CHECK(ndr_push_trailer_align(ndr, 5));
5498 : }
5499 8 : if (ndr_flags & NDR_BUFFERS) {
5500 8 : if (r->array) {
5501 4 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, r->count));
5502 460 : for (cntr_array_1 = 0; cntr_array_1 < (r->count); cntr_array_1++) {
5503 456 : NDR_CHECK(ndr_push_srvsvc_NetShareInfo1005(ndr, NDR_SCALARS, &r->array[cntr_array_1]));
5504 : }
5505 : }
5506 : }
5507 8 : return NDR_ERR_SUCCESS;
5508 : }
5509 :
5510 8 : static enum ndr_err_code ndr_pull_srvsvc_NetShareCtr1005(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct srvsvc_NetShareCtr1005 *r)
5511 : {
5512 0 : uint32_t _ptr_array;
5513 8 : uint32_t size_array_1 = 0;
5514 0 : uint32_t cntr_array_1;
5515 8 : TALLOC_CTX *_mem_save_array_0 = NULL;
5516 8 : TALLOC_CTX *_mem_save_array_1 = NULL;
5517 8 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
5518 8 : if (ndr_flags & NDR_SCALARS) {
5519 8 : NDR_CHECK(ndr_pull_align(ndr, 5));
5520 8 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->count));
5521 8 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_array));
5522 8 : if (_ptr_array) {
5523 4 : NDR_PULL_ALLOC(ndr, r->array);
5524 : } else {
5525 4 : r->array = NULL;
5526 : }
5527 8 : NDR_CHECK(ndr_pull_trailer_align(ndr, 5));
5528 : }
5529 8 : if (ndr_flags & NDR_BUFFERS) {
5530 8 : if (r->array) {
5531 4 : _mem_save_array_0 = NDR_PULL_GET_MEM_CTX(ndr);
5532 4 : NDR_PULL_SET_MEM_CTX(ndr, r->array, 0);
5533 4 : NDR_CHECK(ndr_pull_array_size(ndr, &r->array));
5534 4 : NDR_CHECK(ndr_get_array_size(ndr, (void*)&r->array, &size_array_1));
5535 4 : NDR_PULL_ALLOC_N(ndr, r->array, size_array_1);
5536 4 : _mem_save_array_1 = NDR_PULL_GET_MEM_CTX(ndr);
5537 4 : NDR_PULL_SET_MEM_CTX(ndr, r->array, 0);
5538 460 : for (cntr_array_1 = 0; cntr_array_1 < (size_array_1); cntr_array_1++) {
5539 456 : NDR_CHECK(ndr_pull_srvsvc_NetShareInfo1005(ndr, NDR_SCALARS, &r->array[cntr_array_1]));
5540 : }
5541 4 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_array_1, 0);
5542 4 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_array_0, 0);
5543 : }
5544 8 : if (r->array) {
5545 4 : NDR_CHECK(ndr_check_steal_array_size(ndr, (void*)&r->array, r->count));
5546 : }
5547 : }
5548 8 : return NDR_ERR_SUCCESS;
5549 : }
5550 :
5551 0 : _PUBLIC_ void ndr_print_srvsvc_NetShareCtr1005(struct ndr_print *ndr, const char *name, const struct srvsvc_NetShareCtr1005 *r)
5552 : {
5553 0 : uint32_t cntr_array_1;
5554 0 : ndr_print_struct(ndr, name, "srvsvc_NetShareCtr1005");
5555 0 : if (r == NULL) { ndr_print_null(ndr); return; }
5556 0 : ndr->depth++;
5557 0 : ndr_print_uint32(ndr, "count", r->count);
5558 0 : ndr_print_ptr(ndr, "array", r->array);
5559 0 : ndr->depth++;
5560 0 : if (r->array) {
5561 0 : ndr->print(ndr, "%s: ARRAY(%"PRIu32")", "array", (uint32_t)(r->count));
5562 0 : ndr->depth++;
5563 0 : for (cntr_array_1 = 0; cntr_array_1 < (r->count); cntr_array_1++) {
5564 0 : ndr_print_srvsvc_NetShareInfo1005(ndr, "array", &r->array[cntr_array_1]);
5565 : }
5566 0 : ndr->depth--;
5567 : }
5568 0 : ndr->depth--;
5569 0 : ndr->depth--;
5570 : }
5571 :
5572 460 : static enum ndr_err_code ndr_push_srvsvc_NetShareInfo1006(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct srvsvc_NetShareInfo1006 *r)
5573 : {
5574 460 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
5575 460 : if (ndr_flags & NDR_SCALARS) {
5576 460 : NDR_CHECK(ndr_push_align(ndr, 4));
5577 460 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->max_users));
5578 460 : NDR_CHECK(ndr_push_trailer_align(ndr, 4));
5579 : }
5580 460 : if (ndr_flags & NDR_BUFFERS) {
5581 0 : }
5582 460 : return NDR_ERR_SUCCESS;
5583 : }
5584 :
5585 460 : static enum ndr_err_code ndr_pull_srvsvc_NetShareInfo1006(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct srvsvc_NetShareInfo1006 *r)
5586 : {
5587 460 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
5588 460 : if (ndr_flags & NDR_SCALARS) {
5589 460 : NDR_CHECK(ndr_pull_align(ndr, 4));
5590 460 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->max_users));
5591 460 : NDR_CHECK(ndr_pull_trailer_align(ndr, 4));
5592 : }
5593 460 : if (ndr_flags & NDR_BUFFERS) {
5594 0 : }
5595 460 : return NDR_ERR_SUCCESS;
5596 : }
5597 :
5598 0 : _PUBLIC_ void ndr_print_srvsvc_NetShareInfo1006(struct ndr_print *ndr, const char *name, const struct srvsvc_NetShareInfo1006 *r)
5599 : {
5600 0 : ndr_print_struct(ndr, name, "srvsvc_NetShareInfo1006");
5601 0 : if (r == NULL) { ndr_print_null(ndr); return; }
5602 0 : ndr->depth++;
5603 0 : ndr_print_uint32(ndr, "max_users", r->max_users);
5604 0 : ndr->depth--;
5605 : }
5606 :
5607 8 : static enum ndr_err_code ndr_push_srvsvc_NetShareCtr1006(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct srvsvc_NetShareCtr1006 *r)
5608 : {
5609 0 : uint32_t cntr_array_1;
5610 8 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
5611 8 : if (ndr_flags & NDR_SCALARS) {
5612 8 : NDR_CHECK(ndr_push_align(ndr, 5));
5613 8 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->count));
5614 8 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->array));
5615 8 : NDR_CHECK(ndr_push_trailer_align(ndr, 5));
5616 : }
5617 8 : if (ndr_flags & NDR_BUFFERS) {
5618 8 : if (r->array) {
5619 4 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, r->count));
5620 460 : for (cntr_array_1 = 0; cntr_array_1 < (r->count); cntr_array_1++) {
5621 456 : NDR_CHECK(ndr_push_srvsvc_NetShareInfo1006(ndr, NDR_SCALARS, &r->array[cntr_array_1]));
5622 : }
5623 : }
5624 : }
5625 8 : return NDR_ERR_SUCCESS;
5626 : }
5627 :
5628 8 : static enum ndr_err_code ndr_pull_srvsvc_NetShareCtr1006(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct srvsvc_NetShareCtr1006 *r)
5629 : {
5630 0 : uint32_t _ptr_array;
5631 8 : uint32_t size_array_1 = 0;
5632 0 : uint32_t cntr_array_1;
5633 8 : TALLOC_CTX *_mem_save_array_0 = NULL;
5634 8 : TALLOC_CTX *_mem_save_array_1 = NULL;
5635 8 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
5636 8 : if (ndr_flags & NDR_SCALARS) {
5637 8 : NDR_CHECK(ndr_pull_align(ndr, 5));
5638 8 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->count));
5639 8 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_array));
5640 8 : if (_ptr_array) {
5641 4 : NDR_PULL_ALLOC(ndr, r->array);
5642 : } else {
5643 4 : r->array = NULL;
5644 : }
5645 8 : NDR_CHECK(ndr_pull_trailer_align(ndr, 5));
5646 : }
5647 8 : if (ndr_flags & NDR_BUFFERS) {
5648 8 : if (r->array) {
5649 4 : _mem_save_array_0 = NDR_PULL_GET_MEM_CTX(ndr);
5650 4 : NDR_PULL_SET_MEM_CTX(ndr, r->array, 0);
5651 4 : NDR_CHECK(ndr_pull_array_size(ndr, &r->array));
5652 4 : NDR_CHECK(ndr_get_array_size(ndr, (void*)&r->array, &size_array_1));
5653 4 : NDR_PULL_ALLOC_N(ndr, r->array, size_array_1);
5654 4 : _mem_save_array_1 = NDR_PULL_GET_MEM_CTX(ndr);
5655 4 : NDR_PULL_SET_MEM_CTX(ndr, r->array, 0);
5656 460 : for (cntr_array_1 = 0; cntr_array_1 < (size_array_1); cntr_array_1++) {
5657 456 : NDR_CHECK(ndr_pull_srvsvc_NetShareInfo1006(ndr, NDR_SCALARS, &r->array[cntr_array_1]));
5658 : }
5659 4 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_array_1, 0);
5660 4 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_array_0, 0);
5661 : }
5662 8 : if (r->array) {
5663 4 : NDR_CHECK(ndr_check_steal_array_size(ndr, (void*)&r->array, r->count));
5664 : }
5665 : }
5666 8 : return NDR_ERR_SUCCESS;
5667 : }
5668 :
5669 0 : _PUBLIC_ void ndr_print_srvsvc_NetShareCtr1006(struct ndr_print *ndr, const char *name, const struct srvsvc_NetShareCtr1006 *r)
5670 : {
5671 0 : uint32_t cntr_array_1;
5672 0 : ndr_print_struct(ndr, name, "srvsvc_NetShareCtr1006");
5673 0 : if (r == NULL) { ndr_print_null(ndr); return; }
5674 0 : ndr->depth++;
5675 0 : ndr_print_uint32(ndr, "count", r->count);
5676 0 : ndr_print_ptr(ndr, "array", r->array);
5677 0 : ndr->depth++;
5678 0 : if (r->array) {
5679 0 : ndr->print(ndr, "%s: ARRAY(%"PRIu32")", "array", (uint32_t)(r->count));
5680 0 : ndr->depth++;
5681 0 : for (cntr_array_1 = 0; cntr_array_1 < (r->count); cntr_array_1++) {
5682 0 : ndr_print_srvsvc_NetShareInfo1006(ndr, "array", &r->array[cntr_array_1]);
5683 : }
5684 0 : ndr->depth--;
5685 : }
5686 0 : ndr->depth--;
5687 0 : ndr->depth--;
5688 : }
5689 :
5690 916 : static enum ndr_err_code ndr_push_srvsvc_NetShareInfo1007(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct srvsvc_NetShareInfo1007 *r)
5691 : {
5692 916 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
5693 916 : if (ndr_flags & NDR_SCALARS) {
5694 460 : NDR_CHECK(ndr_push_align(ndr, 5));
5695 460 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->flags));
5696 460 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->alternate_directory_name));
5697 460 : NDR_CHECK(ndr_push_trailer_align(ndr, 5));
5698 : }
5699 916 : if (ndr_flags & NDR_BUFFERS) {
5700 460 : if (r->alternate_directory_name) {
5701 460 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->alternate_directory_name, CH_UTF16)));
5702 460 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, 0));
5703 460 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->alternate_directory_name, CH_UTF16)));
5704 460 : NDR_CHECK(ndr_push_charset(ndr, NDR_SCALARS, r->alternate_directory_name, ndr_charset_length(r->alternate_directory_name, CH_UTF16), sizeof(uint16_t), CH_UTF16));
5705 : }
5706 : }
5707 916 : return NDR_ERR_SUCCESS;
5708 : }
5709 :
5710 916 : static enum ndr_err_code ndr_pull_srvsvc_NetShareInfo1007(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct srvsvc_NetShareInfo1007 *r)
5711 : {
5712 0 : uint32_t _ptr_alternate_directory_name;
5713 916 : uint32_t size_alternate_directory_name_1 = 0;
5714 916 : uint32_t length_alternate_directory_name_1 = 0;
5715 916 : TALLOC_CTX *_mem_save_alternate_directory_name_0 = NULL;
5716 916 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
5717 916 : if (ndr_flags & NDR_SCALARS) {
5718 460 : NDR_CHECK(ndr_pull_align(ndr, 5));
5719 460 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->flags));
5720 460 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_alternate_directory_name));
5721 460 : if (_ptr_alternate_directory_name) {
5722 460 : NDR_PULL_ALLOC(ndr, r->alternate_directory_name);
5723 : } else {
5724 0 : r->alternate_directory_name = NULL;
5725 : }
5726 460 : NDR_CHECK(ndr_pull_trailer_align(ndr, 5));
5727 : }
5728 916 : if (ndr_flags & NDR_BUFFERS) {
5729 460 : if (r->alternate_directory_name) {
5730 460 : _mem_save_alternate_directory_name_0 = NDR_PULL_GET_MEM_CTX(ndr);
5731 460 : NDR_PULL_SET_MEM_CTX(ndr, r->alternate_directory_name, 0);
5732 460 : NDR_CHECK(ndr_pull_array_size(ndr, &r->alternate_directory_name));
5733 460 : NDR_CHECK(ndr_pull_array_length(ndr, &r->alternate_directory_name));
5734 460 : NDR_CHECK(ndr_steal_array_size(ndr, (void*)&r->alternate_directory_name, &size_alternate_directory_name_1));
5735 460 : NDR_CHECK(ndr_steal_array_length(ndr, (void*)&r->alternate_directory_name, &length_alternate_directory_name_1));
5736 460 : if (length_alternate_directory_name_1 > size_alternate_directory_name_1) {
5737 0 : return ndr_pull_error(ndr, NDR_ERR_ARRAY_SIZE, "Bad array size %"PRIu32": should exceed array length %"PRIu32"", size_alternate_directory_name_1, length_alternate_directory_name_1);
5738 : }
5739 460 : NDR_CHECK(ndr_check_string_terminator(ndr, length_alternate_directory_name_1, sizeof(uint16_t)));
5740 460 : NDR_CHECK(ndr_pull_charset(ndr, NDR_SCALARS, &r->alternate_directory_name, length_alternate_directory_name_1, sizeof(uint16_t), CH_UTF16));
5741 460 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_alternate_directory_name_0, 0);
5742 : }
5743 : }
5744 916 : return NDR_ERR_SUCCESS;
5745 : }
5746 :
5747 0 : _PUBLIC_ void ndr_print_srvsvc_NetShareInfo1007(struct ndr_print *ndr, const char *name, const struct srvsvc_NetShareInfo1007 *r)
5748 : {
5749 0 : ndr_print_struct(ndr, name, "srvsvc_NetShareInfo1007");
5750 0 : if (r == NULL) { ndr_print_null(ndr); return; }
5751 0 : ndr->depth++;
5752 0 : ndr_print_uint32(ndr, "flags", r->flags);
5753 0 : ndr_print_ptr(ndr, "alternate_directory_name", r->alternate_directory_name);
5754 0 : ndr->depth++;
5755 0 : if (r->alternate_directory_name) {
5756 0 : ndr_print_string(ndr, "alternate_directory_name", r->alternate_directory_name);
5757 : }
5758 0 : ndr->depth--;
5759 0 : ndr->depth--;
5760 : }
5761 :
5762 8 : static enum ndr_err_code ndr_push_srvsvc_NetShareCtr1007(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct srvsvc_NetShareCtr1007 *r)
5763 : {
5764 0 : uint32_t cntr_array_1;
5765 8 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
5766 8 : if (ndr_flags & NDR_SCALARS) {
5767 8 : NDR_CHECK(ndr_push_align(ndr, 5));
5768 8 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->count));
5769 8 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->array));
5770 8 : NDR_CHECK(ndr_push_trailer_align(ndr, 5));
5771 : }
5772 8 : if (ndr_flags & NDR_BUFFERS) {
5773 8 : if (r->array) {
5774 4 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, r->count));
5775 460 : for (cntr_array_1 = 0; cntr_array_1 < (r->count); cntr_array_1++) {
5776 456 : NDR_CHECK(ndr_push_srvsvc_NetShareInfo1007(ndr, NDR_SCALARS, &r->array[cntr_array_1]));
5777 : }
5778 460 : for (cntr_array_1 = 0; cntr_array_1 < (r->count); cntr_array_1++) {
5779 456 : NDR_CHECK(ndr_push_srvsvc_NetShareInfo1007(ndr, NDR_BUFFERS, &r->array[cntr_array_1]));
5780 : }
5781 : }
5782 : }
5783 8 : return NDR_ERR_SUCCESS;
5784 : }
5785 :
5786 8 : static enum ndr_err_code ndr_pull_srvsvc_NetShareCtr1007(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct srvsvc_NetShareCtr1007 *r)
5787 : {
5788 0 : uint32_t _ptr_array;
5789 8 : uint32_t size_array_1 = 0;
5790 0 : uint32_t cntr_array_1;
5791 8 : TALLOC_CTX *_mem_save_array_0 = NULL;
5792 8 : TALLOC_CTX *_mem_save_array_1 = NULL;
5793 8 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
5794 8 : if (ndr_flags & NDR_SCALARS) {
5795 8 : NDR_CHECK(ndr_pull_align(ndr, 5));
5796 8 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->count));
5797 8 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_array));
5798 8 : if (_ptr_array) {
5799 4 : NDR_PULL_ALLOC(ndr, r->array);
5800 : } else {
5801 4 : r->array = NULL;
5802 : }
5803 8 : NDR_CHECK(ndr_pull_trailer_align(ndr, 5));
5804 : }
5805 8 : if (ndr_flags & NDR_BUFFERS) {
5806 8 : if (r->array) {
5807 4 : _mem_save_array_0 = NDR_PULL_GET_MEM_CTX(ndr);
5808 4 : NDR_PULL_SET_MEM_CTX(ndr, r->array, 0);
5809 4 : NDR_CHECK(ndr_pull_array_size(ndr, &r->array));
5810 4 : NDR_CHECK(ndr_get_array_size(ndr, (void*)&r->array, &size_array_1));
5811 4 : NDR_PULL_ALLOC_N(ndr, r->array, size_array_1);
5812 4 : _mem_save_array_1 = NDR_PULL_GET_MEM_CTX(ndr);
5813 4 : NDR_PULL_SET_MEM_CTX(ndr, r->array, 0);
5814 460 : for (cntr_array_1 = 0; cntr_array_1 < (size_array_1); cntr_array_1++) {
5815 456 : NDR_CHECK(ndr_pull_srvsvc_NetShareInfo1007(ndr, NDR_SCALARS, &r->array[cntr_array_1]));
5816 : }
5817 460 : for (cntr_array_1 = 0; cntr_array_1 < (size_array_1); cntr_array_1++) {
5818 456 : NDR_CHECK(ndr_pull_srvsvc_NetShareInfo1007(ndr, NDR_BUFFERS, &r->array[cntr_array_1]));
5819 : }
5820 4 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_array_1, 0);
5821 4 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_array_0, 0);
5822 : }
5823 8 : if (r->array) {
5824 4 : NDR_CHECK(ndr_check_array_size(ndr, (void*)&r->array, r->count));
5825 : }
5826 464 : for (cntr_array_1 = 0; cntr_array_1 < (size_array_1); cntr_array_1++) {
5827 0 : }
5828 : }
5829 8 : return NDR_ERR_SUCCESS;
5830 : }
5831 :
5832 0 : _PUBLIC_ void ndr_print_srvsvc_NetShareCtr1007(struct ndr_print *ndr, const char *name, const struct srvsvc_NetShareCtr1007 *r)
5833 : {
5834 0 : uint32_t cntr_array_1;
5835 0 : ndr_print_struct(ndr, name, "srvsvc_NetShareCtr1007");
5836 0 : if (r == NULL) { ndr_print_null(ndr); return; }
5837 0 : ndr->depth++;
5838 0 : ndr_print_uint32(ndr, "count", r->count);
5839 0 : ndr_print_ptr(ndr, "array", r->array);
5840 0 : ndr->depth++;
5841 0 : if (r->array) {
5842 0 : ndr->print(ndr, "%s: ARRAY(%"PRIu32")", "array", (uint32_t)(r->count));
5843 0 : ndr->depth++;
5844 0 : for (cntr_array_1 = 0; cntr_array_1 < (r->count); cntr_array_1++) {
5845 0 : ndr_print_srvsvc_NetShareInfo1007(ndr, "array", &r->array[cntr_array_1]);
5846 : }
5847 0 : ndr->depth--;
5848 : }
5849 0 : ndr->depth--;
5850 0 : ndr->depth--;
5851 : }
5852 :
5853 0 : static enum ndr_err_code ndr_push_srvsvc_NetShareCtr1501(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct srvsvc_NetShareCtr1501 *r)
5854 : {
5855 0 : uint32_t cntr_array_1;
5856 0 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
5857 0 : if (ndr_flags & NDR_SCALARS) {
5858 0 : NDR_CHECK(ndr_push_align(ndr, 5));
5859 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->count));
5860 0 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->array));
5861 0 : NDR_CHECK(ndr_push_trailer_align(ndr, 5));
5862 : }
5863 0 : if (ndr_flags & NDR_BUFFERS) {
5864 0 : if (r->array) {
5865 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, r->count));
5866 0 : for (cntr_array_1 = 0; cntr_array_1 < (r->count); cntr_array_1++) {
5867 0 : NDR_CHECK(ndr_push_sec_desc_buf(ndr, NDR_SCALARS, &r->array[cntr_array_1]));
5868 : }
5869 0 : for (cntr_array_1 = 0; cntr_array_1 < (r->count); cntr_array_1++) {
5870 0 : NDR_CHECK(ndr_push_sec_desc_buf(ndr, NDR_BUFFERS, &r->array[cntr_array_1]));
5871 : }
5872 : }
5873 : }
5874 0 : return NDR_ERR_SUCCESS;
5875 : }
5876 :
5877 0 : static enum ndr_err_code ndr_pull_srvsvc_NetShareCtr1501(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct srvsvc_NetShareCtr1501 *r)
5878 : {
5879 0 : uint32_t _ptr_array;
5880 0 : uint32_t size_array_1 = 0;
5881 0 : uint32_t cntr_array_1;
5882 0 : TALLOC_CTX *_mem_save_array_0 = NULL;
5883 0 : TALLOC_CTX *_mem_save_array_1 = NULL;
5884 0 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
5885 0 : if (ndr_flags & NDR_SCALARS) {
5886 0 : NDR_CHECK(ndr_pull_align(ndr, 5));
5887 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->count));
5888 0 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_array));
5889 0 : if (_ptr_array) {
5890 0 : NDR_PULL_ALLOC(ndr, r->array);
5891 : } else {
5892 0 : r->array = NULL;
5893 : }
5894 0 : NDR_CHECK(ndr_pull_trailer_align(ndr, 5));
5895 : }
5896 0 : if (ndr_flags & NDR_BUFFERS) {
5897 0 : if (r->array) {
5898 0 : _mem_save_array_0 = NDR_PULL_GET_MEM_CTX(ndr);
5899 0 : NDR_PULL_SET_MEM_CTX(ndr, r->array, 0);
5900 0 : NDR_CHECK(ndr_pull_array_size(ndr, &r->array));
5901 0 : NDR_CHECK(ndr_get_array_size(ndr, (void*)&r->array, &size_array_1));
5902 0 : NDR_PULL_ALLOC_N(ndr, r->array, size_array_1);
5903 0 : _mem_save_array_1 = NDR_PULL_GET_MEM_CTX(ndr);
5904 0 : NDR_PULL_SET_MEM_CTX(ndr, r->array, 0);
5905 0 : for (cntr_array_1 = 0; cntr_array_1 < (size_array_1); cntr_array_1++) {
5906 0 : NDR_CHECK(ndr_pull_sec_desc_buf(ndr, NDR_SCALARS, &r->array[cntr_array_1]));
5907 : }
5908 0 : for (cntr_array_1 = 0; cntr_array_1 < (size_array_1); cntr_array_1++) {
5909 0 : NDR_CHECK(ndr_pull_sec_desc_buf(ndr, NDR_BUFFERS, &r->array[cntr_array_1]));
5910 : }
5911 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_array_1, 0);
5912 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_array_0, 0);
5913 : }
5914 0 : if (r->array) {
5915 0 : NDR_CHECK(ndr_check_array_size(ndr, (void*)&r->array, r->count));
5916 : }
5917 0 : for (cntr_array_1 = 0; cntr_array_1 < (size_array_1); cntr_array_1++) {
5918 0 : }
5919 : }
5920 0 : return NDR_ERR_SUCCESS;
5921 : }
5922 :
5923 0 : _PUBLIC_ void ndr_print_srvsvc_NetShareCtr1501(struct ndr_print *ndr, const char *name, const struct srvsvc_NetShareCtr1501 *r)
5924 : {
5925 0 : uint32_t cntr_array_1;
5926 0 : ndr_print_struct(ndr, name, "srvsvc_NetShareCtr1501");
5927 0 : if (r == NULL) { ndr_print_null(ndr); return; }
5928 0 : ndr->depth++;
5929 0 : ndr_print_uint32(ndr, "count", r->count);
5930 0 : ndr_print_ptr(ndr, "array", r->array);
5931 0 : ndr->depth++;
5932 0 : if (r->array) {
5933 0 : ndr->print(ndr, "%s: ARRAY(%"PRIu32")", "array", (uint32_t)(r->count));
5934 0 : ndr->depth++;
5935 0 : for (cntr_array_1 = 0; cntr_array_1 < (r->count); cntr_array_1++) {
5936 0 : ndr_print_sec_desc_buf(ndr, "array", &r->array[cntr_array_1]);
5937 : }
5938 0 : ndr->depth--;
5939 : }
5940 0 : ndr->depth--;
5941 0 : ndr->depth--;
5942 : }
5943 :
5944 583 : static enum ndr_err_code ndr_push_srvsvc_NetShareInfo(struct ndr_push *ndr, ndr_flags_type ndr_flags, const union srvsvc_NetShareInfo *r)
5945 : {
5946 0 : uint32_t level;
5947 583 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
5948 583 : if (ndr_flags & NDR_SCALARS) {
5949 : /* This token is not used again (except perhaps below in the NDR_BUFFERS case) */
5950 583 : NDR_CHECK(ndr_push_steal_switch_value(ndr, r, &level));
5951 583 : NDR_CHECK(ndr_push_union_align(ndr, 5));
5952 583 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, level));
5953 583 : NDR_CHECK(ndr_push_union_align(ndr, 5));
5954 583 : switch (level) {
5955 91 : case 0: {
5956 91 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->info0));
5957 91 : break; }
5958 :
5959 92 : case 1: {
5960 92 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->info1));
5961 92 : break; }
5962 :
5963 93 : case 2: {
5964 93 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->info2));
5965 93 : break; }
5966 :
5967 79 : case 501: {
5968 79 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->info501));
5969 79 : break; }
5970 :
5971 100 : case 502: {
5972 100 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->info502));
5973 100 : break; }
5974 :
5975 4 : case 1004: {
5976 4 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->info1004));
5977 4 : break; }
5978 :
5979 88 : case 1005: {
5980 88 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->info1005));
5981 88 : break; }
5982 :
5983 4 : case 1006: {
5984 4 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->info1006));
5985 4 : break; }
5986 :
5987 4 : case 1007: {
5988 4 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->info1007));
5989 4 : break; }
5990 :
5991 28 : case 1501: {
5992 28 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->info1501));
5993 28 : break; }
5994 :
5995 0 : default: {
5996 0 : break; }
5997 :
5998 : }
5999 : }
6000 583 : if (ndr_flags & NDR_BUFFERS) {
6001 583 : if (!(ndr_flags & NDR_SCALARS)) {
6002 : /* We didn't get it above, and the token is not needed after this. */
6003 0 : NDR_CHECK(ndr_push_steal_switch_value(ndr, r, &level));
6004 : }
6005 583 : switch (level) {
6006 91 : case 0:
6007 91 : if (r->info0) {
6008 91 : NDR_CHECK(ndr_push_srvsvc_NetShareInfo0(ndr, NDR_SCALARS|NDR_BUFFERS, r->info0));
6009 : }
6010 91 : break;
6011 :
6012 92 : case 1:
6013 92 : if (r->info1) {
6014 92 : NDR_CHECK(ndr_push_srvsvc_NetShareInfo1(ndr, NDR_SCALARS|NDR_BUFFERS, r->info1));
6015 : }
6016 92 : break;
6017 :
6018 93 : case 2:
6019 93 : if (r->info2) {
6020 88 : NDR_CHECK(ndr_push_srvsvc_NetShareInfo2(ndr, NDR_SCALARS|NDR_BUFFERS, r->info2));
6021 : }
6022 93 : break;
6023 :
6024 79 : case 501:
6025 79 : if (r->info501) {
6026 79 : NDR_CHECK(ndr_push_srvsvc_NetShareInfo501(ndr, NDR_SCALARS|NDR_BUFFERS, r->info501));
6027 : }
6028 79 : break;
6029 :
6030 100 : case 502:
6031 100 : if (r->info502) {
6032 95 : NDR_CHECK(ndr_push_srvsvc_NetShareInfo502(ndr, NDR_SCALARS|NDR_BUFFERS, r->info502));
6033 : }
6034 100 : break;
6035 :
6036 4 : case 1004:
6037 4 : if (r->info1004) {
6038 4 : NDR_CHECK(ndr_push_srvsvc_NetShareInfo1004(ndr, NDR_SCALARS|NDR_BUFFERS, r->info1004));
6039 : }
6040 4 : break;
6041 :
6042 88 : case 1005:
6043 88 : if (r->info1005) {
6044 86 : NDR_CHECK(ndr_push_srvsvc_NetShareInfo1005(ndr, NDR_SCALARS, r->info1005));
6045 : }
6046 88 : break;
6047 :
6048 4 : case 1006:
6049 4 : if (r->info1006) {
6050 4 : NDR_CHECK(ndr_push_srvsvc_NetShareInfo1006(ndr, NDR_SCALARS, r->info1006));
6051 : }
6052 4 : break;
6053 :
6054 4 : case 1007:
6055 4 : if (r->info1007) {
6056 4 : NDR_CHECK(ndr_push_srvsvc_NetShareInfo1007(ndr, NDR_SCALARS|NDR_BUFFERS, r->info1007));
6057 : }
6058 4 : break;
6059 :
6060 28 : case 1501:
6061 28 : if (r->info1501) {
6062 28 : NDR_CHECK(ndr_push_sec_desc_buf(ndr, NDR_SCALARS|NDR_BUFFERS, r->info1501));
6063 : }
6064 28 : break;
6065 :
6066 0 : default:
6067 0 : break;
6068 :
6069 : }
6070 : }
6071 583 : return NDR_ERR_SUCCESS;
6072 : }
6073 :
6074 1710 : static enum ndr_err_code ndr_pull_srvsvc_NetShareInfo(struct ndr_pull *ndr, ndr_flags_type ndr_flags, union srvsvc_NetShareInfo *r)
6075 : {
6076 0 : uint32_t level;
6077 0 : uint32_t _level;
6078 1710 : TALLOC_CTX *_mem_save_info0_0 = NULL;
6079 0 : uint32_t _ptr_info0;
6080 1710 : TALLOC_CTX *_mem_save_info1_0 = NULL;
6081 0 : uint32_t _ptr_info1;
6082 1710 : TALLOC_CTX *_mem_save_info2_0 = NULL;
6083 0 : uint32_t _ptr_info2;
6084 1710 : TALLOC_CTX *_mem_save_info501_0 = NULL;
6085 0 : uint32_t _ptr_info501;
6086 1710 : TALLOC_CTX *_mem_save_info502_0 = NULL;
6087 0 : uint32_t _ptr_info502;
6088 1710 : TALLOC_CTX *_mem_save_info1004_0 = NULL;
6089 0 : uint32_t _ptr_info1004;
6090 1710 : TALLOC_CTX *_mem_save_info1005_0 = NULL;
6091 0 : uint32_t _ptr_info1005;
6092 1710 : TALLOC_CTX *_mem_save_info1006_0 = NULL;
6093 0 : uint32_t _ptr_info1006;
6094 1710 : TALLOC_CTX *_mem_save_info1007_0 = NULL;
6095 0 : uint32_t _ptr_info1007;
6096 1710 : TALLOC_CTX *_mem_save_info1501_0 = NULL;
6097 0 : uint32_t _ptr_info1501;
6098 1710 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
6099 1710 : if (ndr_flags & NDR_SCALARS) {
6100 : /* This token is not used again (except perhaps below in the NDR_BUFFERS case) */
6101 1710 : NDR_CHECK(ndr_pull_steal_switch_value(ndr, r, &level));
6102 1710 : NDR_CHECK(ndr_pull_union_align(ndr, 5));
6103 1710 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &_level));
6104 1710 : if (_level != level) {
6105 0 : return ndr_pull_error(ndr, NDR_ERR_BAD_SWITCH, "Bad switch value %"PRIu32" for r at %s", (uint32_t)_level, __location__);
6106 : }
6107 1710 : NDR_CHECK(ndr_pull_union_align(ndr, 5));
6108 1710 : switch (level) {
6109 76 : case 0: {
6110 76 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_info0));
6111 76 : if (_ptr_info0) {
6112 76 : NDR_PULL_ALLOC(ndr, r->info0);
6113 : } else {
6114 0 : r->info0 = NULL;
6115 : }
6116 76 : break; }
6117 :
6118 77 : case 1: {
6119 77 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_info1));
6120 77 : if (_ptr_info1) {
6121 77 : NDR_PULL_ALLOC(ndr, r->info1);
6122 : } else {
6123 0 : r->info1 = NULL;
6124 : }
6125 77 : break; }
6126 :
6127 78 : case 2: {
6128 78 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_info2));
6129 78 : if (_ptr_info2) {
6130 74 : NDR_PULL_ALLOC(ndr, r->info2);
6131 : } else {
6132 4 : r->info2 = NULL;
6133 : }
6134 78 : break; }
6135 :
6136 64 : case 501: {
6137 64 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_info501));
6138 64 : if (_ptr_info501) {
6139 64 : NDR_PULL_ALLOC(ndr, r->info501);
6140 : } else {
6141 0 : r->info501 = NULL;
6142 : }
6143 64 : break; }
6144 :
6145 1300 : case 502: {
6146 1300 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_info502));
6147 1300 : if (_ptr_info502) {
6148 1296 : NDR_PULL_ALLOC(ndr, r->info502);
6149 : } else {
6150 4 : r->info502 = NULL;
6151 : }
6152 1300 : break; }
6153 :
6154 4 : case 1004: {
6155 4 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_info1004));
6156 4 : if (_ptr_info1004) {
6157 4 : NDR_PULL_ALLOC(ndr, r->info1004);
6158 : } else {
6159 0 : r->info1004 = NULL;
6160 : }
6161 4 : break; }
6162 :
6163 75 : case 1005: {
6164 75 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_info1005));
6165 75 : if (_ptr_info1005) {
6166 72 : NDR_PULL_ALLOC(ndr, r->info1005);
6167 : } else {
6168 3 : r->info1005 = NULL;
6169 : }
6170 75 : break; }
6171 :
6172 4 : case 1006: {
6173 4 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_info1006));
6174 4 : if (_ptr_info1006) {
6175 4 : NDR_PULL_ALLOC(ndr, r->info1006);
6176 : } else {
6177 0 : r->info1006 = NULL;
6178 : }
6179 4 : break; }
6180 :
6181 4 : case 1007: {
6182 4 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_info1007));
6183 4 : if (_ptr_info1007) {
6184 4 : NDR_PULL_ALLOC(ndr, r->info1007);
6185 : } else {
6186 0 : r->info1007 = NULL;
6187 : }
6188 4 : break; }
6189 :
6190 28 : case 1501: {
6191 28 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_info1501));
6192 28 : if (_ptr_info1501) {
6193 28 : NDR_PULL_ALLOC(ndr, r->info1501);
6194 : } else {
6195 0 : r->info1501 = NULL;
6196 : }
6197 28 : break; }
6198 :
6199 0 : default: {
6200 0 : break; }
6201 :
6202 : }
6203 : }
6204 1710 : if (ndr_flags & NDR_BUFFERS) {
6205 1710 : if (!(ndr_flags & NDR_SCALARS)) {
6206 : /* We didn't get it above, and the token is not needed after this. */
6207 0 : NDR_CHECK(ndr_pull_steal_switch_value(ndr, r, &level));
6208 : }
6209 1710 : switch (level) {
6210 76 : case 0:
6211 76 : if (r->info0) {
6212 76 : _mem_save_info0_0 = NDR_PULL_GET_MEM_CTX(ndr);
6213 76 : NDR_PULL_SET_MEM_CTX(ndr, r->info0, 0);
6214 76 : NDR_CHECK(ndr_pull_srvsvc_NetShareInfo0(ndr, NDR_SCALARS|NDR_BUFFERS, r->info0));
6215 76 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_info0_0, 0);
6216 : }
6217 76 : break;
6218 :
6219 77 : case 1:
6220 77 : if (r->info1) {
6221 77 : _mem_save_info1_0 = NDR_PULL_GET_MEM_CTX(ndr);
6222 77 : NDR_PULL_SET_MEM_CTX(ndr, r->info1, 0);
6223 77 : NDR_CHECK(ndr_pull_srvsvc_NetShareInfo1(ndr, NDR_SCALARS|NDR_BUFFERS, r->info1));
6224 77 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_info1_0, 0);
6225 : }
6226 77 : break;
6227 :
6228 78 : case 2:
6229 78 : if (r->info2) {
6230 74 : _mem_save_info2_0 = NDR_PULL_GET_MEM_CTX(ndr);
6231 74 : NDR_PULL_SET_MEM_CTX(ndr, r->info2, 0);
6232 74 : NDR_CHECK(ndr_pull_srvsvc_NetShareInfo2(ndr, NDR_SCALARS|NDR_BUFFERS, r->info2));
6233 74 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_info2_0, 0);
6234 : }
6235 78 : break;
6236 :
6237 64 : case 501:
6238 64 : if (r->info501) {
6239 64 : _mem_save_info501_0 = NDR_PULL_GET_MEM_CTX(ndr);
6240 64 : NDR_PULL_SET_MEM_CTX(ndr, r->info501, 0);
6241 64 : NDR_CHECK(ndr_pull_srvsvc_NetShareInfo501(ndr, NDR_SCALARS|NDR_BUFFERS, r->info501));
6242 64 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_info501_0, 0);
6243 : }
6244 64 : break;
6245 :
6246 1300 : case 502:
6247 1300 : if (r->info502) {
6248 1296 : _mem_save_info502_0 = NDR_PULL_GET_MEM_CTX(ndr);
6249 1296 : NDR_PULL_SET_MEM_CTX(ndr, r->info502, 0);
6250 1296 : NDR_CHECK(ndr_pull_srvsvc_NetShareInfo502(ndr, NDR_SCALARS|NDR_BUFFERS, r->info502));
6251 1296 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_info502_0, 0);
6252 : }
6253 1300 : break;
6254 :
6255 4 : case 1004:
6256 4 : if (r->info1004) {
6257 4 : _mem_save_info1004_0 = NDR_PULL_GET_MEM_CTX(ndr);
6258 4 : NDR_PULL_SET_MEM_CTX(ndr, r->info1004, 0);
6259 4 : NDR_CHECK(ndr_pull_srvsvc_NetShareInfo1004(ndr, NDR_SCALARS|NDR_BUFFERS, r->info1004));
6260 4 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_info1004_0, 0);
6261 : }
6262 4 : break;
6263 :
6264 75 : case 1005:
6265 75 : if (r->info1005) {
6266 72 : _mem_save_info1005_0 = NDR_PULL_GET_MEM_CTX(ndr);
6267 72 : NDR_PULL_SET_MEM_CTX(ndr, r->info1005, 0);
6268 72 : NDR_CHECK(ndr_pull_srvsvc_NetShareInfo1005(ndr, NDR_SCALARS, r->info1005));
6269 72 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_info1005_0, 0);
6270 : }
6271 75 : break;
6272 :
6273 4 : case 1006:
6274 4 : if (r->info1006) {
6275 4 : _mem_save_info1006_0 = NDR_PULL_GET_MEM_CTX(ndr);
6276 4 : NDR_PULL_SET_MEM_CTX(ndr, r->info1006, 0);
6277 4 : NDR_CHECK(ndr_pull_srvsvc_NetShareInfo1006(ndr, NDR_SCALARS, r->info1006));
6278 4 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_info1006_0, 0);
6279 : }
6280 4 : break;
6281 :
6282 4 : case 1007:
6283 4 : if (r->info1007) {
6284 4 : _mem_save_info1007_0 = NDR_PULL_GET_MEM_CTX(ndr);
6285 4 : NDR_PULL_SET_MEM_CTX(ndr, r->info1007, 0);
6286 4 : NDR_CHECK(ndr_pull_srvsvc_NetShareInfo1007(ndr, NDR_SCALARS|NDR_BUFFERS, r->info1007));
6287 4 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_info1007_0, 0);
6288 : }
6289 4 : break;
6290 :
6291 28 : case 1501:
6292 28 : if (r->info1501) {
6293 28 : _mem_save_info1501_0 = NDR_PULL_GET_MEM_CTX(ndr);
6294 28 : NDR_PULL_SET_MEM_CTX(ndr, r->info1501, 0);
6295 28 : NDR_CHECK(ndr_pull_sec_desc_buf(ndr, NDR_SCALARS|NDR_BUFFERS, r->info1501));
6296 28 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_info1501_0, 0);
6297 : }
6298 28 : break;
6299 :
6300 0 : default:
6301 0 : break;
6302 :
6303 : }
6304 : }
6305 1710 : return NDR_ERR_SUCCESS;
6306 : }
6307 :
6308 180 : _PUBLIC_ void ndr_print_srvsvc_NetShareInfo(struct ndr_print *ndr, const char *name, const union srvsvc_NetShareInfo *r)
6309 : {
6310 0 : uint32_t level;
6311 180 : level = ndr_print_steal_switch_value(ndr, r);
6312 180 : ndr_print_union(ndr, name, level, "srvsvc_NetShareInfo");
6313 180 : switch (level) {
6314 30 : case 0:
6315 30 : ndr_print_ptr(ndr, "info0", r->info0);
6316 30 : ndr->depth++;
6317 30 : if (r->info0) {
6318 30 : ndr_print_srvsvc_NetShareInfo0(ndr, "info0", r->info0);
6319 : }
6320 30 : ndr->depth--;
6321 30 : break;
6322 :
6323 30 : case 1:
6324 30 : ndr_print_ptr(ndr, "info1", r->info1);
6325 30 : ndr->depth++;
6326 30 : if (r->info1) {
6327 30 : ndr_print_srvsvc_NetShareInfo1(ndr, "info1", r->info1);
6328 : }
6329 30 : ndr->depth--;
6330 30 : break;
6331 :
6332 30 : case 2:
6333 30 : ndr_print_ptr(ndr, "info2", r->info2);
6334 30 : ndr->depth++;
6335 30 : if (r->info2) {
6336 28 : ndr_print_srvsvc_NetShareInfo2(ndr, "info2", r->info2);
6337 : }
6338 30 : ndr->depth--;
6339 30 : break;
6340 :
6341 30 : case 501:
6342 30 : ndr_print_ptr(ndr, "info501", r->info501);
6343 30 : ndr->depth++;
6344 30 : if (r->info501) {
6345 30 : ndr_print_srvsvc_NetShareInfo501(ndr, "info501", r->info501);
6346 : }
6347 30 : ndr->depth--;
6348 30 : break;
6349 :
6350 30 : case 502:
6351 30 : ndr_print_ptr(ndr, "info502", r->info502);
6352 30 : ndr->depth++;
6353 30 : if (r->info502) {
6354 28 : ndr_print_srvsvc_NetShareInfo502(ndr, "info502", r->info502);
6355 : }
6356 30 : ndr->depth--;
6357 30 : break;
6358 :
6359 0 : case 1004:
6360 0 : ndr_print_ptr(ndr, "info1004", r->info1004);
6361 0 : ndr->depth++;
6362 0 : if (r->info1004) {
6363 0 : ndr_print_srvsvc_NetShareInfo1004(ndr, "info1004", r->info1004);
6364 : }
6365 0 : ndr->depth--;
6366 0 : break;
6367 :
6368 30 : case 1005:
6369 30 : ndr_print_ptr(ndr, "info1005", r->info1005);
6370 30 : ndr->depth++;
6371 30 : if (r->info1005) {
6372 30 : ndr_print_srvsvc_NetShareInfo1005(ndr, "info1005", r->info1005);
6373 : }
6374 30 : ndr->depth--;
6375 30 : break;
6376 :
6377 0 : case 1006:
6378 0 : ndr_print_ptr(ndr, "info1006", r->info1006);
6379 0 : ndr->depth++;
6380 0 : if (r->info1006) {
6381 0 : ndr_print_srvsvc_NetShareInfo1006(ndr, "info1006", r->info1006);
6382 : }
6383 0 : ndr->depth--;
6384 0 : break;
6385 :
6386 0 : case 1007:
6387 0 : ndr_print_ptr(ndr, "info1007", r->info1007);
6388 0 : ndr->depth++;
6389 0 : if (r->info1007) {
6390 0 : ndr_print_srvsvc_NetShareInfo1007(ndr, "info1007", r->info1007);
6391 : }
6392 0 : ndr->depth--;
6393 0 : break;
6394 :
6395 0 : case 1501:
6396 0 : ndr_print_ptr(ndr, "info1501", r->info1501);
6397 0 : ndr->depth++;
6398 0 : if (r->info1501) {
6399 0 : ndr_print_sec_desc_buf(ndr, "info1501", r->info1501);
6400 : }
6401 0 : ndr->depth--;
6402 0 : break;
6403 :
6404 0 : default:
6405 0 : break;
6406 :
6407 : }
6408 180 : }
6409 :
6410 1200 : static enum ndr_err_code ndr_push_srvsvc_NetShareCtr(struct ndr_push *ndr, ndr_flags_type ndr_flags, const union srvsvc_NetShareCtr *r)
6411 : {
6412 0 : uint32_t level;
6413 1200 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
6414 1200 : if (ndr_flags & NDR_SCALARS) {
6415 : /* This token is not used again (except perhaps below in the NDR_BUFFERS case) */
6416 600 : NDR_CHECK(ndr_push_steal_switch_value(ndr, r, &level));
6417 600 : NDR_CHECK(ndr_push_union_align(ndr, 5));
6418 600 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, level));
6419 600 : NDR_CHECK(ndr_push_union_align(ndr, 5));
6420 600 : switch (level) {
6421 78 : case 0: {
6422 78 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->ctr0));
6423 78 : break; }
6424 :
6425 276 : case 1: {
6426 276 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->ctr1));
6427 276 : break; }
6428 :
6429 114 : case 2: {
6430 114 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->ctr2));
6431 114 : break; }
6432 :
6433 54 : case 501: {
6434 54 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->ctr501));
6435 54 : break; }
6436 :
6437 46 : case 502: {
6438 46 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->ctr502));
6439 46 : break; }
6440 :
6441 8 : case 1004: {
6442 8 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->ctr1004));
6443 8 : break; }
6444 :
6445 8 : case 1005: {
6446 8 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->ctr1005));
6447 8 : break; }
6448 :
6449 8 : case 1006: {
6450 8 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->ctr1006));
6451 8 : break; }
6452 :
6453 8 : case 1007: {
6454 8 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->ctr1007));
6455 8 : break; }
6456 :
6457 0 : case 1501: {
6458 0 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->ctr1501));
6459 0 : break; }
6460 :
6461 0 : default: {
6462 0 : break; }
6463 :
6464 : }
6465 : }
6466 1200 : if (ndr_flags & NDR_BUFFERS) {
6467 600 : if (!(ndr_flags & NDR_SCALARS)) {
6468 : /* We didn't get it above, and the token is not needed after this. */
6469 600 : NDR_CHECK(ndr_push_steal_switch_value(ndr, r, &level));
6470 : }
6471 600 : switch (level) {
6472 78 : case 0:
6473 78 : if (r->ctr0) {
6474 78 : NDR_CHECK(ndr_push_srvsvc_NetShareCtr0(ndr, NDR_SCALARS|NDR_BUFFERS, r->ctr0));
6475 : }
6476 78 : break;
6477 :
6478 276 : case 1:
6479 276 : if (r->ctr1) {
6480 276 : NDR_CHECK(ndr_push_srvsvc_NetShareCtr1(ndr, NDR_SCALARS|NDR_BUFFERS, r->ctr1));
6481 : }
6482 276 : break;
6483 :
6484 114 : case 2:
6485 114 : if (r->ctr2) {
6486 114 : NDR_CHECK(ndr_push_srvsvc_NetShareCtr2(ndr, NDR_SCALARS|NDR_BUFFERS, r->ctr2));
6487 : }
6488 114 : break;
6489 :
6490 54 : case 501:
6491 54 : if (r->ctr501) {
6492 54 : NDR_CHECK(ndr_push_srvsvc_NetShareCtr501(ndr, NDR_SCALARS|NDR_BUFFERS, r->ctr501));
6493 : }
6494 54 : break;
6495 :
6496 46 : case 502:
6497 46 : if (r->ctr502) {
6498 46 : NDR_CHECK(ndr_push_srvsvc_NetShareCtr502(ndr, NDR_SCALARS|NDR_BUFFERS, r->ctr502));
6499 : }
6500 46 : break;
6501 :
6502 8 : case 1004:
6503 8 : if (r->ctr1004) {
6504 8 : NDR_CHECK(ndr_push_srvsvc_NetShareCtr1004(ndr, NDR_SCALARS|NDR_BUFFERS, r->ctr1004));
6505 : }
6506 8 : break;
6507 :
6508 8 : case 1005:
6509 8 : if (r->ctr1005) {
6510 8 : NDR_CHECK(ndr_push_srvsvc_NetShareCtr1005(ndr, NDR_SCALARS|NDR_BUFFERS, r->ctr1005));
6511 : }
6512 8 : break;
6513 :
6514 8 : case 1006:
6515 8 : if (r->ctr1006) {
6516 8 : NDR_CHECK(ndr_push_srvsvc_NetShareCtr1006(ndr, NDR_SCALARS|NDR_BUFFERS, r->ctr1006));
6517 : }
6518 8 : break;
6519 :
6520 8 : case 1007:
6521 8 : if (r->ctr1007) {
6522 8 : NDR_CHECK(ndr_push_srvsvc_NetShareCtr1007(ndr, NDR_SCALARS|NDR_BUFFERS, r->ctr1007));
6523 : }
6524 8 : break;
6525 :
6526 0 : case 1501:
6527 0 : if (r->ctr1501) {
6528 0 : NDR_CHECK(ndr_push_srvsvc_NetShareCtr1501(ndr, NDR_SCALARS|NDR_BUFFERS, r->ctr1501));
6529 : }
6530 0 : break;
6531 :
6532 0 : default:
6533 0 : break;
6534 :
6535 : }
6536 : }
6537 1200 : return NDR_ERR_SUCCESS;
6538 : }
6539 :
6540 1160 : static enum ndr_err_code ndr_pull_srvsvc_NetShareCtr(struct ndr_pull *ndr, ndr_flags_type ndr_flags, union srvsvc_NetShareCtr *r)
6541 : {
6542 0 : uint32_t level;
6543 0 : uint32_t _level;
6544 1160 : TALLOC_CTX *_mem_save_ctr0_0 = NULL;
6545 0 : uint32_t _ptr_ctr0;
6546 1160 : TALLOC_CTX *_mem_save_ctr1_0 = NULL;
6547 0 : uint32_t _ptr_ctr1;
6548 1160 : TALLOC_CTX *_mem_save_ctr2_0 = NULL;
6549 0 : uint32_t _ptr_ctr2;
6550 1160 : TALLOC_CTX *_mem_save_ctr501_0 = NULL;
6551 0 : uint32_t _ptr_ctr501;
6552 1160 : TALLOC_CTX *_mem_save_ctr502_0 = NULL;
6553 0 : uint32_t _ptr_ctr502;
6554 1160 : TALLOC_CTX *_mem_save_ctr1004_0 = NULL;
6555 0 : uint32_t _ptr_ctr1004;
6556 1160 : TALLOC_CTX *_mem_save_ctr1005_0 = NULL;
6557 0 : uint32_t _ptr_ctr1005;
6558 1160 : TALLOC_CTX *_mem_save_ctr1006_0 = NULL;
6559 0 : uint32_t _ptr_ctr1006;
6560 1160 : TALLOC_CTX *_mem_save_ctr1007_0 = NULL;
6561 0 : uint32_t _ptr_ctr1007;
6562 1160 : TALLOC_CTX *_mem_save_ctr1501_0 = NULL;
6563 0 : uint32_t _ptr_ctr1501;
6564 1160 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
6565 1160 : if (ndr_flags & NDR_SCALARS) {
6566 : /* This token is not used again (except perhaps below in the NDR_BUFFERS case) */
6567 580 : NDR_CHECK(ndr_pull_steal_switch_value(ndr, r, &level));
6568 580 : NDR_CHECK(ndr_pull_union_align(ndr, 5));
6569 580 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &_level));
6570 580 : if (_level != level) {
6571 0 : return ndr_pull_error(ndr, NDR_ERR_BAD_SWITCH, "Bad switch value %"PRIu32" for r at %s", (uint32_t)_level, __location__);
6572 : }
6573 580 : NDR_CHECK(ndr_pull_union_align(ndr, 5));
6574 580 : switch (level) {
6575 74 : case 0: {
6576 74 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_ctr0));
6577 74 : if (_ptr_ctr0) {
6578 74 : NDR_PULL_ALLOC(ndr, r->ctr0);
6579 : } else {
6580 0 : r->ctr0 = NULL;
6581 : }
6582 74 : break; }
6583 :
6584 272 : case 1: {
6585 272 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_ctr1));
6586 272 : if (_ptr_ctr1) {
6587 272 : NDR_PULL_ALLOC(ndr, r->ctr1);
6588 : } else {
6589 0 : r->ctr1 = NULL;
6590 : }
6591 272 : break; }
6592 :
6593 110 : case 2: {
6594 110 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_ctr2));
6595 110 : if (_ptr_ctr2) {
6596 110 : NDR_PULL_ALLOC(ndr, r->ctr2);
6597 : } else {
6598 0 : r->ctr2 = NULL;
6599 : }
6600 110 : break; }
6601 :
6602 50 : case 501: {
6603 50 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_ctr501));
6604 50 : if (_ptr_ctr501) {
6605 50 : NDR_PULL_ALLOC(ndr, r->ctr501);
6606 : } else {
6607 0 : r->ctr501 = NULL;
6608 : }
6609 50 : break; }
6610 :
6611 42 : case 502: {
6612 42 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_ctr502));
6613 42 : if (_ptr_ctr502) {
6614 42 : NDR_PULL_ALLOC(ndr, r->ctr502);
6615 : } else {
6616 0 : r->ctr502 = NULL;
6617 : }
6618 42 : break; }
6619 :
6620 8 : case 1004: {
6621 8 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_ctr1004));
6622 8 : if (_ptr_ctr1004) {
6623 8 : NDR_PULL_ALLOC(ndr, r->ctr1004);
6624 : } else {
6625 0 : r->ctr1004 = NULL;
6626 : }
6627 8 : break; }
6628 :
6629 8 : case 1005: {
6630 8 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_ctr1005));
6631 8 : if (_ptr_ctr1005) {
6632 8 : NDR_PULL_ALLOC(ndr, r->ctr1005);
6633 : } else {
6634 0 : r->ctr1005 = NULL;
6635 : }
6636 8 : break; }
6637 :
6638 8 : case 1006: {
6639 8 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_ctr1006));
6640 8 : if (_ptr_ctr1006) {
6641 8 : NDR_PULL_ALLOC(ndr, r->ctr1006);
6642 : } else {
6643 0 : r->ctr1006 = NULL;
6644 : }
6645 8 : break; }
6646 :
6647 8 : case 1007: {
6648 8 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_ctr1007));
6649 8 : if (_ptr_ctr1007) {
6650 8 : NDR_PULL_ALLOC(ndr, r->ctr1007);
6651 : } else {
6652 0 : r->ctr1007 = NULL;
6653 : }
6654 8 : break; }
6655 :
6656 0 : case 1501: {
6657 0 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_ctr1501));
6658 0 : if (_ptr_ctr1501) {
6659 0 : NDR_PULL_ALLOC(ndr, r->ctr1501);
6660 : } else {
6661 0 : r->ctr1501 = NULL;
6662 : }
6663 0 : break; }
6664 :
6665 0 : default: {
6666 0 : break; }
6667 :
6668 : }
6669 : }
6670 1160 : if (ndr_flags & NDR_BUFFERS) {
6671 580 : if (!(ndr_flags & NDR_SCALARS)) {
6672 : /* We didn't get it above, and the token is not needed after this. */
6673 580 : NDR_CHECK(ndr_pull_steal_switch_value(ndr, r, &level));
6674 : }
6675 580 : switch (level) {
6676 74 : case 0:
6677 74 : if (r->ctr0) {
6678 74 : _mem_save_ctr0_0 = NDR_PULL_GET_MEM_CTX(ndr);
6679 74 : NDR_PULL_SET_MEM_CTX(ndr, r->ctr0, 0);
6680 74 : NDR_CHECK(ndr_pull_srvsvc_NetShareCtr0(ndr, NDR_SCALARS|NDR_BUFFERS, r->ctr0));
6681 74 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_ctr0_0, 0);
6682 : }
6683 74 : break;
6684 :
6685 272 : case 1:
6686 272 : if (r->ctr1) {
6687 272 : _mem_save_ctr1_0 = NDR_PULL_GET_MEM_CTX(ndr);
6688 272 : NDR_PULL_SET_MEM_CTX(ndr, r->ctr1, 0);
6689 272 : NDR_CHECK(ndr_pull_srvsvc_NetShareCtr1(ndr, NDR_SCALARS|NDR_BUFFERS, r->ctr1));
6690 272 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_ctr1_0, 0);
6691 : }
6692 272 : break;
6693 :
6694 110 : case 2:
6695 110 : if (r->ctr2) {
6696 110 : _mem_save_ctr2_0 = NDR_PULL_GET_MEM_CTX(ndr);
6697 110 : NDR_PULL_SET_MEM_CTX(ndr, r->ctr2, 0);
6698 110 : NDR_CHECK(ndr_pull_srvsvc_NetShareCtr2(ndr, NDR_SCALARS|NDR_BUFFERS, r->ctr2));
6699 110 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_ctr2_0, 0);
6700 : }
6701 110 : break;
6702 :
6703 50 : case 501:
6704 50 : if (r->ctr501) {
6705 50 : _mem_save_ctr501_0 = NDR_PULL_GET_MEM_CTX(ndr);
6706 50 : NDR_PULL_SET_MEM_CTX(ndr, r->ctr501, 0);
6707 50 : NDR_CHECK(ndr_pull_srvsvc_NetShareCtr501(ndr, NDR_SCALARS|NDR_BUFFERS, r->ctr501));
6708 50 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_ctr501_0, 0);
6709 : }
6710 50 : break;
6711 :
6712 42 : case 502:
6713 42 : if (r->ctr502) {
6714 42 : _mem_save_ctr502_0 = NDR_PULL_GET_MEM_CTX(ndr);
6715 42 : NDR_PULL_SET_MEM_CTX(ndr, r->ctr502, 0);
6716 42 : NDR_CHECK(ndr_pull_srvsvc_NetShareCtr502(ndr, NDR_SCALARS|NDR_BUFFERS, r->ctr502));
6717 42 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_ctr502_0, 0);
6718 : }
6719 42 : break;
6720 :
6721 8 : case 1004:
6722 8 : if (r->ctr1004) {
6723 8 : _mem_save_ctr1004_0 = NDR_PULL_GET_MEM_CTX(ndr);
6724 8 : NDR_PULL_SET_MEM_CTX(ndr, r->ctr1004, 0);
6725 8 : NDR_CHECK(ndr_pull_srvsvc_NetShareCtr1004(ndr, NDR_SCALARS|NDR_BUFFERS, r->ctr1004));
6726 8 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_ctr1004_0, 0);
6727 : }
6728 8 : break;
6729 :
6730 8 : case 1005:
6731 8 : if (r->ctr1005) {
6732 8 : _mem_save_ctr1005_0 = NDR_PULL_GET_MEM_CTX(ndr);
6733 8 : NDR_PULL_SET_MEM_CTX(ndr, r->ctr1005, 0);
6734 8 : NDR_CHECK(ndr_pull_srvsvc_NetShareCtr1005(ndr, NDR_SCALARS|NDR_BUFFERS, r->ctr1005));
6735 8 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_ctr1005_0, 0);
6736 : }
6737 8 : break;
6738 :
6739 8 : case 1006:
6740 8 : if (r->ctr1006) {
6741 8 : _mem_save_ctr1006_0 = NDR_PULL_GET_MEM_CTX(ndr);
6742 8 : NDR_PULL_SET_MEM_CTX(ndr, r->ctr1006, 0);
6743 8 : NDR_CHECK(ndr_pull_srvsvc_NetShareCtr1006(ndr, NDR_SCALARS|NDR_BUFFERS, r->ctr1006));
6744 8 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_ctr1006_0, 0);
6745 : }
6746 8 : break;
6747 :
6748 8 : case 1007:
6749 8 : if (r->ctr1007) {
6750 8 : _mem_save_ctr1007_0 = NDR_PULL_GET_MEM_CTX(ndr);
6751 8 : NDR_PULL_SET_MEM_CTX(ndr, r->ctr1007, 0);
6752 8 : NDR_CHECK(ndr_pull_srvsvc_NetShareCtr1007(ndr, NDR_SCALARS|NDR_BUFFERS, r->ctr1007));
6753 8 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_ctr1007_0, 0);
6754 : }
6755 8 : break;
6756 :
6757 0 : case 1501:
6758 0 : if (r->ctr1501) {
6759 0 : _mem_save_ctr1501_0 = NDR_PULL_GET_MEM_CTX(ndr);
6760 0 : NDR_PULL_SET_MEM_CTX(ndr, r->ctr1501, 0);
6761 0 : NDR_CHECK(ndr_pull_srvsvc_NetShareCtr1501(ndr, NDR_SCALARS|NDR_BUFFERS, r->ctr1501));
6762 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_ctr1501_0, 0);
6763 : }
6764 0 : break;
6765 :
6766 0 : default:
6767 0 : break;
6768 :
6769 : }
6770 : }
6771 1160 : return NDR_ERR_SUCCESS;
6772 : }
6773 :
6774 40 : _PUBLIC_ void ndr_print_srvsvc_NetShareCtr(struct ndr_print *ndr, const char *name, const union srvsvc_NetShareCtr *r)
6775 : {
6776 0 : uint32_t level;
6777 40 : level = ndr_print_steal_switch_value(ndr, r);
6778 40 : ndr_print_union(ndr, name, level, "srvsvc_NetShareCtr");
6779 40 : switch (level) {
6780 8 : case 0:
6781 8 : ndr_print_ptr(ndr, "ctr0", r->ctr0);
6782 8 : ndr->depth++;
6783 8 : if (r->ctr0) {
6784 8 : ndr_print_srvsvc_NetShareCtr0(ndr, "ctr0", r->ctr0);
6785 : }
6786 8 : ndr->depth--;
6787 8 : break;
6788 :
6789 8 : case 1:
6790 8 : ndr_print_ptr(ndr, "ctr1", r->ctr1);
6791 8 : ndr->depth++;
6792 8 : if (r->ctr1) {
6793 8 : ndr_print_srvsvc_NetShareCtr1(ndr, "ctr1", r->ctr1);
6794 : }
6795 8 : ndr->depth--;
6796 8 : break;
6797 :
6798 8 : case 2:
6799 8 : ndr_print_ptr(ndr, "ctr2", r->ctr2);
6800 8 : ndr->depth++;
6801 8 : if (r->ctr2) {
6802 8 : ndr_print_srvsvc_NetShareCtr2(ndr, "ctr2", r->ctr2);
6803 : }
6804 8 : ndr->depth--;
6805 8 : break;
6806 :
6807 8 : case 501:
6808 8 : ndr_print_ptr(ndr, "ctr501", r->ctr501);
6809 8 : ndr->depth++;
6810 8 : if (r->ctr501) {
6811 8 : ndr_print_srvsvc_NetShareCtr501(ndr, "ctr501", r->ctr501);
6812 : }
6813 8 : ndr->depth--;
6814 8 : break;
6815 :
6816 8 : case 502:
6817 8 : ndr_print_ptr(ndr, "ctr502", r->ctr502);
6818 8 : ndr->depth++;
6819 8 : if (r->ctr502) {
6820 8 : ndr_print_srvsvc_NetShareCtr502(ndr, "ctr502", r->ctr502);
6821 : }
6822 8 : ndr->depth--;
6823 8 : break;
6824 :
6825 0 : case 1004:
6826 0 : ndr_print_ptr(ndr, "ctr1004", r->ctr1004);
6827 0 : ndr->depth++;
6828 0 : if (r->ctr1004) {
6829 0 : ndr_print_srvsvc_NetShareCtr1004(ndr, "ctr1004", r->ctr1004);
6830 : }
6831 0 : ndr->depth--;
6832 0 : break;
6833 :
6834 0 : case 1005:
6835 0 : ndr_print_ptr(ndr, "ctr1005", r->ctr1005);
6836 0 : ndr->depth++;
6837 0 : if (r->ctr1005) {
6838 0 : ndr_print_srvsvc_NetShareCtr1005(ndr, "ctr1005", r->ctr1005);
6839 : }
6840 0 : ndr->depth--;
6841 0 : break;
6842 :
6843 0 : case 1006:
6844 0 : ndr_print_ptr(ndr, "ctr1006", r->ctr1006);
6845 0 : ndr->depth++;
6846 0 : if (r->ctr1006) {
6847 0 : ndr_print_srvsvc_NetShareCtr1006(ndr, "ctr1006", r->ctr1006);
6848 : }
6849 0 : ndr->depth--;
6850 0 : break;
6851 :
6852 0 : case 1007:
6853 0 : ndr_print_ptr(ndr, "ctr1007", r->ctr1007);
6854 0 : ndr->depth++;
6855 0 : if (r->ctr1007) {
6856 0 : ndr_print_srvsvc_NetShareCtr1007(ndr, "ctr1007", r->ctr1007);
6857 : }
6858 0 : ndr->depth--;
6859 0 : break;
6860 :
6861 0 : case 1501:
6862 0 : ndr_print_ptr(ndr, "ctr1501", r->ctr1501);
6863 0 : ndr->depth++;
6864 0 : if (r->ctr1501) {
6865 0 : ndr_print_srvsvc_NetShareCtr1501(ndr, "ctr1501", r->ctr1501);
6866 : }
6867 0 : ndr->depth--;
6868 0 : break;
6869 :
6870 0 : default:
6871 0 : break;
6872 :
6873 : }
6874 40 : }
6875 :
6876 600 : static enum ndr_err_code ndr_push_srvsvc_NetShareInfoCtr(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct srvsvc_NetShareInfoCtr *r)
6877 : {
6878 600 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
6879 600 : if (ndr_flags & NDR_SCALARS) {
6880 600 : NDR_CHECK(ndr_push_align(ndr, 5));
6881 600 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->level));
6882 600 : NDR_CHECK(ndr_push_set_switch_value(ndr, &r->ctr, r->level));
6883 600 : NDR_CHECK(ndr_push_srvsvc_NetShareCtr(ndr, NDR_SCALARS, &r->ctr));
6884 600 : NDR_CHECK(ndr_push_trailer_align(ndr, 5));
6885 : }
6886 600 : if (ndr_flags & NDR_BUFFERS) {
6887 600 : NDR_CHECK(ndr_push_set_switch_value(ndr, &r->ctr, r->level));
6888 600 : NDR_CHECK(ndr_push_srvsvc_NetShareCtr(ndr, NDR_BUFFERS, &r->ctr));
6889 : }
6890 600 : return NDR_ERR_SUCCESS;
6891 : }
6892 :
6893 580 : static enum ndr_err_code ndr_pull_srvsvc_NetShareInfoCtr(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct srvsvc_NetShareInfoCtr *r)
6894 : {
6895 580 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
6896 580 : if (ndr_flags & NDR_SCALARS) {
6897 580 : NDR_CHECK(ndr_pull_align(ndr, 5));
6898 580 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->level));
6899 580 : NDR_CHECK(ndr_pull_set_switch_value(ndr, &r->ctr, r->level));
6900 580 : NDR_CHECK(ndr_pull_srvsvc_NetShareCtr(ndr, NDR_SCALARS, &r->ctr));
6901 580 : NDR_CHECK(ndr_pull_trailer_align(ndr, 5));
6902 : }
6903 580 : if (ndr_flags & NDR_BUFFERS) {
6904 580 : NDR_CHECK(ndr_pull_set_switch_value(ndr, &r->ctr, r->level));
6905 580 : NDR_CHECK(ndr_pull_srvsvc_NetShareCtr(ndr, NDR_BUFFERS, &r->ctr));
6906 : }
6907 580 : return NDR_ERR_SUCCESS;
6908 : }
6909 :
6910 40 : _PUBLIC_ void ndr_print_srvsvc_NetShareInfoCtr(struct ndr_print *ndr, const char *name, const struct srvsvc_NetShareInfoCtr *r)
6911 : {
6912 40 : ndr_print_struct(ndr, name, "srvsvc_NetShareInfoCtr");
6913 40 : if (r == NULL) { ndr_print_null(ndr); return; }
6914 40 : ndr->depth++;
6915 40 : ndr_print_uint32(ndr, "level", r->level);
6916 40 : ndr_print_set_switch_value(ndr, &r->ctr, r->level);
6917 40 : ndr_print_srvsvc_NetShareCtr(ndr, "ctr", &r->ctr);
6918 40 : ndr->depth--;
6919 : }
6920 :
6921 89 : _PUBLIC_ enum ndr_err_code ndr_push_srvsvc_PlatformId(struct ndr_push *ndr, ndr_flags_type ndr_flags, enum srvsvc_PlatformId r)
6922 : {
6923 89 : NDR_CHECK(ndr_push_enum_uint32(ndr, NDR_SCALARS, r));
6924 89 : return NDR_ERR_SUCCESS;
6925 : }
6926 :
6927 83 : _PUBLIC_ enum ndr_err_code ndr_pull_srvsvc_PlatformId(struct ndr_pull *ndr, ndr_flags_type ndr_flags, enum srvsvc_PlatformId *r)
6928 : {
6929 0 : uint32_t v;
6930 83 : NDR_CHECK(ndr_pull_enum_uint32(ndr, NDR_SCALARS, &v));
6931 83 : *r = v;
6932 83 : return NDR_ERR_SUCCESS;
6933 : }
6934 :
6935 12 : _PUBLIC_ void ndr_print_srvsvc_PlatformId(struct ndr_print *ndr, const char *name, enum srvsvc_PlatformId r)
6936 : {
6937 12 : const char *val = NULL;
6938 :
6939 12 : switch (r) {
6940 0 : case PLATFORM_ID_DOS: val = "PLATFORM_ID_DOS"; break;
6941 0 : case PLATFORM_ID_OS2: val = "PLATFORM_ID_OS2"; break;
6942 10 : case PLATFORM_ID_NT: val = "PLATFORM_ID_NT"; break;
6943 0 : case PLATFORM_ID_OSF: val = "PLATFORM_ID_OSF"; break;
6944 0 : case PLATFORM_ID_VMS: val = "PLATFORM_ID_VMS"; break;
6945 : }
6946 12 : ndr_print_enum(ndr, name, "ENUM", val, r);
6947 12 : }
6948 :
6949 17 : _PUBLIC_ enum ndr_err_code ndr_push_srvsvc_NetSrvInfo100(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct srvsvc_NetSrvInfo100 *r)
6950 : {
6951 17 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
6952 17 : if (ndr_flags & NDR_SCALARS) {
6953 13 : NDR_CHECK(ndr_push_align(ndr, 5));
6954 13 : NDR_CHECK(ndr_push_srvsvc_PlatformId(ndr, NDR_SCALARS, r->platform_id));
6955 13 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->server_name));
6956 13 : NDR_CHECK(ndr_push_trailer_align(ndr, 5));
6957 : }
6958 17 : if (ndr_flags & NDR_BUFFERS) {
6959 13 : if (r->server_name) {
6960 9 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->server_name, CH_UTF16)));
6961 9 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, 0));
6962 9 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->server_name, CH_UTF16)));
6963 9 : NDR_CHECK(ndr_push_charset(ndr, NDR_SCALARS, r->server_name, ndr_charset_length(r->server_name, CH_UTF16), sizeof(uint16_t), CH_UTF16));
6964 : }
6965 : }
6966 17 : return NDR_ERR_SUCCESS;
6967 : }
6968 :
6969 16 : _PUBLIC_ enum ndr_err_code ndr_pull_srvsvc_NetSrvInfo100(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct srvsvc_NetSrvInfo100 *r)
6970 : {
6971 0 : uint32_t _ptr_server_name;
6972 16 : uint32_t size_server_name_1 = 0;
6973 16 : uint32_t length_server_name_1 = 0;
6974 16 : TALLOC_CTX *_mem_save_server_name_0 = NULL;
6975 16 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
6976 16 : if (ndr_flags & NDR_SCALARS) {
6977 12 : NDR_CHECK(ndr_pull_align(ndr, 5));
6978 12 : NDR_CHECK(ndr_pull_srvsvc_PlatformId(ndr, NDR_SCALARS, &r->platform_id));
6979 12 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_server_name));
6980 12 : if (_ptr_server_name) {
6981 8 : NDR_PULL_ALLOC(ndr, r->server_name);
6982 : } else {
6983 4 : r->server_name = NULL;
6984 : }
6985 12 : NDR_CHECK(ndr_pull_trailer_align(ndr, 5));
6986 : }
6987 16 : if (ndr_flags & NDR_BUFFERS) {
6988 12 : if (r->server_name) {
6989 8 : _mem_save_server_name_0 = NDR_PULL_GET_MEM_CTX(ndr);
6990 8 : NDR_PULL_SET_MEM_CTX(ndr, r->server_name, 0);
6991 8 : NDR_CHECK(ndr_pull_array_size(ndr, &r->server_name));
6992 8 : NDR_CHECK(ndr_pull_array_length(ndr, &r->server_name));
6993 8 : NDR_CHECK(ndr_steal_array_size(ndr, (void*)&r->server_name, &size_server_name_1));
6994 8 : NDR_CHECK(ndr_steal_array_length(ndr, (void*)&r->server_name, &length_server_name_1));
6995 8 : if (length_server_name_1 > size_server_name_1) {
6996 0 : return ndr_pull_error(ndr, NDR_ERR_ARRAY_SIZE, "Bad array size %"PRIu32": should exceed array length %"PRIu32"", size_server_name_1, length_server_name_1);
6997 : }
6998 8 : NDR_CHECK(ndr_check_string_terminator(ndr, length_server_name_1, sizeof(uint16_t)));
6999 8 : NDR_CHECK(ndr_pull_charset(ndr, NDR_SCALARS, &r->server_name, length_server_name_1, sizeof(uint16_t), CH_UTF16));
7000 8 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_server_name_0, 0);
7001 : }
7002 : }
7003 16 : return NDR_ERR_SUCCESS;
7004 : }
7005 :
7006 0 : static void ndr_print_flags_srvsvc_NetSrvInfo100(struct ndr_print *ndr, const char *name, ndr_flags_type unused, const struct srvsvc_NetSrvInfo100 *r)
7007 : {
7008 0 : ndr_print_srvsvc_NetSrvInfo100(ndr, name, r);
7009 0 : }
7010 :
7011 2 : _PUBLIC_ void ndr_print_srvsvc_NetSrvInfo100(struct ndr_print *ndr, const char *name, const struct srvsvc_NetSrvInfo100 *r)
7012 : {
7013 2 : ndr_print_struct(ndr, name, "srvsvc_NetSrvInfo100");
7014 2 : if (r == NULL) { ndr_print_null(ndr); return; }
7015 2 : ndr->depth++;
7016 2 : ndr_print_srvsvc_PlatformId(ndr, "platform_id", r->platform_id);
7017 2 : ndr_print_ptr(ndr, "server_name", r->server_name);
7018 2 : ndr->depth++;
7019 2 : if (r->server_name) {
7020 2 : ndr_print_string(ndr, "server_name", r->server_name);
7021 : }
7022 2 : ndr->depth--;
7023 2 : ndr->depth--;
7024 : }
7025 :
7026 56 : _PUBLIC_ enum ndr_err_code ndr_push_srvsvc_NetSrvInfo101(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct srvsvc_NetSrvInfo101 *r)
7027 : {
7028 56 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
7029 56 : if (ndr_flags & NDR_SCALARS) {
7030 47 : NDR_CHECK(ndr_push_align(ndr, 5));
7031 47 : NDR_CHECK(ndr_push_srvsvc_PlatformId(ndr, NDR_SCALARS, r->platform_id));
7032 47 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->server_name));
7033 47 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->version_major));
7034 47 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->version_minor));
7035 47 : NDR_CHECK(ndr_push_svcctl_ServerType(ndr, NDR_SCALARS, r->server_type));
7036 47 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->comment));
7037 47 : NDR_CHECK(ndr_push_trailer_align(ndr, 5));
7038 : }
7039 56 : if (ndr_flags & NDR_BUFFERS) {
7040 47 : if (r->server_name) {
7041 38 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->server_name, CH_UTF16)));
7042 38 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, 0));
7043 38 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->server_name, CH_UTF16)));
7044 38 : NDR_CHECK(ndr_push_charset(ndr, NDR_SCALARS, r->server_name, ndr_charset_length(r->server_name, CH_UTF16), sizeof(uint16_t), CH_UTF16));
7045 : }
7046 47 : if (r->comment) {
7047 38 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->comment, CH_UTF16)));
7048 38 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, 0));
7049 38 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->comment, CH_UTF16)));
7050 38 : NDR_CHECK(ndr_push_charset(ndr, NDR_SCALARS, r->comment, ndr_charset_length(r->comment, CH_UTF16), sizeof(uint16_t), CH_UTF16));
7051 : }
7052 : }
7053 56 : return NDR_ERR_SUCCESS;
7054 : }
7055 :
7056 53 : _PUBLIC_ enum ndr_err_code ndr_pull_srvsvc_NetSrvInfo101(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct srvsvc_NetSrvInfo101 *r)
7057 : {
7058 0 : uint32_t _ptr_server_name;
7059 53 : uint32_t size_server_name_1 = 0;
7060 53 : uint32_t length_server_name_1 = 0;
7061 53 : TALLOC_CTX *_mem_save_server_name_0 = NULL;
7062 0 : uint32_t _ptr_comment;
7063 53 : uint32_t size_comment_1 = 0;
7064 53 : uint32_t length_comment_1 = 0;
7065 53 : TALLOC_CTX *_mem_save_comment_0 = NULL;
7066 53 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
7067 53 : if (ndr_flags & NDR_SCALARS) {
7068 45 : NDR_CHECK(ndr_pull_align(ndr, 5));
7069 45 : NDR_CHECK(ndr_pull_srvsvc_PlatformId(ndr, NDR_SCALARS, &r->platform_id));
7070 45 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_server_name));
7071 45 : if (_ptr_server_name) {
7072 37 : NDR_PULL_ALLOC(ndr, r->server_name);
7073 : } else {
7074 8 : r->server_name = NULL;
7075 : }
7076 45 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->version_major));
7077 45 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->version_minor));
7078 45 : NDR_CHECK(ndr_pull_svcctl_ServerType(ndr, NDR_SCALARS, &r->server_type));
7079 45 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_comment));
7080 45 : if (_ptr_comment) {
7081 37 : NDR_PULL_ALLOC(ndr, r->comment);
7082 : } else {
7083 8 : r->comment = NULL;
7084 : }
7085 45 : NDR_CHECK(ndr_pull_trailer_align(ndr, 5));
7086 : }
7087 53 : if (ndr_flags & NDR_BUFFERS) {
7088 45 : if (r->server_name) {
7089 37 : _mem_save_server_name_0 = NDR_PULL_GET_MEM_CTX(ndr);
7090 37 : NDR_PULL_SET_MEM_CTX(ndr, r->server_name, 0);
7091 37 : NDR_CHECK(ndr_pull_array_size(ndr, &r->server_name));
7092 37 : NDR_CHECK(ndr_pull_array_length(ndr, &r->server_name));
7093 37 : NDR_CHECK(ndr_steal_array_size(ndr, (void*)&r->server_name, &size_server_name_1));
7094 37 : NDR_CHECK(ndr_steal_array_length(ndr, (void*)&r->server_name, &length_server_name_1));
7095 37 : if (length_server_name_1 > size_server_name_1) {
7096 0 : return ndr_pull_error(ndr, NDR_ERR_ARRAY_SIZE, "Bad array size %"PRIu32": should exceed array length %"PRIu32"", size_server_name_1, length_server_name_1);
7097 : }
7098 37 : NDR_CHECK(ndr_check_string_terminator(ndr, length_server_name_1, sizeof(uint16_t)));
7099 37 : NDR_CHECK(ndr_pull_charset(ndr, NDR_SCALARS, &r->server_name, length_server_name_1, sizeof(uint16_t), CH_UTF16));
7100 37 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_server_name_0, 0);
7101 : }
7102 45 : if (r->comment) {
7103 37 : _mem_save_comment_0 = NDR_PULL_GET_MEM_CTX(ndr);
7104 37 : NDR_PULL_SET_MEM_CTX(ndr, r->comment, 0);
7105 37 : NDR_CHECK(ndr_pull_array_size(ndr, &r->comment));
7106 37 : NDR_CHECK(ndr_pull_array_length(ndr, &r->comment));
7107 37 : NDR_CHECK(ndr_steal_array_size(ndr, (void*)&r->comment, &size_comment_1));
7108 37 : NDR_CHECK(ndr_steal_array_length(ndr, (void*)&r->comment, &length_comment_1));
7109 37 : if (length_comment_1 > size_comment_1) {
7110 0 : return ndr_pull_error(ndr, NDR_ERR_ARRAY_SIZE, "Bad array size %"PRIu32": should exceed array length %"PRIu32"", size_comment_1, length_comment_1);
7111 : }
7112 37 : NDR_CHECK(ndr_check_string_terminator(ndr, length_comment_1, sizeof(uint16_t)));
7113 37 : NDR_CHECK(ndr_pull_charset(ndr, NDR_SCALARS, &r->comment, length_comment_1, sizeof(uint16_t), CH_UTF16));
7114 37 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_comment_0, 0);
7115 : }
7116 : }
7117 53 : return NDR_ERR_SUCCESS;
7118 : }
7119 :
7120 0 : static void ndr_print_flags_srvsvc_NetSrvInfo101(struct ndr_print *ndr, const char *name, ndr_flags_type unused, const struct srvsvc_NetSrvInfo101 *r)
7121 : {
7122 0 : ndr_print_srvsvc_NetSrvInfo101(ndr, name, r);
7123 0 : }
7124 :
7125 4 : _PUBLIC_ void ndr_print_srvsvc_NetSrvInfo101(struct ndr_print *ndr, const char *name, const struct srvsvc_NetSrvInfo101 *r)
7126 : {
7127 4 : ndr_print_struct(ndr, name, "srvsvc_NetSrvInfo101");
7128 4 : if (r == NULL) { ndr_print_null(ndr); return; }
7129 4 : ndr->depth++;
7130 4 : ndr_print_srvsvc_PlatformId(ndr, "platform_id", r->platform_id);
7131 4 : ndr_print_ptr(ndr, "server_name", r->server_name);
7132 4 : ndr->depth++;
7133 4 : if (r->server_name) {
7134 2 : ndr_print_string(ndr, "server_name", r->server_name);
7135 : }
7136 4 : ndr->depth--;
7137 4 : ndr_print_uint32(ndr, "version_major", r->version_major);
7138 4 : ndr_print_uint32(ndr, "version_minor", r->version_minor);
7139 4 : ndr_print_svcctl_ServerType(ndr, "server_type", r->server_type);
7140 4 : ndr_print_ptr(ndr, "comment", r->comment);
7141 4 : ndr->depth++;
7142 4 : if (r->comment) {
7143 2 : ndr_print_string(ndr, "comment", r->comment);
7144 : }
7145 4 : ndr->depth--;
7146 4 : ndr->depth--;
7147 : }
7148 :
7149 9 : static enum ndr_err_code ndr_push_srvsvc_NetSrvInfo102(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct srvsvc_NetSrvInfo102 *r)
7150 : {
7151 9 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
7152 9 : if (ndr_flags & NDR_SCALARS) {
7153 9 : NDR_CHECK(ndr_push_align(ndr, 5));
7154 9 : NDR_CHECK(ndr_push_srvsvc_PlatformId(ndr, NDR_SCALARS, r->platform_id));
7155 9 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->server_name));
7156 9 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->version_major));
7157 9 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->version_minor));
7158 9 : NDR_CHECK(ndr_push_svcctl_ServerType(ndr, NDR_SCALARS, r->server_type));
7159 9 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->comment));
7160 9 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->users));
7161 9 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->disc));
7162 9 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->hidden));
7163 9 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->announce));
7164 9 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->anndelta));
7165 9 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->licenses));
7166 9 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->userpath));
7167 9 : NDR_CHECK(ndr_push_trailer_align(ndr, 5));
7168 : }
7169 9 : if (ndr_flags & NDR_BUFFERS) {
7170 9 : if (r->server_name) {
7171 9 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->server_name, CH_UTF16)));
7172 9 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, 0));
7173 9 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->server_name, CH_UTF16)));
7174 9 : NDR_CHECK(ndr_push_charset(ndr, NDR_SCALARS, r->server_name, ndr_charset_length(r->server_name, CH_UTF16), sizeof(uint16_t), CH_UTF16));
7175 : }
7176 9 : if (r->comment) {
7177 9 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->comment, CH_UTF16)));
7178 9 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, 0));
7179 9 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->comment, CH_UTF16)));
7180 9 : NDR_CHECK(ndr_push_charset(ndr, NDR_SCALARS, r->comment, ndr_charset_length(r->comment, CH_UTF16), sizeof(uint16_t), CH_UTF16));
7181 : }
7182 9 : if (r->userpath) {
7183 9 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->userpath, CH_UTF16)));
7184 9 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, 0));
7185 9 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->userpath, CH_UTF16)));
7186 9 : NDR_CHECK(ndr_push_charset(ndr, NDR_SCALARS, r->userpath, ndr_charset_length(r->userpath, CH_UTF16), sizeof(uint16_t), CH_UTF16));
7187 : }
7188 : }
7189 9 : return NDR_ERR_SUCCESS;
7190 : }
7191 :
7192 8 : static enum ndr_err_code ndr_pull_srvsvc_NetSrvInfo102(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct srvsvc_NetSrvInfo102 *r)
7193 : {
7194 0 : uint32_t _ptr_server_name;
7195 8 : uint32_t size_server_name_1 = 0;
7196 8 : uint32_t length_server_name_1 = 0;
7197 8 : TALLOC_CTX *_mem_save_server_name_0 = NULL;
7198 0 : uint32_t _ptr_comment;
7199 8 : uint32_t size_comment_1 = 0;
7200 8 : uint32_t length_comment_1 = 0;
7201 8 : TALLOC_CTX *_mem_save_comment_0 = NULL;
7202 0 : uint32_t _ptr_userpath;
7203 8 : uint32_t size_userpath_1 = 0;
7204 8 : uint32_t length_userpath_1 = 0;
7205 8 : TALLOC_CTX *_mem_save_userpath_0 = NULL;
7206 8 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
7207 8 : if (ndr_flags & NDR_SCALARS) {
7208 8 : NDR_CHECK(ndr_pull_align(ndr, 5));
7209 8 : NDR_CHECK(ndr_pull_srvsvc_PlatformId(ndr, NDR_SCALARS, &r->platform_id));
7210 8 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_server_name));
7211 8 : if (_ptr_server_name) {
7212 8 : NDR_PULL_ALLOC(ndr, r->server_name);
7213 : } else {
7214 0 : r->server_name = NULL;
7215 : }
7216 8 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->version_major));
7217 8 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->version_minor));
7218 8 : NDR_CHECK(ndr_pull_svcctl_ServerType(ndr, NDR_SCALARS, &r->server_type));
7219 8 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_comment));
7220 8 : if (_ptr_comment) {
7221 8 : NDR_PULL_ALLOC(ndr, r->comment);
7222 : } else {
7223 0 : r->comment = NULL;
7224 : }
7225 8 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->users));
7226 8 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->disc));
7227 8 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->hidden));
7228 8 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->announce));
7229 8 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->anndelta));
7230 8 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->licenses));
7231 8 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_userpath));
7232 8 : if (_ptr_userpath) {
7233 8 : NDR_PULL_ALLOC(ndr, r->userpath);
7234 : } else {
7235 0 : r->userpath = NULL;
7236 : }
7237 8 : NDR_CHECK(ndr_pull_trailer_align(ndr, 5));
7238 : }
7239 8 : if (ndr_flags & NDR_BUFFERS) {
7240 8 : if (r->server_name) {
7241 8 : _mem_save_server_name_0 = NDR_PULL_GET_MEM_CTX(ndr);
7242 8 : NDR_PULL_SET_MEM_CTX(ndr, r->server_name, 0);
7243 8 : NDR_CHECK(ndr_pull_array_size(ndr, &r->server_name));
7244 8 : NDR_CHECK(ndr_pull_array_length(ndr, &r->server_name));
7245 8 : NDR_CHECK(ndr_steal_array_size(ndr, (void*)&r->server_name, &size_server_name_1));
7246 8 : NDR_CHECK(ndr_steal_array_length(ndr, (void*)&r->server_name, &length_server_name_1));
7247 8 : if (length_server_name_1 > size_server_name_1) {
7248 0 : return ndr_pull_error(ndr, NDR_ERR_ARRAY_SIZE, "Bad array size %"PRIu32": should exceed array length %"PRIu32"", size_server_name_1, length_server_name_1);
7249 : }
7250 8 : NDR_CHECK(ndr_check_string_terminator(ndr, length_server_name_1, sizeof(uint16_t)));
7251 8 : NDR_CHECK(ndr_pull_charset(ndr, NDR_SCALARS, &r->server_name, length_server_name_1, sizeof(uint16_t), CH_UTF16));
7252 8 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_server_name_0, 0);
7253 : }
7254 8 : if (r->comment) {
7255 8 : _mem_save_comment_0 = NDR_PULL_GET_MEM_CTX(ndr);
7256 8 : NDR_PULL_SET_MEM_CTX(ndr, r->comment, 0);
7257 8 : NDR_CHECK(ndr_pull_array_size(ndr, &r->comment));
7258 8 : NDR_CHECK(ndr_pull_array_length(ndr, &r->comment));
7259 8 : NDR_CHECK(ndr_steal_array_size(ndr, (void*)&r->comment, &size_comment_1));
7260 8 : NDR_CHECK(ndr_steal_array_length(ndr, (void*)&r->comment, &length_comment_1));
7261 8 : if (length_comment_1 > size_comment_1) {
7262 0 : return ndr_pull_error(ndr, NDR_ERR_ARRAY_SIZE, "Bad array size %"PRIu32": should exceed array length %"PRIu32"", size_comment_1, length_comment_1);
7263 : }
7264 8 : NDR_CHECK(ndr_check_string_terminator(ndr, length_comment_1, sizeof(uint16_t)));
7265 8 : NDR_CHECK(ndr_pull_charset(ndr, NDR_SCALARS, &r->comment, length_comment_1, sizeof(uint16_t), CH_UTF16));
7266 8 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_comment_0, 0);
7267 : }
7268 8 : if (r->userpath) {
7269 8 : _mem_save_userpath_0 = NDR_PULL_GET_MEM_CTX(ndr);
7270 8 : NDR_PULL_SET_MEM_CTX(ndr, r->userpath, 0);
7271 8 : NDR_CHECK(ndr_pull_array_size(ndr, &r->userpath));
7272 8 : NDR_CHECK(ndr_pull_array_length(ndr, &r->userpath));
7273 8 : NDR_CHECK(ndr_steal_array_size(ndr, (void*)&r->userpath, &size_userpath_1));
7274 8 : NDR_CHECK(ndr_steal_array_length(ndr, (void*)&r->userpath, &length_userpath_1));
7275 8 : if (length_userpath_1 > size_userpath_1) {
7276 0 : return ndr_pull_error(ndr, NDR_ERR_ARRAY_SIZE, "Bad array size %"PRIu32": should exceed array length %"PRIu32"", size_userpath_1, length_userpath_1);
7277 : }
7278 8 : NDR_CHECK(ndr_check_string_terminator(ndr, length_userpath_1, sizeof(uint16_t)));
7279 8 : NDR_CHECK(ndr_pull_charset(ndr, NDR_SCALARS, &r->userpath, length_userpath_1, sizeof(uint16_t), CH_UTF16));
7280 8 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_userpath_0, 0);
7281 : }
7282 : }
7283 8 : return NDR_ERR_SUCCESS;
7284 : }
7285 :
7286 2 : _PUBLIC_ void ndr_print_srvsvc_NetSrvInfo102(struct ndr_print *ndr, const char *name, const struct srvsvc_NetSrvInfo102 *r)
7287 : {
7288 2 : ndr_print_struct(ndr, name, "srvsvc_NetSrvInfo102");
7289 2 : if (r == NULL) { ndr_print_null(ndr); return; }
7290 2 : ndr->depth++;
7291 2 : ndr_print_srvsvc_PlatformId(ndr, "platform_id", r->platform_id);
7292 2 : ndr_print_ptr(ndr, "server_name", r->server_name);
7293 2 : ndr->depth++;
7294 2 : if (r->server_name) {
7295 2 : ndr_print_string(ndr, "server_name", r->server_name);
7296 : }
7297 2 : ndr->depth--;
7298 2 : ndr_print_uint32(ndr, "version_major", r->version_major);
7299 2 : ndr_print_uint32(ndr, "version_minor", r->version_minor);
7300 2 : ndr_print_svcctl_ServerType(ndr, "server_type", r->server_type);
7301 2 : ndr_print_ptr(ndr, "comment", r->comment);
7302 2 : ndr->depth++;
7303 2 : if (r->comment) {
7304 2 : ndr_print_string(ndr, "comment", r->comment);
7305 : }
7306 2 : ndr->depth--;
7307 2 : ndr_print_uint32(ndr, "users", r->users);
7308 2 : ndr_print_uint32(ndr, "disc", r->disc);
7309 2 : ndr_print_uint32(ndr, "hidden", r->hidden);
7310 2 : ndr_print_uint32(ndr, "announce", r->announce);
7311 2 : ndr_print_uint32(ndr, "anndelta", r->anndelta);
7312 2 : ndr_print_uint32(ndr, "licenses", r->licenses);
7313 2 : ndr_print_ptr(ndr, "userpath", r->userpath);
7314 2 : ndr->depth++;
7315 2 : if (r->userpath) {
7316 2 : ndr_print_string(ndr, "userpath", r->userpath);
7317 : }
7318 2 : ndr->depth--;
7319 2 : ndr->depth--;
7320 : }
7321 :
7322 0 : static enum ndr_err_code ndr_push_srvsvc_NetSrvInfo402(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct srvsvc_NetSrvInfo402 *r)
7323 : {
7324 0 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
7325 0 : if (ndr_flags & NDR_SCALARS) {
7326 0 : NDR_CHECK(ndr_push_align(ndr, 5));
7327 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->ulist_mtime));
7328 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->glist_mtime));
7329 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->alist_mtime));
7330 0 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->alerts));
7331 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->security));
7332 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->numadmin));
7333 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->lanmask));
7334 0 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->guestaccount));
7335 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->chdevs));
7336 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->chdevqs));
7337 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->chdevjobs));
7338 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->connections));
7339 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->shares));
7340 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->openfiles));
7341 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->sessopen));
7342 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->sesssvc));
7343 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->sessreqs));
7344 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->opensearch));
7345 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->activelocks));
7346 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->numreqbufs));
7347 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->sizereqbufs));
7348 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->numbigbufs));
7349 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->numfiletasks));
7350 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->alertsched));
7351 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->erroralert));
7352 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->logonalert));
7353 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->accessalert));
7354 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->diskalert));
7355 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->netioalert));
7356 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->maxaudits));
7357 0 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->srvheuristics));
7358 0 : NDR_CHECK(ndr_push_trailer_align(ndr, 5));
7359 : }
7360 0 : if (ndr_flags & NDR_BUFFERS) {
7361 0 : if (r->alerts) {
7362 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->alerts, CH_UTF16)));
7363 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, 0));
7364 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->alerts, CH_UTF16)));
7365 0 : NDR_CHECK(ndr_push_charset(ndr, NDR_SCALARS, r->alerts, ndr_charset_length(r->alerts, CH_UTF16), sizeof(uint16_t), CH_UTF16));
7366 : }
7367 0 : if (r->guestaccount) {
7368 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->guestaccount, CH_UTF16)));
7369 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, 0));
7370 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->guestaccount, CH_UTF16)));
7371 0 : NDR_CHECK(ndr_push_charset(ndr, NDR_SCALARS, r->guestaccount, ndr_charset_length(r->guestaccount, CH_UTF16), sizeof(uint16_t), CH_UTF16));
7372 : }
7373 0 : if (r->srvheuristics) {
7374 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->srvheuristics, CH_UTF16)));
7375 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, 0));
7376 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->srvheuristics, CH_UTF16)));
7377 0 : NDR_CHECK(ndr_push_charset(ndr, NDR_SCALARS, r->srvheuristics, ndr_charset_length(r->srvheuristics, CH_UTF16), sizeof(uint16_t), CH_UTF16));
7378 : }
7379 : }
7380 0 : return NDR_ERR_SUCCESS;
7381 : }
7382 :
7383 0 : static enum ndr_err_code ndr_pull_srvsvc_NetSrvInfo402(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct srvsvc_NetSrvInfo402 *r)
7384 : {
7385 0 : uint32_t _ptr_alerts;
7386 0 : uint32_t size_alerts_1 = 0;
7387 0 : uint32_t length_alerts_1 = 0;
7388 0 : TALLOC_CTX *_mem_save_alerts_0 = NULL;
7389 0 : uint32_t _ptr_guestaccount;
7390 0 : uint32_t size_guestaccount_1 = 0;
7391 0 : uint32_t length_guestaccount_1 = 0;
7392 0 : TALLOC_CTX *_mem_save_guestaccount_0 = NULL;
7393 0 : uint32_t _ptr_srvheuristics;
7394 0 : uint32_t size_srvheuristics_1 = 0;
7395 0 : uint32_t length_srvheuristics_1 = 0;
7396 0 : TALLOC_CTX *_mem_save_srvheuristics_0 = NULL;
7397 0 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
7398 0 : if (ndr_flags & NDR_SCALARS) {
7399 0 : NDR_CHECK(ndr_pull_align(ndr, 5));
7400 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->ulist_mtime));
7401 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->glist_mtime));
7402 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->alist_mtime));
7403 0 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_alerts));
7404 0 : if (_ptr_alerts) {
7405 0 : NDR_PULL_ALLOC(ndr, r->alerts);
7406 : } else {
7407 0 : r->alerts = NULL;
7408 : }
7409 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->security));
7410 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->numadmin));
7411 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->lanmask));
7412 0 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_guestaccount));
7413 0 : if (_ptr_guestaccount) {
7414 0 : NDR_PULL_ALLOC(ndr, r->guestaccount);
7415 : } else {
7416 0 : r->guestaccount = NULL;
7417 : }
7418 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->chdevs));
7419 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->chdevqs));
7420 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->chdevjobs));
7421 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->connections));
7422 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->shares));
7423 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->openfiles));
7424 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->sessopen));
7425 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->sesssvc));
7426 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->sessreqs));
7427 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->opensearch));
7428 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->activelocks));
7429 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->numreqbufs));
7430 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->sizereqbufs));
7431 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->numbigbufs));
7432 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->numfiletasks));
7433 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->alertsched));
7434 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->erroralert));
7435 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->logonalert));
7436 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->accessalert));
7437 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->diskalert));
7438 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->netioalert));
7439 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->maxaudits));
7440 0 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_srvheuristics));
7441 0 : if (_ptr_srvheuristics) {
7442 0 : NDR_PULL_ALLOC(ndr, r->srvheuristics);
7443 : } else {
7444 0 : r->srvheuristics = NULL;
7445 : }
7446 0 : NDR_CHECK(ndr_pull_trailer_align(ndr, 5));
7447 : }
7448 0 : if (ndr_flags & NDR_BUFFERS) {
7449 0 : if (r->alerts) {
7450 0 : _mem_save_alerts_0 = NDR_PULL_GET_MEM_CTX(ndr);
7451 0 : NDR_PULL_SET_MEM_CTX(ndr, r->alerts, 0);
7452 0 : NDR_CHECK(ndr_pull_array_size(ndr, &r->alerts));
7453 0 : NDR_CHECK(ndr_pull_array_length(ndr, &r->alerts));
7454 0 : NDR_CHECK(ndr_steal_array_size(ndr, (void*)&r->alerts, &size_alerts_1));
7455 0 : NDR_CHECK(ndr_steal_array_length(ndr, (void*)&r->alerts, &length_alerts_1));
7456 0 : if (length_alerts_1 > size_alerts_1) {
7457 0 : return ndr_pull_error(ndr, NDR_ERR_ARRAY_SIZE, "Bad array size %"PRIu32": should exceed array length %"PRIu32"", size_alerts_1, length_alerts_1);
7458 : }
7459 0 : NDR_CHECK(ndr_check_string_terminator(ndr, length_alerts_1, sizeof(uint16_t)));
7460 0 : NDR_CHECK(ndr_pull_charset(ndr, NDR_SCALARS, &r->alerts, length_alerts_1, sizeof(uint16_t), CH_UTF16));
7461 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_alerts_0, 0);
7462 : }
7463 0 : if (r->guestaccount) {
7464 0 : _mem_save_guestaccount_0 = NDR_PULL_GET_MEM_CTX(ndr);
7465 0 : NDR_PULL_SET_MEM_CTX(ndr, r->guestaccount, 0);
7466 0 : NDR_CHECK(ndr_pull_array_size(ndr, &r->guestaccount));
7467 0 : NDR_CHECK(ndr_pull_array_length(ndr, &r->guestaccount));
7468 0 : NDR_CHECK(ndr_steal_array_size(ndr, (void*)&r->guestaccount, &size_guestaccount_1));
7469 0 : NDR_CHECK(ndr_steal_array_length(ndr, (void*)&r->guestaccount, &length_guestaccount_1));
7470 0 : if (length_guestaccount_1 > size_guestaccount_1) {
7471 0 : return ndr_pull_error(ndr, NDR_ERR_ARRAY_SIZE, "Bad array size %"PRIu32": should exceed array length %"PRIu32"", size_guestaccount_1, length_guestaccount_1);
7472 : }
7473 0 : NDR_CHECK(ndr_check_string_terminator(ndr, length_guestaccount_1, sizeof(uint16_t)));
7474 0 : NDR_CHECK(ndr_pull_charset(ndr, NDR_SCALARS, &r->guestaccount, length_guestaccount_1, sizeof(uint16_t), CH_UTF16));
7475 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_guestaccount_0, 0);
7476 : }
7477 0 : if (r->srvheuristics) {
7478 0 : _mem_save_srvheuristics_0 = NDR_PULL_GET_MEM_CTX(ndr);
7479 0 : NDR_PULL_SET_MEM_CTX(ndr, r->srvheuristics, 0);
7480 0 : NDR_CHECK(ndr_pull_array_size(ndr, &r->srvheuristics));
7481 0 : NDR_CHECK(ndr_pull_array_length(ndr, &r->srvheuristics));
7482 0 : NDR_CHECK(ndr_steal_array_size(ndr, (void*)&r->srvheuristics, &size_srvheuristics_1));
7483 0 : NDR_CHECK(ndr_steal_array_length(ndr, (void*)&r->srvheuristics, &length_srvheuristics_1));
7484 0 : if (length_srvheuristics_1 > size_srvheuristics_1) {
7485 0 : return ndr_pull_error(ndr, NDR_ERR_ARRAY_SIZE, "Bad array size %"PRIu32": should exceed array length %"PRIu32"", size_srvheuristics_1, length_srvheuristics_1);
7486 : }
7487 0 : NDR_CHECK(ndr_check_string_terminator(ndr, length_srvheuristics_1, sizeof(uint16_t)));
7488 0 : NDR_CHECK(ndr_pull_charset(ndr, NDR_SCALARS, &r->srvheuristics, length_srvheuristics_1, sizeof(uint16_t), CH_UTF16));
7489 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_srvheuristics_0, 0);
7490 : }
7491 : }
7492 0 : return NDR_ERR_SUCCESS;
7493 : }
7494 :
7495 0 : _PUBLIC_ void ndr_print_srvsvc_NetSrvInfo402(struct ndr_print *ndr, const char *name, const struct srvsvc_NetSrvInfo402 *r)
7496 : {
7497 0 : ndr_print_struct(ndr, name, "srvsvc_NetSrvInfo402");
7498 0 : if (r == NULL) { ndr_print_null(ndr); return; }
7499 0 : ndr->depth++;
7500 0 : ndr_print_uint32(ndr, "ulist_mtime", r->ulist_mtime);
7501 0 : ndr_print_uint32(ndr, "glist_mtime", r->glist_mtime);
7502 0 : ndr_print_uint32(ndr, "alist_mtime", r->alist_mtime);
7503 0 : ndr_print_ptr(ndr, "alerts", r->alerts);
7504 0 : ndr->depth++;
7505 0 : if (r->alerts) {
7506 0 : ndr_print_string(ndr, "alerts", r->alerts);
7507 : }
7508 0 : ndr->depth--;
7509 0 : ndr_print_uint32(ndr, "security", r->security);
7510 0 : ndr_print_uint32(ndr, "numadmin", r->numadmin);
7511 0 : ndr_print_uint32(ndr, "lanmask", r->lanmask);
7512 0 : ndr_print_ptr(ndr, "guestaccount", r->guestaccount);
7513 0 : ndr->depth++;
7514 0 : if (r->guestaccount) {
7515 0 : ndr_print_string(ndr, "guestaccount", r->guestaccount);
7516 : }
7517 0 : ndr->depth--;
7518 0 : ndr_print_uint32(ndr, "chdevs", r->chdevs);
7519 0 : ndr_print_uint32(ndr, "chdevqs", r->chdevqs);
7520 0 : ndr_print_uint32(ndr, "chdevjobs", r->chdevjobs);
7521 0 : ndr_print_uint32(ndr, "connections", r->connections);
7522 0 : ndr_print_uint32(ndr, "shares", r->shares);
7523 0 : ndr_print_uint32(ndr, "openfiles", r->openfiles);
7524 0 : ndr_print_uint32(ndr, "sessopen", r->sessopen);
7525 0 : ndr_print_uint32(ndr, "sesssvc", r->sesssvc);
7526 0 : ndr_print_uint32(ndr, "sessreqs", r->sessreqs);
7527 0 : ndr_print_uint32(ndr, "opensearch", r->opensearch);
7528 0 : ndr_print_uint32(ndr, "activelocks", r->activelocks);
7529 0 : ndr_print_uint32(ndr, "numreqbufs", r->numreqbufs);
7530 0 : ndr_print_uint32(ndr, "sizereqbufs", r->sizereqbufs);
7531 0 : ndr_print_uint32(ndr, "numbigbufs", r->numbigbufs);
7532 0 : ndr_print_uint32(ndr, "numfiletasks", r->numfiletasks);
7533 0 : ndr_print_uint32(ndr, "alertsched", r->alertsched);
7534 0 : ndr_print_uint32(ndr, "erroralert", r->erroralert);
7535 0 : ndr_print_uint32(ndr, "logonalert", r->logonalert);
7536 0 : ndr_print_uint32(ndr, "accessalert", r->accessalert);
7537 0 : ndr_print_uint32(ndr, "diskalert", r->diskalert);
7538 0 : ndr_print_uint32(ndr, "netioalert", r->netioalert);
7539 0 : ndr_print_uint32(ndr, "maxaudits", r->maxaudits);
7540 0 : ndr_print_ptr(ndr, "srvheuristics", r->srvheuristics);
7541 0 : ndr->depth++;
7542 0 : if (r->srvheuristics) {
7543 0 : ndr_print_string(ndr, "srvheuristics", r->srvheuristics);
7544 : }
7545 0 : ndr->depth--;
7546 0 : ndr->depth--;
7547 : }
7548 :
7549 0 : static enum ndr_err_code ndr_push_srvsvc_NetSrvInfo403(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct srvsvc_NetSrvInfo403 *r)
7550 : {
7551 0 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
7552 0 : if (ndr_flags & NDR_SCALARS) {
7553 0 : NDR_CHECK(ndr_push_align(ndr, 5));
7554 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->ulist_mtime));
7555 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->glist_mtime));
7556 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->alist_mtime));
7557 0 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->alerts));
7558 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->security));
7559 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->numadmin));
7560 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->lanmask));
7561 0 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->guestaccount));
7562 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->chdevs));
7563 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->chdevqs));
7564 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->chdevjobs));
7565 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->connections));
7566 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->shares));
7567 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->openfiles));
7568 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->sessopen));
7569 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->sesssvc));
7570 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->sessreqs));
7571 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->opensearch));
7572 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->activelocks));
7573 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->numreqbufs));
7574 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->sizereqbufs));
7575 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->numbigbufs));
7576 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->numfiletasks));
7577 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->alertsched));
7578 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->erroralert));
7579 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->logonalert));
7580 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->accessalert));
7581 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->diskalert));
7582 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->netioalert));
7583 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->maxaudits));
7584 0 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->srvheuristics));
7585 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->auditedevents));
7586 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->auditprofile));
7587 0 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->autopath));
7588 0 : NDR_CHECK(ndr_push_trailer_align(ndr, 5));
7589 : }
7590 0 : if (ndr_flags & NDR_BUFFERS) {
7591 0 : if (r->alerts) {
7592 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->alerts, CH_UTF16)));
7593 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, 0));
7594 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->alerts, CH_UTF16)));
7595 0 : NDR_CHECK(ndr_push_charset(ndr, NDR_SCALARS, r->alerts, ndr_charset_length(r->alerts, CH_UTF16), sizeof(uint16_t), CH_UTF16));
7596 : }
7597 0 : if (r->guestaccount) {
7598 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->guestaccount, CH_UTF16)));
7599 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, 0));
7600 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->guestaccount, CH_UTF16)));
7601 0 : NDR_CHECK(ndr_push_charset(ndr, NDR_SCALARS, r->guestaccount, ndr_charset_length(r->guestaccount, CH_UTF16), sizeof(uint16_t), CH_UTF16));
7602 : }
7603 0 : if (r->srvheuristics) {
7604 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->srvheuristics, CH_UTF16)));
7605 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, 0));
7606 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->srvheuristics, CH_UTF16)));
7607 0 : NDR_CHECK(ndr_push_charset(ndr, NDR_SCALARS, r->srvheuristics, ndr_charset_length(r->srvheuristics, CH_UTF16), sizeof(uint16_t), CH_UTF16));
7608 : }
7609 0 : if (r->autopath) {
7610 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->autopath, CH_UTF16)));
7611 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, 0));
7612 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->autopath, CH_UTF16)));
7613 0 : NDR_CHECK(ndr_push_charset(ndr, NDR_SCALARS, r->autopath, ndr_charset_length(r->autopath, CH_UTF16), sizeof(uint16_t), CH_UTF16));
7614 : }
7615 : }
7616 0 : return NDR_ERR_SUCCESS;
7617 : }
7618 :
7619 0 : static enum ndr_err_code ndr_pull_srvsvc_NetSrvInfo403(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct srvsvc_NetSrvInfo403 *r)
7620 : {
7621 0 : uint32_t _ptr_alerts;
7622 0 : uint32_t size_alerts_1 = 0;
7623 0 : uint32_t length_alerts_1 = 0;
7624 0 : TALLOC_CTX *_mem_save_alerts_0 = NULL;
7625 0 : uint32_t _ptr_guestaccount;
7626 0 : uint32_t size_guestaccount_1 = 0;
7627 0 : uint32_t length_guestaccount_1 = 0;
7628 0 : TALLOC_CTX *_mem_save_guestaccount_0 = NULL;
7629 0 : uint32_t _ptr_srvheuristics;
7630 0 : uint32_t size_srvheuristics_1 = 0;
7631 0 : uint32_t length_srvheuristics_1 = 0;
7632 0 : TALLOC_CTX *_mem_save_srvheuristics_0 = NULL;
7633 0 : uint32_t _ptr_autopath;
7634 0 : uint32_t size_autopath_1 = 0;
7635 0 : uint32_t length_autopath_1 = 0;
7636 0 : TALLOC_CTX *_mem_save_autopath_0 = NULL;
7637 0 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
7638 0 : if (ndr_flags & NDR_SCALARS) {
7639 0 : NDR_CHECK(ndr_pull_align(ndr, 5));
7640 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->ulist_mtime));
7641 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->glist_mtime));
7642 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->alist_mtime));
7643 0 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_alerts));
7644 0 : if (_ptr_alerts) {
7645 0 : NDR_PULL_ALLOC(ndr, r->alerts);
7646 : } else {
7647 0 : r->alerts = NULL;
7648 : }
7649 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->security));
7650 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->numadmin));
7651 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->lanmask));
7652 0 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_guestaccount));
7653 0 : if (_ptr_guestaccount) {
7654 0 : NDR_PULL_ALLOC(ndr, r->guestaccount);
7655 : } else {
7656 0 : r->guestaccount = NULL;
7657 : }
7658 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->chdevs));
7659 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->chdevqs));
7660 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->chdevjobs));
7661 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->connections));
7662 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->shares));
7663 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->openfiles));
7664 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->sessopen));
7665 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->sesssvc));
7666 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->sessreqs));
7667 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->opensearch));
7668 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->activelocks));
7669 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->numreqbufs));
7670 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->sizereqbufs));
7671 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->numbigbufs));
7672 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->numfiletasks));
7673 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->alertsched));
7674 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->erroralert));
7675 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->logonalert));
7676 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->accessalert));
7677 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->diskalert));
7678 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->netioalert));
7679 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->maxaudits));
7680 0 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_srvheuristics));
7681 0 : if (_ptr_srvheuristics) {
7682 0 : NDR_PULL_ALLOC(ndr, r->srvheuristics);
7683 : } else {
7684 0 : r->srvheuristics = NULL;
7685 : }
7686 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->auditedevents));
7687 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->auditprofile));
7688 0 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_autopath));
7689 0 : if (_ptr_autopath) {
7690 0 : NDR_PULL_ALLOC(ndr, r->autopath);
7691 : } else {
7692 0 : r->autopath = NULL;
7693 : }
7694 0 : NDR_CHECK(ndr_pull_trailer_align(ndr, 5));
7695 : }
7696 0 : if (ndr_flags & NDR_BUFFERS) {
7697 0 : if (r->alerts) {
7698 0 : _mem_save_alerts_0 = NDR_PULL_GET_MEM_CTX(ndr);
7699 0 : NDR_PULL_SET_MEM_CTX(ndr, r->alerts, 0);
7700 0 : NDR_CHECK(ndr_pull_array_size(ndr, &r->alerts));
7701 0 : NDR_CHECK(ndr_pull_array_length(ndr, &r->alerts));
7702 0 : NDR_CHECK(ndr_steal_array_size(ndr, (void*)&r->alerts, &size_alerts_1));
7703 0 : NDR_CHECK(ndr_steal_array_length(ndr, (void*)&r->alerts, &length_alerts_1));
7704 0 : if (length_alerts_1 > size_alerts_1) {
7705 0 : return ndr_pull_error(ndr, NDR_ERR_ARRAY_SIZE, "Bad array size %"PRIu32": should exceed array length %"PRIu32"", size_alerts_1, length_alerts_1);
7706 : }
7707 0 : NDR_CHECK(ndr_check_string_terminator(ndr, length_alerts_1, sizeof(uint16_t)));
7708 0 : NDR_CHECK(ndr_pull_charset(ndr, NDR_SCALARS, &r->alerts, length_alerts_1, sizeof(uint16_t), CH_UTF16));
7709 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_alerts_0, 0);
7710 : }
7711 0 : if (r->guestaccount) {
7712 0 : _mem_save_guestaccount_0 = NDR_PULL_GET_MEM_CTX(ndr);
7713 0 : NDR_PULL_SET_MEM_CTX(ndr, r->guestaccount, 0);
7714 0 : NDR_CHECK(ndr_pull_array_size(ndr, &r->guestaccount));
7715 0 : NDR_CHECK(ndr_pull_array_length(ndr, &r->guestaccount));
7716 0 : NDR_CHECK(ndr_steal_array_size(ndr, (void*)&r->guestaccount, &size_guestaccount_1));
7717 0 : NDR_CHECK(ndr_steal_array_length(ndr, (void*)&r->guestaccount, &length_guestaccount_1));
7718 0 : if (length_guestaccount_1 > size_guestaccount_1) {
7719 0 : return ndr_pull_error(ndr, NDR_ERR_ARRAY_SIZE, "Bad array size %"PRIu32": should exceed array length %"PRIu32"", size_guestaccount_1, length_guestaccount_1);
7720 : }
7721 0 : NDR_CHECK(ndr_check_string_terminator(ndr, length_guestaccount_1, sizeof(uint16_t)));
7722 0 : NDR_CHECK(ndr_pull_charset(ndr, NDR_SCALARS, &r->guestaccount, length_guestaccount_1, sizeof(uint16_t), CH_UTF16));
7723 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_guestaccount_0, 0);
7724 : }
7725 0 : if (r->srvheuristics) {
7726 0 : _mem_save_srvheuristics_0 = NDR_PULL_GET_MEM_CTX(ndr);
7727 0 : NDR_PULL_SET_MEM_CTX(ndr, r->srvheuristics, 0);
7728 0 : NDR_CHECK(ndr_pull_array_size(ndr, &r->srvheuristics));
7729 0 : NDR_CHECK(ndr_pull_array_length(ndr, &r->srvheuristics));
7730 0 : NDR_CHECK(ndr_steal_array_size(ndr, (void*)&r->srvheuristics, &size_srvheuristics_1));
7731 0 : NDR_CHECK(ndr_steal_array_length(ndr, (void*)&r->srvheuristics, &length_srvheuristics_1));
7732 0 : if (length_srvheuristics_1 > size_srvheuristics_1) {
7733 0 : return ndr_pull_error(ndr, NDR_ERR_ARRAY_SIZE, "Bad array size %"PRIu32": should exceed array length %"PRIu32"", size_srvheuristics_1, length_srvheuristics_1);
7734 : }
7735 0 : NDR_CHECK(ndr_check_string_terminator(ndr, length_srvheuristics_1, sizeof(uint16_t)));
7736 0 : NDR_CHECK(ndr_pull_charset(ndr, NDR_SCALARS, &r->srvheuristics, length_srvheuristics_1, sizeof(uint16_t), CH_UTF16));
7737 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_srvheuristics_0, 0);
7738 : }
7739 0 : if (r->autopath) {
7740 0 : _mem_save_autopath_0 = NDR_PULL_GET_MEM_CTX(ndr);
7741 0 : NDR_PULL_SET_MEM_CTX(ndr, r->autopath, 0);
7742 0 : NDR_CHECK(ndr_pull_array_size(ndr, &r->autopath));
7743 0 : NDR_CHECK(ndr_pull_array_length(ndr, &r->autopath));
7744 0 : NDR_CHECK(ndr_steal_array_size(ndr, (void*)&r->autopath, &size_autopath_1));
7745 0 : NDR_CHECK(ndr_steal_array_length(ndr, (void*)&r->autopath, &length_autopath_1));
7746 0 : if (length_autopath_1 > size_autopath_1) {
7747 0 : return ndr_pull_error(ndr, NDR_ERR_ARRAY_SIZE, "Bad array size %"PRIu32": should exceed array length %"PRIu32"", size_autopath_1, length_autopath_1);
7748 : }
7749 0 : NDR_CHECK(ndr_check_string_terminator(ndr, length_autopath_1, sizeof(uint16_t)));
7750 0 : NDR_CHECK(ndr_pull_charset(ndr, NDR_SCALARS, &r->autopath, length_autopath_1, sizeof(uint16_t), CH_UTF16));
7751 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_autopath_0, 0);
7752 : }
7753 : }
7754 0 : return NDR_ERR_SUCCESS;
7755 : }
7756 :
7757 0 : _PUBLIC_ void ndr_print_srvsvc_NetSrvInfo403(struct ndr_print *ndr, const char *name, const struct srvsvc_NetSrvInfo403 *r)
7758 : {
7759 0 : ndr_print_struct(ndr, name, "srvsvc_NetSrvInfo403");
7760 0 : if (r == NULL) { ndr_print_null(ndr); return; }
7761 0 : ndr->depth++;
7762 0 : ndr_print_uint32(ndr, "ulist_mtime", r->ulist_mtime);
7763 0 : ndr_print_uint32(ndr, "glist_mtime", r->glist_mtime);
7764 0 : ndr_print_uint32(ndr, "alist_mtime", r->alist_mtime);
7765 0 : ndr_print_ptr(ndr, "alerts", r->alerts);
7766 0 : ndr->depth++;
7767 0 : if (r->alerts) {
7768 0 : ndr_print_string(ndr, "alerts", r->alerts);
7769 : }
7770 0 : ndr->depth--;
7771 0 : ndr_print_uint32(ndr, "security", r->security);
7772 0 : ndr_print_uint32(ndr, "numadmin", r->numadmin);
7773 0 : ndr_print_uint32(ndr, "lanmask", r->lanmask);
7774 0 : ndr_print_ptr(ndr, "guestaccount", r->guestaccount);
7775 0 : ndr->depth++;
7776 0 : if (r->guestaccount) {
7777 0 : ndr_print_string(ndr, "guestaccount", r->guestaccount);
7778 : }
7779 0 : ndr->depth--;
7780 0 : ndr_print_uint32(ndr, "chdevs", r->chdevs);
7781 0 : ndr_print_uint32(ndr, "chdevqs", r->chdevqs);
7782 0 : ndr_print_uint32(ndr, "chdevjobs", r->chdevjobs);
7783 0 : ndr_print_uint32(ndr, "connections", r->connections);
7784 0 : ndr_print_uint32(ndr, "shares", r->shares);
7785 0 : ndr_print_uint32(ndr, "openfiles", r->openfiles);
7786 0 : ndr_print_uint32(ndr, "sessopen", r->sessopen);
7787 0 : ndr_print_uint32(ndr, "sesssvc", r->sesssvc);
7788 0 : ndr_print_uint32(ndr, "sessreqs", r->sessreqs);
7789 0 : ndr_print_uint32(ndr, "opensearch", r->opensearch);
7790 0 : ndr_print_uint32(ndr, "activelocks", r->activelocks);
7791 0 : ndr_print_uint32(ndr, "numreqbufs", r->numreqbufs);
7792 0 : ndr_print_uint32(ndr, "sizereqbufs", r->sizereqbufs);
7793 0 : ndr_print_uint32(ndr, "numbigbufs", r->numbigbufs);
7794 0 : ndr_print_uint32(ndr, "numfiletasks", r->numfiletasks);
7795 0 : ndr_print_uint32(ndr, "alertsched", r->alertsched);
7796 0 : ndr_print_uint32(ndr, "erroralert", r->erroralert);
7797 0 : ndr_print_uint32(ndr, "logonalert", r->logonalert);
7798 0 : ndr_print_uint32(ndr, "accessalert", r->accessalert);
7799 0 : ndr_print_uint32(ndr, "diskalert", r->diskalert);
7800 0 : ndr_print_uint32(ndr, "netioalert", r->netioalert);
7801 0 : ndr_print_uint32(ndr, "maxaudits", r->maxaudits);
7802 0 : ndr_print_ptr(ndr, "srvheuristics", r->srvheuristics);
7803 0 : ndr->depth++;
7804 0 : if (r->srvheuristics) {
7805 0 : ndr_print_string(ndr, "srvheuristics", r->srvheuristics);
7806 : }
7807 0 : ndr->depth--;
7808 0 : ndr_print_uint32(ndr, "auditedevents", r->auditedevents);
7809 0 : ndr_print_uint32(ndr, "auditprofile", r->auditprofile);
7810 0 : ndr_print_ptr(ndr, "autopath", r->autopath);
7811 0 : ndr->depth++;
7812 0 : if (r->autopath) {
7813 0 : ndr_print_string(ndr, "autopath", r->autopath);
7814 : }
7815 0 : ndr->depth--;
7816 0 : ndr->depth--;
7817 : }
7818 :
7819 0 : static enum ndr_err_code ndr_push_srvsvc_NetSrvInfo502(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct srvsvc_NetSrvInfo502 *r)
7820 : {
7821 0 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
7822 0 : if (ndr_flags & NDR_SCALARS) {
7823 0 : NDR_CHECK(ndr_push_align(ndr, 4));
7824 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->sessopen));
7825 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->sesssvc));
7826 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->opensearch));
7827 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->sizereqbufs));
7828 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->initworkitems));
7829 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->maxworkitems));
7830 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->rawworkitems));
7831 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->irpstacksize));
7832 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->maxrawbuflen));
7833 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->sessusers));
7834 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->sessconns));
7835 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->maxpagedmemoryusage));
7836 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->maxnonpagedmemoryusage));
7837 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->enablesoftcompat));
7838 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->enableforcedlogoff));
7839 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->timesource));
7840 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->acceptdownlevelapis));
7841 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->lmannounce));
7842 0 : NDR_CHECK(ndr_push_trailer_align(ndr, 4));
7843 : }
7844 0 : if (ndr_flags & NDR_BUFFERS) {
7845 0 : }
7846 0 : return NDR_ERR_SUCCESS;
7847 : }
7848 :
7849 0 : static enum ndr_err_code ndr_pull_srvsvc_NetSrvInfo502(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct srvsvc_NetSrvInfo502 *r)
7850 : {
7851 0 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
7852 0 : if (ndr_flags & NDR_SCALARS) {
7853 0 : NDR_CHECK(ndr_pull_align(ndr, 4));
7854 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->sessopen));
7855 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->sesssvc));
7856 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->opensearch));
7857 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->sizereqbufs));
7858 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->initworkitems));
7859 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->maxworkitems));
7860 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->rawworkitems));
7861 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->irpstacksize));
7862 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->maxrawbuflen));
7863 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->sessusers));
7864 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->sessconns));
7865 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->maxpagedmemoryusage));
7866 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->maxnonpagedmemoryusage));
7867 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->enablesoftcompat));
7868 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->enableforcedlogoff));
7869 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->timesource));
7870 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->acceptdownlevelapis));
7871 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->lmannounce));
7872 0 : NDR_CHECK(ndr_pull_trailer_align(ndr, 4));
7873 : }
7874 0 : if (ndr_flags & NDR_BUFFERS) {
7875 0 : }
7876 0 : return NDR_ERR_SUCCESS;
7877 : }
7878 :
7879 0 : _PUBLIC_ void ndr_print_srvsvc_NetSrvInfo502(struct ndr_print *ndr, const char *name, const struct srvsvc_NetSrvInfo502 *r)
7880 : {
7881 0 : ndr_print_struct(ndr, name, "srvsvc_NetSrvInfo502");
7882 0 : if (r == NULL) { ndr_print_null(ndr); return; }
7883 0 : ndr->depth++;
7884 0 : ndr_print_uint32(ndr, "sessopen", r->sessopen);
7885 0 : ndr_print_uint32(ndr, "sesssvc", r->sesssvc);
7886 0 : ndr_print_uint32(ndr, "opensearch", r->opensearch);
7887 0 : ndr_print_uint32(ndr, "sizereqbufs", r->sizereqbufs);
7888 0 : ndr_print_uint32(ndr, "initworkitems", r->initworkitems);
7889 0 : ndr_print_uint32(ndr, "maxworkitems", r->maxworkitems);
7890 0 : ndr_print_uint32(ndr, "rawworkitems", r->rawworkitems);
7891 0 : ndr_print_uint32(ndr, "irpstacksize", r->irpstacksize);
7892 0 : ndr_print_uint32(ndr, "maxrawbuflen", r->maxrawbuflen);
7893 0 : ndr_print_uint32(ndr, "sessusers", r->sessusers);
7894 0 : ndr_print_uint32(ndr, "sessconns", r->sessconns);
7895 0 : ndr_print_uint32(ndr, "maxpagedmemoryusage", r->maxpagedmemoryusage);
7896 0 : ndr_print_uint32(ndr, "maxnonpagedmemoryusage", r->maxnonpagedmemoryusage);
7897 0 : ndr_print_uint32(ndr, "enablesoftcompat", r->enablesoftcompat);
7898 0 : ndr_print_uint32(ndr, "enableforcedlogoff", r->enableforcedlogoff);
7899 0 : ndr_print_uint32(ndr, "timesource", r->timesource);
7900 0 : ndr_print_uint32(ndr, "acceptdownlevelapis", r->acceptdownlevelapis);
7901 0 : ndr_print_uint32(ndr, "lmannounce", r->lmannounce);
7902 0 : ndr->depth--;
7903 : }
7904 :
7905 0 : static enum ndr_err_code ndr_push_srvsvc_NetSrvInfo503(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct srvsvc_NetSrvInfo503 *r)
7906 : {
7907 0 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
7908 0 : if (ndr_flags & NDR_SCALARS) {
7909 0 : NDR_CHECK(ndr_push_align(ndr, 5));
7910 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->sessopen));
7911 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->sesssvc));
7912 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->opensearch));
7913 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->sizereqbufs));
7914 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->initworkitems));
7915 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->maxworkitems));
7916 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->rawworkitems));
7917 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->irpstacksize));
7918 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->maxrawbuflen));
7919 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->sessusers));
7920 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->sessconns));
7921 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->maxpagedmemoryusage));
7922 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->maxnonpagedmemoryusage));
7923 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->enablesoftcompat));
7924 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->enableforcedlogoff));
7925 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->timesource));
7926 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->acceptdownlevelapis));
7927 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->lmannounce));
7928 0 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->domain));
7929 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->maxcopyreadlen));
7930 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->maxcopywritelen));
7931 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->minkeepsearch));
7932 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->maxkeepsearch));
7933 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->minkeepcomplsearch));
7934 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->maxkeepcomplsearch));
7935 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->threadcountadd));
7936 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->numlockthreads));
7937 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->scavtimeout));
7938 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->minrcvqueue));
7939 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->minfreeworkitems));
7940 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->xactmemsize));
7941 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->threadpriority));
7942 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->maxmpxct));
7943 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->oplockbreakwait));
7944 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->oplockbreakresponsewait));
7945 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->enableoplocks));
7946 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->enableoplockforceclose));
7947 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->enablefcbopens));
7948 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->enableraw));
7949 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->enablesharednetdrives));
7950 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->minfreeconnections));
7951 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->maxfreeconnections));
7952 0 : NDR_CHECK(ndr_push_trailer_align(ndr, 5));
7953 : }
7954 0 : if (ndr_flags & NDR_BUFFERS) {
7955 0 : if (r->domain) {
7956 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->domain, CH_UTF16)));
7957 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, 0));
7958 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->domain, CH_UTF16)));
7959 0 : NDR_CHECK(ndr_push_charset(ndr, NDR_SCALARS, r->domain, ndr_charset_length(r->domain, CH_UTF16), sizeof(uint16_t), CH_UTF16));
7960 : }
7961 : }
7962 0 : return NDR_ERR_SUCCESS;
7963 : }
7964 :
7965 0 : static enum ndr_err_code ndr_pull_srvsvc_NetSrvInfo503(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct srvsvc_NetSrvInfo503 *r)
7966 : {
7967 0 : uint32_t _ptr_domain;
7968 0 : uint32_t size_domain_1 = 0;
7969 0 : uint32_t length_domain_1 = 0;
7970 0 : TALLOC_CTX *_mem_save_domain_0 = NULL;
7971 0 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
7972 0 : if (ndr_flags & NDR_SCALARS) {
7973 0 : NDR_CHECK(ndr_pull_align(ndr, 5));
7974 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->sessopen));
7975 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->sesssvc));
7976 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->opensearch));
7977 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->sizereqbufs));
7978 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->initworkitems));
7979 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->maxworkitems));
7980 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->rawworkitems));
7981 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->irpstacksize));
7982 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->maxrawbuflen));
7983 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->sessusers));
7984 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->sessconns));
7985 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->maxpagedmemoryusage));
7986 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->maxnonpagedmemoryusage));
7987 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->enablesoftcompat));
7988 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->enableforcedlogoff));
7989 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->timesource));
7990 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->acceptdownlevelapis));
7991 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->lmannounce));
7992 0 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_domain));
7993 0 : if (_ptr_domain) {
7994 0 : NDR_PULL_ALLOC(ndr, r->domain);
7995 : } else {
7996 0 : r->domain = NULL;
7997 : }
7998 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->maxcopyreadlen));
7999 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->maxcopywritelen));
8000 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->minkeepsearch));
8001 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->maxkeepsearch));
8002 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->minkeepcomplsearch));
8003 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->maxkeepcomplsearch));
8004 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->threadcountadd));
8005 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->numlockthreads));
8006 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->scavtimeout));
8007 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->minrcvqueue));
8008 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->minfreeworkitems));
8009 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->xactmemsize));
8010 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->threadpriority));
8011 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->maxmpxct));
8012 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->oplockbreakwait));
8013 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->oplockbreakresponsewait));
8014 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->enableoplocks));
8015 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->enableoplockforceclose));
8016 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->enablefcbopens));
8017 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->enableraw));
8018 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->enablesharednetdrives));
8019 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->minfreeconnections));
8020 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->maxfreeconnections));
8021 0 : NDR_CHECK(ndr_pull_trailer_align(ndr, 5));
8022 : }
8023 0 : if (ndr_flags & NDR_BUFFERS) {
8024 0 : if (r->domain) {
8025 0 : _mem_save_domain_0 = NDR_PULL_GET_MEM_CTX(ndr);
8026 0 : NDR_PULL_SET_MEM_CTX(ndr, r->domain, 0);
8027 0 : NDR_CHECK(ndr_pull_array_size(ndr, &r->domain));
8028 0 : NDR_CHECK(ndr_pull_array_length(ndr, &r->domain));
8029 0 : NDR_CHECK(ndr_steal_array_size(ndr, (void*)&r->domain, &size_domain_1));
8030 0 : NDR_CHECK(ndr_steal_array_length(ndr, (void*)&r->domain, &length_domain_1));
8031 0 : if (length_domain_1 > size_domain_1) {
8032 0 : return ndr_pull_error(ndr, NDR_ERR_ARRAY_SIZE, "Bad array size %"PRIu32": should exceed array length %"PRIu32"", size_domain_1, length_domain_1);
8033 : }
8034 0 : NDR_CHECK(ndr_check_string_terminator(ndr, length_domain_1, sizeof(uint16_t)));
8035 0 : NDR_CHECK(ndr_pull_charset(ndr, NDR_SCALARS, &r->domain, length_domain_1, sizeof(uint16_t), CH_UTF16));
8036 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_domain_0, 0);
8037 : }
8038 : }
8039 0 : return NDR_ERR_SUCCESS;
8040 : }
8041 :
8042 0 : _PUBLIC_ void ndr_print_srvsvc_NetSrvInfo503(struct ndr_print *ndr, const char *name, const struct srvsvc_NetSrvInfo503 *r)
8043 : {
8044 0 : ndr_print_struct(ndr, name, "srvsvc_NetSrvInfo503");
8045 0 : if (r == NULL) { ndr_print_null(ndr); return; }
8046 0 : ndr->depth++;
8047 0 : ndr_print_uint32(ndr, "sessopen", r->sessopen);
8048 0 : ndr_print_uint32(ndr, "sesssvc", r->sesssvc);
8049 0 : ndr_print_uint32(ndr, "opensearch", r->opensearch);
8050 0 : ndr_print_uint32(ndr, "sizereqbufs", r->sizereqbufs);
8051 0 : ndr_print_uint32(ndr, "initworkitems", r->initworkitems);
8052 0 : ndr_print_uint32(ndr, "maxworkitems", r->maxworkitems);
8053 0 : ndr_print_uint32(ndr, "rawworkitems", r->rawworkitems);
8054 0 : ndr_print_uint32(ndr, "irpstacksize", r->irpstacksize);
8055 0 : ndr_print_uint32(ndr, "maxrawbuflen", r->maxrawbuflen);
8056 0 : ndr_print_uint32(ndr, "sessusers", r->sessusers);
8057 0 : ndr_print_uint32(ndr, "sessconns", r->sessconns);
8058 0 : ndr_print_uint32(ndr, "maxpagedmemoryusage", r->maxpagedmemoryusage);
8059 0 : ndr_print_uint32(ndr, "maxnonpagedmemoryusage", r->maxnonpagedmemoryusage);
8060 0 : ndr_print_uint32(ndr, "enablesoftcompat", r->enablesoftcompat);
8061 0 : ndr_print_uint32(ndr, "enableforcedlogoff", r->enableforcedlogoff);
8062 0 : ndr_print_uint32(ndr, "timesource", r->timesource);
8063 0 : ndr_print_uint32(ndr, "acceptdownlevelapis", r->acceptdownlevelapis);
8064 0 : ndr_print_uint32(ndr, "lmannounce", r->lmannounce);
8065 0 : ndr_print_ptr(ndr, "domain", r->domain);
8066 0 : ndr->depth++;
8067 0 : if (r->domain) {
8068 0 : ndr_print_string(ndr, "domain", r->domain);
8069 : }
8070 0 : ndr->depth--;
8071 0 : ndr_print_uint32(ndr, "maxcopyreadlen", r->maxcopyreadlen);
8072 0 : ndr_print_uint32(ndr, "maxcopywritelen", r->maxcopywritelen);
8073 0 : ndr_print_uint32(ndr, "minkeepsearch", r->minkeepsearch);
8074 0 : ndr_print_uint32(ndr, "maxkeepsearch", r->maxkeepsearch);
8075 0 : ndr_print_uint32(ndr, "minkeepcomplsearch", r->minkeepcomplsearch);
8076 0 : ndr_print_uint32(ndr, "maxkeepcomplsearch", r->maxkeepcomplsearch);
8077 0 : ndr_print_uint32(ndr, "threadcountadd", r->threadcountadd);
8078 0 : ndr_print_uint32(ndr, "numlockthreads", r->numlockthreads);
8079 0 : ndr_print_uint32(ndr, "scavtimeout", r->scavtimeout);
8080 0 : ndr_print_uint32(ndr, "minrcvqueue", r->minrcvqueue);
8081 0 : ndr_print_uint32(ndr, "minfreeworkitems", r->minfreeworkitems);
8082 0 : ndr_print_uint32(ndr, "xactmemsize", r->xactmemsize);
8083 0 : ndr_print_uint32(ndr, "threadpriority", r->threadpriority);
8084 0 : ndr_print_uint32(ndr, "maxmpxct", r->maxmpxct);
8085 0 : ndr_print_uint32(ndr, "oplockbreakwait", r->oplockbreakwait);
8086 0 : ndr_print_uint32(ndr, "oplockbreakresponsewait", r->oplockbreakresponsewait);
8087 0 : ndr_print_uint32(ndr, "enableoplocks", r->enableoplocks);
8088 0 : ndr_print_uint32(ndr, "enableoplockforceclose", r->enableoplockforceclose);
8089 0 : ndr_print_uint32(ndr, "enablefcbopens", r->enablefcbopens);
8090 0 : ndr_print_uint32(ndr, "enableraw", r->enableraw);
8091 0 : ndr_print_uint32(ndr, "enablesharednetdrives", r->enablesharednetdrives);
8092 0 : ndr_print_uint32(ndr, "minfreeconnections", r->minfreeconnections);
8093 0 : ndr_print_uint32(ndr, "maxfreeconnections", r->maxfreeconnections);
8094 0 : ndr->depth--;
8095 : }
8096 :
8097 0 : static enum ndr_err_code ndr_push_srvsvc_NetSrvInfo599(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct srvsvc_NetSrvInfo599 *r)
8098 : {
8099 0 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
8100 0 : if (ndr_flags & NDR_SCALARS) {
8101 0 : NDR_CHECK(ndr_push_align(ndr, 5));
8102 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->sessopen));
8103 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->sesssvc));
8104 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->opensearch));
8105 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->sizereqbufs));
8106 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->initworkitems));
8107 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->maxworkitems));
8108 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->rawworkitems));
8109 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->irpstacksize));
8110 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->maxrawbuflen));
8111 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->sessusers));
8112 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->sessconns));
8113 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->maxpagedmemoryusage));
8114 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->maxnonpagedmemoryusage));
8115 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->enablesoftcompat));
8116 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->enableforcedlogoff));
8117 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->timesource));
8118 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->acceptdownlevelapis));
8119 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->lmannounce));
8120 0 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->domain));
8121 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->maxcopyreadlen));
8122 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->maxcopywritelen));
8123 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->minkeepsearch));
8124 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->minkeepcomplsearch));
8125 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->maxkeepcomplsearch));
8126 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->threadcountadd));
8127 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->numlockthreads));
8128 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->scavtimeout));
8129 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->minrcvqueue));
8130 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->minfreeworkitems));
8131 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->xactmemsize));
8132 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->threadpriority));
8133 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->maxmpxct));
8134 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->oplockbreakwait));
8135 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->oplockbreakresponsewait));
8136 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->enableoplocks));
8137 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->enableoplockforceclose));
8138 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->enablefcbopens));
8139 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->enableraw));
8140 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->enablesharednetdrives));
8141 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->minfreeconnections));
8142 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->maxfreeconnections));
8143 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->initsesstable));
8144 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->initconntable));
8145 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->initfiletable));
8146 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->initsearchtable));
8147 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->alertsched));
8148 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->errortreshold));
8149 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->networkerrortreshold));
8150 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->diskspacetreshold));
8151 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->reserved));
8152 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->maxlinkdelay));
8153 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->minlinkthroughput));
8154 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->linkinfovalidtime));
8155 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->scavqosinfoupdatetime));
8156 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->maxworkitemidletime));
8157 0 : NDR_CHECK(ndr_push_trailer_align(ndr, 5));
8158 : }
8159 0 : if (ndr_flags & NDR_BUFFERS) {
8160 0 : if (r->domain) {
8161 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->domain, CH_UTF16)));
8162 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, 0));
8163 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->domain, CH_UTF16)));
8164 0 : NDR_CHECK(ndr_push_charset(ndr, NDR_SCALARS, r->domain, ndr_charset_length(r->domain, CH_UTF16), sizeof(uint16_t), CH_UTF16));
8165 : }
8166 : }
8167 0 : return NDR_ERR_SUCCESS;
8168 : }
8169 :
8170 0 : static enum ndr_err_code ndr_pull_srvsvc_NetSrvInfo599(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct srvsvc_NetSrvInfo599 *r)
8171 : {
8172 0 : uint32_t _ptr_domain;
8173 0 : uint32_t size_domain_1 = 0;
8174 0 : uint32_t length_domain_1 = 0;
8175 0 : TALLOC_CTX *_mem_save_domain_0 = NULL;
8176 0 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
8177 0 : if (ndr_flags & NDR_SCALARS) {
8178 0 : NDR_CHECK(ndr_pull_align(ndr, 5));
8179 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->sessopen));
8180 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->sesssvc));
8181 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->opensearch));
8182 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->sizereqbufs));
8183 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->initworkitems));
8184 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->maxworkitems));
8185 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->rawworkitems));
8186 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->irpstacksize));
8187 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->maxrawbuflen));
8188 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->sessusers));
8189 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->sessconns));
8190 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->maxpagedmemoryusage));
8191 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->maxnonpagedmemoryusage));
8192 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->enablesoftcompat));
8193 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->enableforcedlogoff));
8194 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->timesource));
8195 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->acceptdownlevelapis));
8196 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->lmannounce));
8197 0 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_domain));
8198 0 : if (_ptr_domain) {
8199 0 : NDR_PULL_ALLOC(ndr, r->domain);
8200 : } else {
8201 0 : r->domain = NULL;
8202 : }
8203 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->maxcopyreadlen));
8204 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->maxcopywritelen));
8205 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->minkeepsearch));
8206 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->minkeepcomplsearch));
8207 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->maxkeepcomplsearch));
8208 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->threadcountadd));
8209 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->numlockthreads));
8210 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->scavtimeout));
8211 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->minrcvqueue));
8212 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->minfreeworkitems));
8213 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->xactmemsize));
8214 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->threadpriority));
8215 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->maxmpxct));
8216 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->oplockbreakwait));
8217 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->oplockbreakresponsewait));
8218 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->enableoplocks));
8219 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->enableoplockforceclose));
8220 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->enablefcbopens));
8221 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->enableraw));
8222 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->enablesharednetdrives));
8223 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->minfreeconnections));
8224 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->maxfreeconnections));
8225 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->initsesstable));
8226 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->initconntable));
8227 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->initfiletable));
8228 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->initsearchtable));
8229 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->alertsched));
8230 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->errortreshold));
8231 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->networkerrortreshold));
8232 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->diskspacetreshold));
8233 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->reserved));
8234 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->maxlinkdelay));
8235 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->minlinkthroughput));
8236 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->linkinfovalidtime));
8237 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->scavqosinfoupdatetime));
8238 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->maxworkitemidletime));
8239 0 : NDR_CHECK(ndr_pull_trailer_align(ndr, 5));
8240 : }
8241 0 : if (ndr_flags & NDR_BUFFERS) {
8242 0 : if (r->domain) {
8243 0 : _mem_save_domain_0 = NDR_PULL_GET_MEM_CTX(ndr);
8244 0 : NDR_PULL_SET_MEM_CTX(ndr, r->domain, 0);
8245 0 : NDR_CHECK(ndr_pull_array_size(ndr, &r->domain));
8246 0 : NDR_CHECK(ndr_pull_array_length(ndr, &r->domain));
8247 0 : NDR_CHECK(ndr_steal_array_size(ndr, (void*)&r->domain, &size_domain_1));
8248 0 : NDR_CHECK(ndr_steal_array_length(ndr, (void*)&r->domain, &length_domain_1));
8249 0 : if (length_domain_1 > size_domain_1) {
8250 0 : return ndr_pull_error(ndr, NDR_ERR_ARRAY_SIZE, "Bad array size %"PRIu32": should exceed array length %"PRIu32"", size_domain_1, length_domain_1);
8251 : }
8252 0 : NDR_CHECK(ndr_check_string_terminator(ndr, length_domain_1, sizeof(uint16_t)));
8253 0 : NDR_CHECK(ndr_pull_charset(ndr, NDR_SCALARS, &r->domain, length_domain_1, sizeof(uint16_t), CH_UTF16));
8254 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_domain_0, 0);
8255 : }
8256 : }
8257 0 : return NDR_ERR_SUCCESS;
8258 : }
8259 :
8260 0 : _PUBLIC_ void ndr_print_srvsvc_NetSrvInfo599(struct ndr_print *ndr, const char *name, const struct srvsvc_NetSrvInfo599 *r)
8261 : {
8262 0 : ndr_print_struct(ndr, name, "srvsvc_NetSrvInfo599");
8263 0 : if (r == NULL) { ndr_print_null(ndr); return; }
8264 0 : ndr->depth++;
8265 0 : ndr_print_uint32(ndr, "sessopen", r->sessopen);
8266 0 : ndr_print_uint32(ndr, "sesssvc", r->sesssvc);
8267 0 : ndr_print_uint32(ndr, "opensearch", r->opensearch);
8268 0 : ndr_print_uint32(ndr, "sizereqbufs", r->sizereqbufs);
8269 0 : ndr_print_uint32(ndr, "initworkitems", r->initworkitems);
8270 0 : ndr_print_uint32(ndr, "maxworkitems", r->maxworkitems);
8271 0 : ndr_print_uint32(ndr, "rawworkitems", r->rawworkitems);
8272 0 : ndr_print_uint32(ndr, "irpstacksize", r->irpstacksize);
8273 0 : ndr_print_uint32(ndr, "maxrawbuflen", r->maxrawbuflen);
8274 0 : ndr_print_uint32(ndr, "sessusers", r->sessusers);
8275 0 : ndr_print_uint32(ndr, "sessconns", r->sessconns);
8276 0 : ndr_print_uint32(ndr, "maxpagedmemoryusage", r->maxpagedmemoryusage);
8277 0 : ndr_print_uint32(ndr, "maxnonpagedmemoryusage", r->maxnonpagedmemoryusage);
8278 0 : ndr_print_uint32(ndr, "enablesoftcompat", r->enablesoftcompat);
8279 0 : ndr_print_uint32(ndr, "enableforcedlogoff", r->enableforcedlogoff);
8280 0 : ndr_print_uint32(ndr, "timesource", r->timesource);
8281 0 : ndr_print_uint32(ndr, "acceptdownlevelapis", r->acceptdownlevelapis);
8282 0 : ndr_print_uint32(ndr, "lmannounce", r->lmannounce);
8283 0 : ndr_print_ptr(ndr, "domain", r->domain);
8284 0 : ndr->depth++;
8285 0 : if (r->domain) {
8286 0 : ndr_print_string(ndr, "domain", r->domain);
8287 : }
8288 0 : ndr->depth--;
8289 0 : ndr_print_uint32(ndr, "maxcopyreadlen", r->maxcopyreadlen);
8290 0 : ndr_print_uint32(ndr, "maxcopywritelen", r->maxcopywritelen);
8291 0 : ndr_print_uint32(ndr, "minkeepsearch", r->minkeepsearch);
8292 0 : ndr_print_uint32(ndr, "minkeepcomplsearch", r->minkeepcomplsearch);
8293 0 : ndr_print_uint32(ndr, "maxkeepcomplsearch", r->maxkeepcomplsearch);
8294 0 : ndr_print_uint32(ndr, "threadcountadd", r->threadcountadd);
8295 0 : ndr_print_uint32(ndr, "numlockthreads", r->numlockthreads);
8296 0 : ndr_print_uint32(ndr, "scavtimeout", r->scavtimeout);
8297 0 : ndr_print_uint32(ndr, "minrcvqueue", r->minrcvqueue);
8298 0 : ndr_print_uint32(ndr, "minfreeworkitems", r->minfreeworkitems);
8299 0 : ndr_print_uint32(ndr, "xactmemsize", r->xactmemsize);
8300 0 : ndr_print_uint32(ndr, "threadpriority", r->threadpriority);
8301 0 : ndr_print_uint32(ndr, "maxmpxct", r->maxmpxct);
8302 0 : ndr_print_uint32(ndr, "oplockbreakwait", r->oplockbreakwait);
8303 0 : ndr_print_uint32(ndr, "oplockbreakresponsewait", r->oplockbreakresponsewait);
8304 0 : ndr_print_uint32(ndr, "enableoplocks", r->enableoplocks);
8305 0 : ndr_print_uint32(ndr, "enableoplockforceclose", r->enableoplockforceclose);
8306 0 : ndr_print_uint32(ndr, "enablefcbopens", r->enablefcbopens);
8307 0 : ndr_print_uint32(ndr, "enableraw", r->enableraw);
8308 0 : ndr_print_uint32(ndr, "enablesharednetdrives", r->enablesharednetdrives);
8309 0 : ndr_print_uint32(ndr, "minfreeconnections", r->minfreeconnections);
8310 0 : ndr_print_uint32(ndr, "maxfreeconnections", r->maxfreeconnections);
8311 0 : ndr_print_uint32(ndr, "initsesstable", r->initsesstable);
8312 0 : ndr_print_uint32(ndr, "initconntable", r->initconntable);
8313 0 : ndr_print_uint32(ndr, "initfiletable", r->initfiletable);
8314 0 : ndr_print_uint32(ndr, "initsearchtable", r->initsearchtable);
8315 0 : ndr_print_uint32(ndr, "alertsched", r->alertsched);
8316 0 : ndr_print_uint32(ndr, "errortreshold", r->errortreshold);
8317 0 : ndr_print_uint32(ndr, "networkerrortreshold", r->networkerrortreshold);
8318 0 : ndr_print_uint32(ndr, "diskspacetreshold", r->diskspacetreshold);
8319 0 : ndr_print_uint32(ndr, "reserved", r->reserved);
8320 0 : ndr_print_uint32(ndr, "maxlinkdelay", r->maxlinkdelay);
8321 0 : ndr_print_uint32(ndr, "minlinkthroughput", r->minlinkthroughput);
8322 0 : ndr_print_uint32(ndr, "linkinfovalidtime", r->linkinfovalidtime);
8323 0 : ndr_print_uint32(ndr, "scavqosinfoupdatetime", r->scavqosinfoupdatetime);
8324 0 : ndr_print_uint32(ndr, "maxworkitemidletime", r->maxworkitemidletime);
8325 0 : ndr->depth--;
8326 : }
8327 :
8328 0 : static enum ndr_err_code ndr_push_srvsvc_NetSrvInfo1005(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct srvsvc_NetSrvInfo1005 *r)
8329 : {
8330 0 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
8331 0 : if (ndr_flags & NDR_SCALARS) {
8332 0 : NDR_CHECK(ndr_push_align(ndr, 5));
8333 0 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->comment));
8334 0 : NDR_CHECK(ndr_push_trailer_align(ndr, 5));
8335 : }
8336 0 : if (ndr_flags & NDR_BUFFERS) {
8337 0 : if (r->comment) {
8338 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->comment, CH_UTF16)));
8339 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, 0));
8340 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->comment, CH_UTF16)));
8341 0 : NDR_CHECK(ndr_push_charset(ndr, NDR_SCALARS, r->comment, ndr_charset_length(r->comment, CH_UTF16), sizeof(uint16_t), CH_UTF16));
8342 : }
8343 : }
8344 0 : return NDR_ERR_SUCCESS;
8345 : }
8346 :
8347 0 : static enum ndr_err_code ndr_pull_srvsvc_NetSrvInfo1005(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct srvsvc_NetSrvInfo1005 *r)
8348 : {
8349 0 : uint32_t _ptr_comment;
8350 0 : uint32_t size_comment_1 = 0;
8351 0 : uint32_t length_comment_1 = 0;
8352 0 : TALLOC_CTX *_mem_save_comment_0 = NULL;
8353 0 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
8354 0 : if (ndr_flags & NDR_SCALARS) {
8355 0 : NDR_CHECK(ndr_pull_align(ndr, 5));
8356 0 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_comment));
8357 0 : if (_ptr_comment) {
8358 0 : NDR_PULL_ALLOC(ndr, r->comment);
8359 : } else {
8360 0 : r->comment = NULL;
8361 : }
8362 0 : NDR_CHECK(ndr_pull_trailer_align(ndr, 5));
8363 : }
8364 0 : if (ndr_flags & NDR_BUFFERS) {
8365 0 : if (r->comment) {
8366 0 : _mem_save_comment_0 = NDR_PULL_GET_MEM_CTX(ndr);
8367 0 : NDR_PULL_SET_MEM_CTX(ndr, r->comment, 0);
8368 0 : NDR_CHECK(ndr_pull_array_size(ndr, &r->comment));
8369 0 : NDR_CHECK(ndr_pull_array_length(ndr, &r->comment));
8370 0 : NDR_CHECK(ndr_steal_array_size(ndr, (void*)&r->comment, &size_comment_1));
8371 0 : NDR_CHECK(ndr_steal_array_length(ndr, (void*)&r->comment, &length_comment_1));
8372 0 : if (length_comment_1 > size_comment_1) {
8373 0 : return ndr_pull_error(ndr, NDR_ERR_ARRAY_SIZE, "Bad array size %"PRIu32": should exceed array length %"PRIu32"", size_comment_1, length_comment_1);
8374 : }
8375 0 : NDR_CHECK(ndr_check_string_terminator(ndr, length_comment_1, sizeof(uint16_t)));
8376 0 : NDR_CHECK(ndr_pull_charset(ndr, NDR_SCALARS, &r->comment, length_comment_1, sizeof(uint16_t), CH_UTF16));
8377 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_comment_0, 0);
8378 : }
8379 : }
8380 0 : return NDR_ERR_SUCCESS;
8381 : }
8382 :
8383 0 : _PUBLIC_ void ndr_print_srvsvc_NetSrvInfo1005(struct ndr_print *ndr, const char *name, const struct srvsvc_NetSrvInfo1005 *r)
8384 : {
8385 0 : ndr_print_struct(ndr, name, "srvsvc_NetSrvInfo1005");
8386 0 : if (r == NULL) { ndr_print_null(ndr); return; }
8387 0 : ndr->depth++;
8388 0 : ndr_print_ptr(ndr, "comment", r->comment);
8389 0 : ndr->depth++;
8390 0 : if (r->comment) {
8391 0 : ndr_print_string(ndr, "comment", r->comment);
8392 : }
8393 0 : ndr->depth--;
8394 0 : ndr->depth--;
8395 : }
8396 :
8397 0 : static enum ndr_err_code ndr_push_srvsvc_NetSrvInfo1010(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct srvsvc_NetSrvInfo1010 *r)
8398 : {
8399 0 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
8400 0 : if (ndr_flags & NDR_SCALARS) {
8401 0 : NDR_CHECK(ndr_push_align(ndr, 4));
8402 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->disc));
8403 0 : NDR_CHECK(ndr_push_trailer_align(ndr, 4));
8404 : }
8405 0 : if (ndr_flags & NDR_BUFFERS) {
8406 0 : }
8407 0 : return NDR_ERR_SUCCESS;
8408 : }
8409 :
8410 0 : static enum ndr_err_code ndr_pull_srvsvc_NetSrvInfo1010(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct srvsvc_NetSrvInfo1010 *r)
8411 : {
8412 0 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
8413 0 : if (ndr_flags & NDR_SCALARS) {
8414 0 : NDR_CHECK(ndr_pull_align(ndr, 4));
8415 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->disc));
8416 0 : NDR_CHECK(ndr_pull_trailer_align(ndr, 4));
8417 : }
8418 0 : if (ndr_flags & NDR_BUFFERS) {
8419 0 : }
8420 0 : return NDR_ERR_SUCCESS;
8421 : }
8422 :
8423 0 : _PUBLIC_ void ndr_print_srvsvc_NetSrvInfo1010(struct ndr_print *ndr, const char *name, const struct srvsvc_NetSrvInfo1010 *r)
8424 : {
8425 0 : ndr_print_struct(ndr, name, "srvsvc_NetSrvInfo1010");
8426 0 : if (r == NULL) { ndr_print_null(ndr); return; }
8427 0 : ndr->depth++;
8428 0 : ndr_print_uint32(ndr, "disc", r->disc);
8429 0 : ndr->depth--;
8430 : }
8431 :
8432 0 : static enum ndr_err_code ndr_push_srvsvc_NetSrvInfo1016(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct srvsvc_NetSrvInfo1016 *r)
8433 : {
8434 0 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
8435 0 : if (ndr_flags & NDR_SCALARS) {
8436 0 : NDR_CHECK(ndr_push_align(ndr, 4));
8437 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->hidden));
8438 0 : NDR_CHECK(ndr_push_trailer_align(ndr, 4));
8439 : }
8440 0 : if (ndr_flags & NDR_BUFFERS) {
8441 0 : }
8442 0 : return NDR_ERR_SUCCESS;
8443 : }
8444 :
8445 0 : static enum ndr_err_code ndr_pull_srvsvc_NetSrvInfo1016(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct srvsvc_NetSrvInfo1016 *r)
8446 : {
8447 0 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
8448 0 : if (ndr_flags & NDR_SCALARS) {
8449 0 : NDR_CHECK(ndr_pull_align(ndr, 4));
8450 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->hidden));
8451 0 : NDR_CHECK(ndr_pull_trailer_align(ndr, 4));
8452 : }
8453 0 : if (ndr_flags & NDR_BUFFERS) {
8454 0 : }
8455 0 : return NDR_ERR_SUCCESS;
8456 : }
8457 :
8458 0 : _PUBLIC_ void ndr_print_srvsvc_NetSrvInfo1016(struct ndr_print *ndr, const char *name, const struct srvsvc_NetSrvInfo1016 *r)
8459 : {
8460 0 : ndr_print_struct(ndr, name, "srvsvc_NetSrvInfo1016");
8461 0 : if (r == NULL) { ndr_print_null(ndr); return; }
8462 0 : ndr->depth++;
8463 0 : ndr_print_uint32(ndr, "hidden", r->hidden);
8464 0 : ndr->depth--;
8465 : }
8466 :
8467 0 : static enum ndr_err_code ndr_push_srvsvc_NetSrvInfo1017(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct srvsvc_NetSrvInfo1017 *r)
8468 : {
8469 0 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
8470 0 : if (ndr_flags & NDR_SCALARS) {
8471 0 : NDR_CHECK(ndr_push_align(ndr, 4));
8472 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->announce));
8473 0 : NDR_CHECK(ndr_push_trailer_align(ndr, 4));
8474 : }
8475 0 : if (ndr_flags & NDR_BUFFERS) {
8476 0 : }
8477 0 : return NDR_ERR_SUCCESS;
8478 : }
8479 :
8480 0 : static enum ndr_err_code ndr_pull_srvsvc_NetSrvInfo1017(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct srvsvc_NetSrvInfo1017 *r)
8481 : {
8482 0 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
8483 0 : if (ndr_flags & NDR_SCALARS) {
8484 0 : NDR_CHECK(ndr_pull_align(ndr, 4));
8485 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->announce));
8486 0 : NDR_CHECK(ndr_pull_trailer_align(ndr, 4));
8487 : }
8488 0 : if (ndr_flags & NDR_BUFFERS) {
8489 0 : }
8490 0 : return NDR_ERR_SUCCESS;
8491 : }
8492 :
8493 0 : _PUBLIC_ void ndr_print_srvsvc_NetSrvInfo1017(struct ndr_print *ndr, const char *name, const struct srvsvc_NetSrvInfo1017 *r)
8494 : {
8495 0 : ndr_print_struct(ndr, name, "srvsvc_NetSrvInfo1017");
8496 0 : if (r == NULL) { ndr_print_null(ndr); return; }
8497 0 : ndr->depth++;
8498 0 : ndr_print_uint32(ndr, "announce", r->announce);
8499 0 : ndr->depth--;
8500 : }
8501 :
8502 0 : static enum ndr_err_code ndr_push_srvsvc_NetSrvInfo1018(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct srvsvc_NetSrvInfo1018 *r)
8503 : {
8504 0 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
8505 0 : if (ndr_flags & NDR_SCALARS) {
8506 0 : NDR_CHECK(ndr_push_align(ndr, 4));
8507 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->anndelta));
8508 0 : NDR_CHECK(ndr_push_trailer_align(ndr, 4));
8509 : }
8510 0 : if (ndr_flags & NDR_BUFFERS) {
8511 0 : }
8512 0 : return NDR_ERR_SUCCESS;
8513 : }
8514 :
8515 0 : static enum ndr_err_code ndr_pull_srvsvc_NetSrvInfo1018(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct srvsvc_NetSrvInfo1018 *r)
8516 : {
8517 0 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
8518 0 : if (ndr_flags & NDR_SCALARS) {
8519 0 : NDR_CHECK(ndr_pull_align(ndr, 4));
8520 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->anndelta));
8521 0 : NDR_CHECK(ndr_pull_trailer_align(ndr, 4));
8522 : }
8523 0 : if (ndr_flags & NDR_BUFFERS) {
8524 0 : }
8525 0 : return NDR_ERR_SUCCESS;
8526 : }
8527 :
8528 0 : _PUBLIC_ void ndr_print_srvsvc_NetSrvInfo1018(struct ndr_print *ndr, const char *name, const struct srvsvc_NetSrvInfo1018 *r)
8529 : {
8530 0 : ndr_print_struct(ndr, name, "srvsvc_NetSrvInfo1018");
8531 0 : if (r == NULL) { ndr_print_null(ndr); return; }
8532 0 : ndr->depth++;
8533 0 : ndr_print_uint32(ndr, "anndelta", r->anndelta);
8534 0 : ndr->depth--;
8535 : }
8536 :
8537 0 : static enum ndr_err_code ndr_push_srvsvc_NetSrvInfo1107(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct srvsvc_NetSrvInfo1107 *r)
8538 : {
8539 0 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
8540 0 : if (ndr_flags & NDR_SCALARS) {
8541 0 : NDR_CHECK(ndr_push_align(ndr, 4));
8542 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->users));
8543 0 : NDR_CHECK(ndr_push_trailer_align(ndr, 4));
8544 : }
8545 0 : if (ndr_flags & NDR_BUFFERS) {
8546 0 : }
8547 0 : return NDR_ERR_SUCCESS;
8548 : }
8549 :
8550 0 : static enum ndr_err_code ndr_pull_srvsvc_NetSrvInfo1107(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct srvsvc_NetSrvInfo1107 *r)
8551 : {
8552 0 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
8553 0 : if (ndr_flags & NDR_SCALARS) {
8554 0 : NDR_CHECK(ndr_pull_align(ndr, 4));
8555 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->users));
8556 0 : NDR_CHECK(ndr_pull_trailer_align(ndr, 4));
8557 : }
8558 0 : if (ndr_flags & NDR_BUFFERS) {
8559 0 : }
8560 0 : return NDR_ERR_SUCCESS;
8561 : }
8562 :
8563 0 : _PUBLIC_ void ndr_print_srvsvc_NetSrvInfo1107(struct ndr_print *ndr, const char *name, const struct srvsvc_NetSrvInfo1107 *r)
8564 : {
8565 0 : ndr_print_struct(ndr, name, "srvsvc_NetSrvInfo1107");
8566 0 : if (r == NULL) { ndr_print_null(ndr); return; }
8567 0 : ndr->depth++;
8568 0 : ndr_print_uint32(ndr, "users", r->users);
8569 0 : ndr->depth--;
8570 : }
8571 :
8572 0 : static enum ndr_err_code ndr_push_srvsvc_NetSrvInfo1501(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct srvsvc_NetSrvInfo1501 *r)
8573 : {
8574 0 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
8575 0 : if (ndr_flags & NDR_SCALARS) {
8576 0 : NDR_CHECK(ndr_push_align(ndr, 4));
8577 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->sessopens));
8578 0 : NDR_CHECK(ndr_push_trailer_align(ndr, 4));
8579 : }
8580 0 : if (ndr_flags & NDR_BUFFERS) {
8581 0 : }
8582 0 : return NDR_ERR_SUCCESS;
8583 : }
8584 :
8585 0 : static enum ndr_err_code ndr_pull_srvsvc_NetSrvInfo1501(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct srvsvc_NetSrvInfo1501 *r)
8586 : {
8587 0 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
8588 0 : if (ndr_flags & NDR_SCALARS) {
8589 0 : NDR_CHECK(ndr_pull_align(ndr, 4));
8590 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->sessopens));
8591 0 : NDR_CHECK(ndr_pull_trailer_align(ndr, 4));
8592 : }
8593 0 : if (ndr_flags & NDR_BUFFERS) {
8594 0 : }
8595 0 : return NDR_ERR_SUCCESS;
8596 : }
8597 :
8598 0 : _PUBLIC_ void ndr_print_srvsvc_NetSrvInfo1501(struct ndr_print *ndr, const char *name, const struct srvsvc_NetSrvInfo1501 *r)
8599 : {
8600 0 : ndr_print_struct(ndr, name, "srvsvc_NetSrvInfo1501");
8601 0 : if (r == NULL) { ndr_print_null(ndr); return; }
8602 0 : ndr->depth++;
8603 0 : ndr_print_uint32(ndr, "sessopens", r->sessopens);
8604 0 : ndr->depth--;
8605 : }
8606 :
8607 0 : static enum ndr_err_code ndr_push_srvsvc_NetSrvInfo1502(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct srvsvc_NetSrvInfo1502 *r)
8608 : {
8609 0 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
8610 0 : if (ndr_flags & NDR_SCALARS) {
8611 0 : NDR_CHECK(ndr_push_align(ndr, 4));
8612 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->sessvcs));
8613 0 : NDR_CHECK(ndr_push_trailer_align(ndr, 4));
8614 : }
8615 0 : if (ndr_flags & NDR_BUFFERS) {
8616 0 : }
8617 0 : return NDR_ERR_SUCCESS;
8618 : }
8619 :
8620 0 : static enum ndr_err_code ndr_pull_srvsvc_NetSrvInfo1502(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct srvsvc_NetSrvInfo1502 *r)
8621 : {
8622 0 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
8623 0 : if (ndr_flags & NDR_SCALARS) {
8624 0 : NDR_CHECK(ndr_pull_align(ndr, 4));
8625 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->sessvcs));
8626 0 : NDR_CHECK(ndr_pull_trailer_align(ndr, 4));
8627 : }
8628 0 : if (ndr_flags & NDR_BUFFERS) {
8629 0 : }
8630 0 : return NDR_ERR_SUCCESS;
8631 : }
8632 :
8633 0 : _PUBLIC_ void ndr_print_srvsvc_NetSrvInfo1502(struct ndr_print *ndr, const char *name, const struct srvsvc_NetSrvInfo1502 *r)
8634 : {
8635 0 : ndr_print_struct(ndr, name, "srvsvc_NetSrvInfo1502");
8636 0 : if (r == NULL) { ndr_print_null(ndr); return; }
8637 0 : ndr->depth++;
8638 0 : ndr_print_uint32(ndr, "sessvcs", r->sessvcs);
8639 0 : ndr->depth--;
8640 : }
8641 :
8642 0 : static enum ndr_err_code ndr_push_srvsvc_NetSrvInfo1503(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct srvsvc_NetSrvInfo1503 *r)
8643 : {
8644 0 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
8645 0 : if (ndr_flags & NDR_SCALARS) {
8646 0 : NDR_CHECK(ndr_push_align(ndr, 4));
8647 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->opensearch));
8648 0 : NDR_CHECK(ndr_push_trailer_align(ndr, 4));
8649 : }
8650 0 : if (ndr_flags & NDR_BUFFERS) {
8651 0 : }
8652 0 : return NDR_ERR_SUCCESS;
8653 : }
8654 :
8655 0 : static enum ndr_err_code ndr_pull_srvsvc_NetSrvInfo1503(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct srvsvc_NetSrvInfo1503 *r)
8656 : {
8657 0 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
8658 0 : if (ndr_flags & NDR_SCALARS) {
8659 0 : NDR_CHECK(ndr_pull_align(ndr, 4));
8660 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->opensearch));
8661 0 : NDR_CHECK(ndr_pull_trailer_align(ndr, 4));
8662 : }
8663 0 : if (ndr_flags & NDR_BUFFERS) {
8664 0 : }
8665 0 : return NDR_ERR_SUCCESS;
8666 : }
8667 :
8668 0 : _PUBLIC_ void ndr_print_srvsvc_NetSrvInfo1503(struct ndr_print *ndr, const char *name, const struct srvsvc_NetSrvInfo1503 *r)
8669 : {
8670 0 : ndr_print_struct(ndr, name, "srvsvc_NetSrvInfo1503");
8671 0 : if (r == NULL) { ndr_print_null(ndr); return; }
8672 0 : ndr->depth++;
8673 0 : ndr_print_uint32(ndr, "opensearch", r->opensearch);
8674 0 : ndr->depth--;
8675 : }
8676 :
8677 0 : static enum ndr_err_code ndr_push_srvsvc_NetSrvInfo1506(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct srvsvc_NetSrvInfo1506 *r)
8678 : {
8679 0 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
8680 0 : if (ndr_flags & NDR_SCALARS) {
8681 0 : NDR_CHECK(ndr_push_align(ndr, 4));
8682 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->maxworkitems));
8683 0 : NDR_CHECK(ndr_push_trailer_align(ndr, 4));
8684 : }
8685 0 : if (ndr_flags & NDR_BUFFERS) {
8686 0 : }
8687 0 : return NDR_ERR_SUCCESS;
8688 : }
8689 :
8690 0 : static enum ndr_err_code ndr_pull_srvsvc_NetSrvInfo1506(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct srvsvc_NetSrvInfo1506 *r)
8691 : {
8692 0 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
8693 0 : if (ndr_flags & NDR_SCALARS) {
8694 0 : NDR_CHECK(ndr_pull_align(ndr, 4));
8695 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->maxworkitems));
8696 0 : NDR_CHECK(ndr_pull_trailer_align(ndr, 4));
8697 : }
8698 0 : if (ndr_flags & NDR_BUFFERS) {
8699 0 : }
8700 0 : return NDR_ERR_SUCCESS;
8701 : }
8702 :
8703 0 : _PUBLIC_ void ndr_print_srvsvc_NetSrvInfo1506(struct ndr_print *ndr, const char *name, const struct srvsvc_NetSrvInfo1506 *r)
8704 : {
8705 0 : ndr_print_struct(ndr, name, "srvsvc_NetSrvInfo1506");
8706 0 : if (r == NULL) { ndr_print_null(ndr); return; }
8707 0 : ndr->depth++;
8708 0 : ndr_print_uint32(ndr, "maxworkitems", r->maxworkitems);
8709 0 : ndr->depth--;
8710 : }
8711 :
8712 0 : static enum ndr_err_code ndr_push_srvsvc_NetSrvInfo1509(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct srvsvc_NetSrvInfo1509 *r)
8713 : {
8714 0 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
8715 0 : if (ndr_flags & NDR_SCALARS) {
8716 0 : NDR_CHECK(ndr_push_align(ndr, 4));
8717 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->maxrawbuflen));
8718 0 : NDR_CHECK(ndr_push_trailer_align(ndr, 4));
8719 : }
8720 0 : if (ndr_flags & NDR_BUFFERS) {
8721 0 : }
8722 0 : return NDR_ERR_SUCCESS;
8723 : }
8724 :
8725 0 : static enum ndr_err_code ndr_pull_srvsvc_NetSrvInfo1509(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct srvsvc_NetSrvInfo1509 *r)
8726 : {
8727 0 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
8728 0 : if (ndr_flags & NDR_SCALARS) {
8729 0 : NDR_CHECK(ndr_pull_align(ndr, 4));
8730 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->maxrawbuflen));
8731 0 : NDR_CHECK(ndr_pull_trailer_align(ndr, 4));
8732 : }
8733 0 : if (ndr_flags & NDR_BUFFERS) {
8734 0 : }
8735 0 : return NDR_ERR_SUCCESS;
8736 : }
8737 :
8738 0 : _PUBLIC_ void ndr_print_srvsvc_NetSrvInfo1509(struct ndr_print *ndr, const char *name, const struct srvsvc_NetSrvInfo1509 *r)
8739 : {
8740 0 : ndr_print_struct(ndr, name, "srvsvc_NetSrvInfo1509");
8741 0 : if (r == NULL) { ndr_print_null(ndr); return; }
8742 0 : ndr->depth++;
8743 0 : ndr_print_uint32(ndr, "maxrawbuflen", r->maxrawbuflen);
8744 0 : ndr->depth--;
8745 : }
8746 :
8747 0 : static enum ndr_err_code ndr_push_srvsvc_NetSrvInfo1510(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct srvsvc_NetSrvInfo1510 *r)
8748 : {
8749 0 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
8750 0 : if (ndr_flags & NDR_SCALARS) {
8751 0 : NDR_CHECK(ndr_push_align(ndr, 4));
8752 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->sessusers));
8753 0 : NDR_CHECK(ndr_push_trailer_align(ndr, 4));
8754 : }
8755 0 : if (ndr_flags & NDR_BUFFERS) {
8756 0 : }
8757 0 : return NDR_ERR_SUCCESS;
8758 : }
8759 :
8760 0 : static enum ndr_err_code ndr_pull_srvsvc_NetSrvInfo1510(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct srvsvc_NetSrvInfo1510 *r)
8761 : {
8762 0 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
8763 0 : if (ndr_flags & NDR_SCALARS) {
8764 0 : NDR_CHECK(ndr_pull_align(ndr, 4));
8765 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->sessusers));
8766 0 : NDR_CHECK(ndr_pull_trailer_align(ndr, 4));
8767 : }
8768 0 : if (ndr_flags & NDR_BUFFERS) {
8769 0 : }
8770 0 : return NDR_ERR_SUCCESS;
8771 : }
8772 :
8773 0 : _PUBLIC_ void ndr_print_srvsvc_NetSrvInfo1510(struct ndr_print *ndr, const char *name, const struct srvsvc_NetSrvInfo1510 *r)
8774 : {
8775 0 : ndr_print_struct(ndr, name, "srvsvc_NetSrvInfo1510");
8776 0 : if (r == NULL) { ndr_print_null(ndr); return; }
8777 0 : ndr->depth++;
8778 0 : ndr_print_uint32(ndr, "sessusers", r->sessusers);
8779 0 : ndr->depth--;
8780 : }
8781 :
8782 0 : static enum ndr_err_code ndr_push_srvsvc_NetSrvInfo1511(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct srvsvc_NetSrvInfo1511 *r)
8783 : {
8784 0 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
8785 0 : if (ndr_flags & NDR_SCALARS) {
8786 0 : NDR_CHECK(ndr_push_align(ndr, 4));
8787 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->sesscons));
8788 0 : NDR_CHECK(ndr_push_trailer_align(ndr, 4));
8789 : }
8790 0 : if (ndr_flags & NDR_BUFFERS) {
8791 0 : }
8792 0 : return NDR_ERR_SUCCESS;
8793 : }
8794 :
8795 0 : static enum ndr_err_code ndr_pull_srvsvc_NetSrvInfo1511(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct srvsvc_NetSrvInfo1511 *r)
8796 : {
8797 0 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
8798 0 : if (ndr_flags & NDR_SCALARS) {
8799 0 : NDR_CHECK(ndr_pull_align(ndr, 4));
8800 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->sesscons));
8801 0 : NDR_CHECK(ndr_pull_trailer_align(ndr, 4));
8802 : }
8803 0 : if (ndr_flags & NDR_BUFFERS) {
8804 0 : }
8805 0 : return NDR_ERR_SUCCESS;
8806 : }
8807 :
8808 0 : _PUBLIC_ void ndr_print_srvsvc_NetSrvInfo1511(struct ndr_print *ndr, const char *name, const struct srvsvc_NetSrvInfo1511 *r)
8809 : {
8810 0 : ndr_print_struct(ndr, name, "srvsvc_NetSrvInfo1511");
8811 0 : if (r == NULL) { ndr_print_null(ndr); return; }
8812 0 : ndr->depth++;
8813 0 : ndr_print_uint32(ndr, "sesscons", r->sesscons);
8814 0 : ndr->depth--;
8815 : }
8816 :
8817 0 : static enum ndr_err_code ndr_push_srvsvc_NetSrvInfo1512(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct srvsvc_NetSrvInfo1512 *r)
8818 : {
8819 0 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
8820 0 : if (ndr_flags & NDR_SCALARS) {
8821 0 : NDR_CHECK(ndr_push_align(ndr, 4));
8822 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->maxnonpagedmemoryusage));
8823 0 : NDR_CHECK(ndr_push_trailer_align(ndr, 4));
8824 : }
8825 0 : if (ndr_flags & NDR_BUFFERS) {
8826 0 : }
8827 0 : return NDR_ERR_SUCCESS;
8828 : }
8829 :
8830 0 : static enum ndr_err_code ndr_pull_srvsvc_NetSrvInfo1512(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct srvsvc_NetSrvInfo1512 *r)
8831 : {
8832 0 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
8833 0 : if (ndr_flags & NDR_SCALARS) {
8834 0 : NDR_CHECK(ndr_pull_align(ndr, 4));
8835 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->maxnonpagedmemoryusage));
8836 0 : NDR_CHECK(ndr_pull_trailer_align(ndr, 4));
8837 : }
8838 0 : if (ndr_flags & NDR_BUFFERS) {
8839 0 : }
8840 0 : return NDR_ERR_SUCCESS;
8841 : }
8842 :
8843 0 : _PUBLIC_ void ndr_print_srvsvc_NetSrvInfo1512(struct ndr_print *ndr, const char *name, const struct srvsvc_NetSrvInfo1512 *r)
8844 : {
8845 0 : ndr_print_struct(ndr, name, "srvsvc_NetSrvInfo1512");
8846 0 : if (r == NULL) { ndr_print_null(ndr); return; }
8847 0 : ndr->depth++;
8848 0 : ndr_print_uint32(ndr, "maxnonpagedmemoryusage", r->maxnonpagedmemoryusage);
8849 0 : ndr->depth--;
8850 : }
8851 :
8852 0 : static enum ndr_err_code ndr_push_srvsvc_NetSrvInfo1513(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct srvsvc_NetSrvInfo1513 *r)
8853 : {
8854 0 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
8855 0 : if (ndr_flags & NDR_SCALARS) {
8856 0 : NDR_CHECK(ndr_push_align(ndr, 4));
8857 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->maxpagedmemoryusage));
8858 0 : NDR_CHECK(ndr_push_trailer_align(ndr, 4));
8859 : }
8860 0 : if (ndr_flags & NDR_BUFFERS) {
8861 0 : }
8862 0 : return NDR_ERR_SUCCESS;
8863 : }
8864 :
8865 0 : static enum ndr_err_code ndr_pull_srvsvc_NetSrvInfo1513(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct srvsvc_NetSrvInfo1513 *r)
8866 : {
8867 0 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
8868 0 : if (ndr_flags & NDR_SCALARS) {
8869 0 : NDR_CHECK(ndr_pull_align(ndr, 4));
8870 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->maxpagedmemoryusage));
8871 0 : NDR_CHECK(ndr_pull_trailer_align(ndr, 4));
8872 : }
8873 0 : if (ndr_flags & NDR_BUFFERS) {
8874 0 : }
8875 0 : return NDR_ERR_SUCCESS;
8876 : }
8877 :
8878 0 : _PUBLIC_ void ndr_print_srvsvc_NetSrvInfo1513(struct ndr_print *ndr, const char *name, const struct srvsvc_NetSrvInfo1513 *r)
8879 : {
8880 0 : ndr_print_struct(ndr, name, "srvsvc_NetSrvInfo1513");
8881 0 : if (r == NULL) { ndr_print_null(ndr); return; }
8882 0 : ndr->depth++;
8883 0 : ndr_print_uint32(ndr, "maxpagedmemoryusage", r->maxpagedmemoryusage);
8884 0 : ndr->depth--;
8885 : }
8886 :
8887 0 : static enum ndr_err_code ndr_push_srvsvc_NetSrvInfo1514(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct srvsvc_NetSrvInfo1514 *r)
8888 : {
8889 0 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
8890 0 : if (ndr_flags & NDR_SCALARS) {
8891 0 : NDR_CHECK(ndr_push_align(ndr, 4));
8892 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->enablesoftcompat));
8893 0 : NDR_CHECK(ndr_push_trailer_align(ndr, 4));
8894 : }
8895 0 : if (ndr_flags & NDR_BUFFERS) {
8896 0 : }
8897 0 : return NDR_ERR_SUCCESS;
8898 : }
8899 :
8900 0 : static enum ndr_err_code ndr_pull_srvsvc_NetSrvInfo1514(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct srvsvc_NetSrvInfo1514 *r)
8901 : {
8902 0 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
8903 0 : if (ndr_flags & NDR_SCALARS) {
8904 0 : NDR_CHECK(ndr_pull_align(ndr, 4));
8905 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->enablesoftcompat));
8906 0 : NDR_CHECK(ndr_pull_trailer_align(ndr, 4));
8907 : }
8908 0 : if (ndr_flags & NDR_BUFFERS) {
8909 0 : }
8910 0 : return NDR_ERR_SUCCESS;
8911 : }
8912 :
8913 0 : _PUBLIC_ void ndr_print_srvsvc_NetSrvInfo1514(struct ndr_print *ndr, const char *name, const struct srvsvc_NetSrvInfo1514 *r)
8914 : {
8915 0 : ndr_print_struct(ndr, name, "srvsvc_NetSrvInfo1514");
8916 0 : if (r == NULL) { ndr_print_null(ndr); return; }
8917 0 : ndr->depth++;
8918 0 : ndr_print_uint32(ndr, "enablesoftcompat", r->enablesoftcompat);
8919 0 : ndr->depth--;
8920 : }
8921 :
8922 0 : static enum ndr_err_code ndr_push_srvsvc_NetSrvInfo1515(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct srvsvc_NetSrvInfo1515 *r)
8923 : {
8924 0 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
8925 0 : if (ndr_flags & NDR_SCALARS) {
8926 0 : NDR_CHECK(ndr_push_align(ndr, 4));
8927 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->enableforcedlogoff));
8928 0 : NDR_CHECK(ndr_push_trailer_align(ndr, 4));
8929 : }
8930 0 : if (ndr_flags & NDR_BUFFERS) {
8931 0 : }
8932 0 : return NDR_ERR_SUCCESS;
8933 : }
8934 :
8935 0 : static enum ndr_err_code ndr_pull_srvsvc_NetSrvInfo1515(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct srvsvc_NetSrvInfo1515 *r)
8936 : {
8937 0 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
8938 0 : if (ndr_flags & NDR_SCALARS) {
8939 0 : NDR_CHECK(ndr_pull_align(ndr, 4));
8940 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->enableforcedlogoff));
8941 0 : NDR_CHECK(ndr_pull_trailer_align(ndr, 4));
8942 : }
8943 0 : if (ndr_flags & NDR_BUFFERS) {
8944 0 : }
8945 0 : return NDR_ERR_SUCCESS;
8946 : }
8947 :
8948 0 : _PUBLIC_ void ndr_print_srvsvc_NetSrvInfo1515(struct ndr_print *ndr, const char *name, const struct srvsvc_NetSrvInfo1515 *r)
8949 : {
8950 0 : ndr_print_struct(ndr, name, "srvsvc_NetSrvInfo1515");
8951 0 : if (r == NULL) { ndr_print_null(ndr); return; }
8952 0 : ndr->depth++;
8953 0 : ndr_print_uint32(ndr, "enableforcedlogoff", r->enableforcedlogoff);
8954 0 : ndr->depth--;
8955 : }
8956 :
8957 0 : static enum ndr_err_code ndr_push_srvsvc_NetSrvInfo1516(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct srvsvc_NetSrvInfo1516 *r)
8958 : {
8959 0 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
8960 0 : if (ndr_flags & NDR_SCALARS) {
8961 0 : NDR_CHECK(ndr_push_align(ndr, 4));
8962 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->timesource));
8963 0 : NDR_CHECK(ndr_push_trailer_align(ndr, 4));
8964 : }
8965 0 : if (ndr_flags & NDR_BUFFERS) {
8966 0 : }
8967 0 : return NDR_ERR_SUCCESS;
8968 : }
8969 :
8970 0 : static enum ndr_err_code ndr_pull_srvsvc_NetSrvInfo1516(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct srvsvc_NetSrvInfo1516 *r)
8971 : {
8972 0 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
8973 0 : if (ndr_flags & NDR_SCALARS) {
8974 0 : NDR_CHECK(ndr_pull_align(ndr, 4));
8975 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->timesource));
8976 0 : NDR_CHECK(ndr_pull_trailer_align(ndr, 4));
8977 : }
8978 0 : if (ndr_flags & NDR_BUFFERS) {
8979 0 : }
8980 0 : return NDR_ERR_SUCCESS;
8981 : }
8982 :
8983 0 : _PUBLIC_ void ndr_print_srvsvc_NetSrvInfo1516(struct ndr_print *ndr, const char *name, const struct srvsvc_NetSrvInfo1516 *r)
8984 : {
8985 0 : ndr_print_struct(ndr, name, "srvsvc_NetSrvInfo1516");
8986 0 : if (r == NULL) { ndr_print_null(ndr); return; }
8987 0 : ndr->depth++;
8988 0 : ndr_print_uint32(ndr, "timesource", r->timesource);
8989 0 : ndr->depth--;
8990 : }
8991 :
8992 0 : static enum ndr_err_code ndr_push_srvsvc_NetSrvInfo1518(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct srvsvc_NetSrvInfo1518 *r)
8993 : {
8994 0 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
8995 0 : if (ndr_flags & NDR_SCALARS) {
8996 0 : NDR_CHECK(ndr_push_align(ndr, 4));
8997 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->lmannounce));
8998 0 : NDR_CHECK(ndr_push_trailer_align(ndr, 4));
8999 : }
9000 0 : if (ndr_flags & NDR_BUFFERS) {
9001 0 : }
9002 0 : return NDR_ERR_SUCCESS;
9003 : }
9004 :
9005 0 : static enum ndr_err_code ndr_pull_srvsvc_NetSrvInfo1518(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct srvsvc_NetSrvInfo1518 *r)
9006 : {
9007 0 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
9008 0 : if (ndr_flags & NDR_SCALARS) {
9009 0 : NDR_CHECK(ndr_pull_align(ndr, 4));
9010 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->lmannounce));
9011 0 : NDR_CHECK(ndr_pull_trailer_align(ndr, 4));
9012 : }
9013 0 : if (ndr_flags & NDR_BUFFERS) {
9014 0 : }
9015 0 : return NDR_ERR_SUCCESS;
9016 : }
9017 :
9018 0 : _PUBLIC_ void ndr_print_srvsvc_NetSrvInfo1518(struct ndr_print *ndr, const char *name, const struct srvsvc_NetSrvInfo1518 *r)
9019 : {
9020 0 : ndr_print_struct(ndr, name, "srvsvc_NetSrvInfo1518");
9021 0 : if (r == NULL) { ndr_print_null(ndr); return; }
9022 0 : ndr->depth++;
9023 0 : ndr_print_uint32(ndr, "lmannounce", r->lmannounce);
9024 0 : ndr->depth--;
9025 : }
9026 :
9027 0 : static enum ndr_err_code ndr_push_srvsvc_NetSrvInfo1520(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct srvsvc_NetSrvInfo1520 *r)
9028 : {
9029 0 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
9030 0 : if (ndr_flags & NDR_SCALARS) {
9031 0 : NDR_CHECK(ndr_push_align(ndr, 4));
9032 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->maxcopyreadlen));
9033 0 : NDR_CHECK(ndr_push_trailer_align(ndr, 4));
9034 : }
9035 0 : if (ndr_flags & NDR_BUFFERS) {
9036 0 : }
9037 0 : return NDR_ERR_SUCCESS;
9038 : }
9039 :
9040 0 : static enum ndr_err_code ndr_pull_srvsvc_NetSrvInfo1520(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct srvsvc_NetSrvInfo1520 *r)
9041 : {
9042 0 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
9043 0 : if (ndr_flags & NDR_SCALARS) {
9044 0 : NDR_CHECK(ndr_pull_align(ndr, 4));
9045 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->maxcopyreadlen));
9046 0 : NDR_CHECK(ndr_pull_trailer_align(ndr, 4));
9047 : }
9048 0 : if (ndr_flags & NDR_BUFFERS) {
9049 0 : }
9050 0 : return NDR_ERR_SUCCESS;
9051 : }
9052 :
9053 0 : _PUBLIC_ void ndr_print_srvsvc_NetSrvInfo1520(struct ndr_print *ndr, const char *name, const struct srvsvc_NetSrvInfo1520 *r)
9054 : {
9055 0 : ndr_print_struct(ndr, name, "srvsvc_NetSrvInfo1520");
9056 0 : if (r == NULL) { ndr_print_null(ndr); return; }
9057 0 : ndr->depth++;
9058 0 : ndr_print_uint32(ndr, "maxcopyreadlen", r->maxcopyreadlen);
9059 0 : ndr->depth--;
9060 : }
9061 :
9062 0 : static enum ndr_err_code ndr_push_srvsvc_NetSrvInfo1521(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct srvsvc_NetSrvInfo1521 *r)
9063 : {
9064 0 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
9065 0 : if (ndr_flags & NDR_SCALARS) {
9066 0 : NDR_CHECK(ndr_push_align(ndr, 4));
9067 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->maxcopywritelen));
9068 0 : NDR_CHECK(ndr_push_trailer_align(ndr, 4));
9069 : }
9070 0 : if (ndr_flags & NDR_BUFFERS) {
9071 0 : }
9072 0 : return NDR_ERR_SUCCESS;
9073 : }
9074 :
9075 0 : static enum ndr_err_code ndr_pull_srvsvc_NetSrvInfo1521(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct srvsvc_NetSrvInfo1521 *r)
9076 : {
9077 0 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
9078 0 : if (ndr_flags & NDR_SCALARS) {
9079 0 : NDR_CHECK(ndr_pull_align(ndr, 4));
9080 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->maxcopywritelen));
9081 0 : NDR_CHECK(ndr_pull_trailer_align(ndr, 4));
9082 : }
9083 0 : if (ndr_flags & NDR_BUFFERS) {
9084 0 : }
9085 0 : return NDR_ERR_SUCCESS;
9086 : }
9087 :
9088 0 : _PUBLIC_ void ndr_print_srvsvc_NetSrvInfo1521(struct ndr_print *ndr, const char *name, const struct srvsvc_NetSrvInfo1521 *r)
9089 : {
9090 0 : ndr_print_struct(ndr, name, "srvsvc_NetSrvInfo1521");
9091 0 : if (r == NULL) { ndr_print_null(ndr); return; }
9092 0 : ndr->depth++;
9093 0 : ndr_print_uint32(ndr, "maxcopywritelen", r->maxcopywritelen);
9094 0 : ndr->depth--;
9095 : }
9096 :
9097 0 : static enum ndr_err_code ndr_push_srvsvc_NetSrvInfo1522(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct srvsvc_NetSrvInfo1522 *r)
9098 : {
9099 0 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
9100 0 : if (ndr_flags & NDR_SCALARS) {
9101 0 : NDR_CHECK(ndr_push_align(ndr, 4));
9102 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->minkeepsearch));
9103 0 : NDR_CHECK(ndr_push_trailer_align(ndr, 4));
9104 : }
9105 0 : if (ndr_flags & NDR_BUFFERS) {
9106 0 : }
9107 0 : return NDR_ERR_SUCCESS;
9108 : }
9109 :
9110 0 : static enum ndr_err_code ndr_pull_srvsvc_NetSrvInfo1522(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct srvsvc_NetSrvInfo1522 *r)
9111 : {
9112 0 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
9113 0 : if (ndr_flags & NDR_SCALARS) {
9114 0 : NDR_CHECK(ndr_pull_align(ndr, 4));
9115 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->minkeepsearch));
9116 0 : NDR_CHECK(ndr_pull_trailer_align(ndr, 4));
9117 : }
9118 0 : if (ndr_flags & NDR_BUFFERS) {
9119 0 : }
9120 0 : return NDR_ERR_SUCCESS;
9121 : }
9122 :
9123 0 : _PUBLIC_ void ndr_print_srvsvc_NetSrvInfo1522(struct ndr_print *ndr, const char *name, const struct srvsvc_NetSrvInfo1522 *r)
9124 : {
9125 0 : ndr_print_struct(ndr, name, "srvsvc_NetSrvInfo1522");
9126 0 : if (r == NULL) { ndr_print_null(ndr); return; }
9127 0 : ndr->depth++;
9128 0 : ndr_print_uint32(ndr, "minkeepsearch", r->minkeepsearch);
9129 0 : ndr->depth--;
9130 : }
9131 :
9132 0 : static enum ndr_err_code ndr_push_srvsvc_NetSrvInfo1523(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct srvsvc_NetSrvInfo1523 *r)
9133 : {
9134 0 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
9135 0 : if (ndr_flags & NDR_SCALARS) {
9136 0 : NDR_CHECK(ndr_push_align(ndr, 4));
9137 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->maxkeepsearch));
9138 0 : NDR_CHECK(ndr_push_trailer_align(ndr, 4));
9139 : }
9140 0 : if (ndr_flags & NDR_BUFFERS) {
9141 0 : }
9142 0 : return NDR_ERR_SUCCESS;
9143 : }
9144 :
9145 0 : static enum ndr_err_code ndr_pull_srvsvc_NetSrvInfo1523(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct srvsvc_NetSrvInfo1523 *r)
9146 : {
9147 0 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
9148 0 : if (ndr_flags & NDR_SCALARS) {
9149 0 : NDR_CHECK(ndr_pull_align(ndr, 4));
9150 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->maxkeepsearch));
9151 0 : NDR_CHECK(ndr_pull_trailer_align(ndr, 4));
9152 : }
9153 0 : if (ndr_flags & NDR_BUFFERS) {
9154 0 : }
9155 0 : return NDR_ERR_SUCCESS;
9156 : }
9157 :
9158 0 : _PUBLIC_ void ndr_print_srvsvc_NetSrvInfo1523(struct ndr_print *ndr, const char *name, const struct srvsvc_NetSrvInfo1523 *r)
9159 : {
9160 0 : ndr_print_struct(ndr, name, "srvsvc_NetSrvInfo1523");
9161 0 : if (r == NULL) { ndr_print_null(ndr); return; }
9162 0 : ndr->depth++;
9163 0 : ndr_print_uint32(ndr, "maxkeepsearch", r->maxkeepsearch);
9164 0 : ndr->depth--;
9165 : }
9166 :
9167 0 : static enum ndr_err_code ndr_push_srvsvc_NetSrvInfo1524(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct srvsvc_NetSrvInfo1524 *r)
9168 : {
9169 0 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
9170 0 : if (ndr_flags & NDR_SCALARS) {
9171 0 : NDR_CHECK(ndr_push_align(ndr, 4));
9172 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->minkeepcomplsearch));
9173 0 : NDR_CHECK(ndr_push_trailer_align(ndr, 4));
9174 : }
9175 0 : if (ndr_flags & NDR_BUFFERS) {
9176 0 : }
9177 0 : return NDR_ERR_SUCCESS;
9178 : }
9179 :
9180 0 : static enum ndr_err_code ndr_pull_srvsvc_NetSrvInfo1524(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct srvsvc_NetSrvInfo1524 *r)
9181 : {
9182 0 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
9183 0 : if (ndr_flags & NDR_SCALARS) {
9184 0 : NDR_CHECK(ndr_pull_align(ndr, 4));
9185 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->minkeepcomplsearch));
9186 0 : NDR_CHECK(ndr_pull_trailer_align(ndr, 4));
9187 : }
9188 0 : if (ndr_flags & NDR_BUFFERS) {
9189 0 : }
9190 0 : return NDR_ERR_SUCCESS;
9191 : }
9192 :
9193 0 : _PUBLIC_ void ndr_print_srvsvc_NetSrvInfo1524(struct ndr_print *ndr, const char *name, const struct srvsvc_NetSrvInfo1524 *r)
9194 : {
9195 0 : ndr_print_struct(ndr, name, "srvsvc_NetSrvInfo1524");
9196 0 : if (r == NULL) { ndr_print_null(ndr); return; }
9197 0 : ndr->depth++;
9198 0 : ndr_print_uint32(ndr, "minkeepcomplsearch", r->minkeepcomplsearch);
9199 0 : ndr->depth--;
9200 : }
9201 :
9202 0 : static enum ndr_err_code ndr_push_srvsvc_NetSrvInfo1525(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct srvsvc_NetSrvInfo1525 *r)
9203 : {
9204 0 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
9205 0 : if (ndr_flags & NDR_SCALARS) {
9206 0 : NDR_CHECK(ndr_push_align(ndr, 4));
9207 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->maxkeepcomplsearch));
9208 0 : NDR_CHECK(ndr_push_trailer_align(ndr, 4));
9209 : }
9210 0 : if (ndr_flags & NDR_BUFFERS) {
9211 0 : }
9212 0 : return NDR_ERR_SUCCESS;
9213 : }
9214 :
9215 0 : static enum ndr_err_code ndr_pull_srvsvc_NetSrvInfo1525(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct srvsvc_NetSrvInfo1525 *r)
9216 : {
9217 0 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
9218 0 : if (ndr_flags & NDR_SCALARS) {
9219 0 : NDR_CHECK(ndr_pull_align(ndr, 4));
9220 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->maxkeepcomplsearch));
9221 0 : NDR_CHECK(ndr_pull_trailer_align(ndr, 4));
9222 : }
9223 0 : if (ndr_flags & NDR_BUFFERS) {
9224 0 : }
9225 0 : return NDR_ERR_SUCCESS;
9226 : }
9227 :
9228 0 : _PUBLIC_ void ndr_print_srvsvc_NetSrvInfo1525(struct ndr_print *ndr, const char *name, const struct srvsvc_NetSrvInfo1525 *r)
9229 : {
9230 0 : ndr_print_struct(ndr, name, "srvsvc_NetSrvInfo1525");
9231 0 : if (r == NULL) { ndr_print_null(ndr); return; }
9232 0 : ndr->depth++;
9233 0 : ndr_print_uint32(ndr, "maxkeepcomplsearch", r->maxkeepcomplsearch);
9234 0 : ndr->depth--;
9235 : }
9236 :
9237 0 : static enum ndr_err_code ndr_push_srvsvc_NetSrvInfo1528(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct srvsvc_NetSrvInfo1528 *r)
9238 : {
9239 0 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
9240 0 : if (ndr_flags & NDR_SCALARS) {
9241 0 : NDR_CHECK(ndr_push_align(ndr, 4));
9242 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->scavtimeout));
9243 0 : NDR_CHECK(ndr_push_trailer_align(ndr, 4));
9244 : }
9245 0 : if (ndr_flags & NDR_BUFFERS) {
9246 0 : }
9247 0 : return NDR_ERR_SUCCESS;
9248 : }
9249 :
9250 0 : static enum ndr_err_code ndr_pull_srvsvc_NetSrvInfo1528(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct srvsvc_NetSrvInfo1528 *r)
9251 : {
9252 0 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
9253 0 : if (ndr_flags & NDR_SCALARS) {
9254 0 : NDR_CHECK(ndr_pull_align(ndr, 4));
9255 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->scavtimeout));
9256 0 : NDR_CHECK(ndr_pull_trailer_align(ndr, 4));
9257 : }
9258 0 : if (ndr_flags & NDR_BUFFERS) {
9259 0 : }
9260 0 : return NDR_ERR_SUCCESS;
9261 : }
9262 :
9263 0 : _PUBLIC_ void ndr_print_srvsvc_NetSrvInfo1528(struct ndr_print *ndr, const char *name, const struct srvsvc_NetSrvInfo1528 *r)
9264 : {
9265 0 : ndr_print_struct(ndr, name, "srvsvc_NetSrvInfo1528");
9266 0 : if (r == NULL) { ndr_print_null(ndr); return; }
9267 0 : ndr->depth++;
9268 0 : ndr_print_uint32(ndr, "scavtimeout", r->scavtimeout);
9269 0 : ndr->depth--;
9270 : }
9271 :
9272 0 : static enum ndr_err_code ndr_push_srvsvc_NetSrvInfo1529(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct srvsvc_NetSrvInfo1529 *r)
9273 : {
9274 0 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
9275 0 : if (ndr_flags & NDR_SCALARS) {
9276 0 : NDR_CHECK(ndr_push_align(ndr, 4));
9277 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->minrcvqueue));
9278 0 : NDR_CHECK(ndr_push_trailer_align(ndr, 4));
9279 : }
9280 0 : if (ndr_flags & NDR_BUFFERS) {
9281 0 : }
9282 0 : return NDR_ERR_SUCCESS;
9283 : }
9284 :
9285 0 : static enum ndr_err_code ndr_pull_srvsvc_NetSrvInfo1529(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct srvsvc_NetSrvInfo1529 *r)
9286 : {
9287 0 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
9288 0 : if (ndr_flags & NDR_SCALARS) {
9289 0 : NDR_CHECK(ndr_pull_align(ndr, 4));
9290 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->minrcvqueue));
9291 0 : NDR_CHECK(ndr_pull_trailer_align(ndr, 4));
9292 : }
9293 0 : if (ndr_flags & NDR_BUFFERS) {
9294 0 : }
9295 0 : return NDR_ERR_SUCCESS;
9296 : }
9297 :
9298 0 : _PUBLIC_ void ndr_print_srvsvc_NetSrvInfo1529(struct ndr_print *ndr, const char *name, const struct srvsvc_NetSrvInfo1529 *r)
9299 : {
9300 0 : ndr_print_struct(ndr, name, "srvsvc_NetSrvInfo1529");
9301 0 : if (r == NULL) { ndr_print_null(ndr); return; }
9302 0 : ndr->depth++;
9303 0 : ndr_print_uint32(ndr, "minrcvqueue", r->minrcvqueue);
9304 0 : ndr->depth--;
9305 : }
9306 :
9307 0 : static enum ndr_err_code ndr_push_srvsvc_NetSrvInfo1530(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct srvsvc_NetSrvInfo1530 *r)
9308 : {
9309 0 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
9310 0 : if (ndr_flags & NDR_SCALARS) {
9311 0 : NDR_CHECK(ndr_push_align(ndr, 4));
9312 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->minfreeworkitems));
9313 0 : NDR_CHECK(ndr_push_trailer_align(ndr, 4));
9314 : }
9315 0 : if (ndr_flags & NDR_BUFFERS) {
9316 0 : }
9317 0 : return NDR_ERR_SUCCESS;
9318 : }
9319 :
9320 0 : static enum ndr_err_code ndr_pull_srvsvc_NetSrvInfo1530(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct srvsvc_NetSrvInfo1530 *r)
9321 : {
9322 0 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
9323 0 : if (ndr_flags & NDR_SCALARS) {
9324 0 : NDR_CHECK(ndr_pull_align(ndr, 4));
9325 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->minfreeworkitems));
9326 0 : NDR_CHECK(ndr_pull_trailer_align(ndr, 4));
9327 : }
9328 0 : if (ndr_flags & NDR_BUFFERS) {
9329 0 : }
9330 0 : return NDR_ERR_SUCCESS;
9331 : }
9332 :
9333 0 : _PUBLIC_ void ndr_print_srvsvc_NetSrvInfo1530(struct ndr_print *ndr, const char *name, const struct srvsvc_NetSrvInfo1530 *r)
9334 : {
9335 0 : ndr_print_struct(ndr, name, "srvsvc_NetSrvInfo1530");
9336 0 : if (r == NULL) { ndr_print_null(ndr); return; }
9337 0 : ndr->depth++;
9338 0 : ndr_print_uint32(ndr, "minfreeworkitems", r->minfreeworkitems);
9339 0 : ndr->depth--;
9340 : }
9341 :
9342 0 : static enum ndr_err_code ndr_push_srvsvc_NetSrvInfo1533(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct srvsvc_NetSrvInfo1533 *r)
9343 : {
9344 0 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
9345 0 : if (ndr_flags & NDR_SCALARS) {
9346 0 : NDR_CHECK(ndr_push_align(ndr, 4));
9347 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->maxmpxct));
9348 0 : NDR_CHECK(ndr_push_trailer_align(ndr, 4));
9349 : }
9350 0 : if (ndr_flags & NDR_BUFFERS) {
9351 0 : }
9352 0 : return NDR_ERR_SUCCESS;
9353 : }
9354 :
9355 0 : static enum ndr_err_code ndr_pull_srvsvc_NetSrvInfo1533(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct srvsvc_NetSrvInfo1533 *r)
9356 : {
9357 0 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
9358 0 : if (ndr_flags & NDR_SCALARS) {
9359 0 : NDR_CHECK(ndr_pull_align(ndr, 4));
9360 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->maxmpxct));
9361 0 : NDR_CHECK(ndr_pull_trailer_align(ndr, 4));
9362 : }
9363 0 : if (ndr_flags & NDR_BUFFERS) {
9364 0 : }
9365 0 : return NDR_ERR_SUCCESS;
9366 : }
9367 :
9368 0 : _PUBLIC_ void ndr_print_srvsvc_NetSrvInfo1533(struct ndr_print *ndr, const char *name, const struct srvsvc_NetSrvInfo1533 *r)
9369 : {
9370 0 : ndr_print_struct(ndr, name, "srvsvc_NetSrvInfo1533");
9371 0 : if (r == NULL) { ndr_print_null(ndr); return; }
9372 0 : ndr->depth++;
9373 0 : ndr_print_uint32(ndr, "maxmpxct", r->maxmpxct);
9374 0 : ndr->depth--;
9375 : }
9376 :
9377 0 : static enum ndr_err_code ndr_push_srvsvc_NetSrvInfo1534(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct srvsvc_NetSrvInfo1534 *r)
9378 : {
9379 0 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
9380 0 : if (ndr_flags & NDR_SCALARS) {
9381 0 : NDR_CHECK(ndr_push_align(ndr, 4));
9382 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->oplockbreakwait));
9383 0 : NDR_CHECK(ndr_push_trailer_align(ndr, 4));
9384 : }
9385 0 : if (ndr_flags & NDR_BUFFERS) {
9386 0 : }
9387 0 : return NDR_ERR_SUCCESS;
9388 : }
9389 :
9390 0 : static enum ndr_err_code ndr_pull_srvsvc_NetSrvInfo1534(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct srvsvc_NetSrvInfo1534 *r)
9391 : {
9392 0 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
9393 0 : if (ndr_flags & NDR_SCALARS) {
9394 0 : NDR_CHECK(ndr_pull_align(ndr, 4));
9395 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->oplockbreakwait));
9396 0 : NDR_CHECK(ndr_pull_trailer_align(ndr, 4));
9397 : }
9398 0 : if (ndr_flags & NDR_BUFFERS) {
9399 0 : }
9400 0 : return NDR_ERR_SUCCESS;
9401 : }
9402 :
9403 0 : _PUBLIC_ void ndr_print_srvsvc_NetSrvInfo1534(struct ndr_print *ndr, const char *name, const struct srvsvc_NetSrvInfo1534 *r)
9404 : {
9405 0 : ndr_print_struct(ndr, name, "srvsvc_NetSrvInfo1534");
9406 0 : if (r == NULL) { ndr_print_null(ndr); return; }
9407 0 : ndr->depth++;
9408 0 : ndr_print_uint32(ndr, "oplockbreakwait", r->oplockbreakwait);
9409 0 : ndr->depth--;
9410 : }
9411 :
9412 0 : static enum ndr_err_code ndr_push_srvsvc_NetSrvInfo1535(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct srvsvc_NetSrvInfo1535 *r)
9413 : {
9414 0 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
9415 0 : if (ndr_flags & NDR_SCALARS) {
9416 0 : NDR_CHECK(ndr_push_align(ndr, 4));
9417 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->oplockbreakresponsewait));
9418 0 : NDR_CHECK(ndr_push_trailer_align(ndr, 4));
9419 : }
9420 0 : if (ndr_flags & NDR_BUFFERS) {
9421 0 : }
9422 0 : return NDR_ERR_SUCCESS;
9423 : }
9424 :
9425 0 : static enum ndr_err_code ndr_pull_srvsvc_NetSrvInfo1535(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct srvsvc_NetSrvInfo1535 *r)
9426 : {
9427 0 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
9428 0 : if (ndr_flags & NDR_SCALARS) {
9429 0 : NDR_CHECK(ndr_pull_align(ndr, 4));
9430 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->oplockbreakresponsewait));
9431 0 : NDR_CHECK(ndr_pull_trailer_align(ndr, 4));
9432 : }
9433 0 : if (ndr_flags & NDR_BUFFERS) {
9434 0 : }
9435 0 : return NDR_ERR_SUCCESS;
9436 : }
9437 :
9438 0 : _PUBLIC_ void ndr_print_srvsvc_NetSrvInfo1535(struct ndr_print *ndr, const char *name, const struct srvsvc_NetSrvInfo1535 *r)
9439 : {
9440 0 : ndr_print_struct(ndr, name, "srvsvc_NetSrvInfo1535");
9441 0 : if (r == NULL) { ndr_print_null(ndr); return; }
9442 0 : ndr->depth++;
9443 0 : ndr_print_uint32(ndr, "oplockbreakresponsewait", r->oplockbreakresponsewait);
9444 0 : ndr->depth--;
9445 : }
9446 :
9447 0 : static enum ndr_err_code ndr_push_srvsvc_NetSrvInfo1536(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct srvsvc_NetSrvInfo1536 *r)
9448 : {
9449 0 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
9450 0 : if (ndr_flags & NDR_SCALARS) {
9451 0 : NDR_CHECK(ndr_push_align(ndr, 4));
9452 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->enableoplocks));
9453 0 : NDR_CHECK(ndr_push_trailer_align(ndr, 4));
9454 : }
9455 0 : if (ndr_flags & NDR_BUFFERS) {
9456 0 : }
9457 0 : return NDR_ERR_SUCCESS;
9458 : }
9459 :
9460 0 : static enum ndr_err_code ndr_pull_srvsvc_NetSrvInfo1536(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct srvsvc_NetSrvInfo1536 *r)
9461 : {
9462 0 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
9463 0 : if (ndr_flags & NDR_SCALARS) {
9464 0 : NDR_CHECK(ndr_pull_align(ndr, 4));
9465 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->enableoplocks));
9466 0 : NDR_CHECK(ndr_pull_trailer_align(ndr, 4));
9467 : }
9468 0 : if (ndr_flags & NDR_BUFFERS) {
9469 0 : }
9470 0 : return NDR_ERR_SUCCESS;
9471 : }
9472 :
9473 0 : _PUBLIC_ void ndr_print_srvsvc_NetSrvInfo1536(struct ndr_print *ndr, const char *name, const struct srvsvc_NetSrvInfo1536 *r)
9474 : {
9475 0 : ndr_print_struct(ndr, name, "srvsvc_NetSrvInfo1536");
9476 0 : if (r == NULL) { ndr_print_null(ndr); return; }
9477 0 : ndr->depth++;
9478 0 : ndr_print_uint32(ndr, "enableoplocks", r->enableoplocks);
9479 0 : ndr->depth--;
9480 : }
9481 :
9482 0 : static enum ndr_err_code ndr_push_srvsvc_NetSrvInfo1537(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct srvsvc_NetSrvInfo1537 *r)
9483 : {
9484 0 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
9485 0 : if (ndr_flags & NDR_SCALARS) {
9486 0 : NDR_CHECK(ndr_push_align(ndr, 4));
9487 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->enableoplockforceclose));
9488 0 : NDR_CHECK(ndr_push_trailer_align(ndr, 4));
9489 : }
9490 0 : if (ndr_flags & NDR_BUFFERS) {
9491 0 : }
9492 0 : return NDR_ERR_SUCCESS;
9493 : }
9494 :
9495 0 : static enum ndr_err_code ndr_pull_srvsvc_NetSrvInfo1537(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct srvsvc_NetSrvInfo1537 *r)
9496 : {
9497 0 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
9498 0 : if (ndr_flags & NDR_SCALARS) {
9499 0 : NDR_CHECK(ndr_pull_align(ndr, 4));
9500 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->enableoplockforceclose));
9501 0 : NDR_CHECK(ndr_pull_trailer_align(ndr, 4));
9502 : }
9503 0 : if (ndr_flags & NDR_BUFFERS) {
9504 0 : }
9505 0 : return NDR_ERR_SUCCESS;
9506 : }
9507 :
9508 0 : _PUBLIC_ void ndr_print_srvsvc_NetSrvInfo1537(struct ndr_print *ndr, const char *name, const struct srvsvc_NetSrvInfo1537 *r)
9509 : {
9510 0 : ndr_print_struct(ndr, name, "srvsvc_NetSrvInfo1537");
9511 0 : if (r == NULL) { ndr_print_null(ndr); return; }
9512 0 : ndr->depth++;
9513 0 : ndr_print_uint32(ndr, "enableoplockforceclose", r->enableoplockforceclose);
9514 0 : ndr->depth--;
9515 : }
9516 :
9517 0 : static enum ndr_err_code ndr_push_srvsvc_NetSrvInfo1538(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct srvsvc_NetSrvInfo1538 *r)
9518 : {
9519 0 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
9520 0 : if (ndr_flags & NDR_SCALARS) {
9521 0 : NDR_CHECK(ndr_push_align(ndr, 4));
9522 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->enablefcbopens));
9523 0 : NDR_CHECK(ndr_push_trailer_align(ndr, 4));
9524 : }
9525 0 : if (ndr_flags & NDR_BUFFERS) {
9526 0 : }
9527 0 : return NDR_ERR_SUCCESS;
9528 : }
9529 :
9530 0 : static enum ndr_err_code ndr_pull_srvsvc_NetSrvInfo1538(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct srvsvc_NetSrvInfo1538 *r)
9531 : {
9532 0 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
9533 0 : if (ndr_flags & NDR_SCALARS) {
9534 0 : NDR_CHECK(ndr_pull_align(ndr, 4));
9535 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->enablefcbopens));
9536 0 : NDR_CHECK(ndr_pull_trailer_align(ndr, 4));
9537 : }
9538 0 : if (ndr_flags & NDR_BUFFERS) {
9539 0 : }
9540 0 : return NDR_ERR_SUCCESS;
9541 : }
9542 :
9543 0 : _PUBLIC_ void ndr_print_srvsvc_NetSrvInfo1538(struct ndr_print *ndr, const char *name, const struct srvsvc_NetSrvInfo1538 *r)
9544 : {
9545 0 : ndr_print_struct(ndr, name, "srvsvc_NetSrvInfo1538");
9546 0 : if (r == NULL) { ndr_print_null(ndr); return; }
9547 0 : ndr->depth++;
9548 0 : ndr_print_uint32(ndr, "enablefcbopens", r->enablefcbopens);
9549 0 : ndr->depth--;
9550 : }
9551 :
9552 0 : static enum ndr_err_code ndr_push_srvsvc_NetSrvInfo1539(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct srvsvc_NetSrvInfo1539 *r)
9553 : {
9554 0 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
9555 0 : if (ndr_flags & NDR_SCALARS) {
9556 0 : NDR_CHECK(ndr_push_align(ndr, 4));
9557 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->enableraw));
9558 0 : NDR_CHECK(ndr_push_trailer_align(ndr, 4));
9559 : }
9560 0 : if (ndr_flags & NDR_BUFFERS) {
9561 0 : }
9562 0 : return NDR_ERR_SUCCESS;
9563 : }
9564 :
9565 0 : static enum ndr_err_code ndr_pull_srvsvc_NetSrvInfo1539(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct srvsvc_NetSrvInfo1539 *r)
9566 : {
9567 0 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
9568 0 : if (ndr_flags & NDR_SCALARS) {
9569 0 : NDR_CHECK(ndr_pull_align(ndr, 4));
9570 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->enableraw));
9571 0 : NDR_CHECK(ndr_pull_trailer_align(ndr, 4));
9572 : }
9573 0 : if (ndr_flags & NDR_BUFFERS) {
9574 0 : }
9575 0 : return NDR_ERR_SUCCESS;
9576 : }
9577 :
9578 0 : _PUBLIC_ void ndr_print_srvsvc_NetSrvInfo1539(struct ndr_print *ndr, const char *name, const struct srvsvc_NetSrvInfo1539 *r)
9579 : {
9580 0 : ndr_print_struct(ndr, name, "srvsvc_NetSrvInfo1539");
9581 0 : if (r == NULL) { ndr_print_null(ndr); return; }
9582 0 : ndr->depth++;
9583 0 : ndr_print_uint32(ndr, "enableraw", r->enableraw);
9584 0 : ndr->depth--;
9585 : }
9586 :
9587 0 : static enum ndr_err_code ndr_push_srvsvc_NetSrvInfo1540(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct srvsvc_NetSrvInfo1540 *r)
9588 : {
9589 0 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
9590 0 : if (ndr_flags & NDR_SCALARS) {
9591 0 : NDR_CHECK(ndr_push_align(ndr, 4));
9592 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->enablesharednetdrives));
9593 0 : NDR_CHECK(ndr_push_trailer_align(ndr, 4));
9594 : }
9595 0 : if (ndr_flags & NDR_BUFFERS) {
9596 0 : }
9597 0 : return NDR_ERR_SUCCESS;
9598 : }
9599 :
9600 0 : static enum ndr_err_code ndr_pull_srvsvc_NetSrvInfo1540(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct srvsvc_NetSrvInfo1540 *r)
9601 : {
9602 0 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
9603 0 : if (ndr_flags & NDR_SCALARS) {
9604 0 : NDR_CHECK(ndr_pull_align(ndr, 4));
9605 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->enablesharednetdrives));
9606 0 : NDR_CHECK(ndr_pull_trailer_align(ndr, 4));
9607 : }
9608 0 : if (ndr_flags & NDR_BUFFERS) {
9609 0 : }
9610 0 : return NDR_ERR_SUCCESS;
9611 : }
9612 :
9613 0 : _PUBLIC_ void ndr_print_srvsvc_NetSrvInfo1540(struct ndr_print *ndr, const char *name, const struct srvsvc_NetSrvInfo1540 *r)
9614 : {
9615 0 : ndr_print_struct(ndr, name, "srvsvc_NetSrvInfo1540");
9616 0 : if (r == NULL) { ndr_print_null(ndr); return; }
9617 0 : ndr->depth++;
9618 0 : ndr_print_uint32(ndr, "enablesharednetdrives", r->enablesharednetdrives);
9619 0 : ndr->depth--;
9620 : }
9621 :
9622 0 : static enum ndr_err_code ndr_push_srvsvc_NetSrvInfo1541(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct srvsvc_NetSrvInfo1541 *r)
9623 : {
9624 0 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
9625 0 : if (ndr_flags & NDR_SCALARS) {
9626 0 : NDR_CHECK(ndr_push_align(ndr, 4));
9627 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->minfreeconnections));
9628 0 : NDR_CHECK(ndr_push_trailer_align(ndr, 4));
9629 : }
9630 0 : if (ndr_flags & NDR_BUFFERS) {
9631 0 : }
9632 0 : return NDR_ERR_SUCCESS;
9633 : }
9634 :
9635 0 : static enum ndr_err_code ndr_pull_srvsvc_NetSrvInfo1541(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct srvsvc_NetSrvInfo1541 *r)
9636 : {
9637 0 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
9638 0 : if (ndr_flags & NDR_SCALARS) {
9639 0 : NDR_CHECK(ndr_pull_align(ndr, 4));
9640 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->minfreeconnections));
9641 0 : NDR_CHECK(ndr_pull_trailer_align(ndr, 4));
9642 : }
9643 0 : if (ndr_flags & NDR_BUFFERS) {
9644 0 : }
9645 0 : return NDR_ERR_SUCCESS;
9646 : }
9647 :
9648 0 : _PUBLIC_ void ndr_print_srvsvc_NetSrvInfo1541(struct ndr_print *ndr, const char *name, const struct srvsvc_NetSrvInfo1541 *r)
9649 : {
9650 0 : ndr_print_struct(ndr, name, "srvsvc_NetSrvInfo1541");
9651 0 : if (r == NULL) { ndr_print_null(ndr); return; }
9652 0 : ndr->depth++;
9653 0 : ndr_print_uint32(ndr, "minfreeconnections", r->minfreeconnections);
9654 0 : ndr->depth--;
9655 : }
9656 :
9657 0 : static enum ndr_err_code ndr_push_srvsvc_NetSrvInfo1542(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct srvsvc_NetSrvInfo1542 *r)
9658 : {
9659 0 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
9660 0 : if (ndr_flags & NDR_SCALARS) {
9661 0 : NDR_CHECK(ndr_push_align(ndr, 4));
9662 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->maxfreeconnections));
9663 0 : NDR_CHECK(ndr_push_trailer_align(ndr, 4));
9664 : }
9665 0 : if (ndr_flags & NDR_BUFFERS) {
9666 0 : }
9667 0 : return NDR_ERR_SUCCESS;
9668 : }
9669 :
9670 0 : static enum ndr_err_code ndr_pull_srvsvc_NetSrvInfo1542(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct srvsvc_NetSrvInfo1542 *r)
9671 : {
9672 0 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
9673 0 : if (ndr_flags & NDR_SCALARS) {
9674 0 : NDR_CHECK(ndr_pull_align(ndr, 4));
9675 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->maxfreeconnections));
9676 0 : NDR_CHECK(ndr_pull_trailer_align(ndr, 4));
9677 : }
9678 0 : if (ndr_flags & NDR_BUFFERS) {
9679 0 : }
9680 0 : return NDR_ERR_SUCCESS;
9681 : }
9682 :
9683 0 : _PUBLIC_ void ndr_print_srvsvc_NetSrvInfo1542(struct ndr_print *ndr, const char *name, const struct srvsvc_NetSrvInfo1542 *r)
9684 : {
9685 0 : ndr_print_struct(ndr, name, "srvsvc_NetSrvInfo1542");
9686 0 : if (r == NULL) { ndr_print_null(ndr); return; }
9687 0 : ndr->depth++;
9688 0 : ndr_print_uint32(ndr, "maxfreeconnections", r->maxfreeconnections);
9689 0 : ndr->depth--;
9690 : }
9691 :
9692 0 : static enum ndr_err_code ndr_push_srvsvc_NetSrvInfo1543(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct srvsvc_NetSrvInfo1543 *r)
9693 : {
9694 0 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
9695 0 : if (ndr_flags & NDR_SCALARS) {
9696 0 : NDR_CHECK(ndr_push_align(ndr, 4));
9697 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->initsesstable));
9698 0 : NDR_CHECK(ndr_push_trailer_align(ndr, 4));
9699 : }
9700 0 : if (ndr_flags & NDR_BUFFERS) {
9701 0 : }
9702 0 : return NDR_ERR_SUCCESS;
9703 : }
9704 :
9705 0 : static enum ndr_err_code ndr_pull_srvsvc_NetSrvInfo1543(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct srvsvc_NetSrvInfo1543 *r)
9706 : {
9707 0 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
9708 0 : if (ndr_flags & NDR_SCALARS) {
9709 0 : NDR_CHECK(ndr_pull_align(ndr, 4));
9710 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->initsesstable));
9711 0 : NDR_CHECK(ndr_pull_trailer_align(ndr, 4));
9712 : }
9713 0 : if (ndr_flags & NDR_BUFFERS) {
9714 0 : }
9715 0 : return NDR_ERR_SUCCESS;
9716 : }
9717 :
9718 0 : _PUBLIC_ void ndr_print_srvsvc_NetSrvInfo1543(struct ndr_print *ndr, const char *name, const struct srvsvc_NetSrvInfo1543 *r)
9719 : {
9720 0 : ndr_print_struct(ndr, name, "srvsvc_NetSrvInfo1543");
9721 0 : if (r == NULL) { ndr_print_null(ndr); return; }
9722 0 : ndr->depth++;
9723 0 : ndr_print_uint32(ndr, "initsesstable", r->initsesstable);
9724 0 : ndr->depth--;
9725 : }
9726 :
9727 0 : static enum ndr_err_code ndr_push_srvsvc_NetSrvInfo1544(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct srvsvc_NetSrvInfo1544 *r)
9728 : {
9729 0 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
9730 0 : if (ndr_flags & NDR_SCALARS) {
9731 0 : NDR_CHECK(ndr_push_align(ndr, 4));
9732 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->initconntable));
9733 0 : NDR_CHECK(ndr_push_trailer_align(ndr, 4));
9734 : }
9735 0 : if (ndr_flags & NDR_BUFFERS) {
9736 0 : }
9737 0 : return NDR_ERR_SUCCESS;
9738 : }
9739 :
9740 0 : static enum ndr_err_code ndr_pull_srvsvc_NetSrvInfo1544(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct srvsvc_NetSrvInfo1544 *r)
9741 : {
9742 0 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
9743 0 : if (ndr_flags & NDR_SCALARS) {
9744 0 : NDR_CHECK(ndr_pull_align(ndr, 4));
9745 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->initconntable));
9746 0 : NDR_CHECK(ndr_pull_trailer_align(ndr, 4));
9747 : }
9748 0 : if (ndr_flags & NDR_BUFFERS) {
9749 0 : }
9750 0 : return NDR_ERR_SUCCESS;
9751 : }
9752 :
9753 0 : _PUBLIC_ void ndr_print_srvsvc_NetSrvInfo1544(struct ndr_print *ndr, const char *name, const struct srvsvc_NetSrvInfo1544 *r)
9754 : {
9755 0 : ndr_print_struct(ndr, name, "srvsvc_NetSrvInfo1544");
9756 0 : if (r == NULL) { ndr_print_null(ndr); return; }
9757 0 : ndr->depth++;
9758 0 : ndr_print_uint32(ndr, "initconntable", r->initconntable);
9759 0 : ndr->depth--;
9760 : }
9761 :
9762 0 : static enum ndr_err_code ndr_push_srvsvc_NetSrvInfo1545(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct srvsvc_NetSrvInfo1545 *r)
9763 : {
9764 0 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
9765 0 : if (ndr_flags & NDR_SCALARS) {
9766 0 : NDR_CHECK(ndr_push_align(ndr, 4));
9767 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->initfiletable));
9768 0 : NDR_CHECK(ndr_push_trailer_align(ndr, 4));
9769 : }
9770 0 : if (ndr_flags & NDR_BUFFERS) {
9771 0 : }
9772 0 : return NDR_ERR_SUCCESS;
9773 : }
9774 :
9775 0 : static enum ndr_err_code ndr_pull_srvsvc_NetSrvInfo1545(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct srvsvc_NetSrvInfo1545 *r)
9776 : {
9777 0 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
9778 0 : if (ndr_flags & NDR_SCALARS) {
9779 0 : NDR_CHECK(ndr_pull_align(ndr, 4));
9780 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->initfiletable));
9781 0 : NDR_CHECK(ndr_pull_trailer_align(ndr, 4));
9782 : }
9783 0 : if (ndr_flags & NDR_BUFFERS) {
9784 0 : }
9785 0 : return NDR_ERR_SUCCESS;
9786 : }
9787 :
9788 0 : _PUBLIC_ void ndr_print_srvsvc_NetSrvInfo1545(struct ndr_print *ndr, const char *name, const struct srvsvc_NetSrvInfo1545 *r)
9789 : {
9790 0 : ndr_print_struct(ndr, name, "srvsvc_NetSrvInfo1545");
9791 0 : if (r == NULL) { ndr_print_null(ndr); return; }
9792 0 : ndr->depth++;
9793 0 : ndr_print_uint32(ndr, "initfiletable", r->initfiletable);
9794 0 : ndr->depth--;
9795 : }
9796 :
9797 0 : static enum ndr_err_code ndr_push_srvsvc_NetSrvInfo1546(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct srvsvc_NetSrvInfo1546 *r)
9798 : {
9799 0 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
9800 0 : if (ndr_flags & NDR_SCALARS) {
9801 0 : NDR_CHECK(ndr_push_align(ndr, 4));
9802 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->initsearchtable));
9803 0 : NDR_CHECK(ndr_push_trailer_align(ndr, 4));
9804 : }
9805 0 : if (ndr_flags & NDR_BUFFERS) {
9806 0 : }
9807 0 : return NDR_ERR_SUCCESS;
9808 : }
9809 :
9810 0 : static enum ndr_err_code ndr_pull_srvsvc_NetSrvInfo1546(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct srvsvc_NetSrvInfo1546 *r)
9811 : {
9812 0 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
9813 0 : if (ndr_flags & NDR_SCALARS) {
9814 0 : NDR_CHECK(ndr_pull_align(ndr, 4));
9815 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->initsearchtable));
9816 0 : NDR_CHECK(ndr_pull_trailer_align(ndr, 4));
9817 : }
9818 0 : if (ndr_flags & NDR_BUFFERS) {
9819 0 : }
9820 0 : return NDR_ERR_SUCCESS;
9821 : }
9822 :
9823 0 : _PUBLIC_ void ndr_print_srvsvc_NetSrvInfo1546(struct ndr_print *ndr, const char *name, const struct srvsvc_NetSrvInfo1546 *r)
9824 : {
9825 0 : ndr_print_struct(ndr, name, "srvsvc_NetSrvInfo1546");
9826 0 : if (r == NULL) { ndr_print_null(ndr); return; }
9827 0 : ndr->depth++;
9828 0 : ndr_print_uint32(ndr, "initsearchtable", r->initsearchtable);
9829 0 : ndr->depth--;
9830 : }
9831 :
9832 0 : static enum ndr_err_code ndr_push_srvsvc_NetSrvInfo1547(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct srvsvc_NetSrvInfo1547 *r)
9833 : {
9834 0 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
9835 0 : if (ndr_flags & NDR_SCALARS) {
9836 0 : NDR_CHECK(ndr_push_align(ndr, 4));
9837 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->alertsched));
9838 0 : NDR_CHECK(ndr_push_trailer_align(ndr, 4));
9839 : }
9840 0 : if (ndr_flags & NDR_BUFFERS) {
9841 0 : }
9842 0 : return NDR_ERR_SUCCESS;
9843 : }
9844 :
9845 0 : static enum ndr_err_code ndr_pull_srvsvc_NetSrvInfo1547(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct srvsvc_NetSrvInfo1547 *r)
9846 : {
9847 0 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
9848 0 : if (ndr_flags & NDR_SCALARS) {
9849 0 : NDR_CHECK(ndr_pull_align(ndr, 4));
9850 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->alertsched));
9851 0 : NDR_CHECK(ndr_pull_trailer_align(ndr, 4));
9852 : }
9853 0 : if (ndr_flags & NDR_BUFFERS) {
9854 0 : }
9855 0 : return NDR_ERR_SUCCESS;
9856 : }
9857 :
9858 0 : _PUBLIC_ void ndr_print_srvsvc_NetSrvInfo1547(struct ndr_print *ndr, const char *name, const struct srvsvc_NetSrvInfo1547 *r)
9859 : {
9860 0 : ndr_print_struct(ndr, name, "srvsvc_NetSrvInfo1547");
9861 0 : if (r == NULL) { ndr_print_null(ndr); return; }
9862 0 : ndr->depth++;
9863 0 : ndr_print_uint32(ndr, "alertsched", r->alertsched);
9864 0 : ndr->depth--;
9865 : }
9866 :
9867 0 : static enum ndr_err_code ndr_push_srvsvc_NetSrvInfo1548(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct srvsvc_NetSrvInfo1548 *r)
9868 : {
9869 0 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
9870 0 : if (ndr_flags & NDR_SCALARS) {
9871 0 : NDR_CHECK(ndr_push_align(ndr, 4));
9872 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->errortreshold));
9873 0 : NDR_CHECK(ndr_push_trailer_align(ndr, 4));
9874 : }
9875 0 : if (ndr_flags & NDR_BUFFERS) {
9876 0 : }
9877 0 : return NDR_ERR_SUCCESS;
9878 : }
9879 :
9880 0 : static enum ndr_err_code ndr_pull_srvsvc_NetSrvInfo1548(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct srvsvc_NetSrvInfo1548 *r)
9881 : {
9882 0 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
9883 0 : if (ndr_flags & NDR_SCALARS) {
9884 0 : NDR_CHECK(ndr_pull_align(ndr, 4));
9885 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->errortreshold));
9886 0 : NDR_CHECK(ndr_pull_trailer_align(ndr, 4));
9887 : }
9888 0 : if (ndr_flags & NDR_BUFFERS) {
9889 0 : }
9890 0 : return NDR_ERR_SUCCESS;
9891 : }
9892 :
9893 0 : _PUBLIC_ void ndr_print_srvsvc_NetSrvInfo1548(struct ndr_print *ndr, const char *name, const struct srvsvc_NetSrvInfo1548 *r)
9894 : {
9895 0 : ndr_print_struct(ndr, name, "srvsvc_NetSrvInfo1548");
9896 0 : if (r == NULL) { ndr_print_null(ndr); return; }
9897 0 : ndr->depth++;
9898 0 : ndr_print_uint32(ndr, "errortreshold", r->errortreshold);
9899 0 : ndr->depth--;
9900 : }
9901 :
9902 0 : static enum ndr_err_code ndr_push_srvsvc_NetSrvInfo1549(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct srvsvc_NetSrvInfo1549 *r)
9903 : {
9904 0 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
9905 0 : if (ndr_flags & NDR_SCALARS) {
9906 0 : NDR_CHECK(ndr_push_align(ndr, 4));
9907 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->networkerrortreshold));
9908 0 : NDR_CHECK(ndr_push_trailer_align(ndr, 4));
9909 : }
9910 0 : if (ndr_flags & NDR_BUFFERS) {
9911 0 : }
9912 0 : return NDR_ERR_SUCCESS;
9913 : }
9914 :
9915 0 : static enum ndr_err_code ndr_pull_srvsvc_NetSrvInfo1549(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct srvsvc_NetSrvInfo1549 *r)
9916 : {
9917 0 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
9918 0 : if (ndr_flags & NDR_SCALARS) {
9919 0 : NDR_CHECK(ndr_pull_align(ndr, 4));
9920 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->networkerrortreshold));
9921 0 : NDR_CHECK(ndr_pull_trailer_align(ndr, 4));
9922 : }
9923 0 : if (ndr_flags & NDR_BUFFERS) {
9924 0 : }
9925 0 : return NDR_ERR_SUCCESS;
9926 : }
9927 :
9928 0 : _PUBLIC_ void ndr_print_srvsvc_NetSrvInfo1549(struct ndr_print *ndr, const char *name, const struct srvsvc_NetSrvInfo1549 *r)
9929 : {
9930 0 : ndr_print_struct(ndr, name, "srvsvc_NetSrvInfo1549");
9931 0 : if (r == NULL) { ndr_print_null(ndr); return; }
9932 0 : ndr->depth++;
9933 0 : ndr_print_uint32(ndr, "networkerrortreshold", r->networkerrortreshold);
9934 0 : ndr->depth--;
9935 : }
9936 :
9937 0 : static enum ndr_err_code ndr_push_srvsvc_NetSrvInfo1550(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct srvsvc_NetSrvInfo1550 *r)
9938 : {
9939 0 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
9940 0 : if (ndr_flags & NDR_SCALARS) {
9941 0 : NDR_CHECK(ndr_push_align(ndr, 4));
9942 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->diskspacetreshold));
9943 0 : NDR_CHECK(ndr_push_trailer_align(ndr, 4));
9944 : }
9945 0 : if (ndr_flags & NDR_BUFFERS) {
9946 0 : }
9947 0 : return NDR_ERR_SUCCESS;
9948 : }
9949 :
9950 0 : static enum ndr_err_code ndr_pull_srvsvc_NetSrvInfo1550(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct srvsvc_NetSrvInfo1550 *r)
9951 : {
9952 0 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
9953 0 : if (ndr_flags & NDR_SCALARS) {
9954 0 : NDR_CHECK(ndr_pull_align(ndr, 4));
9955 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->diskspacetreshold));
9956 0 : NDR_CHECK(ndr_pull_trailer_align(ndr, 4));
9957 : }
9958 0 : if (ndr_flags & NDR_BUFFERS) {
9959 0 : }
9960 0 : return NDR_ERR_SUCCESS;
9961 : }
9962 :
9963 0 : _PUBLIC_ void ndr_print_srvsvc_NetSrvInfo1550(struct ndr_print *ndr, const char *name, const struct srvsvc_NetSrvInfo1550 *r)
9964 : {
9965 0 : ndr_print_struct(ndr, name, "srvsvc_NetSrvInfo1550");
9966 0 : if (r == NULL) { ndr_print_null(ndr); return; }
9967 0 : ndr->depth++;
9968 0 : ndr_print_uint32(ndr, "diskspacetreshold", r->diskspacetreshold);
9969 0 : ndr->depth--;
9970 : }
9971 :
9972 0 : static enum ndr_err_code ndr_push_srvsvc_NetSrvInfo1552(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct srvsvc_NetSrvInfo1552 *r)
9973 : {
9974 0 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
9975 0 : if (ndr_flags & NDR_SCALARS) {
9976 0 : NDR_CHECK(ndr_push_align(ndr, 4));
9977 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->maxlinkdelay));
9978 0 : NDR_CHECK(ndr_push_trailer_align(ndr, 4));
9979 : }
9980 0 : if (ndr_flags & NDR_BUFFERS) {
9981 0 : }
9982 0 : return NDR_ERR_SUCCESS;
9983 : }
9984 :
9985 0 : static enum ndr_err_code ndr_pull_srvsvc_NetSrvInfo1552(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct srvsvc_NetSrvInfo1552 *r)
9986 : {
9987 0 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
9988 0 : if (ndr_flags & NDR_SCALARS) {
9989 0 : NDR_CHECK(ndr_pull_align(ndr, 4));
9990 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->maxlinkdelay));
9991 0 : NDR_CHECK(ndr_pull_trailer_align(ndr, 4));
9992 : }
9993 0 : if (ndr_flags & NDR_BUFFERS) {
9994 0 : }
9995 0 : return NDR_ERR_SUCCESS;
9996 : }
9997 :
9998 0 : _PUBLIC_ void ndr_print_srvsvc_NetSrvInfo1552(struct ndr_print *ndr, const char *name, const struct srvsvc_NetSrvInfo1552 *r)
9999 : {
10000 0 : ndr_print_struct(ndr, name, "srvsvc_NetSrvInfo1552");
10001 0 : if (r == NULL) { ndr_print_null(ndr); return; }
10002 0 : ndr->depth++;
10003 0 : ndr_print_uint32(ndr, "maxlinkdelay", r->maxlinkdelay);
10004 0 : ndr->depth--;
10005 : }
10006 :
10007 0 : static enum ndr_err_code ndr_push_srvsvc_NetSrvInfo1553(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct srvsvc_NetSrvInfo1553 *r)
10008 : {
10009 0 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
10010 0 : if (ndr_flags & NDR_SCALARS) {
10011 0 : NDR_CHECK(ndr_push_align(ndr, 4));
10012 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->minlinkthroughput));
10013 0 : NDR_CHECK(ndr_push_trailer_align(ndr, 4));
10014 : }
10015 0 : if (ndr_flags & NDR_BUFFERS) {
10016 0 : }
10017 0 : return NDR_ERR_SUCCESS;
10018 : }
10019 :
10020 0 : static enum ndr_err_code ndr_pull_srvsvc_NetSrvInfo1553(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct srvsvc_NetSrvInfo1553 *r)
10021 : {
10022 0 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
10023 0 : if (ndr_flags & NDR_SCALARS) {
10024 0 : NDR_CHECK(ndr_pull_align(ndr, 4));
10025 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->minlinkthroughput));
10026 0 : NDR_CHECK(ndr_pull_trailer_align(ndr, 4));
10027 : }
10028 0 : if (ndr_flags & NDR_BUFFERS) {
10029 0 : }
10030 0 : return NDR_ERR_SUCCESS;
10031 : }
10032 :
10033 0 : _PUBLIC_ void ndr_print_srvsvc_NetSrvInfo1553(struct ndr_print *ndr, const char *name, const struct srvsvc_NetSrvInfo1553 *r)
10034 : {
10035 0 : ndr_print_struct(ndr, name, "srvsvc_NetSrvInfo1553");
10036 0 : if (r == NULL) { ndr_print_null(ndr); return; }
10037 0 : ndr->depth++;
10038 0 : ndr_print_uint32(ndr, "minlinkthroughput", r->minlinkthroughput);
10039 0 : ndr->depth--;
10040 : }
10041 :
10042 0 : static enum ndr_err_code ndr_push_srvsvc_NetSrvInfo1554(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct srvsvc_NetSrvInfo1554 *r)
10043 : {
10044 0 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
10045 0 : if (ndr_flags & NDR_SCALARS) {
10046 0 : NDR_CHECK(ndr_push_align(ndr, 4));
10047 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->linkinfovalidtime));
10048 0 : NDR_CHECK(ndr_push_trailer_align(ndr, 4));
10049 : }
10050 0 : if (ndr_flags & NDR_BUFFERS) {
10051 0 : }
10052 0 : return NDR_ERR_SUCCESS;
10053 : }
10054 :
10055 0 : static enum ndr_err_code ndr_pull_srvsvc_NetSrvInfo1554(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct srvsvc_NetSrvInfo1554 *r)
10056 : {
10057 0 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
10058 0 : if (ndr_flags & NDR_SCALARS) {
10059 0 : NDR_CHECK(ndr_pull_align(ndr, 4));
10060 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->linkinfovalidtime));
10061 0 : NDR_CHECK(ndr_pull_trailer_align(ndr, 4));
10062 : }
10063 0 : if (ndr_flags & NDR_BUFFERS) {
10064 0 : }
10065 0 : return NDR_ERR_SUCCESS;
10066 : }
10067 :
10068 0 : _PUBLIC_ void ndr_print_srvsvc_NetSrvInfo1554(struct ndr_print *ndr, const char *name, const struct srvsvc_NetSrvInfo1554 *r)
10069 : {
10070 0 : ndr_print_struct(ndr, name, "srvsvc_NetSrvInfo1554");
10071 0 : if (r == NULL) { ndr_print_null(ndr); return; }
10072 0 : ndr->depth++;
10073 0 : ndr_print_uint32(ndr, "linkinfovalidtime", r->linkinfovalidtime);
10074 0 : ndr->depth--;
10075 : }
10076 :
10077 0 : static enum ndr_err_code ndr_push_srvsvc_NetSrvInfo1555(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct srvsvc_NetSrvInfo1555 *r)
10078 : {
10079 0 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
10080 0 : if (ndr_flags & NDR_SCALARS) {
10081 0 : NDR_CHECK(ndr_push_align(ndr, 4));
10082 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->scavqosinfoupdatetime));
10083 0 : NDR_CHECK(ndr_push_trailer_align(ndr, 4));
10084 : }
10085 0 : if (ndr_flags & NDR_BUFFERS) {
10086 0 : }
10087 0 : return NDR_ERR_SUCCESS;
10088 : }
10089 :
10090 0 : static enum ndr_err_code ndr_pull_srvsvc_NetSrvInfo1555(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct srvsvc_NetSrvInfo1555 *r)
10091 : {
10092 0 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
10093 0 : if (ndr_flags & NDR_SCALARS) {
10094 0 : NDR_CHECK(ndr_pull_align(ndr, 4));
10095 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->scavqosinfoupdatetime));
10096 0 : NDR_CHECK(ndr_pull_trailer_align(ndr, 4));
10097 : }
10098 0 : if (ndr_flags & NDR_BUFFERS) {
10099 0 : }
10100 0 : return NDR_ERR_SUCCESS;
10101 : }
10102 :
10103 0 : _PUBLIC_ void ndr_print_srvsvc_NetSrvInfo1555(struct ndr_print *ndr, const char *name, const struct srvsvc_NetSrvInfo1555 *r)
10104 : {
10105 0 : ndr_print_struct(ndr, name, "srvsvc_NetSrvInfo1555");
10106 0 : if (r == NULL) { ndr_print_null(ndr); return; }
10107 0 : ndr->depth++;
10108 0 : ndr_print_uint32(ndr, "scavqosinfoupdatetime", r->scavqosinfoupdatetime);
10109 0 : ndr->depth--;
10110 : }
10111 :
10112 0 : static enum ndr_err_code ndr_push_srvsvc_NetSrvInfo1556(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct srvsvc_NetSrvInfo1556 *r)
10113 : {
10114 0 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
10115 0 : if (ndr_flags & NDR_SCALARS) {
10116 0 : NDR_CHECK(ndr_push_align(ndr, 4));
10117 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->maxworkitemidletime));
10118 0 : NDR_CHECK(ndr_push_trailer_align(ndr, 4));
10119 : }
10120 0 : if (ndr_flags & NDR_BUFFERS) {
10121 0 : }
10122 0 : return NDR_ERR_SUCCESS;
10123 : }
10124 :
10125 0 : static enum ndr_err_code ndr_pull_srvsvc_NetSrvInfo1556(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct srvsvc_NetSrvInfo1556 *r)
10126 : {
10127 0 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
10128 0 : if (ndr_flags & NDR_SCALARS) {
10129 0 : NDR_CHECK(ndr_pull_align(ndr, 4));
10130 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->maxworkitemidletime));
10131 0 : NDR_CHECK(ndr_pull_trailer_align(ndr, 4));
10132 : }
10133 0 : if (ndr_flags & NDR_BUFFERS) {
10134 0 : }
10135 0 : return NDR_ERR_SUCCESS;
10136 : }
10137 :
10138 0 : _PUBLIC_ void ndr_print_srvsvc_NetSrvInfo1556(struct ndr_print *ndr, const char *name, const struct srvsvc_NetSrvInfo1556 *r)
10139 : {
10140 0 : ndr_print_struct(ndr, name, "srvsvc_NetSrvInfo1556");
10141 0 : if (r == NULL) { ndr_print_null(ndr); return; }
10142 0 : ndr->depth++;
10143 0 : ndr_print_uint32(ndr, "maxworkitemidletime", r->maxworkitemidletime);
10144 0 : ndr->depth--;
10145 : }
10146 :
10147 74 : static enum ndr_err_code ndr_push_srvsvc_NetSrvInfo(struct ndr_push *ndr, ndr_flags_type ndr_flags, const union srvsvc_NetSrvInfo *r)
10148 : {
10149 0 : uint32_t level;
10150 74 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
10151 74 : if (ndr_flags & NDR_SCALARS) {
10152 : /* This token is not used again (except perhaps below in the NDR_BUFFERS case) */
10153 74 : NDR_CHECK(ndr_push_steal_switch_value(ndr, r, &level));
10154 74 : NDR_CHECK(ndr_push_union_align(ndr, 5));
10155 74 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, level));
10156 74 : NDR_CHECK(ndr_push_union_align(ndr, 5));
10157 74 : switch (level) {
10158 9 : case 100: {
10159 9 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->info100));
10160 9 : break; }
10161 :
10162 38 : case 101: {
10163 38 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->info101));
10164 38 : break; }
10165 :
10166 9 : case 102: {
10167 9 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->info102));
10168 9 : break; }
10169 :
10170 0 : case 402: {
10171 0 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->info402));
10172 0 : break; }
10173 :
10174 0 : case 403: {
10175 0 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->info403));
10176 0 : break; }
10177 :
10178 9 : case 502: {
10179 9 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->info502));
10180 9 : break; }
10181 :
10182 9 : case 503: {
10183 9 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->info503));
10184 9 : break; }
10185 :
10186 0 : case 599: {
10187 0 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->info599));
10188 0 : break; }
10189 :
10190 0 : case 1005: {
10191 0 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->info1005));
10192 0 : break; }
10193 :
10194 0 : case 1010: {
10195 0 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->info1010));
10196 0 : break; }
10197 :
10198 0 : case 1016: {
10199 0 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->info1016));
10200 0 : break; }
10201 :
10202 0 : case 1017: {
10203 0 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->info1017));
10204 0 : break; }
10205 :
10206 0 : case 1018: {
10207 0 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->info1018));
10208 0 : break; }
10209 :
10210 0 : case 1107: {
10211 0 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->info1107));
10212 0 : break; }
10213 :
10214 0 : case 1501: {
10215 0 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->info1501));
10216 0 : break; }
10217 :
10218 0 : case 1502: {
10219 0 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->info1502));
10220 0 : break; }
10221 :
10222 0 : case 1503: {
10223 0 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->info1503));
10224 0 : break; }
10225 :
10226 0 : case 1506: {
10227 0 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->info1506));
10228 0 : break; }
10229 :
10230 0 : case 1509: {
10231 0 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->info1509));
10232 0 : break; }
10233 :
10234 0 : case 1510: {
10235 0 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->info1510));
10236 0 : break; }
10237 :
10238 0 : case 1511: {
10239 0 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->info1511));
10240 0 : break; }
10241 :
10242 0 : case 1512: {
10243 0 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->info1512));
10244 0 : break; }
10245 :
10246 0 : case 1513: {
10247 0 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->info1513));
10248 0 : break; }
10249 :
10250 0 : case 1514: {
10251 0 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->info1514));
10252 0 : break; }
10253 :
10254 0 : case 1515: {
10255 0 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->info1515));
10256 0 : break; }
10257 :
10258 0 : case 1516: {
10259 0 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->info1516));
10260 0 : break; }
10261 :
10262 0 : case 1518: {
10263 0 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->info1518));
10264 0 : break; }
10265 :
10266 0 : case 1520: {
10267 0 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->info1520));
10268 0 : break; }
10269 :
10270 0 : case 1521: {
10271 0 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->info1521));
10272 0 : break; }
10273 :
10274 0 : case 1522: {
10275 0 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->info1522));
10276 0 : break; }
10277 :
10278 0 : case 1523: {
10279 0 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->info1523));
10280 0 : break; }
10281 :
10282 0 : case 1524: {
10283 0 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->info1524));
10284 0 : break; }
10285 :
10286 0 : case 1525: {
10287 0 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->info1525));
10288 0 : break; }
10289 :
10290 0 : case 1528: {
10291 0 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->info1528));
10292 0 : break; }
10293 :
10294 0 : case 1529: {
10295 0 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->info1529));
10296 0 : break; }
10297 :
10298 0 : case 1530: {
10299 0 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->info1530));
10300 0 : break; }
10301 :
10302 0 : case 1533: {
10303 0 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->info1533));
10304 0 : break; }
10305 :
10306 0 : case 1534: {
10307 0 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->info1534));
10308 0 : break; }
10309 :
10310 0 : case 1535: {
10311 0 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->info1535));
10312 0 : break; }
10313 :
10314 0 : case 1536: {
10315 0 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->info1536));
10316 0 : break; }
10317 :
10318 0 : case 1537: {
10319 0 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->info1537));
10320 0 : break; }
10321 :
10322 0 : case 1538: {
10323 0 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->info1538));
10324 0 : break; }
10325 :
10326 0 : case 1539: {
10327 0 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->info1539));
10328 0 : break; }
10329 :
10330 0 : case 1540: {
10331 0 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->info1540));
10332 0 : break; }
10333 :
10334 0 : case 1541: {
10335 0 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->info1541));
10336 0 : break; }
10337 :
10338 0 : case 1542: {
10339 0 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->info1542));
10340 0 : break; }
10341 :
10342 0 : case 1543: {
10343 0 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->info1543));
10344 0 : break; }
10345 :
10346 0 : case 1544: {
10347 0 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->info1544));
10348 0 : break; }
10349 :
10350 0 : case 1545: {
10351 0 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->info1545));
10352 0 : break; }
10353 :
10354 0 : case 1546: {
10355 0 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->info1546));
10356 0 : break; }
10357 :
10358 0 : case 1547: {
10359 0 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->info1547));
10360 0 : break; }
10361 :
10362 0 : case 1548: {
10363 0 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->info1548));
10364 0 : break; }
10365 :
10366 0 : case 1549: {
10367 0 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->info1549));
10368 0 : break; }
10369 :
10370 0 : case 1550: {
10371 0 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->info1550));
10372 0 : break; }
10373 :
10374 0 : case 1552: {
10375 0 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->info1552));
10376 0 : break; }
10377 :
10378 0 : case 1553: {
10379 0 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->info1553));
10380 0 : break; }
10381 :
10382 0 : case 1554: {
10383 0 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->info1554));
10384 0 : break; }
10385 :
10386 0 : case 1555: {
10387 0 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->info1555));
10388 0 : break; }
10389 :
10390 0 : case 1556: {
10391 0 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->info1556));
10392 0 : break; }
10393 :
10394 0 : default: {
10395 0 : break; }
10396 :
10397 : }
10398 : }
10399 74 : if (ndr_flags & NDR_BUFFERS) {
10400 74 : if (!(ndr_flags & NDR_SCALARS)) {
10401 : /* We didn't get it above, and the token is not needed after this. */
10402 0 : NDR_CHECK(ndr_push_steal_switch_value(ndr, r, &level));
10403 : }
10404 74 : switch (level) {
10405 9 : case 100:
10406 9 : if (r->info100) {
10407 9 : NDR_CHECK(ndr_push_srvsvc_NetSrvInfo100(ndr, NDR_SCALARS|NDR_BUFFERS, r->info100));
10408 : }
10409 9 : break;
10410 :
10411 38 : case 101:
10412 38 : if (r->info101) {
10413 38 : NDR_CHECK(ndr_push_srvsvc_NetSrvInfo101(ndr, NDR_SCALARS|NDR_BUFFERS, r->info101));
10414 : }
10415 38 : break;
10416 :
10417 9 : case 102:
10418 9 : if (r->info102) {
10419 9 : NDR_CHECK(ndr_push_srvsvc_NetSrvInfo102(ndr, NDR_SCALARS|NDR_BUFFERS, r->info102));
10420 : }
10421 9 : break;
10422 :
10423 0 : case 402:
10424 0 : if (r->info402) {
10425 0 : NDR_CHECK(ndr_push_srvsvc_NetSrvInfo402(ndr, NDR_SCALARS|NDR_BUFFERS, r->info402));
10426 : }
10427 0 : break;
10428 :
10429 0 : case 403:
10430 0 : if (r->info403) {
10431 0 : NDR_CHECK(ndr_push_srvsvc_NetSrvInfo403(ndr, NDR_SCALARS|NDR_BUFFERS, r->info403));
10432 : }
10433 0 : break;
10434 :
10435 9 : case 502:
10436 9 : if (r->info502) {
10437 0 : NDR_CHECK(ndr_push_srvsvc_NetSrvInfo502(ndr, NDR_SCALARS, r->info502));
10438 : }
10439 9 : break;
10440 :
10441 9 : case 503:
10442 9 : if (r->info503) {
10443 0 : NDR_CHECK(ndr_push_srvsvc_NetSrvInfo503(ndr, NDR_SCALARS|NDR_BUFFERS, r->info503));
10444 : }
10445 9 : break;
10446 :
10447 0 : case 599:
10448 0 : if (r->info599) {
10449 0 : NDR_CHECK(ndr_push_srvsvc_NetSrvInfo599(ndr, NDR_SCALARS|NDR_BUFFERS, r->info599));
10450 : }
10451 0 : break;
10452 :
10453 0 : case 1005:
10454 0 : if (r->info1005) {
10455 0 : NDR_CHECK(ndr_push_srvsvc_NetSrvInfo1005(ndr, NDR_SCALARS|NDR_BUFFERS, r->info1005));
10456 : }
10457 0 : break;
10458 :
10459 0 : case 1010:
10460 0 : if (r->info1010) {
10461 0 : NDR_CHECK(ndr_push_srvsvc_NetSrvInfo1010(ndr, NDR_SCALARS, r->info1010));
10462 : }
10463 0 : break;
10464 :
10465 0 : case 1016:
10466 0 : if (r->info1016) {
10467 0 : NDR_CHECK(ndr_push_srvsvc_NetSrvInfo1016(ndr, NDR_SCALARS, r->info1016));
10468 : }
10469 0 : break;
10470 :
10471 0 : case 1017:
10472 0 : if (r->info1017) {
10473 0 : NDR_CHECK(ndr_push_srvsvc_NetSrvInfo1017(ndr, NDR_SCALARS, r->info1017));
10474 : }
10475 0 : break;
10476 :
10477 0 : case 1018:
10478 0 : if (r->info1018) {
10479 0 : NDR_CHECK(ndr_push_srvsvc_NetSrvInfo1018(ndr, NDR_SCALARS, r->info1018));
10480 : }
10481 0 : break;
10482 :
10483 0 : case 1107:
10484 0 : if (r->info1107) {
10485 0 : NDR_CHECK(ndr_push_srvsvc_NetSrvInfo1107(ndr, NDR_SCALARS, r->info1107));
10486 : }
10487 0 : break;
10488 :
10489 0 : case 1501:
10490 0 : if (r->info1501) {
10491 0 : NDR_CHECK(ndr_push_srvsvc_NetSrvInfo1501(ndr, NDR_SCALARS, r->info1501));
10492 : }
10493 0 : break;
10494 :
10495 0 : case 1502:
10496 0 : if (r->info1502) {
10497 0 : NDR_CHECK(ndr_push_srvsvc_NetSrvInfo1502(ndr, NDR_SCALARS, r->info1502));
10498 : }
10499 0 : break;
10500 :
10501 0 : case 1503:
10502 0 : if (r->info1503) {
10503 0 : NDR_CHECK(ndr_push_srvsvc_NetSrvInfo1503(ndr, NDR_SCALARS, r->info1503));
10504 : }
10505 0 : break;
10506 :
10507 0 : case 1506:
10508 0 : if (r->info1506) {
10509 0 : NDR_CHECK(ndr_push_srvsvc_NetSrvInfo1506(ndr, NDR_SCALARS, r->info1506));
10510 : }
10511 0 : break;
10512 :
10513 0 : case 1509:
10514 0 : if (r->info1509) {
10515 0 : NDR_CHECK(ndr_push_srvsvc_NetSrvInfo1509(ndr, NDR_SCALARS, r->info1509));
10516 : }
10517 0 : break;
10518 :
10519 0 : case 1510:
10520 0 : if (r->info1510) {
10521 0 : NDR_CHECK(ndr_push_srvsvc_NetSrvInfo1510(ndr, NDR_SCALARS, r->info1510));
10522 : }
10523 0 : break;
10524 :
10525 0 : case 1511:
10526 0 : if (r->info1511) {
10527 0 : NDR_CHECK(ndr_push_srvsvc_NetSrvInfo1511(ndr, NDR_SCALARS, r->info1511));
10528 : }
10529 0 : break;
10530 :
10531 0 : case 1512:
10532 0 : if (r->info1512) {
10533 0 : NDR_CHECK(ndr_push_srvsvc_NetSrvInfo1512(ndr, NDR_SCALARS, r->info1512));
10534 : }
10535 0 : break;
10536 :
10537 0 : case 1513:
10538 0 : if (r->info1513) {
10539 0 : NDR_CHECK(ndr_push_srvsvc_NetSrvInfo1513(ndr, NDR_SCALARS, r->info1513));
10540 : }
10541 0 : break;
10542 :
10543 0 : case 1514:
10544 0 : if (r->info1514) {
10545 0 : NDR_CHECK(ndr_push_srvsvc_NetSrvInfo1514(ndr, NDR_SCALARS, r->info1514));
10546 : }
10547 0 : break;
10548 :
10549 0 : case 1515:
10550 0 : if (r->info1515) {
10551 0 : NDR_CHECK(ndr_push_srvsvc_NetSrvInfo1515(ndr, NDR_SCALARS, r->info1515));
10552 : }
10553 0 : break;
10554 :
10555 0 : case 1516:
10556 0 : if (r->info1516) {
10557 0 : NDR_CHECK(ndr_push_srvsvc_NetSrvInfo1516(ndr, NDR_SCALARS, r->info1516));
10558 : }
10559 0 : break;
10560 :
10561 0 : case 1518:
10562 0 : if (r->info1518) {
10563 0 : NDR_CHECK(ndr_push_srvsvc_NetSrvInfo1518(ndr, NDR_SCALARS, r->info1518));
10564 : }
10565 0 : break;
10566 :
10567 0 : case 1520:
10568 0 : if (r->info1520) {
10569 0 : NDR_CHECK(ndr_push_srvsvc_NetSrvInfo1520(ndr, NDR_SCALARS, r->info1520));
10570 : }
10571 0 : break;
10572 :
10573 0 : case 1521:
10574 0 : if (r->info1521) {
10575 0 : NDR_CHECK(ndr_push_srvsvc_NetSrvInfo1521(ndr, NDR_SCALARS, r->info1521));
10576 : }
10577 0 : break;
10578 :
10579 0 : case 1522:
10580 0 : if (r->info1522) {
10581 0 : NDR_CHECK(ndr_push_srvsvc_NetSrvInfo1522(ndr, NDR_SCALARS, r->info1522));
10582 : }
10583 0 : break;
10584 :
10585 0 : case 1523:
10586 0 : if (r->info1523) {
10587 0 : NDR_CHECK(ndr_push_srvsvc_NetSrvInfo1523(ndr, NDR_SCALARS, r->info1523));
10588 : }
10589 0 : break;
10590 :
10591 0 : case 1524:
10592 0 : if (r->info1524) {
10593 0 : NDR_CHECK(ndr_push_srvsvc_NetSrvInfo1524(ndr, NDR_SCALARS, r->info1524));
10594 : }
10595 0 : break;
10596 :
10597 0 : case 1525:
10598 0 : if (r->info1525) {
10599 0 : NDR_CHECK(ndr_push_srvsvc_NetSrvInfo1525(ndr, NDR_SCALARS, r->info1525));
10600 : }
10601 0 : break;
10602 :
10603 0 : case 1528:
10604 0 : if (r->info1528) {
10605 0 : NDR_CHECK(ndr_push_srvsvc_NetSrvInfo1528(ndr, NDR_SCALARS, r->info1528));
10606 : }
10607 0 : break;
10608 :
10609 0 : case 1529:
10610 0 : if (r->info1529) {
10611 0 : NDR_CHECK(ndr_push_srvsvc_NetSrvInfo1529(ndr, NDR_SCALARS, r->info1529));
10612 : }
10613 0 : break;
10614 :
10615 0 : case 1530:
10616 0 : if (r->info1530) {
10617 0 : NDR_CHECK(ndr_push_srvsvc_NetSrvInfo1530(ndr, NDR_SCALARS, r->info1530));
10618 : }
10619 0 : break;
10620 :
10621 0 : case 1533:
10622 0 : if (r->info1533) {
10623 0 : NDR_CHECK(ndr_push_srvsvc_NetSrvInfo1533(ndr, NDR_SCALARS, r->info1533));
10624 : }
10625 0 : break;
10626 :
10627 0 : case 1534:
10628 0 : if (r->info1534) {
10629 0 : NDR_CHECK(ndr_push_srvsvc_NetSrvInfo1534(ndr, NDR_SCALARS, r->info1534));
10630 : }
10631 0 : break;
10632 :
10633 0 : case 1535:
10634 0 : if (r->info1535) {
10635 0 : NDR_CHECK(ndr_push_srvsvc_NetSrvInfo1535(ndr, NDR_SCALARS, r->info1535));
10636 : }
10637 0 : break;
10638 :
10639 0 : case 1536:
10640 0 : if (r->info1536) {
10641 0 : NDR_CHECK(ndr_push_srvsvc_NetSrvInfo1536(ndr, NDR_SCALARS, r->info1536));
10642 : }
10643 0 : break;
10644 :
10645 0 : case 1537:
10646 0 : if (r->info1537) {
10647 0 : NDR_CHECK(ndr_push_srvsvc_NetSrvInfo1537(ndr, NDR_SCALARS, r->info1537));
10648 : }
10649 0 : break;
10650 :
10651 0 : case 1538:
10652 0 : if (r->info1538) {
10653 0 : NDR_CHECK(ndr_push_srvsvc_NetSrvInfo1538(ndr, NDR_SCALARS, r->info1538));
10654 : }
10655 0 : break;
10656 :
10657 0 : case 1539:
10658 0 : if (r->info1539) {
10659 0 : NDR_CHECK(ndr_push_srvsvc_NetSrvInfo1539(ndr, NDR_SCALARS, r->info1539));
10660 : }
10661 0 : break;
10662 :
10663 0 : case 1540:
10664 0 : if (r->info1540) {
10665 0 : NDR_CHECK(ndr_push_srvsvc_NetSrvInfo1540(ndr, NDR_SCALARS, r->info1540));
10666 : }
10667 0 : break;
10668 :
10669 0 : case 1541:
10670 0 : if (r->info1541) {
10671 0 : NDR_CHECK(ndr_push_srvsvc_NetSrvInfo1541(ndr, NDR_SCALARS, r->info1541));
10672 : }
10673 0 : break;
10674 :
10675 0 : case 1542:
10676 0 : if (r->info1542) {
10677 0 : NDR_CHECK(ndr_push_srvsvc_NetSrvInfo1542(ndr, NDR_SCALARS, r->info1542));
10678 : }
10679 0 : break;
10680 :
10681 0 : case 1543:
10682 0 : if (r->info1543) {
10683 0 : NDR_CHECK(ndr_push_srvsvc_NetSrvInfo1543(ndr, NDR_SCALARS, r->info1543));
10684 : }
10685 0 : break;
10686 :
10687 0 : case 1544:
10688 0 : if (r->info1544) {
10689 0 : NDR_CHECK(ndr_push_srvsvc_NetSrvInfo1544(ndr, NDR_SCALARS, r->info1544));
10690 : }
10691 0 : break;
10692 :
10693 0 : case 1545:
10694 0 : if (r->info1545) {
10695 0 : NDR_CHECK(ndr_push_srvsvc_NetSrvInfo1545(ndr, NDR_SCALARS, r->info1545));
10696 : }
10697 0 : break;
10698 :
10699 0 : case 1546:
10700 0 : if (r->info1546) {
10701 0 : NDR_CHECK(ndr_push_srvsvc_NetSrvInfo1546(ndr, NDR_SCALARS, r->info1546));
10702 : }
10703 0 : break;
10704 :
10705 0 : case 1547:
10706 0 : if (r->info1547) {
10707 0 : NDR_CHECK(ndr_push_srvsvc_NetSrvInfo1547(ndr, NDR_SCALARS, r->info1547));
10708 : }
10709 0 : break;
10710 :
10711 0 : case 1548:
10712 0 : if (r->info1548) {
10713 0 : NDR_CHECK(ndr_push_srvsvc_NetSrvInfo1548(ndr, NDR_SCALARS, r->info1548));
10714 : }
10715 0 : break;
10716 :
10717 0 : case 1549:
10718 0 : if (r->info1549) {
10719 0 : NDR_CHECK(ndr_push_srvsvc_NetSrvInfo1549(ndr, NDR_SCALARS, r->info1549));
10720 : }
10721 0 : break;
10722 :
10723 0 : case 1550:
10724 0 : if (r->info1550) {
10725 0 : NDR_CHECK(ndr_push_srvsvc_NetSrvInfo1550(ndr, NDR_SCALARS, r->info1550));
10726 : }
10727 0 : break;
10728 :
10729 0 : case 1552:
10730 0 : if (r->info1552) {
10731 0 : NDR_CHECK(ndr_push_srvsvc_NetSrvInfo1552(ndr, NDR_SCALARS, r->info1552));
10732 : }
10733 0 : break;
10734 :
10735 0 : case 1553:
10736 0 : if (r->info1553) {
10737 0 : NDR_CHECK(ndr_push_srvsvc_NetSrvInfo1553(ndr, NDR_SCALARS, r->info1553));
10738 : }
10739 0 : break;
10740 :
10741 0 : case 1554:
10742 0 : if (r->info1554) {
10743 0 : NDR_CHECK(ndr_push_srvsvc_NetSrvInfo1554(ndr, NDR_SCALARS, r->info1554));
10744 : }
10745 0 : break;
10746 :
10747 0 : case 1555:
10748 0 : if (r->info1555) {
10749 0 : NDR_CHECK(ndr_push_srvsvc_NetSrvInfo1555(ndr, NDR_SCALARS, r->info1555));
10750 : }
10751 0 : break;
10752 :
10753 0 : case 1556:
10754 0 : if (r->info1556) {
10755 0 : NDR_CHECK(ndr_push_srvsvc_NetSrvInfo1556(ndr, NDR_SCALARS, r->info1556));
10756 : }
10757 0 : break;
10758 :
10759 0 : default:
10760 0 : break;
10761 :
10762 : }
10763 : }
10764 74 : return NDR_ERR_SUCCESS;
10765 : }
10766 :
10767 69 : static enum ndr_err_code ndr_pull_srvsvc_NetSrvInfo(struct ndr_pull *ndr, ndr_flags_type ndr_flags, union srvsvc_NetSrvInfo *r)
10768 : {
10769 0 : uint32_t level;
10770 0 : uint32_t _level;
10771 69 : TALLOC_CTX *_mem_save_info100_0 = NULL;
10772 0 : uint32_t _ptr_info100;
10773 69 : TALLOC_CTX *_mem_save_info101_0 = NULL;
10774 0 : uint32_t _ptr_info101;
10775 69 : TALLOC_CTX *_mem_save_info102_0 = NULL;
10776 0 : uint32_t _ptr_info102;
10777 69 : TALLOC_CTX *_mem_save_info402_0 = NULL;
10778 0 : uint32_t _ptr_info402;
10779 69 : TALLOC_CTX *_mem_save_info403_0 = NULL;
10780 0 : uint32_t _ptr_info403;
10781 69 : TALLOC_CTX *_mem_save_info502_0 = NULL;
10782 0 : uint32_t _ptr_info502;
10783 69 : TALLOC_CTX *_mem_save_info503_0 = NULL;
10784 0 : uint32_t _ptr_info503;
10785 69 : TALLOC_CTX *_mem_save_info599_0 = NULL;
10786 0 : uint32_t _ptr_info599;
10787 69 : TALLOC_CTX *_mem_save_info1005_0 = NULL;
10788 0 : uint32_t _ptr_info1005;
10789 69 : TALLOC_CTX *_mem_save_info1010_0 = NULL;
10790 0 : uint32_t _ptr_info1010;
10791 69 : TALLOC_CTX *_mem_save_info1016_0 = NULL;
10792 0 : uint32_t _ptr_info1016;
10793 69 : TALLOC_CTX *_mem_save_info1017_0 = NULL;
10794 0 : uint32_t _ptr_info1017;
10795 69 : TALLOC_CTX *_mem_save_info1018_0 = NULL;
10796 0 : uint32_t _ptr_info1018;
10797 69 : TALLOC_CTX *_mem_save_info1107_0 = NULL;
10798 0 : uint32_t _ptr_info1107;
10799 69 : TALLOC_CTX *_mem_save_info1501_0 = NULL;
10800 0 : uint32_t _ptr_info1501;
10801 69 : TALLOC_CTX *_mem_save_info1502_0 = NULL;
10802 0 : uint32_t _ptr_info1502;
10803 69 : TALLOC_CTX *_mem_save_info1503_0 = NULL;
10804 0 : uint32_t _ptr_info1503;
10805 69 : TALLOC_CTX *_mem_save_info1506_0 = NULL;
10806 0 : uint32_t _ptr_info1506;
10807 69 : TALLOC_CTX *_mem_save_info1509_0 = NULL;
10808 0 : uint32_t _ptr_info1509;
10809 69 : TALLOC_CTX *_mem_save_info1510_0 = NULL;
10810 0 : uint32_t _ptr_info1510;
10811 69 : TALLOC_CTX *_mem_save_info1511_0 = NULL;
10812 0 : uint32_t _ptr_info1511;
10813 69 : TALLOC_CTX *_mem_save_info1512_0 = NULL;
10814 0 : uint32_t _ptr_info1512;
10815 69 : TALLOC_CTX *_mem_save_info1513_0 = NULL;
10816 0 : uint32_t _ptr_info1513;
10817 69 : TALLOC_CTX *_mem_save_info1514_0 = NULL;
10818 0 : uint32_t _ptr_info1514;
10819 69 : TALLOC_CTX *_mem_save_info1515_0 = NULL;
10820 0 : uint32_t _ptr_info1515;
10821 69 : TALLOC_CTX *_mem_save_info1516_0 = NULL;
10822 0 : uint32_t _ptr_info1516;
10823 69 : TALLOC_CTX *_mem_save_info1518_0 = NULL;
10824 0 : uint32_t _ptr_info1518;
10825 69 : TALLOC_CTX *_mem_save_info1520_0 = NULL;
10826 0 : uint32_t _ptr_info1520;
10827 69 : TALLOC_CTX *_mem_save_info1521_0 = NULL;
10828 0 : uint32_t _ptr_info1521;
10829 69 : TALLOC_CTX *_mem_save_info1522_0 = NULL;
10830 0 : uint32_t _ptr_info1522;
10831 69 : TALLOC_CTX *_mem_save_info1523_0 = NULL;
10832 0 : uint32_t _ptr_info1523;
10833 69 : TALLOC_CTX *_mem_save_info1524_0 = NULL;
10834 0 : uint32_t _ptr_info1524;
10835 69 : TALLOC_CTX *_mem_save_info1525_0 = NULL;
10836 0 : uint32_t _ptr_info1525;
10837 69 : TALLOC_CTX *_mem_save_info1528_0 = NULL;
10838 0 : uint32_t _ptr_info1528;
10839 69 : TALLOC_CTX *_mem_save_info1529_0 = NULL;
10840 0 : uint32_t _ptr_info1529;
10841 69 : TALLOC_CTX *_mem_save_info1530_0 = NULL;
10842 0 : uint32_t _ptr_info1530;
10843 69 : TALLOC_CTX *_mem_save_info1533_0 = NULL;
10844 0 : uint32_t _ptr_info1533;
10845 69 : TALLOC_CTX *_mem_save_info1534_0 = NULL;
10846 0 : uint32_t _ptr_info1534;
10847 69 : TALLOC_CTX *_mem_save_info1535_0 = NULL;
10848 0 : uint32_t _ptr_info1535;
10849 69 : TALLOC_CTX *_mem_save_info1536_0 = NULL;
10850 0 : uint32_t _ptr_info1536;
10851 69 : TALLOC_CTX *_mem_save_info1537_0 = NULL;
10852 0 : uint32_t _ptr_info1537;
10853 69 : TALLOC_CTX *_mem_save_info1538_0 = NULL;
10854 0 : uint32_t _ptr_info1538;
10855 69 : TALLOC_CTX *_mem_save_info1539_0 = NULL;
10856 0 : uint32_t _ptr_info1539;
10857 69 : TALLOC_CTX *_mem_save_info1540_0 = NULL;
10858 0 : uint32_t _ptr_info1540;
10859 69 : TALLOC_CTX *_mem_save_info1541_0 = NULL;
10860 0 : uint32_t _ptr_info1541;
10861 69 : TALLOC_CTX *_mem_save_info1542_0 = NULL;
10862 0 : uint32_t _ptr_info1542;
10863 69 : TALLOC_CTX *_mem_save_info1543_0 = NULL;
10864 0 : uint32_t _ptr_info1543;
10865 69 : TALLOC_CTX *_mem_save_info1544_0 = NULL;
10866 0 : uint32_t _ptr_info1544;
10867 69 : TALLOC_CTX *_mem_save_info1545_0 = NULL;
10868 0 : uint32_t _ptr_info1545;
10869 69 : TALLOC_CTX *_mem_save_info1546_0 = NULL;
10870 0 : uint32_t _ptr_info1546;
10871 69 : TALLOC_CTX *_mem_save_info1547_0 = NULL;
10872 0 : uint32_t _ptr_info1547;
10873 69 : TALLOC_CTX *_mem_save_info1548_0 = NULL;
10874 0 : uint32_t _ptr_info1548;
10875 69 : TALLOC_CTX *_mem_save_info1549_0 = NULL;
10876 0 : uint32_t _ptr_info1549;
10877 69 : TALLOC_CTX *_mem_save_info1550_0 = NULL;
10878 0 : uint32_t _ptr_info1550;
10879 69 : TALLOC_CTX *_mem_save_info1552_0 = NULL;
10880 0 : uint32_t _ptr_info1552;
10881 69 : TALLOC_CTX *_mem_save_info1553_0 = NULL;
10882 0 : uint32_t _ptr_info1553;
10883 69 : TALLOC_CTX *_mem_save_info1554_0 = NULL;
10884 0 : uint32_t _ptr_info1554;
10885 69 : TALLOC_CTX *_mem_save_info1555_0 = NULL;
10886 0 : uint32_t _ptr_info1555;
10887 69 : TALLOC_CTX *_mem_save_info1556_0 = NULL;
10888 0 : uint32_t _ptr_info1556;
10889 69 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
10890 69 : if (ndr_flags & NDR_SCALARS) {
10891 : /* This token is not used again (except perhaps below in the NDR_BUFFERS case) */
10892 69 : NDR_CHECK(ndr_pull_steal_switch_value(ndr, r, &level));
10893 69 : NDR_CHECK(ndr_pull_union_align(ndr, 5));
10894 69 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &_level));
10895 69 : if (_level != level) {
10896 0 : return ndr_pull_error(ndr, NDR_ERR_BAD_SWITCH, "Bad switch value %"PRIu32" for r at %s", (uint32_t)_level, __location__);
10897 : }
10898 69 : NDR_CHECK(ndr_pull_union_align(ndr, 5));
10899 69 : switch (level) {
10900 8 : case 100: {
10901 8 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_info100));
10902 8 : if (_ptr_info100) {
10903 8 : NDR_PULL_ALLOC(ndr, r->info100);
10904 : } else {
10905 0 : r->info100 = NULL;
10906 : }
10907 8 : break; }
10908 :
10909 37 : case 101: {
10910 37 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_info101));
10911 37 : if (_ptr_info101) {
10912 37 : NDR_PULL_ALLOC(ndr, r->info101);
10913 : } else {
10914 0 : r->info101 = NULL;
10915 : }
10916 37 : break; }
10917 :
10918 8 : case 102: {
10919 8 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_info102));
10920 8 : if (_ptr_info102) {
10921 8 : NDR_PULL_ALLOC(ndr, r->info102);
10922 : } else {
10923 0 : r->info102 = NULL;
10924 : }
10925 8 : break; }
10926 :
10927 0 : case 402: {
10928 0 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_info402));
10929 0 : if (_ptr_info402) {
10930 0 : NDR_PULL_ALLOC(ndr, r->info402);
10931 : } else {
10932 0 : r->info402 = NULL;
10933 : }
10934 0 : break; }
10935 :
10936 0 : case 403: {
10937 0 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_info403));
10938 0 : if (_ptr_info403) {
10939 0 : NDR_PULL_ALLOC(ndr, r->info403);
10940 : } else {
10941 0 : r->info403 = NULL;
10942 : }
10943 0 : break; }
10944 :
10945 8 : case 502: {
10946 8 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_info502));
10947 8 : if (_ptr_info502) {
10948 0 : NDR_PULL_ALLOC(ndr, r->info502);
10949 : } else {
10950 8 : r->info502 = NULL;
10951 : }
10952 8 : break; }
10953 :
10954 8 : case 503: {
10955 8 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_info503));
10956 8 : if (_ptr_info503) {
10957 0 : NDR_PULL_ALLOC(ndr, r->info503);
10958 : } else {
10959 8 : r->info503 = NULL;
10960 : }
10961 8 : break; }
10962 :
10963 0 : case 599: {
10964 0 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_info599));
10965 0 : if (_ptr_info599) {
10966 0 : NDR_PULL_ALLOC(ndr, r->info599);
10967 : } else {
10968 0 : r->info599 = NULL;
10969 : }
10970 0 : break; }
10971 :
10972 0 : case 1005: {
10973 0 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_info1005));
10974 0 : if (_ptr_info1005) {
10975 0 : NDR_PULL_ALLOC(ndr, r->info1005);
10976 : } else {
10977 0 : r->info1005 = NULL;
10978 : }
10979 0 : break; }
10980 :
10981 0 : case 1010: {
10982 0 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_info1010));
10983 0 : if (_ptr_info1010) {
10984 0 : NDR_PULL_ALLOC(ndr, r->info1010);
10985 : } else {
10986 0 : r->info1010 = NULL;
10987 : }
10988 0 : break; }
10989 :
10990 0 : case 1016: {
10991 0 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_info1016));
10992 0 : if (_ptr_info1016) {
10993 0 : NDR_PULL_ALLOC(ndr, r->info1016);
10994 : } else {
10995 0 : r->info1016 = NULL;
10996 : }
10997 0 : break; }
10998 :
10999 0 : case 1017: {
11000 0 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_info1017));
11001 0 : if (_ptr_info1017) {
11002 0 : NDR_PULL_ALLOC(ndr, r->info1017);
11003 : } else {
11004 0 : r->info1017 = NULL;
11005 : }
11006 0 : break; }
11007 :
11008 0 : case 1018: {
11009 0 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_info1018));
11010 0 : if (_ptr_info1018) {
11011 0 : NDR_PULL_ALLOC(ndr, r->info1018);
11012 : } else {
11013 0 : r->info1018 = NULL;
11014 : }
11015 0 : break; }
11016 :
11017 0 : case 1107: {
11018 0 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_info1107));
11019 0 : if (_ptr_info1107) {
11020 0 : NDR_PULL_ALLOC(ndr, r->info1107);
11021 : } else {
11022 0 : r->info1107 = NULL;
11023 : }
11024 0 : break; }
11025 :
11026 0 : case 1501: {
11027 0 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_info1501));
11028 0 : if (_ptr_info1501) {
11029 0 : NDR_PULL_ALLOC(ndr, r->info1501);
11030 : } else {
11031 0 : r->info1501 = NULL;
11032 : }
11033 0 : break; }
11034 :
11035 0 : case 1502: {
11036 0 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_info1502));
11037 0 : if (_ptr_info1502) {
11038 0 : NDR_PULL_ALLOC(ndr, r->info1502);
11039 : } else {
11040 0 : r->info1502 = NULL;
11041 : }
11042 0 : break; }
11043 :
11044 0 : case 1503: {
11045 0 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_info1503));
11046 0 : if (_ptr_info1503) {
11047 0 : NDR_PULL_ALLOC(ndr, r->info1503);
11048 : } else {
11049 0 : r->info1503 = NULL;
11050 : }
11051 0 : break; }
11052 :
11053 0 : case 1506: {
11054 0 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_info1506));
11055 0 : if (_ptr_info1506) {
11056 0 : NDR_PULL_ALLOC(ndr, r->info1506);
11057 : } else {
11058 0 : r->info1506 = NULL;
11059 : }
11060 0 : break; }
11061 :
11062 0 : case 1509: {
11063 0 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_info1509));
11064 0 : if (_ptr_info1509) {
11065 0 : NDR_PULL_ALLOC(ndr, r->info1509);
11066 : } else {
11067 0 : r->info1509 = NULL;
11068 : }
11069 0 : break; }
11070 :
11071 0 : case 1510: {
11072 0 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_info1510));
11073 0 : if (_ptr_info1510) {
11074 0 : NDR_PULL_ALLOC(ndr, r->info1510);
11075 : } else {
11076 0 : r->info1510 = NULL;
11077 : }
11078 0 : break; }
11079 :
11080 0 : case 1511: {
11081 0 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_info1511));
11082 0 : if (_ptr_info1511) {
11083 0 : NDR_PULL_ALLOC(ndr, r->info1511);
11084 : } else {
11085 0 : r->info1511 = NULL;
11086 : }
11087 0 : break; }
11088 :
11089 0 : case 1512: {
11090 0 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_info1512));
11091 0 : if (_ptr_info1512) {
11092 0 : NDR_PULL_ALLOC(ndr, r->info1512);
11093 : } else {
11094 0 : r->info1512 = NULL;
11095 : }
11096 0 : break; }
11097 :
11098 0 : case 1513: {
11099 0 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_info1513));
11100 0 : if (_ptr_info1513) {
11101 0 : NDR_PULL_ALLOC(ndr, r->info1513);
11102 : } else {
11103 0 : r->info1513 = NULL;
11104 : }
11105 0 : break; }
11106 :
11107 0 : case 1514: {
11108 0 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_info1514));
11109 0 : if (_ptr_info1514) {
11110 0 : NDR_PULL_ALLOC(ndr, r->info1514);
11111 : } else {
11112 0 : r->info1514 = NULL;
11113 : }
11114 0 : break; }
11115 :
11116 0 : case 1515: {
11117 0 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_info1515));
11118 0 : if (_ptr_info1515) {
11119 0 : NDR_PULL_ALLOC(ndr, r->info1515);
11120 : } else {
11121 0 : r->info1515 = NULL;
11122 : }
11123 0 : break; }
11124 :
11125 0 : case 1516: {
11126 0 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_info1516));
11127 0 : if (_ptr_info1516) {
11128 0 : NDR_PULL_ALLOC(ndr, r->info1516);
11129 : } else {
11130 0 : r->info1516 = NULL;
11131 : }
11132 0 : break; }
11133 :
11134 0 : case 1518: {
11135 0 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_info1518));
11136 0 : if (_ptr_info1518) {
11137 0 : NDR_PULL_ALLOC(ndr, r->info1518);
11138 : } else {
11139 0 : r->info1518 = NULL;
11140 : }
11141 0 : break; }
11142 :
11143 0 : case 1520: {
11144 0 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_info1520));
11145 0 : if (_ptr_info1520) {
11146 0 : NDR_PULL_ALLOC(ndr, r->info1520);
11147 : } else {
11148 0 : r->info1520 = NULL;
11149 : }
11150 0 : break; }
11151 :
11152 0 : case 1521: {
11153 0 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_info1521));
11154 0 : if (_ptr_info1521) {
11155 0 : NDR_PULL_ALLOC(ndr, r->info1521);
11156 : } else {
11157 0 : r->info1521 = NULL;
11158 : }
11159 0 : break; }
11160 :
11161 0 : case 1522: {
11162 0 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_info1522));
11163 0 : if (_ptr_info1522) {
11164 0 : NDR_PULL_ALLOC(ndr, r->info1522);
11165 : } else {
11166 0 : r->info1522 = NULL;
11167 : }
11168 0 : break; }
11169 :
11170 0 : case 1523: {
11171 0 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_info1523));
11172 0 : if (_ptr_info1523) {
11173 0 : NDR_PULL_ALLOC(ndr, r->info1523);
11174 : } else {
11175 0 : r->info1523 = NULL;
11176 : }
11177 0 : break; }
11178 :
11179 0 : case 1524: {
11180 0 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_info1524));
11181 0 : if (_ptr_info1524) {
11182 0 : NDR_PULL_ALLOC(ndr, r->info1524);
11183 : } else {
11184 0 : r->info1524 = NULL;
11185 : }
11186 0 : break; }
11187 :
11188 0 : case 1525: {
11189 0 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_info1525));
11190 0 : if (_ptr_info1525) {
11191 0 : NDR_PULL_ALLOC(ndr, r->info1525);
11192 : } else {
11193 0 : r->info1525 = NULL;
11194 : }
11195 0 : break; }
11196 :
11197 0 : case 1528: {
11198 0 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_info1528));
11199 0 : if (_ptr_info1528) {
11200 0 : NDR_PULL_ALLOC(ndr, r->info1528);
11201 : } else {
11202 0 : r->info1528 = NULL;
11203 : }
11204 0 : break; }
11205 :
11206 0 : case 1529: {
11207 0 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_info1529));
11208 0 : if (_ptr_info1529) {
11209 0 : NDR_PULL_ALLOC(ndr, r->info1529);
11210 : } else {
11211 0 : r->info1529 = NULL;
11212 : }
11213 0 : break; }
11214 :
11215 0 : case 1530: {
11216 0 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_info1530));
11217 0 : if (_ptr_info1530) {
11218 0 : NDR_PULL_ALLOC(ndr, r->info1530);
11219 : } else {
11220 0 : r->info1530 = NULL;
11221 : }
11222 0 : break; }
11223 :
11224 0 : case 1533: {
11225 0 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_info1533));
11226 0 : if (_ptr_info1533) {
11227 0 : NDR_PULL_ALLOC(ndr, r->info1533);
11228 : } else {
11229 0 : r->info1533 = NULL;
11230 : }
11231 0 : break; }
11232 :
11233 0 : case 1534: {
11234 0 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_info1534));
11235 0 : if (_ptr_info1534) {
11236 0 : NDR_PULL_ALLOC(ndr, r->info1534);
11237 : } else {
11238 0 : r->info1534 = NULL;
11239 : }
11240 0 : break; }
11241 :
11242 0 : case 1535: {
11243 0 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_info1535));
11244 0 : if (_ptr_info1535) {
11245 0 : NDR_PULL_ALLOC(ndr, r->info1535);
11246 : } else {
11247 0 : r->info1535 = NULL;
11248 : }
11249 0 : break; }
11250 :
11251 0 : case 1536: {
11252 0 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_info1536));
11253 0 : if (_ptr_info1536) {
11254 0 : NDR_PULL_ALLOC(ndr, r->info1536);
11255 : } else {
11256 0 : r->info1536 = NULL;
11257 : }
11258 0 : break; }
11259 :
11260 0 : case 1537: {
11261 0 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_info1537));
11262 0 : if (_ptr_info1537) {
11263 0 : NDR_PULL_ALLOC(ndr, r->info1537);
11264 : } else {
11265 0 : r->info1537 = NULL;
11266 : }
11267 0 : break; }
11268 :
11269 0 : case 1538: {
11270 0 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_info1538));
11271 0 : if (_ptr_info1538) {
11272 0 : NDR_PULL_ALLOC(ndr, r->info1538);
11273 : } else {
11274 0 : r->info1538 = NULL;
11275 : }
11276 0 : break; }
11277 :
11278 0 : case 1539: {
11279 0 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_info1539));
11280 0 : if (_ptr_info1539) {
11281 0 : NDR_PULL_ALLOC(ndr, r->info1539);
11282 : } else {
11283 0 : r->info1539 = NULL;
11284 : }
11285 0 : break; }
11286 :
11287 0 : case 1540: {
11288 0 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_info1540));
11289 0 : if (_ptr_info1540) {
11290 0 : NDR_PULL_ALLOC(ndr, r->info1540);
11291 : } else {
11292 0 : r->info1540 = NULL;
11293 : }
11294 0 : break; }
11295 :
11296 0 : case 1541: {
11297 0 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_info1541));
11298 0 : if (_ptr_info1541) {
11299 0 : NDR_PULL_ALLOC(ndr, r->info1541);
11300 : } else {
11301 0 : r->info1541 = NULL;
11302 : }
11303 0 : break; }
11304 :
11305 0 : case 1542: {
11306 0 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_info1542));
11307 0 : if (_ptr_info1542) {
11308 0 : NDR_PULL_ALLOC(ndr, r->info1542);
11309 : } else {
11310 0 : r->info1542 = NULL;
11311 : }
11312 0 : break; }
11313 :
11314 0 : case 1543: {
11315 0 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_info1543));
11316 0 : if (_ptr_info1543) {
11317 0 : NDR_PULL_ALLOC(ndr, r->info1543);
11318 : } else {
11319 0 : r->info1543 = NULL;
11320 : }
11321 0 : break; }
11322 :
11323 0 : case 1544: {
11324 0 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_info1544));
11325 0 : if (_ptr_info1544) {
11326 0 : NDR_PULL_ALLOC(ndr, r->info1544);
11327 : } else {
11328 0 : r->info1544 = NULL;
11329 : }
11330 0 : break; }
11331 :
11332 0 : case 1545: {
11333 0 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_info1545));
11334 0 : if (_ptr_info1545) {
11335 0 : NDR_PULL_ALLOC(ndr, r->info1545);
11336 : } else {
11337 0 : r->info1545 = NULL;
11338 : }
11339 0 : break; }
11340 :
11341 0 : case 1546: {
11342 0 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_info1546));
11343 0 : if (_ptr_info1546) {
11344 0 : NDR_PULL_ALLOC(ndr, r->info1546);
11345 : } else {
11346 0 : r->info1546 = NULL;
11347 : }
11348 0 : break; }
11349 :
11350 0 : case 1547: {
11351 0 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_info1547));
11352 0 : if (_ptr_info1547) {
11353 0 : NDR_PULL_ALLOC(ndr, r->info1547);
11354 : } else {
11355 0 : r->info1547 = NULL;
11356 : }
11357 0 : break; }
11358 :
11359 0 : case 1548: {
11360 0 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_info1548));
11361 0 : if (_ptr_info1548) {
11362 0 : NDR_PULL_ALLOC(ndr, r->info1548);
11363 : } else {
11364 0 : r->info1548 = NULL;
11365 : }
11366 0 : break; }
11367 :
11368 0 : case 1549: {
11369 0 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_info1549));
11370 0 : if (_ptr_info1549) {
11371 0 : NDR_PULL_ALLOC(ndr, r->info1549);
11372 : } else {
11373 0 : r->info1549 = NULL;
11374 : }
11375 0 : break; }
11376 :
11377 0 : case 1550: {
11378 0 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_info1550));
11379 0 : if (_ptr_info1550) {
11380 0 : NDR_PULL_ALLOC(ndr, r->info1550);
11381 : } else {
11382 0 : r->info1550 = NULL;
11383 : }
11384 0 : break; }
11385 :
11386 0 : case 1552: {
11387 0 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_info1552));
11388 0 : if (_ptr_info1552) {
11389 0 : NDR_PULL_ALLOC(ndr, r->info1552);
11390 : } else {
11391 0 : r->info1552 = NULL;
11392 : }
11393 0 : break; }
11394 :
11395 0 : case 1553: {
11396 0 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_info1553));
11397 0 : if (_ptr_info1553) {
11398 0 : NDR_PULL_ALLOC(ndr, r->info1553);
11399 : } else {
11400 0 : r->info1553 = NULL;
11401 : }
11402 0 : break; }
11403 :
11404 0 : case 1554: {
11405 0 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_info1554));
11406 0 : if (_ptr_info1554) {
11407 0 : NDR_PULL_ALLOC(ndr, r->info1554);
11408 : } else {
11409 0 : r->info1554 = NULL;
11410 : }
11411 0 : break; }
11412 :
11413 0 : case 1555: {
11414 0 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_info1555));
11415 0 : if (_ptr_info1555) {
11416 0 : NDR_PULL_ALLOC(ndr, r->info1555);
11417 : } else {
11418 0 : r->info1555 = NULL;
11419 : }
11420 0 : break; }
11421 :
11422 0 : case 1556: {
11423 0 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_info1556));
11424 0 : if (_ptr_info1556) {
11425 0 : NDR_PULL_ALLOC(ndr, r->info1556);
11426 : } else {
11427 0 : r->info1556 = NULL;
11428 : }
11429 0 : break; }
11430 :
11431 0 : default: {
11432 0 : break; }
11433 :
11434 : }
11435 : }
11436 69 : if (ndr_flags & NDR_BUFFERS) {
11437 69 : if (!(ndr_flags & NDR_SCALARS)) {
11438 : /* We didn't get it above, and the token is not needed after this. */
11439 0 : NDR_CHECK(ndr_pull_steal_switch_value(ndr, r, &level));
11440 : }
11441 69 : switch (level) {
11442 8 : case 100:
11443 8 : if (r->info100) {
11444 8 : _mem_save_info100_0 = NDR_PULL_GET_MEM_CTX(ndr);
11445 8 : NDR_PULL_SET_MEM_CTX(ndr, r->info100, 0);
11446 8 : NDR_CHECK(ndr_pull_srvsvc_NetSrvInfo100(ndr, NDR_SCALARS|NDR_BUFFERS, r->info100));
11447 8 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_info100_0, 0);
11448 : }
11449 8 : break;
11450 :
11451 37 : case 101:
11452 37 : if (r->info101) {
11453 37 : _mem_save_info101_0 = NDR_PULL_GET_MEM_CTX(ndr);
11454 37 : NDR_PULL_SET_MEM_CTX(ndr, r->info101, 0);
11455 37 : NDR_CHECK(ndr_pull_srvsvc_NetSrvInfo101(ndr, NDR_SCALARS|NDR_BUFFERS, r->info101));
11456 37 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_info101_0, 0);
11457 : }
11458 37 : break;
11459 :
11460 8 : case 102:
11461 8 : if (r->info102) {
11462 8 : _mem_save_info102_0 = NDR_PULL_GET_MEM_CTX(ndr);
11463 8 : NDR_PULL_SET_MEM_CTX(ndr, r->info102, 0);
11464 8 : NDR_CHECK(ndr_pull_srvsvc_NetSrvInfo102(ndr, NDR_SCALARS|NDR_BUFFERS, r->info102));
11465 8 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_info102_0, 0);
11466 : }
11467 8 : break;
11468 :
11469 0 : case 402:
11470 0 : if (r->info402) {
11471 0 : _mem_save_info402_0 = NDR_PULL_GET_MEM_CTX(ndr);
11472 0 : NDR_PULL_SET_MEM_CTX(ndr, r->info402, 0);
11473 0 : NDR_CHECK(ndr_pull_srvsvc_NetSrvInfo402(ndr, NDR_SCALARS|NDR_BUFFERS, r->info402));
11474 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_info402_0, 0);
11475 : }
11476 0 : break;
11477 :
11478 0 : case 403:
11479 0 : if (r->info403) {
11480 0 : _mem_save_info403_0 = NDR_PULL_GET_MEM_CTX(ndr);
11481 0 : NDR_PULL_SET_MEM_CTX(ndr, r->info403, 0);
11482 0 : NDR_CHECK(ndr_pull_srvsvc_NetSrvInfo403(ndr, NDR_SCALARS|NDR_BUFFERS, r->info403));
11483 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_info403_0, 0);
11484 : }
11485 0 : break;
11486 :
11487 8 : case 502:
11488 8 : if (r->info502) {
11489 0 : _mem_save_info502_0 = NDR_PULL_GET_MEM_CTX(ndr);
11490 0 : NDR_PULL_SET_MEM_CTX(ndr, r->info502, 0);
11491 0 : NDR_CHECK(ndr_pull_srvsvc_NetSrvInfo502(ndr, NDR_SCALARS, r->info502));
11492 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_info502_0, 0);
11493 : }
11494 8 : break;
11495 :
11496 8 : case 503:
11497 8 : if (r->info503) {
11498 0 : _mem_save_info503_0 = NDR_PULL_GET_MEM_CTX(ndr);
11499 0 : NDR_PULL_SET_MEM_CTX(ndr, r->info503, 0);
11500 0 : NDR_CHECK(ndr_pull_srvsvc_NetSrvInfo503(ndr, NDR_SCALARS|NDR_BUFFERS, r->info503));
11501 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_info503_0, 0);
11502 : }
11503 8 : break;
11504 :
11505 0 : case 599:
11506 0 : if (r->info599) {
11507 0 : _mem_save_info599_0 = NDR_PULL_GET_MEM_CTX(ndr);
11508 0 : NDR_PULL_SET_MEM_CTX(ndr, r->info599, 0);
11509 0 : NDR_CHECK(ndr_pull_srvsvc_NetSrvInfo599(ndr, NDR_SCALARS|NDR_BUFFERS, r->info599));
11510 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_info599_0, 0);
11511 : }
11512 0 : break;
11513 :
11514 0 : case 1005:
11515 0 : if (r->info1005) {
11516 0 : _mem_save_info1005_0 = NDR_PULL_GET_MEM_CTX(ndr);
11517 0 : NDR_PULL_SET_MEM_CTX(ndr, r->info1005, 0);
11518 0 : NDR_CHECK(ndr_pull_srvsvc_NetSrvInfo1005(ndr, NDR_SCALARS|NDR_BUFFERS, r->info1005));
11519 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_info1005_0, 0);
11520 : }
11521 0 : break;
11522 :
11523 0 : case 1010:
11524 0 : if (r->info1010) {
11525 0 : _mem_save_info1010_0 = NDR_PULL_GET_MEM_CTX(ndr);
11526 0 : NDR_PULL_SET_MEM_CTX(ndr, r->info1010, 0);
11527 0 : NDR_CHECK(ndr_pull_srvsvc_NetSrvInfo1010(ndr, NDR_SCALARS, r->info1010));
11528 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_info1010_0, 0);
11529 : }
11530 0 : break;
11531 :
11532 0 : case 1016:
11533 0 : if (r->info1016) {
11534 0 : _mem_save_info1016_0 = NDR_PULL_GET_MEM_CTX(ndr);
11535 0 : NDR_PULL_SET_MEM_CTX(ndr, r->info1016, 0);
11536 0 : NDR_CHECK(ndr_pull_srvsvc_NetSrvInfo1016(ndr, NDR_SCALARS, r->info1016));
11537 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_info1016_0, 0);
11538 : }
11539 0 : break;
11540 :
11541 0 : case 1017:
11542 0 : if (r->info1017) {
11543 0 : _mem_save_info1017_0 = NDR_PULL_GET_MEM_CTX(ndr);
11544 0 : NDR_PULL_SET_MEM_CTX(ndr, r->info1017, 0);
11545 0 : NDR_CHECK(ndr_pull_srvsvc_NetSrvInfo1017(ndr, NDR_SCALARS, r->info1017));
11546 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_info1017_0, 0);
11547 : }
11548 0 : break;
11549 :
11550 0 : case 1018:
11551 0 : if (r->info1018) {
11552 0 : _mem_save_info1018_0 = NDR_PULL_GET_MEM_CTX(ndr);
11553 0 : NDR_PULL_SET_MEM_CTX(ndr, r->info1018, 0);
11554 0 : NDR_CHECK(ndr_pull_srvsvc_NetSrvInfo1018(ndr, NDR_SCALARS, r->info1018));
11555 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_info1018_0, 0);
11556 : }
11557 0 : break;
11558 :
11559 0 : case 1107:
11560 0 : if (r->info1107) {
11561 0 : _mem_save_info1107_0 = NDR_PULL_GET_MEM_CTX(ndr);
11562 0 : NDR_PULL_SET_MEM_CTX(ndr, r->info1107, 0);
11563 0 : NDR_CHECK(ndr_pull_srvsvc_NetSrvInfo1107(ndr, NDR_SCALARS, r->info1107));
11564 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_info1107_0, 0);
11565 : }
11566 0 : break;
11567 :
11568 0 : case 1501:
11569 0 : if (r->info1501) {
11570 0 : _mem_save_info1501_0 = NDR_PULL_GET_MEM_CTX(ndr);
11571 0 : NDR_PULL_SET_MEM_CTX(ndr, r->info1501, 0);
11572 0 : NDR_CHECK(ndr_pull_srvsvc_NetSrvInfo1501(ndr, NDR_SCALARS, r->info1501));
11573 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_info1501_0, 0);
11574 : }
11575 0 : break;
11576 :
11577 0 : case 1502:
11578 0 : if (r->info1502) {
11579 0 : _mem_save_info1502_0 = NDR_PULL_GET_MEM_CTX(ndr);
11580 0 : NDR_PULL_SET_MEM_CTX(ndr, r->info1502, 0);
11581 0 : NDR_CHECK(ndr_pull_srvsvc_NetSrvInfo1502(ndr, NDR_SCALARS, r->info1502));
11582 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_info1502_0, 0);
11583 : }
11584 0 : break;
11585 :
11586 0 : case 1503:
11587 0 : if (r->info1503) {
11588 0 : _mem_save_info1503_0 = NDR_PULL_GET_MEM_CTX(ndr);
11589 0 : NDR_PULL_SET_MEM_CTX(ndr, r->info1503, 0);
11590 0 : NDR_CHECK(ndr_pull_srvsvc_NetSrvInfo1503(ndr, NDR_SCALARS, r->info1503));
11591 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_info1503_0, 0);
11592 : }
11593 0 : break;
11594 :
11595 0 : case 1506:
11596 0 : if (r->info1506) {
11597 0 : _mem_save_info1506_0 = NDR_PULL_GET_MEM_CTX(ndr);
11598 0 : NDR_PULL_SET_MEM_CTX(ndr, r->info1506, 0);
11599 0 : NDR_CHECK(ndr_pull_srvsvc_NetSrvInfo1506(ndr, NDR_SCALARS, r->info1506));
11600 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_info1506_0, 0);
11601 : }
11602 0 : break;
11603 :
11604 0 : case 1509:
11605 0 : if (r->info1509) {
11606 0 : _mem_save_info1509_0 = NDR_PULL_GET_MEM_CTX(ndr);
11607 0 : NDR_PULL_SET_MEM_CTX(ndr, r->info1509, 0);
11608 0 : NDR_CHECK(ndr_pull_srvsvc_NetSrvInfo1509(ndr, NDR_SCALARS, r->info1509));
11609 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_info1509_0, 0);
11610 : }
11611 0 : break;
11612 :
11613 0 : case 1510:
11614 0 : if (r->info1510) {
11615 0 : _mem_save_info1510_0 = NDR_PULL_GET_MEM_CTX(ndr);
11616 0 : NDR_PULL_SET_MEM_CTX(ndr, r->info1510, 0);
11617 0 : NDR_CHECK(ndr_pull_srvsvc_NetSrvInfo1510(ndr, NDR_SCALARS, r->info1510));
11618 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_info1510_0, 0);
11619 : }
11620 0 : break;
11621 :
11622 0 : case 1511:
11623 0 : if (r->info1511) {
11624 0 : _mem_save_info1511_0 = NDR_PULL_GET_MEM_CTX(ndr);
11625 0 : NDR_PULL_SET_MEM_CTX(ndr, r->info1511, 0);
11626 0 : NDR_CHECK(ndr_pull_srvsvc_NetSrvInfo1511(ndr, NDR_SCALARS, r->info1511));
11627 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_info1511_0, 0);
11628 : }
11629 0 : break;
11630 :
11631 0 : case 1512:
11632 0 : if (r->info1512) {
11633 0 : _mem_save_info1512_0 = NDR_PULL_GET_MEM_CTX(ndr);
11634 0 : NDR_PULL_SET_MEM_CTX(ndr, r->info1512, 0);
11635 0 : NDR_CHECK(ndr_pull_srvsvc_NetSrvInfo1512(ndr, NDR_SCALARS, r->info1512));
11636 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_info1512_0, 0);
11637 : }
11638 0 : break;
11639 :
11640 0 : case 1513:
11641 0 : if (r->info1513) {
11642 0 : _mem_save_info1513_0 = NDR_PULL_GET_MEM_CTX(ndr);
11643 0 : NDR_PULL_SET_MEM_CTX(ndr, r->info1513, 0);
11644 0 : NDR_CHECK(ndr_pull_srvsvc_NetSrvInfo1513(ndr, NDR_SCALARS, r->info1513));
11645 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_info1513_0, 0);
11646 : }
11647 0 : break;
11648 :
11649 0 : case 1514:
11650 0 : if (r->info1514) {
11651 0 : _mem_save_info1514_0 = NDR_PULL_GET_MEM_CTX(ndr);
11652 0 : NDR_PULL_SET_MEM_CTX(ndr, r->info1514, 0);
11653 0 : NDR_CHECK(ndr_pull_srvsvc_NetSrvInfo1514(ndr, NDR_SCALARS, r->info1514));
11654 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_info1514_0, 0);
11655 : }
11656 0 : break;
11657 :
11658 0 : case 1515:
11659 0 : if (r->info1515) {
11660 0 : _mem_save_info1515_0 = NDR_PULL_GET_MEM_CTX(ndr);
11661 0 : NDR_PULL_SET_MEM_CTX(ndr, r->info1515, 0);
11662 0 : NDR_CHECK(ndr_pull_srvsvc_NetSrvInfo1515(ndr, NDR_SCALARS, r->info1515));
11663 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_info1515_0, 0);
11664 : }
11665 0 : break;
11666 :
11667 0 : case 1516:
11668 0 : if (r->info1516) {
11669 0 : _mem_save_info1516_0 = NDR_PULL_GET_MEM_CTX(ndr);
11670 0 : NDR_PULL_SET_MEM_CTX(ndr, r->info1516, 0);
11671 0 : NDR_CHECK(ndr_pull_srvsvc_NetSrvInfo1516(ndr, NDR_SCALARS, r->info1516));
11672 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_info1516_0, 0);
11673 : }
11674 0 : break;
11675 :
11676 0 : case 1518:
11677 0 : if (r->info1518) {
11678 0 : _mem_save_info1518_0 = NDR_PULL_GET_MEM_CTX(ndr);
11679 0 : NDR_PULL_SET_MEM_CTX(ndr, r->info1518, 0);
11680 0 : NDR_CHECK(ndr_pull_srvsvc_NetSrvInfo1518(ndr, NDR_SCALARS, r->info1518));
11681 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_info1518_0, 0);
11682 : }
11683 0 : break;
11684 :
11685 0 : case 1520:
11686 0 : if (r->info1520) {
11687 0 : _mem_save_info1520_0 = NDR_PULL_GET_MEM_CTX(ndr);
11688 0 : NDR_PULL_SET_MEM_CTX(ndr, r->info1520, 0);
11689 0 : NDR_CHECK(ndr_pull_srvsvc_NetSrvInfo1520(ndr, NDR_SCALARS, r->info1520));
11690 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_info1520_0, 0);
11691 : }
11692 0 : break;
11693 :
11694 0 : case 1521:
11695 0 : if (r->info1521) {
11696 0 : _mem_save_info1521_0 = NDR_PULL_GET_MEM_CTX(ndr);
11697 0 : NDR_PULL_SET_MEM_CTX(ndr, r->info1521, 0);
11698 0 : NDR_CHECK(ndr_pull_srvsvc_NetSrvInfo1521(ndr, NDR_SCALARS, r->info1521));
11699 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_info1521_0, 0);
11700 : }
11701 0 : break;
11702 :
11703 0 : case 1522:
11704 0 : if (r->info1522) {
11705 0 : _mem_save_info1522_0 = NDR_PULL_GET_MEM_CTX(ndr);
11706 0 : NDR_PULL_SET_MEM_CTX(ndr, r->info1522, 0);
11707 0 : NDR_CHECK(ndr_pull_srvsvc_NetSrvInfo1522(ndr, NDR_SCALARS, r->info1522));
11708 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_info1522_0, 0);
11709 : }
11710 0 : break;
11711 :
11712 0 : case 1523:
11713 0 : if (r->info1523) {
11714 0 : _mem_save_info1523_0 = NDR_PULL_GET_MEM_CTX(ndr);
11715 0 : NDR_PULL_SET_MEM_CTX(ndr, r->info1523, 0);
11716 0 : NDR_CHECK(ndr_pull_srvsvc_NetSrvInfo1523(ndr, NDR_SCALARS, r->info1523));
11717 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_info1523_0, 0);
11718 : }
11719 0 : break;
11720 :
11721 0 : case 1524:
11722 0 : if (r->info1524) {
11723 0 : _mem_save_info1524_0 = NDR_PULL_GET_MEM_CTX(ndr);
11724 0 : NDR_PULL_SET_MEM_CTX(ndr, r->info1524, 0);
11725 0 : NDR_CHECK(ndr_pull_srvsvc_NetSrvInfo1524(ndr, NDR_SCALARS, r->info1524));
11726 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_info1524_0, 0);
11727 : }
11728 0 : break;
11729 :
11730 0 : case 1525:
11731 0 : if (r->info1525) {
11732 0 : _mem_save_info1525_0 = NDR_PULL_GET_MEM_CTX(ndr);
11733 0 : NDR_PULL_SET_MEM_CTX(ndr, r->info1525, 0);
11734 0 : NDR_CHECK(ndr_pull_srvsvc_NetSrvInfo1525(ndr, NDR_SCALARS, r->info1525));
11735 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_info1525_0, 0);
11736 : }
11737 0 : break;
11738 :
11739 0 : case 1528:
11740 0 : if (r->info1528) {
11741 0 : _mem_save_info1528_0 = NDR_PULL_GET_MEM_CTX(ndr);
11742 0 : NDR_PULL_SET_MEM_CTX(ndr, r->info1528, 0);
11743 0 : NDR_CHECK(ndr_pull_srvsvc_NetSrvInfo1528(ndr, NDR_SCALARS, r->info1528));
11744 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_info1528_0, 0);
11745 : }
11746 0 : break;
11747 :
11748 0 : case 1529:
11749 0 : if (r->info1529) {
11750 0 : _mem_save_info1529_0 = NDR_PULL_GET_MEM_CTX(ndr);
11751 0 : NDR_PULL_SET_MEM_CTX(ndr, r->info1529, 0);
11752 0 : NDR_CHECK(ndr_pull_srvsvc_NetSrvInfo1529(ndr, NDR_SCALARS, r->info1529));
11753 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_info1529_0, 0);
11754 : }
11755 0 : break;
11756 :
11757 0 : case 1530:
11758 0 : if (r->info1530) {
11759 0 : _mem_save_info1530_0 = NDR_PULL_GET_MEM_CTX(ndr);
11760 0 : NDR_PULL_SET_MEM_CTX(ndr, r->info1530, 0);
11761 0 : NDR_CHECK(ndr_pull_srvsvc_NetSrvInfo1530(ndr, NDR_SCALARS, r->info1530));
11762 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_info1530_0, 0);
11763 : }
11764 0 : break;
11765 :
11766 0 : case 1533:
11767 0 : if (r->info1533) {
11768 0 : _mem_save_info1533_0 = NDR_PULL_GET_MEM_CTX(ndr);
11769 0 : NDR_PULL_SET_MEM_CTX(ndr, r->info1533, 0);
11770 0 : NDR_CHECK(ndr_pull_srvsvc_NetSrvInfo1533(ndr, NDR_SCALARS, r->info1533));
11771 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_info1533_0, 0);
11772 : }
11773 0 : break;
11774 :
11775 0 : case 1534:
11776 0 : if (r->info1534) {
11777 0 : _mem_save_info1534_0 = NDR_PULL_GET_MEM_CTX(ndr);
11778 0 : NDR_PULL_SET_MEM_CTX(ndr, r->info1534, 0);
11779 0 : NDR_CHECK(ndr_pull_srvsvc_NetSrvInfo1534(ndr, NDR_SCALARS, r->info1534));
11780 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_info1534_0, 0);
11781 : }
11782 0 : break;
11783 :
11784 0 : case 1535:
11785 0 : if (r->info1535) {
11786 0 : _mem_save_info1535_0 = NDR_PULL_GET_MEM_CTX(ndr);
11787 0 : NDR_PULL_SET_MEM_CTX(ndr, r->info1535, 0);
11788 0 : NDR_CHECK(ndr_pull_srvsvc_NetSrvInfo1535(ndr, NDR_SCALARS, r->info1535));
11789 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_info1535_0, 0);
11790 : }
11791 0 : break;
11792 :
11793 0 : case 1536:
11794 0 : if (r->info1536) {
11795 0 : _mem_save_info1536_0 = NDR_PULL_GET_MEM_CTX(ndr);
11796 0 : NDR_PULL_SET_MEM_CTX(ndr, r->info1536, 0);
11797 0 : NDR_CHECK(ndr_pull_srvsvc_NetSrvInfo1536(ndr, NDR_SCALARS, r->info1536));
11798 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_info1536_0, 0);
11799 : }
11800 0 : break;
11801 :
11802 0 : case 1537:
11803 0 : if (r->info1537) {
11804 0 : _mem_save_info1537_0 = NDR_PULL_GET_MEM_CTX(ndr);
11805 0 : NDR_PULL_SET_MEM_CTX(ndr, r->info1537, 0);
11806 0 : NDR_CHECK(ndr_pull_srvsvc_NetSrvInfo1537(ndr, NDR_SCALARS, r->info1537));
11807 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_info1537_0, 0);
11808 : }
11809 0 : break;
11810 :
11811 0 : case 1538:
11812 0 : if (r->info1538) {
11813 0 : _mem_save_info1538_0 = NDR_PULL_GET_MEM_CTX(ndr);
11814 0 : NDR_PULL_SET_MEM_CTX(ndr, r->info1538, 0);
11815 0 : NDR_CHECK(ndr_pull_srvsvc_NetSrvInfo1538(ndr, NDR_SCALARS, r->info1538));
11816 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_info1538_0, 0);
11817 : }
11818 0 : break;
11819 :
11820 0 : case 1539:
11821 0 : if (r->info1539) {
11822 0 : _mem_save_info1539_0 = NDR_PULL_GET_MEM_CTX(ndr);
11823 0 : NDR_PULL_SET_MEM_CTX(ndr, r->info1539, 0);
11824 0 : NDR_CHECK(ndr_pull_srvsvc_NetSrvInfo1539(ndr, NDR_SCALARS, r->info1539));
11825 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_info1539_0, 0);
11826 : }
11827 0 : break;
11828 :
11829 0 : case 1540:
11830 0 : if (r->info1540) {
11831 0 : _mem_save_info1540_0 = NDR_PULL_GET_MEM_CTX(ndr);
11832 0 : NDR_PULL_SET_MEM_CTX(ndr, r->info1540, 0);
11833 0 : NDR_CHECK(ndr_pull_srvsvc_NetSrvInfo1540(ndr, NDR_SCALARS, r->info1540));
11834 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_info1540_0, 0);
11835 : }
11836 0 : break;
11837 :
11838 0 : case 1541:
11839 0 : if (r->info1541) {
11840 0 : _mem_save_info1541_0 = NDR_PULL_GET_MEM_CTX(ndr);
11841 0 : NDR_PULL_SET_MEM_CTX(ndr, r->info1541, 0);
11842 0 : NDR_CHECK(ndr_pull_srvsvc_NetSrvInfo1541(ndr, NDR_SCALARS, r->info1541));
11843 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_info1541_0, 0);
11844 : }
11845 0 : break;
11846 :
11847 0 : case 1542:
11848 0 : if (r->info1542) {
11849 0 : _mem_save_info1542_0 = NDR_PULL_GET_MEM_CTX(ndr);
11850 0 : NDR_PULL_SET_MEM_CTX(ndr, r->info1542, 0);
11851 0 : NDR_CHECK(ndr_pull_srvsvc_NetSrvInfo1542(ndr, NDR_SCALARS, r->info1542));
11852 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_info1542_0, 0);
11853 : }
11854 0 : break;
11855 :
11856 0 : case 1543:
11857 0 : if (r->info1543) {
11858 0 : _mem_save_info1543_0 = NDR_PULL_GET_MEM_CTX(ndr);
11859 0 : NDR_PULL_SET_MEM_CTX(ndr, r->info1543, 0);
11860 0 : NDR_CHECK(ndr_pull_srvsvc_NetSrvInfo1543(ndr, NDR_SCALARS, r->info1543));
11861 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_info1543_0, 0);
11862 : }
11863 0 : break;
11864 :
11865 0 : case 1544:
11866 0 : if (r->info1544) {
11867 0 : _mem_save_info1544_0 = NDR_PULL_GET_MEM_CTX(ndr);
11868 0 : NDR_PULL_SET_MEM_CTX(ndr, r->info1544, 0);
11869 0 : NDR_CHECK(ndr_pull_srvsvc_NetSrvInfo1544(ndr, NDR_SCALARS, r->info1544));
11870 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_info1544_0, 0);
11871 : }
11872 0 : break;
11873 :
11874 0 : case 1545:
11875 0 : if (r->info1545) {
11876 0 : _mem_save_info1545_0 = NDR_PULL_GET_MEM_CTX(ndr);
11877 0 : NDR_PULL_SET_MEM_CTX(ndr, r->info1545, 0);
11878 0 : NDR_CHECK(ndr_pull_srvsvc_NetSrvInfo1545(ndr, NDR_SCALARS, r->info1545));
11879 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_info1545_0, 0);
11880 : }
11881 0 : break;
11882 :
11883 0 : case 1546:
11884 0 : if (r->info1546) {
11885 0 : _mem_save_info1546_0 = NDR_PULL_GET_MEM_CTX(ndr);
11886 0 : NDR_PULL_SET_MEM_CTX(ndr, r->info1546, 0);
11887 0 : NDR_CHECK(ndr_pull_srvsvc_NetSrvInfo1546(ndr, NDR_SCALARS, r->info1546));
11888 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_info1546_0, 0);
11889 : }
11890 0 : break;
11891 :
11892 0 : case 1547:
11893 0 : if (r->info1547) {
11894 0 : _mem_save_info1547_0 = NDR_PULL_GET_MEM_CTX(ndr);
11895 0 : NDR_PULL_SET_MEM_CTX(ndr, r->info1547, 0);
11896 0 : NDR_CHECK(ndr_pull_srvsvc_NetSrvInfo1547(ndr, NDR_SCALARS, r->info1547));
11897 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_info1547_0, 0);
11898 : }
11899 0 : break;
11900 :
11901 0 : case 1548:
11902 0 : if (r->info1548) {
11903 0 : _mem_save_info1548_0 = NDR_PULL_GET_MEM_CTX(ndr);
11904 0 : NDR_PULL_SET_MEM_CTX(ndr, r->info1548, 0);
11905 0 : NDR_CHECK(ndr_pull_srvsvc_NetSrvInfo1548(ndr, NDR_SCALARS, r->info1548));
11906 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_info1548_0, 0);
11907 : }
11908 0 : break;
11909 :
11910 0 : case 1549:
11911 0 : if (r->info1549) {
11912 0 : _mem_save_info1549_0 = NDR_PULL_GET_MEM_CTX(ndr);
11913 0 : NDR_PULL_SET_MEM_CTX(ndr, r->info1549, 0);
11914 0 : NDR_CHECK(ndr_pull_srvsvc_NetSrvInfo1549(ndr, NDR_SCALARS, r->info1549));
11915 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_info1549_0, 0);
11916 : }
11917 0 : break;
11918 :
11919 0 : case 1550:
11920 0 : if (r->info1550) {
11921 0 : _mem_save_info1550_0 = NDR_PULL_GET_MEM_CTX(ndr);
11922 0 : NDR_PULL_SET_MEM_CTX(ndr, r->info1550, 0);
11923 0 : NDR_CHECK(ndr_pull_srvsvc_NetSrvInfo1550(ndr, NDR_SCALARS, r->info1550));
11924 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_info1550_0, 0);
11925 : }
11926 0 : break;
11927 :
11928 0 : case 1552:
11929 0 : if (r->info1552) {
11930 0 : _mem_save_info1552_0 = NDR_PULL_GET_MEM_CTX(ndr);
11931 0 : NDR_PULL_SET_MEM_CTX(ndr, r->info1552, 0);
11932 0 : NDR_CHECK(ndr_pull_srvsvc_NetSrvInfo1552(ndr, NDR_SCALARS, r->info1552));
11933 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_info1552_0, 0);
11934 : }
11935 0 : break;
11936 :
11937 0 : case 1553:
11938 0 : if (r->info1553) {
11939 0 : _mem_save_info1553_0 = NDR_PULL_GET_MEM_CTX(ndr);
11940 0 : NDR_PULL_SET_MEM_CTX(ndr, r->info1553, 0);
11941 0 : NDR_CHECK(ndr_pull_srvsvc_NetSrvInfo1553(ndr, NDR_SCALARS, r->info1553));
11942 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_info1553_0, 0);
11943 : }
11944 0 : break;
11945 :
11946 0 : case 1554:
11947 0 : if (r->info1554) {
11948 0 : _mem_save_info1554_0 = NDR_PULL_GET_MEM_CTX(ndr);
11949 0 : NDR_PULL_SET_MEM_CTX(ndr, r->info1554, 0);
11950 0 : NDR_CHECK(ndr_pull_srvsvc_NetSrvInfo1554(ndr, NDR_SCALARS, r->info1554));
11951 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_info1554_0, 0);
11952 : }
11953 0 : break;
11954 :
11955 0 : case 1555:
11956 0 : if (r->info1555) {
11957 0 : _mem_save_info1555_0 = NDR_PULL_GET_MEM_CTX(ndr);
11958 0 : NDR_PULL_SET_MEM_CTX(ndr, r->info1555, 0);
11959 0 : NDR_CHECK(ndr_pull_srvsvc_NetSrvInfo1555(ndr, NDR_SCALARS, r->info1555));
11960 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_info1555_0, 0);
11961 : }
11962 0 : break;
11963 :
11964 0 : case 1556:
11965 0 : if (r->info1556) {
11966 0 : _mem_save_info1556_0 = NDR_PULL_GET_MEM_CTX(ndr);
11967 0 : NDR_PULL_SET_MEM_CTX(ndr, r->info1556, 0);
11968 0 : NDR_CHECK(ndr_pull_srvsvc_NetSrvInfo1556(ndr, NDR_SCALARS, r->info1556));
11969 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_info1556_0, 0);
11970 : }
11971 0 : break;
11972 :
11973 0 : default:
11974 0 : break;
11975 :
11976 : }
11977 : }
11978 69 : return NDR_ERR_SUCCESS;
11979 : }
11980 :
11981 10 : _PUBLIC_ void ndr_print_srvsvc_NetSrvInfo(struct ndr_print *ndr, const char *name, const union srvsvc_NetSrvInfo *r)
11982 : {
11983 0 : uint32_t level;
11984 10 : level = ndr_print_steal_switch_value(ndr, r);
11985 10 : ndr_print_union(ndr, name, level, "srvsvc_NetSrvInfo");
11986 10 : switch (level) {
11987 2 : case 100:
11988 2 : ndr_print_ptr(ndr, "info100", r->info100);
11989 2 : ndr->depth++;
11990 2 : if (r->info100) {
11991 2 : ndr_print_srvsvc_NetSrvInfo100(ndr, "info100", r->info100);
11992 : }
11993 2 : ndr->depth--;
11994 2 : break;
11995 :
11996 2 : case 101:
11997 2 : ndr_print_ptr(ndr, "info101", r->info101);
11998 2 : ndr->depth++;
11999 2 : if (r->info101) {
12000 2 : ndr_print_srvsvc_NetSrvInfo101(ndr, "info101", r->info101);
12001 : }
12002 2 : ndr->depth--;
12003 2 : break;
12004 :
12005 2 : case 102:
12006 2 : ndr_print_ptr(ndr, "info102", r->info102);
12007 2 : ndr->depth++;
12008 2 : if (r->info102) {
12009 2 : ndr_print_srvsvc_NetSrvInfo102(ndr, "info102", r->info102);
12010 : }
12011 2 : ndr->depth--;
12012 2 : break;
12013 :
12014 0 : case 402:
12015 0 : ndr_print_ptr(ndr, "info402", r->info402);
12016 0 : ndr->depth++;
12017 0 : if (r->info402) {
12018 0 : ndr_print_srvsvc_NetSrvInfo402(ndr, "info402", r->info402);
12019 : }
12020 0 : ndr->depth--;
12021 0 : break;
12022 :
12023 0 : case 403:
12024 0 : ndr_print_ptr(ndr, "info403", r->info403);
12025 0 : ndr->depth++;
12026 0 : if (r->info403) {
12027 0 : ndr_print_srvsvc_NetSrvInfo403(ndr, "info403", r->info403);
12028 : }
12029 0 : ndr->depth--;
12030 0 : break;
12031 :
12032 2 : case 502:
12033 2 : ndr_print_ptr(ndr, "info502", r->info502);
12034 2 : ndr->depth++;
12035 2 : if (r->info502) {
12036 0 : ndr_print_srvsvc_NetSrvInfo502(ndr, "info502", r->info502);
12037 : }
12038 2 : ndr->depth--;
12039 2 : break;
12040 :
12041 2 : case 503:
12042 2 : ndr_print_ptr(ndr, "info503", r->info503);
12043 2 : ndr->depth++;
12044 2 : if (r->info503) {
12045 0 : ndr_print_srvsvc_NetSrvInfo503(ndr, "info503", r->info503);
12046 : }
12047 2 : ndr->depth--;
12048 2 : break;
12049 :
12050 0 : case 599:
12051 0 : ndr_print_ptr(ndr, "info599", r->info599);
12052 0 : ndr->depth++;
12053 0 : if (r->info599) {
12054 0 : ndr_print_srvsvc_NetSrvInfo599(ndr, "info599", r->info599);
12055 : }
12056 0 : ndr->depth--;
12057 0 : break;
12058 :
12059 0 : case 1005:
12060 0 : ndr_print_ptr(ndr, "info1005", r->info1005);
12061 0 : ndr->depth++;
12062 0 : if (r->info1005) {
12063 0 : ndr_print_srvsvc_NetSrvInfo1005(ndr, "info1005", r->info1005);
12064 : }
12065 0 : ndr->depth--;
12066 0 : break;
12067 :
12068 0 : case 1010:
12069 0 : ndr_print_ptr(ndr, "info1010", r->info1010);
12070 0 : ndr->depth++;
12071 0 : if (r->info1010) {
12072 0 : ndr_print_srvsvc_NetSrvInfo1010(ndr, "info1010", r->info1010);
12073 : }
12074 0 : ndr->depth--;
12075 0 : break;
12076 :
12077 0 : case 1016:
12078 0 : ndr_print_ptr(ndr, "info1016", r->info1016);
12079 0 : ndr->depth++;
12080 0 : if (r->info1016) {
12081 0 : ndr_print_srvsvc_NetSrvInfo1016(ndr, "info1016", r->info1016);
12082 : }
12083 0 : ndr->depth--;
12084 0 : break;
12085 :
12086 0 : case 1017:
12087 0 : ndr_print_ptr(ndr, "info1017", r->info1017);
12088 0 : ndr->depth++;
12089 0 : if (r->info1017) {
12090 0 : ndr_print_srvsvc_NetSrvInfo1017(ndr, "info1017", r->info1017);
12091 : }
12092 0 : ndr->depth--;
12093 0 : break;
12094 :
12095 0 : case 1018:
12096 0 : ndr_print_ptr(ndr, "info1018", r->info1018);
12097 0 : ndr->depth++;
12098 0 : if (r->info1018) {
12099 0 : ndr_print_srvsvc_NetSrvInfo1018(ndr, "info1018", r->info1018);
12100 : }
12101 0 : ndr->depth--;
12102 0 : break;
12103 :
12104 0 : case 1107:
12105 0 : ndr_print_ptr(ndr, "info1107", r->info1107);
12106 0 : ndr->depth++;
12107 0 : if (r->info1107) {
12108 0 : ndr_print_srvsvc_NetSrvInfo1107(ndr, "info1107", r->info1107);
12109 : }
12110 0 : ndr->depth--;
12111 0 : break;
12112 :
12113 0 : case 1501:
12114 0 : ndr_print_ptr(ndr, "info1501", r->info1501);
12115 0 : ndr->depth++;
12116 0 : if (r->info1501) {
12117 0 : ndr_print_srvsvc_NetSrvInfo1501(ndr, "info1501", r->info1501);
12118 : }
12119 0 : ndr->depth--;
12120 0 : break;
12121 :
12122 0 : case 1502:
12123 0 : ndr_print_ptr(ndr, "info1502", r->info1502);
12124 0 : ndr->depth++;
12125 0 : if (r->info1502) {
12126 0 : ndr_print_srvsvc_NetSrvInfo1502(ndr, "info1502", r->info1502);
12127 : }
12128 0 : ndr->depth--;
12129 0 : break;
12130 :
12131 0 : case 1503:
12132 0 : ndr_print_ptr(ndr, "info1503", r->info1503);
12133 0 : ndr->depth++;
12134 0 : if (r->info1503) {
12135 0 : ndr_print_srvsvc_NetSrvInfo1503(ndr, "info1503", r->info1503);
12136 : }
12137 0 : ndr->depth--;
12138 0 : break;
12139 :
12140 0 : case 1506:
12141 0 : ndr_print_ptr(ndr, "info1506", r->info1506);
12142 0 : ndr->depth++;
12143 0 : if (r->info1506) {
12144 0 : ndr_print_srvsvc_NetSrvInfo1506(ndr, "info1506", r->info1506);
12145 : }
12146 0 : ndr->depth--;
12147 0 : break;
12148 :
12149 0 : case 1509:
12150 0 : ndr_print_ptr(ndr, "info1509", r->info1509);
12151 0 : ndr->depth++;
12152 0 : if (r->info1509) {
12153 0 : ndr_print_srvsvc_NetSrvInfo1509(ndr, "info1509", r->info1509);
12154 : }
12155 0 : ndr->depth--;
12156 0 : break;
12157 :
12158 0 : case 1510:
12159 0 : ndr_print_ptr(ndr, "info1510", r->info1510);
12160 0 : ndr->depth++;
12161 0 : if (r->info1510) {
12162 0 : ndr_print_srvsvc_NetSrvInfo1510(ndr, "info1510", r->info1510);
12163 : }
12164 0 : ndr->depth--;
12165 0 : break;
12166 :
12167 0 : case 1511:
12168 0 : ndr_print_ptr(ndr, "info1511", r->info1511);
12169 0 : ndr->depth++;
12170 0 : if (r->info1511) {
12171 0 : ndr_print_srvsvc_NetSrvInfo1511(ndr, "info1511", r->info1511);
12172 : }
12173 0 : ndr->depth--;
12174 0 : break;
12175 :
12176 0 : case 1512:
12177 0 : ndr_print_ptr(ndr, "info1512", r->info1512);
12178 0 : ndr->depth++;
12179 0 : if (r->info1512) {
12180 0 : ndr_print_srvsvc_NetSrvInfo1512(ndr, "info1512", r->info1512);
12181 : }
12182 0 : ndr->depth--;
12183 0 : break;
12184 :
12185 0 : case 1513:
12186 0 : ndr_print_ptr(ndr, "info1513", r->info1513);
12187 0 : ndr->depth++;
12188 0 : if (r->info1513) {
12189 0 : ndr_print_srvsvc_NetSrvInfo1513(ndr, "info1513", r->info1513);
12190 : }
12191 0 : ndr->depth--;
12192 0 : break;
12193 :
12194 0 : case 1514:
12195 0 : ndr_print_ptr(ndr, "info1514", r->info1514);
12196 0 : ndr->depth++;
12197 0 : if (r->info1514) {
12198 0 : ndr_print_srvsvc_NetSrvInfo1514(ndr, "info1514", r->info1514);
12199 : }
12200 0 : ndr->depth--;
12201 0 : break;
12202 :
12203 0 : case 1515:
12204 0 : ndr_print_ptr(ndr, "info1515", r->info1515);
12205 0 : ndr->depth++;
12206 0 : if (r->info1515) {
12207 0 : ndr_print_srvsvc_NetSrvInfo1515(ndr, "info1515", r->info1515);
12208 : }
12209 0 : ndr->depth--;
12210 0 : break;
12211 :
12212 0 : case 1516:
12213 0 : ndr_print_ptr(ndr, "info1516", r->info1516);
12214 0 : ndr->depth++;
12215 0 : if (r->info1516) {
12216 0 : ndr_print_srvsvc_NetSrvInfo1516(ndr, "info1516", r->info1516);
12217 : }
12218 0 : ndr->depth--;
12219 0 : break;
12220 :
12221 0 : case 1518:
12222 0 : ndr_print_ptr(ndr, "info1518", r->info1518);
12223 0 : ndr->depth++;
12224 0 : if (r->info1518) {
12225 0 : ndr_print_srvsvc_NetSrvInfo1518(ndr, "info1518", r->info1518);
12226 : }
12227 0 : ndr->depth--;
12228 0 : break;
12229 :
12230 0 : case 1520:
12231 0 : ndr_print_ptr(ndr, "info1520", r->info1520);
12232 0 : ndr->depth++;
12233 0 : if (r->info1520) {
12234 0 : ndr_print_srvsvc_NetSrvInfo1520(ndr, "info1520", r->info1520);
12235 : }
12236 0 : ndr->depth--;
12237 0 : break;
12238 :
12239 0 : case 1521:
12240 0 : ndr_print_ptr(ndr, "info1521", r->info1521);
12241 0 : ndr->depth++;
12242 0 : if (r->info1521) {
12243 0 : ndr_print_srvsvc_NetSrvInfo1521(ndr, "info1521", r->info1521);
12244 : }
12245 0 : ndr->depth--;
12246 0 : break;
12247 :
12248 0 : case 1522:
12249 0 : ndr_print_ptr(ndr, "info1522", r->info1522);
12250 0 : ndr->depth++;
12251 0 : if (r->info1522) {
12252 0 : ndr_print_srvsvc_NetSrvInfo1522(ndr, "info1522", r->info1522);
12253 : }
12254 0 : ndr->depth--;
12255 0 : break;
12256 :
12257 0 : case 1523:
12258 0 : ndr_print_ptr(ndr, "info1523", r->info1523);
12259 0 : ndr->depth++;
12260 0 : if (r->info1523) {
12261 0 : ndr_print_srvsvc_NetSrvInfo1523(ndr, "info1523", r->info1523);
12262 : }
12263 0 : ndr->depth--;
12264 0 : break;
12265 :
12266 0 : case 1524:
12267 0 : ndr_print_ptr(ndr, "info1524", r->info1524);
12268 0 : ndr->depth++;
12269 0 : if (r->info1524) {
12270 0 : ndr_print_srvsvc_NetSrvInfo1524(ndr, "info1524", r->info1524);
12271 : }
12272 0 : ndr->depth--;
12273 0 : break;
12274 :
12275 0 : case 1525:
12276 0 : ndr_print_ptr(ndr, "info1525", r->info1525);
12277 0 : ndr->depth++;
12278 0 : if (r->info1525) {
12279 0 : ndr_print_srvsvc_NetSrvInfo1525(ndr, "info1525", r->info1525);
12280 : }
12281 0 : ndr->depth--;
12282 0 : break;
12283 :
12284 0 : case 1528:
12285 0 : ndr_print_ptr(ndr, "info1528", r->info1528);
12286 0 : ndr->depth++;
12287 0 : if (r->info1528) {
12288 0 : ndr_print_srvsvc_NetSrvInfo1528(ndr, "info1528", r->info1528);
12289 : }
12290 0 : ndr->depth--;
12291 0 : break;
12292 :
12293 0 : case 1529:
12294 0 : ndr_print_ptr(ndr, "info1529", r->info1529);
12295 0 : ndr->depth++;
12296 0 : if (r->info1529) {
12297 0 : ndr_print_srvsvc_NetSrvInfo1529(ndr, "info1529", r->info1529);
12298 : }
12299 0 : ndr->depth--;
12300 0 : break;
12301 :
12302 0 : case 1530:
12303 0 : ndr_print_ptr(ndr, "info1530", r->info1530);
12304 0 : ndr->depth++;
12305 0 : if (r->info1530) {
12306 0 : ndr_print_srvsvc_NetSrvInfo1530(ndr, "info1530", r->info1530);
12307 : }
12308 0 : ndr->depth--;
12309 0 : break;
12310 :
12311 0 : case 1533:
12312 0 : ndr_print_ptr(ndr, "info1533", r->info1533);
12313 0 : ndr->depth++;
12314 0 : if (r->info1533) {
12315 0 : ndr_print_srvsvc_NetSrvInfo1533(ndr, "info1533", r->info1533);
12316 : }
12317 0 : ndr->depth--;
12318 0 : break;
12319 :
12320 0 : case 1534:
12321 0 : ndr_print_ptr(ndr, "info1534", r->info1534);
12322 0 : ndr->depth++;
12323 0 : if (r->info1534) {
12324 0 : ndr_print_srvsvc_NetSrvInfo1534(ndr, "info1534", r->info1534);
12325 : }
12326 0 : ndr->depth--;
12327 0 : break;
12328 :
12329 0 : case 1535:
12330 0 : ndr_print_ptr(ndr, "info1535", r->info1535);
12331 0 : ndr->depth++;
12332 0 : if (r->info1535) {
12333 0 : ndr_print_srvsvc_NetSrvInfo1535(ndr, "info1535", r->info1535);
12334 : }
12335 0 : ndr->depth--;
12336 0 : break;
12337 :
12338 0 : case 1536:
12339 0 : ndr_print_ptr(ndr, "info1536", r->info1536);
12340 0 : ndr->depth++;
12341 0 : if (r->info1536) {
12342 0 : ndr_print_srvsvc_NetSrvInfo1536(ndr, "info1536", r->info1536);
12343 : }
12344 0 : ndr->depth--;
12345 0 : break;
12346 :
12347 0 : case 1537:
12348 0 : ndr_print_ptr(ndr, "info1537", r->info1537);
12349 0 : ndr->depth++;
12350 0 : if (r->info1537) {
12351 0 : ndr_print_srvsvc_NetSrvInfo1537(ndr, "info1537", r->info1537);
12352 : }
12353 0 : ndr->depth--;
12354 0 : break;
12355 :
12356 0 : case 1538:
12357 0 : ndr_print_ptr(ndr, "info1538", r->info1538);
12358 0 : ndr->depth++;
12359 0 : if (r->info1538) {
12360 0 : ndr_print_srvsvc_NetSrvInfo1538(ndr, "info1538", r->info1538);
12361 : }
12362 0 : ndr->depth--;
12363 0 : break;
12364 :
12365 0 : case 1539:
12366 0 : ndr_print_ptr(ndr, "info1539", r->info1539);
12367 0 : ndr->depth++;
12368 0 : if (r->info1539) {
12369 0 : ndr_print_srvsvc_NetSrvInfo1539(ndr, "info1539", r->info1539);
12370 : }
12371 0 : ndr->depth--;
12372 0 : break;
12373 :
12374 0 : case 1540:
12375 0 : ndr_print_ptr(ndr, "info1540", r->info1540);
12376 0 : ndr->depth++;
12377 0 : if (r->info1540) {
12378 0 : ndr_print_srvsvc_NetSrvInfo1540(ndr, "info1540", r->info1540);
12379 : }
12380 0 : ndr->depth--;
12381 0 : break;
12382 :
12383 0 : case 1541:
12384 0 : ndr_print_ptr(ndr, "info1541", r->info1541);
12385 0 : ndr->depth++;
12386 0 : if (r->info1541) {
12387 0 : ndr_print_srvsvc_NetSrvInfo1541(ndr, "info1541", r->info1541);
12388 : }
12389 0 : ndr->depth--;
12390 0 : break;
12391 :
12392 0 : case 1542:
12393 0 : ndr_print_ptr(ndr, "info1542", r->info1542);
12394 0 : ndr->depth++;
12395 0 : if (r->info1542) {
12396 0 : ndr_print_srvsvc_NetSrvInfo1542(ndr, "info1542", r->info1542);
12397 : }
12398 0 : ndr->depth--;
12399 0 : break;
12400 :
12401 0 : case 1543:
12402 0 : ndr_print_ptr(ndr, "info1543", r->info1543);
12403 0 : ndr->depth++;
12404 0 : if (r->info1543) {
12405 0 : ndr_print_srvsvc_NetSrvInfo1543(ndr, "info1543", r->info1543);
12406 : }
12407 0 : ndr->depth--;
12408 0 : break;
12409 :
12410 0 : case 1544:
12411 0 : ndr_print_ptr(ndr, "info1544", r->info1544);
12412 0 : ndr->depth++;
12413 0 : if (r->info1544) {
12414 0 : ndr_print_srvsvc_NetSrvInfo1544(ndr, "info1544", r->info1544);
12415 : }
12416 0 : ndr->depth--;
12417 0 : break;
12418 :
12419 0 : case 1545:
12420 0 : ndr_print_ptr(ndr, "info1545", r->info1545);
12421 0 : ndr->depth++;
12422 0 : if (r->info1545) {
12423 0 : ndr_print_srvsvc_NetSrvInfo1545(ndr, "info1545", r->info1545);
12424 : }
12425 0 : ndr->depth--;
12426 0 : break;
12427 :
12428 0 : case 1546:
12429 0 : ndr_print_ptr(ndr, "info1546", r->info1546);
12430 0 : ndr->depth++;
12431 0 : if (r->info1546) {
12432 0 : ndr_print_srvsvc_NetSrvInfo1546(ndr, "info1546", r->info1546);
12433 : }
12434 0 : ndr->depth--;
12435 0 : break;
12436 :
12437 0 : case 1547:
12438 0 : ndr_print_ptr(ndr, "info1547", r->info1547);
12439 0 : ndr->depth++;
12440 0 : if (r->info1547) {
12441 0 : ndr_print_srvsvc_NetSrvInfo1547(ndr, "info1547", r->info1547);
12442 : }
12443 0 : ndr->depth--;
12444 0 : break;
12445 :
12446 0 : case 1548:
12447 0 : ndr_print_ptr(ndr, "info1548", r->info1548);
12448 0 : ndr->depth++;
12449 0 : if (r->info1548) {
12450 0 : ndr_print_srvsvc_NetSrvInfo1548(ndr, "info1548", r->info1548);
12451 : }
12452 0 : ndr->depth--;
12453 0 : break;
12454 :
12455 0 : case 1549:
12456 0 : ndr_print_ptr(ndr, "info1549", r->info1549);
12457 0 : ndr->depth++;
12458 0 : if (r->info1549) {
12459 0 : ndr_print_srvsvc_NetSrvInfo1549(ndr, "info1549", r->info1549);
12460 : }
12461 0 : ndr->depth--;
12462 0 : break;
12463 :
12464 0 : case 1550:
12465 0 : ndr_print_ptr(ndr, "info1550", r->info1550);
12466 0 : ndr->depth++;
12467 0 : if (r->info1550) {
12468 0 : ndr_print_srvsvc_NetSrvInfo1550(ndr, "info1550", r->info1550);
12469 : }
12470 0 : ndr->depth--;
12471 0 : break;
12472 :
12473 0 : case 1552:
12474 0 : ndr_print_ptr(ndr, "info1552", r->info1552);
12475 0 : ndr->depth++;
12476 0 : if (r->info1552) {
12477 0 : ndr_print_srvsvc_NetSrvInfo1552(ndr, "info1552", r->info1552);
12478 : }
12479 0 : ndr->depth--;
12480 0 : break;
12481 :
12482 0 : case 1553:
12483 0 : ndr_print_ptr(ndr, "info1553", r->info1553);
12484 0 : ndr->depth++;
12485 0 : if (r->info1553) {
12486 0 : ndr_print_srvsvc_NetSrvInfo1553(ndr, "info1553", r->info1553);
12487 : }
12488 0 : ndr->depth--;
12489 0 : break;
12490 :
12491 0 : case 1554:
12492 0 : ndr_print_ptr(ndr, "info1554", r->info1554);
12493 0 : ndr->depth++;
12494 0 : if (r->info1554) {
12495 0 : ndr_print_srvsvc_NetSrvInfo1554(ndr, "info1554", r->info1554);
12496 : }
12497 0 : ndr->depth--;
12498 0 : break;
12499 :
12500 0 : case 1555:
12501 0 : ndr_print_ptr(ndr, "info1555", r->info1555);
12502 0 : ndr->depth++;
12503 0 : if (r->info1555) {
12504 0 : ndr_print_srvsvc_NetSrvInfo1555(ndr, "info1555", r->info1555);
12505 : }
12506 0 : ndr->depth--;
12507 0 : break;
12508 :
12509 0 : case 1556:
12510 0 : ndr_print_ptr(ndr, "info1556", r->info1556);
12511 0 : ndr->depth++;
12512 0 : if (r->info1556) {
12513 0 : ndr_print_srvsvc_NetSrvInfo1556(ndr, "info1556", r->info1556);
12514 : }
12515 0 : ndr->depth--;
12516 0 : break;
12517 :
12518 0 : default:
12519 0 : break;
12520 :
12521 : }
12522 10 : }
12523 :
12524 18 : static enum ndr_err_code ndr_push_srvsvc_NetDiskInfo0(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct srvsvc_NetDiskInfo0 *r)
12525 : {
12526 18 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
12527 18 : if (ndr_flags & NDR_SCALARS) {
12528 18 : NDR_CHECK(ndr_push_align(ndr, 4));
12529 18 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, 0));
12530 18 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, strlen(r->disk) + 1));
12531 18 : NDR_CHECK(ndr_push_charset(ndr, NDR_SCALARS, r->disk, strlen(r->disk) + 1, sizeof(uint16_t), CH_UTF16));
12532 18 : NDR_CHECK(ndr_push_trailer_align(ndr, 4));
12533 : }
12534 18 : if (ndr_flags & NDR_BUFFERS) {
12535 0 : }
12536 18 : return NDR_ERR_SUCCESS;
12537 : }
12538 :
12539 16 : static enum ndr_err_code ndr_pull_srvsvc_NetDiskInfo0(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct srvsvc_NetDiskInfo0 *r)
12540 : {
12541 16 : uint32_t size_disk_0 = 0;
12542 16 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
12543 16 : if (ndr_flags & NDR_SCALARS) {
12544 16 : NDR_CHECK(ndr_pull_align(ndr, 4));
12545 16 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->__disk_offset));
12546 16 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->__disk_length));
12547 16 : size_disk_0 = r->__disk_length;
12548 16 : NDR_CHECK(ndr_pull_charset(ndr, NDR_SCALARS, &r->disk, size_disk_0, sizeof(uint16_t), CH_UTF16));
12549 16 : NDR_CHECK(ndr_pull_trailer_align(ndr, 4));
12550 : }
12551 16 : if (ndr_flags & NDR_BUFFERS) {
12552 0 : }
12553 16 : return NDR_ERR_SUCCESS;
12554 : }
12555 :
12556 4 : _PUBLIC_ void ndr_print_srvsvc_NetDiskInfo0(struct ndr_print *ndr, const char *name, const struct srvsvc_NetDiskInfo0 *r)
12557 : {
12558 4 : ndr_print_struct(ndr, name, "srvsvc_NetDiskInfo0");
12559 4 : if (r == NULL) { ndr_print_null(ndr); return; }
12560 4 : ndr->depth++;
12561 4 : ndr_print_uint32(ndr, "__disk_offset", (ndr->flags & LIBNDR_PRINT_SET_VALUES)?0:r->__disk_offset);
12562 4 : ndr_print_uint32(ndr, "__disk_length", (ndr->flags & LIBNDR_PRINT_SET_VALUES)?strlen(r->disk) + 1:r->__disk_length);
12563 4 : ndr_print_string(ndr, "disk", r->disk);
12564 4 : ndr->depth--;
12565 : }
12566 :
12567 17 : static enum ndr_err_code ndr_push_srvsvc_NetDiskInfo(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct srvsvc_NetDiskInfo *r)
12568 : {
12569 0 : uint32_t cntr_disks_1;
12570 17 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
12571 17 : if (ndr_flags & NDR_SCALARS) {
12572 17 : NDR_CHECK(ndr_push_align(ndr, 5));
12573 17 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->count));
12574 17 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->disks));
12575 17 : NDR_CHECK(ndr_push_trailer_align(ndr, 5));
12576 : }
12577 17 : if (ndr_flags & NDR_BUFFERS) {
12578 17 : if (r->disks) {
12579 9 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, r->count));
12580 9 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, 0));
12581 9 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, r->count));
12582 27 : for (cntr_disks_1 = 0; cntr_disks_1 < (r->count); cntr_disks_1++) {
12583 18 : NDR_CHECK(ndr_push_srvsvc_NetDiskInfo0(ndr, NDR_SCALARS, &r->disks[cntr_disks_1]));
12584 : }
12585 : }
12586 : }
12587 17 : return NDR_ERR_SUCCESS;
12588 : }
12589 :
12590 16 : static enum ndr_err_code ndr_pull_srvsvc_NetDiskInfo(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct srvsvc_NetDiskInfo *r)
12591 : {
12592 0 : uint32_t _ptr_disks;
12593 16 : uint32_t size_disks_1 = 0;
12594 16 : uint32_t length_disks_1 = 0;
12595 0 : uint32_t cntr_disks_1;
12596 16 : TALLOC_CTX *_mem_save_disks_0 = NULL;
12597 16 : TALLOC_CTX *_mem_save_disks_1 = NULL;
12598 16 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
12599 16 : if (ndr_flags & NDR_SCALARS) {
12600 16 : NDR_CHECK(ndr_pull_align(ndr, 5));
12601 16 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->count));
12602 16 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_disks));
12603 16 : if (_ptr_disks) {
12604 8 : NDR_PULL_ALLOC(ndr, r->disks);
12605 : } else {
12606 8 : r->disks = NULL;
12607 : }
12608 16 : NDR_CHECK(ndr_pull_trailer_align(ndr, 5));
12609 : }
12610 16 : if (ndr_flags & NDR_BUFFERS) {
12611 16 : if (r->disks) {
12612 8 : _mem_save_disks_0 = NDR_PULL_GET_MEM_CTX(ndr);
12613 8 : NDR_PULL_SET_MEM_CTX(ndr, r->disks, 0);
12614 8 : NDR_CHECK(ndr_pull_array_size(ndr, &r->disks));
12615 8 : NDR_CHECK(ndr_pull_array_length(ndr, &r->disks));
12616 8 : NDR_CHECK(ndr_get_array_size(ndr, (void*)&r->disks, &size_disks_1));
12617 8 : NDR_CHECK(ndr_get_array_length(ndr, (void*)&r->disks, &length_disks_1));
12618 8 : if (length_disks_1 > size_disks_1) {
12619 0 : return ndr_pull_error(ndr, NDR_ERR_ARRAY_SIZE, "Bad array size %"PRIu32": should exceed array length %"PRIu32"", size_disks_1, length_disks_1);
12620 : }
12621 8 : NDR_PULL_ALLOC_N(ndr, r->disks, size_disks_1);
12622 8 : _mem_save_disks_1 = NDR_PULL_GET_MEM_CTX(ndr);
12623 8 : NDR_PULL_SET_MEM_CTX(ndr, r->disks, 0);
12624 24 : for (cntr_disks_1 = 0; cntr_disks_1 < (length_disks_1); cntr_disks_1++) {
12625 16 : NDR_CHECK(ndr_pull_srvsvc_NetDiskInfo0(ndr, NDR_SCALARS, &r->disks[cntr_disks_1]));
12626 : }
12627 8 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_disks_1, 0);
12628 8 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_disks_0, 0);
12629 : }
12630 16 : if (r->disks) {
12631 8 : NDR_CHECK(ndr_check_steal_array_size(ndr, (void*)&r->disks, r->count));
12632 : }
12633 16 : if (r->disks) {
12634 8 : NDR_CHECK(ndr_check_steal_array_length(ndr, (void*)&r->disks, r->count));
12635 : }
12636 : }
12637 16 : return NDR_ERR_SUCCESS;
12638 : }
12639 :
12640 2 : _PUBLIC_ void ndr_print_srvsvc_NetDiskInfo(struct ndr_print *ndr, const char *name, const struct srvsvc_NetDiskInfo *r)
12641 : {
12642 0 : uint32_t cntr_disks_1;
12643 2 : ndr_print_struct(ndr, name, "srvsvc_NetDiskInfo");
12644 2 : if (r == NULL) { ndr_print_null(ndr); return; }
12645 2 : ndr->depth++;
12646 2 : ndr_print_uint32(ndr, "count", r->count);
12647 2 : ndr_print_ptr(ndr, "disks", r->disks);
12648 2 : ndr->depth++;
12649 2 : if (r->disks) {
12650 2 : ndr->print(ndr, "%s: ARRAY(%"PRIu32")", "disks", (uint32_t)(r->count));
12651 2 : ndr->depth++;
12652 6 : for (cntr_disks_1 = 0; cntr_disks_1 < (r->count); cntr_disks_1++) {
12653 4 : ndr_print_srvsvc_NetDiskInfo0(ndr, "disks", &r->disks[cntr_disks_1]);
12654 : }
12655 2 : ndr->depth--;
12656 : }
12657 2 : ndr->depth--;
12658 2 : ndr->depth--;
12659 : }
12660 :
12661 0 : static enum ndr_err_code ndr_push_srvsvc_Statistics(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct srvsvc_Statistics *r)
12662 : {
12663 0 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
12664 0 : if (ndr_flags & NDR_SCALARS) {
12665 0 : NDR_CHECK(ndr_push_align(ndr, 4));
12666 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->start));
12667 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->fopens));
12668 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->devopens));
12669 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->jobsqueued));
12670 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->sopens));
12671 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->stimeouts));
12672 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->serrorout));
12673 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->pwerrors));
12674 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->permerrors));
12675 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->syserrors));
12676 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->bytessent_low));
12677 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->bytessent_high));
12678 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->bytesrcvd_low));
12679 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->bytesrcvd_high));
12680 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->avresponse));
12681 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->reqbufneed));
12682 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->bigbufneed));
12683 0 : NDR_CHECK(ndr_push_trailer_align(ndr, 4));
12684 : }
12685 0 : if (ndr_flags & NDR_BUFFERS) {
12686 0 : }
12687 0 : return NDR_ERR_SUCCESS;
12688 : }
12689 :
12690 0 : static enum ndr_err_code ndr_pull_srvsvc_Statistics(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct srvsvc_Statistics *r)
12691 : {
12692 0 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
12693 0 : if (ndr_flags & NDR_SCALARS) {
12694 0 : NDR_CHECK(ndr_pull_align(ndr, 4));
12695 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->start));
12696 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->fopens));
12697 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->devopens));
12698 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->jobsqueued));
12699 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->sopens));
12700 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->stimeouts));
12701 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->serrorout));
12702 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->pwerrors));
12703 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->permerrors));
12704 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->syserrors));
12705 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->bytessent_low));
12706 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->bytessent_high));
12707 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->bytesrcvd_low));
12708 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->bytesrcvd_high));
12709 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->avresponse));
12710 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->reqbufneed));
12711 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->bigbufneed));
12712 0 : NDR_CHECK(ndr_pull_trailer_align(ndr, 4));
12713 : }
12714 0 : if (ndr_flags & NDR_BUFFERS) {
12715 0 : }
12716 0 : return NDR_ERR_SUCCESS;
12717 : }
12718 :
12719 0 : _PUBLIC_ void ndr_print_srvsvc_Statistics(struct ndr_print *ndr, const char *name, const struct srvsvc_Statistics *r)
12720 : {
12721 0 : ndr_print_struct(ndr, name, "srvsvc_Statistics");
12722 0 : if (r == NULL) { ndr_print_null(ndr); return; }
12723 0 : ndr->depth++;
12724 0 : ndr_print_uint32(ndr, "start", r->start);
12725 0 : ndr_print_uint32(ndr, "fopens", r->fopens);
12726 0 : ndr_print_uint32(ndr, "devopens", r->devopens);
12727 0 : ndr_print_uint32(ndr, "jobsqueued", r->jobsqueued);
12728 0 : ndr_print_uint32(ndr, "sopens", r->sopens);
12729 0 : ndr_print_uint32(ndr, "stimeouts", r->stimeouts);
12730 0 : ndr_print_uint32(ndr, "serrorout", r->serrorout);
12731 0 : ndr_print_uint32(ndr, "pwerrors", r->pwerrors);
12732 0 : ndr_print_uint32(ndr, "permerrors", r->permerrors);
12733 0 : ndr_print_uint32(ndr, "syserrors", r->syserrors);
12734 0 : ndr_print_uint32(ndr, "bytessent_low", r->bytessent_low);
12735 0 : ndr_print_uint32(ndr, "bytessent_high", r->bytessent_high);
12736 0 : ndr_print_uint32(ndr, "bytesrcvd_low", r->bytesrcvd_low);
12737 0 : ndr_print_uint32(ndr, "bytesrcvd_high", r->bytesrcvd_high);
12738 0 : ndr_print_uint32(ndr, "avresponse", r->avresponse);
12739 0 : ndr_print_uint32(ndr, "reqbufneed", r->reqbufneed);
12740 0 : ndr_print_uint32(ndr, "bigbufneed", r->bigbufneed);
12741 0 : ndr->depth--;
12742 : }
12743 :
12744 0 : static enum ndr_err_code ndr_push_srvsvc_NetTransportInfo0(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct srvsvc_NetTransportInfo0 *r)
12745 : {
12746 0 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
12747 0 : if (ndr_flags & NDR_SCALARS) {
12748 0 : NDR_CHECK(ndr_push_align(ndr, 5));
12749 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->vcs));
12750 0 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->name));
12751 0 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->addr));
12752 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->addr_len));
12753 0 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->net_addr));
12754 0 : NDR_CHECK(ndr_push_trailer_align(ndr, 5));
12755 : }
12756 0 : if (ndr_flags & NDR_BUFFERS) {
12757 0 : if (r->name) {
12758 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->name, CH_UTF16)));
12759 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, 0));
12760 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->name, CH_UTF16)));
12761 0 : NDR_CHECK(ndr_push_charset(ndr, NDR_SCALARS, r->name, ndr_charset_length(r->name, CH_UTF16), sizeof(uint16_t), CH_UTF16));
12762 : }
12763 0 : if (r->addr) {
12764 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, r->addr_len));
12765 0 : NDR_CHECK(ndr_push_array_uint8(ndr, NDR_SCALARS, r->addr, r->addr_len));
12766 : }
12767 0 : if (r->net_addr) {
12768 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->net_addr, CH_UTF16)));
12769 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, 0));
12770 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->net_addr, CH_UTF16)));
12771 0 : NDR_CHECK(ndr_push_charset(ndr, NDR_SCALARS, r->net_addr, ndr_charset_length(r->net_addr, CH_UTF16), sizeof(uint16_t), CH_UTF16));
12772 : }
12773 : }
12774 0 : return NDR_ERR_SUCCESS;
12775 : }
12776 :
12777 0 : static enum ndr_err_code ndr_pull_srvsvc_NetTransportInfo0(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct srvsvc_NetTransportInfo0 *r)
12778 : {
12779 0 : uint32_t _ptr_name;
12780 0 : uint32_t size_name_1 = 0;
12781 0 : uint32_t length_name_1 = 0;
12782 0 : TALLOC_CTX *_mem_save_name_0 = NULL;
12783 0 : uint32_t _ptr_addr;
12784 0 : uint32_t size_addr_1 = 0;
12785 0 : TALLOC_CTX *_mem_save_addr_0 = NULL;
12786 0 : uint32_t _ptr_net_addr;
12787 0 : uint32_t size_net_addr_1 = 0;
12788 0 : uint32_t length_net_addr_1 = 0;
12789 0 : TALLOC_CTX *_mem_save_net_addr_0 = NULL;
12790 0 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
12791 0 : if (ndr_flags & NDR_SCALARS) {
12792 0 : NDR_CHECK(ndr_pull_align(ndr, 5));
12793 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->vcs));
12794 0 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_name));
12795 0 : if (_ptr_name) {
12796 0 : NDR_PULL_ALLOC(ndr, r->name);
12797 : } else {
12798 0 : r->name = NULL;
12799 : }
12800 0 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_addr));
12801 0 : if (_ptr_addr) {
12802 0 : NDR_PULL_ALLOC(ndr, r->addr);
12803 : } else {
12804 0 : r->addr = NULL;
12805 : }
12806 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->addr_len));
12807 0 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_net_addr));
12808 0 : if (_ptr_net_addr) {
12809 0 : NDR_PULL_ALLOC(ndr, r->net_addr);
12810 : } else {
12811 0 : r->net_addr = NULL;
12812 : }
12813 0 : NDR_CHECK(ndr_pull_trailer_align(ndr, 5));
12814 : }
12815 0 : if (ndr_flags & NDR_BUFFERS) {
12816 0 : if (r->name) {
12817 0 : _mem_save_name_0 = NDR_PULL_GET_MEM_CTX(ndr);
12818 0 : NDR_PULL_SET_MEM_CTX(ndr, r->name, 0);
12819 0 : NDR_CHECK(ndr_pull_array_size(ndr, &r->name));
12820 0 : NDR_CHECK(ndr_pull_array_length(ndr, &r->name));
12821 0 : NDR_CHECK(ndr_steal_array_size(ndr, (void*)&r->name, &size_name_1));
12822 0 : NDR_CHECK(ndr_steal_array_length(ndr, (void*)&r->name, &length_name_1));
12823 0 : if (length_name_1 > size_name_1) {
12824 0 : return ndr_pull_error(ndr, NDR_ERR_ARRAY_SIZE, "Bad array size %"PRIu32": should exceed array length %"PRIu32"", size_name_1, length_name_1);
12825 : }
12826 0 : NDR_CHECK(ndr_check_string_terminator(ndr, length_name_1, sizeof(uint16_t)));
12827 0 : NDR_CHECK(ndr_pull_charset(ndr, NDR_SCALARS, &r->name, length_name_1, sizeof(uint16_t), CH_UTF16));
12828 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_name_0, 0);
12829 : }
12830 0 : if (r->addr) {
12831 0 : _mem_save_addr_0 = NDR_PULL_GET_MEM_CTX(ndr);
12832 0 : NDR_PULL_SET_MEM_CTX(ndr, r->addr, 0);
12833 0 : NDR_CHECK(ndr_pull_array_size(ndr, &r->addr));
12834 0 : NDR_CHECK(ndr_get_array_size(ndr, (void*)&r->addr, &size_addr_1));
12835 0 : NDR_PULL_ALLOC_N(ndr, r->addr, size_addr_1);
12836 0 : NDR_CHECK(ndr_pull_array_uint8(ndr, NDR_SCALARS, r->addr, size_addr_1));
12837 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_addr_0, 0);
12838 : }
12839 0 : if (r->net_addr) {
12840 0 : _mem_save_net_addr_0 = NDR_PULL_GET_MEM_CTX(ndr);
12841 0 : NDR_PULL_SET_MEM_CTX(ndr, r->net_addr, 0);
12842 0 : NDR_CHECK(ndr_pull_array_size(ndr, &r->net_addr));
12843 0 : NDR_CHECK(ndr_pull_array_length(ndr, &r->net_addr));
12844 0 : NDR_CHECK(ndr_steal_array_size(ndr, (void*)&r->net_addr, &size_net_addr_1));
12845 0 : NDR_CHECK(ndr_steal_array_length(ndr, (void*)&r->net_addr, &length_net_addr_1));
12846 0 : if (length_net_addr_1 > size_net_addr_1) {
12847 0 : return ndr_pull_error(ndr, NDR_ERR_ARRAY_SIZE, "Bad array size %"PRIu32": should exceed array length %"PRIu32"", size_net_addr_1, length_net_addr_1);
12848 : }
12849 0 : NDR_CHECK(ndr_check_string_terminator(ndr, length_net_addr_1, sizeof(uint16_t)));
12850 0 : NDR_CHECK(ndr_pull_charset(ndr, NDR_SCALARS, &r->net_addr, length_net_addr_1, sizeof(uint16_t), CH_UTF16));
12851 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_net_addr_0, 0);
12852 : }
12853 0 : if (r->addr) {
12854 0 : NDR_CHECK(ndr_check_steal_array_size(ndr, (void*)&r->addr, r->addr_len));
12855 : }
12856 : }
12857 0 : return NDR_ERR_SUCCESS;
12858 : }
12859 :
12860 0 : _PUBLIC_ void ndr_print_srvsvc_NetTransportInfo0(struct ndr_print *ndr, const char *name, const struct srvsvc_NetTransportInfo0 *r)
12861 : {
12862 0 : ndr_print_struct(ndr, name, "srvsvc_NetTransportInfo0");
12863 0 : if (r == NULL) { ndr_print_null(ndr); return; }
12864 0 : ndr->depth++;
12865 0 : ndr_print_uint32(ndr, "vcs", r->vcs);
12866 0 : ndr_print_ptr(ndr, "name", r->name);
12867 0 : ndr->depth++;
12868 0 : if (r->name) {
12869 0 : ndr_print_string(ndr, "name", r->name);
12870 : }
12871 0 : ndr->depth--;
12872 0 : ndr_print_ptr(ndr, "addr", r->addr);
12873 0 : ndr->depth++;
12874 0 : if (r->addr) {
12875 0 : ndr_print_array_uint8(ndr, "addr", r->addr, r->addr_len);
12876 : }
12877 0 : ndr->depth--;
12878 0 : ndr_print_uint32(ndr, "addr_len", r->addr_len);
12879 0 : ndr_print_ptr(ndr, "net_addr", r->net_addr);
12880 0 : ndr->depth++;
12881 0 : if (r->net_addr) {
12882 0 : ndr_print_string(ndr, "net_addr", r->net_addr);
12883 : }
12884 0 : ndr->depth--;
12885 0 : ndr->depth--;
12886 : }
12887 :
12888 13 : static enum ndr_err_code ndr_push_srvsvc_NetTransportCtr0(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct srvsvc_NetTransportCtr0 *r)
12889 : {
12890 0 : uint32_t cntr_array_1;
12891 13 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
12892 13 : if (ndr_flags & NDR_SCALARS) {
12893 13 : NDR_CHECK(ndr_push_align(ndr, 5));
12894 13 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->count));
12895 13 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->array));
12896 13 : NDR_CHECK(ndr_push_trailer_align(ndr, 5));
12897 : }
12898 13 : if (ndr_flags & NDR_BUFFERS) {
12899 13 : if (r->array) {
12900 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, r->count));
12901 0 : for (cntr_array_1 = 0; cntr_array_1 < (r->count); cntr_array_1++) {
12902 0 : NDR_CHECK(ndr_push_srvsvc_NetTransportInfo0(ndr, NDR_SCALARS, &r->array[cntr_array_1]));
12903 : }
12904 0 : for (cntr_array_1 = 0; cntr_array_1 < (r->count); cntr_array_1++) {
12905 0 : NDR_CHECK(ndr_push_srvsvc_NetTransportInfo0(ndr, NDR_BUFFERS, &r->array[cntr_array_1]));
12906 : }
12907 : }
12908 : }
12909 13 : return NDR_ERR_SUCCESS;
12910 : }
12911 :
12912 12 : static enum ndr_err_code ndr_pull_srvsvc_NetTransportCtr0(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct srvsvc_NetTransportCtr0 *r)
12913 : {
12914 0 : uint32_t _ptr_array;
12915 12 : uint32_t size_array_1 = 0;
12916 0 : uint32_t cntr_array_1;
12917 12 : TALLOC_CTX *_mem_save_array_0 = NULL;
12918 12 : TALLOC_CTX *_mem_save_array_1 = NULL;
12919 12 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
12920 12 : if (ndr_flags & NDR_SCALARS) {
12921 12 : NDR_CHECK(ndr_pull_align(ndr, 5));
12922 12 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->count));
12923 12 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_array));
12924 12 : if (_ptr_array) {
12925 0 : NDR_PULL_ALLOC(ndr, r->array);
12926 : } else {
12927 12 : r->array = NULL;
12928 : }
12929 12 : NDR_CHECK(ndr_pull_trailer_align(ndr, 5));
12930 : }
12931 12 : if (ndr_flags & NDR_BUFFERS) {
12932 12 : if (r->array) {
12933 0 : _mem_save_array_0 = NDR_PULL_GET_MEM_CTX(ndr);
12934 0 : NDR_PULL_SET_MEM_CTX(ndr, r->array, 0);
12935 0 : NDR_CHECK(ndr_pull_array_size(ndr, &r->array));
12936 0 : NDR_CHECK(ndr_get_array_size(ndr, (void*)&r->array, &size_array_1));
12937 0 : NDR_PULL_ALLOC_N(ndr, r->array, size_array_1);
12938 0 : _mem_save_array_1 = NDR_PULL_GET_MEM_CTX(ndr);
12939 0 : NDR_PULL_SET_MEM_CTX(ndr, r->array, 0);
12940 0 : for (cntr_array_1 = 0; cntr_array_1 < (size_array_1); cntr_array_1++) {
12941 0 : NDR_CHECK(ndr_pull_srvsvc_NetTransportInfo0(ndr, NDR_SCALARS, &r->array[cntr_array_1]));
12942 : }
12943 0 : for (cntr_array_1 = 0; cntr_array_1 < (size_array_1); cntr_array_1++) {
12944 0 : NDR_CHECK(ndr_pull_srvsvc_NetTransportInfo0(ndr, NDR_BUFFERS, &r->array[cntr_array_1]));
12945 : }
12946 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_array_1, 0);
12947 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_array_0, 0);
12948 : }
12949 12 : if (r->array) {
12950 0 : NDR_CHECK(ndr_check_array_size(ndr, (void*)&r->array, r->count));
12951 : }
12952 12 : for (cntr_array_1 = 0; cntr_array_1 < (size_array_1); cntr_array_1++) {
12953 0 : }
12954 : }
12955 12 : return NDR_ERR_SUCCESS;
12956 : }
12957 :
12958 2 : _PUBLIC_ void ndr_print_srvsvc_NetTransportCtr0(struct ndr_print *ndr, const char *name, const struct srvsvc_NetTransportCtr0 *r)
12959 : {
12960 0 : uint32_t cntr_array_1;
12961 2 : ndr_print_struct(ndr, name, "srvsvc_NetTransportCtr0");
12962 2 : if (r == NULL) { ndr_print_null(ndr); return; }
12963 2 : ndr->depth++;
12964 2 : ndr_print_uint32(ndr, "count", r->count);
12965 2 : ndr_print_ptr(ndr, "array", r->array);
12966 2 : ndr->depth++;
12967 2 : if (r->array) {
12968 0 : ndr->print(ndr, "%s: ARRAY(%"PRIu32")", "array", (uint32_t)(r->count));
12969 0 : ndr->depth++;
12970 0 : for (cntr_array_1 = 0; cntr_array_1 < (r->count); cntr_array_1++) {
12971 0 : ndr_print_srvsvc_NetTransportInfo0(ndr, "array", &r->array[cntr_array_1]);
12972 : }
12973 0 : ndr->depth--;
12974 : }
12975 2 : ndr->depth--;
12976 2 : ndr->depth--;
12977 : }
12978 :
12979 0 : static enum ndr_err_code ndr_push_srvsvc_NetTransportInfo1(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct srvsvc_NetTransportInfo1 *r)
12980 : {
12981 0 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
12982 0 : if (ndr_flags & NDR_SCALARS) {
12983 0 : NDR_CHECK(ndr_push_align(ndr, 5));
12984 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->vcs));
12985 0 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->name));
12986 0 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->addr));
12987 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->addr_len));
12988 0 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->net_addr));
12989 0 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->domain));
12990 0 : NDR_CHECK(ndr_push_trailer_align(ndr, 5));
12991 : }
12992 0 : if (ndr_flags & NDR_BUFFERS) {
12993 0 : if (r->name) {
12994 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->name, CH_UTF16)));
12995 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, 0));
12996 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->name, CH_UTF16)));
12997 0 : NDR_CHECK(ndr_push_charset(ndr, NDR_SCALARS, r->name, ndr_charset_length(r->name, CH_UTF16), sizeof(uint16_t), CH_UTF16));
12998 : }
12999 0 : if (r->addr) {
13000 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, r->addr_len));
13001 0 : NDR_CHECK(ndr_push_array_uint8(ndr, NDR_SCALARS, r->addr, r->addr_len));
13002 : }
13003 0 : if (r->net_addr) {
13004 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->net_addr, CH_UTF16)));
13005 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, 0));
13006 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->net_addr, CH_UTF16)));
13007 0 : NDR_CHECK(ndr_push_charset(ndr, NDR_SCALARS, r->net_addr, ndr_charset_length(r->net_addr, CH_UTF16), sizeof(uint16_t), CH_UTF16));
13008 : }
13009 0 : if (r->domain) {
13010 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->domain, CH_UTF16)));
13011 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, 0));
13012 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->domain, CH_UTF16)));
13013 0 : NDR_CHECK(ndr_push_charset(ndr, NDR_SCALARS, r->domain, ndr_charset_length(r->domain, CH_UTF16), sizeof(uint16_t), CH_UTF16));
13014 : }
13015 : }
13016 0 : return NDR_ERR_SUCCESS;
13017 : }
13018 :
13019 0 : static enum ndr_err_code ndr_pull_srvsvc_NetTransportInfo1(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct srvsvc_NetTransportInfo1 *r)
13020 : {
13021 0 : uint32_t _ptr_name;
13022 0 : uint32_t size_name_1 = 0;
13023 0 : uint32_t length_name_1 = 0;
13024 0 : TALLOC_CTX *_mem_save_name_0 = NULL;
13025 0 : uint32_t _ptr_addr;
13026 0 : uint32_t size_addr_1 = 0;
13027 0 : TALLOC_CTX *_mem_save_addr_0 = NULL;
13028 0 : uint32_t _ptr_net_addr;
13029 0 : uint32_t size_net_addr_1 = 0;
13030 0 : uint32_t length_net_addr_1 = 0;
13031 0 : TALLOC_CTX *_mem_save_net_addr_0 = NULL;
13032 0 : uint32_t _ptr_domain;
13033 0 : uint32_t size_domain_1 = 0;
13034 0 : uint32_t length_domain_1 = 0;
13035 0 : TALLOC_CTX *_mem_save_domain_0 = NULL;
13036 0 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
13037 0 : if (ndr_flags & NDR_SCALARS) {
13038 0 : NDR_CHECK(ndr_pull_align(ndr, 5));
13039 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->vcs));
13040 0 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_name));
13041 0 : if (_ptr_name) {
13042 0 : NDR_PULL_ALLOC(ndr, r->name);
13043 : } else {
13044 0 : r->name = NULL;
13045 : }
13046 0 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_addr));
13047 0 : if (_ptr_addr) {
13048 0 : NDR_PULL_ALLOC(ndr, r->addr);
13049 : } else {
13050 0 : r->addr = NULL;
13051 : }
13052 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->addr_len));
13053 0 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_net_addr));
13054 0 : if (_ptr_net_addr) {
13055 0 : NDR_PULL_ALLOC(ndr, r->net_addr);
13056 : } else {
13057 0 : r->net_addr = NULL;
13058 : }
13059 0 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_domain));
13060 0 : if (_ptr_domain) {
13061 0 : NDR_PULL_ALLOC(ndr, r->domain);
13062 : } else {
13063 0 : r->domain = NULL;
13064 : }
13065 0 : NDR_CHECK(ndr_pull_trailer_align(ndr, 5));
13066 : }
13067 0 : if (ndr_flags & NDR_BUFFERS) {
13068 0 : if (r->name) {
13069 0 : _mem_save_name_0 = NDR_PULL_GET_MEM_CTX(ndr);
13070 0 : NDR_PULL_SET_MEM_CTX(ndr, r->name, 0);
13071 0 : NDR_CHECK(ndr_pull_array_size(ndr, &r->name));
13072 0 : NDR_CHECK(ndr_pull_array_length(ndr, &r->name));
13073 0 : NDR_CHECK(ndr_steal_array_size(ndr, (void*)&r->name, &size_name_1));
13074 0 : NDR_CHECK(ndr_steal_array_length(ndr, (void*)&r->name, &length_name_1));
13075 0 : if (length_name_1 > size_name_1) {
13076 0 : return ndr_pull_error(ndr, NDR_ERR_ARRAY_SIZE, "Bad array size %"PRIu32": should exceed array length %"PRIu32"", size_name_1, length_name_1);
13077 : }
13078 0 : NDR_CHECK(ndr_check_string_terminator(ndr, length_name_1, sizeof(uint16_t)));
13079 0 : NDR_CHECK(ndr_pull_charset(ndr, NDR_SCALARS, &r->name, length_name_1, sizeof(uint16_t), CH_UTF16));
13080 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_name_0, 0);
13081 : }
13082 0 : if (r->addr) {
13083 0 : _mem_save_addr_0 = NDR_PULL_GET_MEM_CTX(ndr);
13084 0 : NDR_PULL_SET_MEM_CTX(ndr, r->addr, 0);
13085 0 : NDR_CHECK(ndr_pull_array_size(ndr, &r->addr));
13086 0 : NDR_CHECK(ndr_get_array_size(ndr, (void*)&r->addr, &size_addr_1));
13087 0 : NDR_PULL_ALLOC_N(ndr, r->addr, size_addr_1);
13088 0 : NDR_CHECK(ndr_pull_array_uint8(ndr, NDR_SCALARS, r->addr, size_addr_1));
13089 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_addr_0, 0);
13090 : }
13091 0 : if (r->net_addr) {
13092 0 : _mem_save_net_addr_0 = NDR_PULL_GET_MEM_CTX(ndr);
13093 0 : NDR_PULL_SET_MEM_CTX(ndr, r->net_addr, 0);
13094 0 : NDR_CHECK(ndr_pull_array_size(ndr, &r->net_addr));
13095 0 : NDR_CHECK(ndr_pull_array_length(ndr, &r->net_addr));
13096 0 : NDR_CHECK(ndr_steal_array_size(ndr, (void*)&r->net_addr, &size_net_addr_1));
13097 0 : NDR_CHECK(ndr_steal_array_length(ndr, (void*)&r->net_addr, &length_net_addr_1));
13098 0 : if (length_net_addr_1 > size_net_addr_1) {
13099 0 : return ndr_pull_error(ndr, NDR_ERR_ARRAY_SIZE, "Bad array size %"PRIu32": should exceed array length %"PRIu32"", size_net_addr_1, length_net_addr_1);
13100 : }
13101 0 : NDR_CHECK(ndr_check_string_terminator(ndr, length_net_addr_1, sizeof(uint16_t)));
13102 0 : NDR_CHECK(ndr_pull_charset(ndr, NDR_SCALARS, &r->net_addr, length_net_addr_1, sizeof(uint16_t), CH_UTF16));
13103 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_net_addr_0, 0);
13104 : }
13105 0 : if (r->domain) {
13106 0 : _mem_save_domain_0 = NDR_PULL_GET_MEM_CTX(ndr);
13107 0 : NDR_PULL_SET_MEM_CTX(ndr, r->domain, 0);
13108 0 : NDR_CHECK(ndr_pull_array_size(ndr, &r->domain));
13109 0 : NDR_CHECK(ndr_pull_array_length(ndr, &r->domain));
13110 0 : NDR_CHECK(ndr_steal_array_size(ndr, (void*)&r->domain, &size_domain_1));
13111 0 : NDR_CHECK(ndr_steal_array_length(ndr, (void*)&r->domain, &length_domain_1));
13112 0 : if (length_domain_1 > size_domain_1) {
13113 0 : return ndr_pull_error(ndr, NDR_ERR_ARRAY_SIZE, "Bad array size %"PRIu32": should exceed array length %"PRIu32"", size_domain_1, length_domain_1);
13114 : }
13115 0 : NDR_CHECK(ndr_check_string_terminator(ndr, length_domain_1, sizeof(uint16_t)));
13116 0 : NDR_CHECK(ndr_pull_charset(ndr, NDR_SCALARS, &r->domain, length_domain_1, sizeof(uint16_t), CH_UTF16));
13117 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_domain_0, 0);
13118 : }
13119 0 : if (r->addr) {
13120 0 : NDR_CHECK(ndr_check_steal_array_size(ndr, (void*)&r->addr, r->addr_len));
13121 : }
13122 : }
13123 0 : return NDR_ERR_SUCCESS;
13124 : }
13125 :
13126 0 : _PUBLIC_ void ndr_print_srvsvc_NetTransportInfo1(struct ndr_print *ndr, const char *name, const struct srvsvc_NetTransportInfo1 *r)
13127 : {
13128 0 : ndr_print_struct(ndr, name, "srvsvc_NetTransportInfo1");
13129 0 : if (r == NULL) { ndr_print_null(ndr); return; }
13130 0 : ndr->depth++;
13131 0 : ndr_print_uint32(ndr, "vcs", r->vcs);
13132 0 : ndr_print_ptr(ndr, "name", r->name);
13133 0 : ndr->depth++;
13134 0 : if (r->name) {
13135 0 : ndr_print_string(ndr, "name", r->name);
13136 : }
13137 0 : ndr->depth--;
13138 0 : ndr_print_ptr(ndr, "addr", r->addr);
13139 0 : ndr->depth++;
13140 0 : if (r->addr) {
13141 0 : ndr_print_array_uint8(ndr, "addr", r->addr, r->addr_len);
13142 : }
13143 0 : ndr->depth--;
13144 0 : ndr_print_uint32(ndr, "addr_len", r->addr_len);
13145 0 : ndr_print_ptr(ndr, "net_addr", r->net_addr);
13146 0 : ndr->depth++;
13147 0 : if (r->net_addr) {
13148 0 : ndr_print_string(ndr, "net_addr", r->net_addr);
13149 : }
13150 0 : ndr->depth--;
13151 0 : ndr_print_ptr(ndr, "domain", r->domain);
13152 0 : ndr->depth++;
13153 0 : if (r->domain) {
13154 0 : ndr_print_string(ndr, "domain", r->domain);
13155 : }
13156 0 : ndr->depth--;
13157 0 : ndr->depth--;
13158 : }
13159 :
13160 9 : static enum ndr_err_code ndr_push_srvsvc_NetTransportCtr1(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct srvsvc_NetTransportCtr1 *r)
13161 : {
13162 0 : uint32_t cntr_array_1;
13163 9 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
13164 9 : if (ndr_flags & NDR_SCALARS) {
13165 9 : NDR_CHECK(ndr_push_align(ndr, 5));
13166 9 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->count));
13167 9 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->array));
13168 9 : NDR_CHECK(ndr_push_trailer_align(ndr, 5));
13169 : }
13170 9 : if (ndr_flags & NDR_BUFFERS) {
13171 9 : if (r->array) {
13172 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, r->count));
13173 0 : for (cntr_array_1 = 0; cntr_array_1 < (r->count); cntr_array_1++) {
13174 0 : NDR_CHECK(ndr_push_srvsvc_NetTransportInfo1(ndr, NDR_SCALARS, &r->array[cntr_array_1]));
13175 : }
13176 0 : for (cntr_array_1 = 0; cntr_array_1 < (r->count); cntr_array_1++) {
13177 0 : NDR_CHECK(ndr_push_srvsvc_NetTransportInfo1(ndr, NDR_BUFFERS, &r->array[cntr_array_1]));
13178 : }
13179 : }
13180 : }
13181 9 : return NDR_ERR_SUCCESS;
13182 : }
13183 :
13184 8 : static enum ndr_err_code ndr_pull_srvsvc_NetTransportCtr1(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct srvsvc_NetTransportCtr1 *r)
13185 : {
13186 0 : uint32_t _ptr_array;
13187 8 : uint32_t size_array_1 = 0;
13188 0 : uint32_t cntr_array_1;
13189 8 : TALLOC_CTX *_mem_save_array_0 = NULL;
13190 8 : TALLOC_CTX *_mem_save_array_1 = NULL;
13191 8 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
13192 8 : if (ndr_flags & NDR_SCALARS) {
13193 8 : NDR_CHECK(ndr_pull_align(ndr, 5));
13194 8 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->count));
13195 8 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_array));
13196 8 : if (_ptr_array) {
13197 0 : NDR_PULL_ALLOC(ndr, r->array);
13198 : } else {
13199 8 : r->array = NULL;
13200 : }
13201 8 : NDR_CHECK(ndr_pull_trailer_align(ndr, 5));
13202 : }
13203 8 : if (ndr_flags & NDR_BUFFERS) {
13204 8 : if (r->array) {
13205 0 : _mem_save_array_0 = NDR_PULL_GET_MEM_CTX(ndr);
13206 0 : NDR_PULL_SET_MEM_CTX(ndr, r->array, 0);
13207 0 : NDR_CHECK(ndr_pull_array_size(ndr, &r->array));
13208 0 : NDR_CHECK(ndr_get_array_size(ndr, (void*)&r->array, &size_array_1));
13209 0 : NDR_PULL_ALLOC_N(ndr, r->array, size_array_1);
13210 0 : _mem_save_array_1 = NDR_PULL_GET_MEM_CTX(ndr);
13211 0 : NDR_PULL_SET_MEM_CTX(ndr, r->array, 0);
13212 0 : for (cntr_array_1 = 0; cntr_array_1 < (size_array_1); cntr_array_1++) {
13213 0 : NDR_CHECK(ndr_pull_srvsvc_NetTransportInfo1(ndr, NDR_SCALARS, &r->array[cntr_array_1]));
13214 : }
13215 0 : for (cntr_array_1 = 0; cntr_array_1 < (size_array_1); cntr_array_1++) {
13216 0 : NDR_CHECK(ndr_pull_srvsvc_NetTransportInfo1(ndr, NDR_BUFFERS, &r->array[cntr_array_1]));
13217 : }
13218 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_array_1, 0);
13219 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_array_0, 0);
13220 : }
13221 8 : if (r->array) {
13222 0 : NDR_CHECK(ndr_check_array_size(ndr, (void*)&r->array, r->count));
13223 : }
13224 8 : for (cntr_array_1 = 0; cntr_array_1 < (size_array_1); cntr_array_1++) {
13225 0 : }
13226 : }
13227 8 : return NDR_ERR_SUCCESS;
13228 : }
13229 :
13230 2 : _PUBLIC_ void ndr_print_srvsvc_NetTransportCtr1(struct ndr_print *ndr, const char *name, const struct srvsvc_NetTransportCtr1 *r)
13231 : {
13232 0 : uint32_t cntr_array_1;
13233 2 : ndr_print_struct(ndr, name, "srvsvc_NetTransportCtr1");
13234 2 : if (r == NULL) { ndr_print_null(ndr); return; }
13235 2 : ndr->depth++;
13236 2 : ndr_print_uint32(ndr, "count", r->count);
13237 2 : ndr_print_ptr(ndr, "array", r->array);
13238 2 : ndr->depth++;
13239 2 : if (r->array) {
13240 0 : ndr->print(ndr, "%s: ARRAY(%"PRIu32")", "array", (uint32_t)(r->count));
13241 0 : ndr->depth++;
13242 0 : for (cntr_array_1 = 0; cntr_array_1 < (r->count); cntr_array_1++) {
13243 0 : ndr_print_srvsvc_NetTransportInfo1(ndr, "array", &r->array[cntr_array_1]);
13244 : }
13245 0 : ndr->depth--;
13246 : }
13247 2 : ndr->depth--;
13248 2 : ndr->depth--;
13249 : }
13250 :
13251 0 : static enum ndr_err_code ndr_push_srvsvc_NetTransportInfo2(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct srvsvc_NetTransportInfo2 *r)
13252 : {
13253 0 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
13254 0 : if (ndr_flags & NDR_SCALARS) {
13255 0 : NDR_CHECK(ndr_push_align(ndr, 5));
13256 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->vcs));
13257 0 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->name));
13258 0 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->addr));
13259 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->addr_len));
13260 0 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->net_addr));
13261 0 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->domain));
13262 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->unknown));
13263 0 : NDR_CHECK(ndr_push_trailer_align(ndr, 5));
13264 : }
13265 0 : if (ndr_flags & NDR_BUFFERS) {
13266 0 : if (r->name) {
13267 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->name, CH_UTF16)));
13268 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, 0));
13269 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->name, CH_UTF16)));
13270 0 : NDR_CHECK(ndr_push_charset(ndr, NDR_SCALARS, r->name, ndr_charset_length(r->name, CH_UTF16), sizeof(uint16_t), CH_UTF16));
13271 : }
13272 0 : if (r->addr) {
13273 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, r->addr_len));
13274 0 : NDR_CHECK(ndr_push_array_uint8(ndr, NDR_SCALARS, r->addr, r->addr_len));
13275 : }
13276 0 : if (r->net_addr) {
13277 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->net_addr, CH_UTF16)));
13278 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, 0));
13279 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->net_addr, CH_UTF16)));
13280 0 : NDR_CHECK(ndr_push_charset(ndr, NDR_SCALARS, r->net_addr, ndr_charset_length(r->net_addr, CH_UTF16), sizeof(uint16_t), CH_UTF16));
13281 : }
13282 0 : if (r->domain) {
13283 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->domain, CH_UTF16)));
13284 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, 0));
13285 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->domain, CH_UTF16)));
13286 0 : NDR_CHECK(ndr_push_charset(ndr, NDR_SCALARS, r->domain, ndr_charset_length(r->domain, CH_UTF16), sizeof(uint16_t), CH_UTF16));
13287 : }
13288 : }
13289 0 : return NDR_ERR_SUCCESS;
13290 : }
13291 :
13292 0 : static enum ndr_err_code ndr_pull_srvsvc_NetTransportInfo2(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct srvsvc_NetTransportInfo2 *r)
13293 : {
13294 0 : uint32_t _ptr_name;
13295 0 : uint32_t size_name_1 = 0;
13296 0 : uint32_t length_name_1 = 0;
13297 0 : TALLOC_CTX *_mem_save_name_0 = NULL;
13298 0 : uint32_t _ptr_addr;
13299 0 : uint32_t size_addr_1 = 0;
13300 0 : TALLOC_CTX *_mem_save_addr_0 = NULL;
13301 0 : uint32_t _ptr_net_addr;
13302 0 : uint32_t size_net_addr_1 = 0;
13303 0 : uint32_t length_net_addr_1 = 0;
13304 0 : TALLOC_CTX *_mem_save_net_addr_0 = NULL;
13305 0 : uint32_t _ptr_domain;
13306 0 : uint32_t size_domain_1 = 0;
13307 0 : uint32_t length_domain_1 = 0;
13308 0 : TALLOC_CTX *_mem_save_domain_0 = NULL;
13309 0 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
13310 0 : if (ndr_flags & NDR_SCALARS) {
13311 0 : NDR_CHECK(ndr_pull_align(ndr, 5));
13312 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->vcs));
13313 0 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_name));
13314 0 : if (_ptr_name) {
13315 0 : NDR_PULL_ALLOC(ndr, r->name);
13316 : } else {
13317 0 : r->name = NULL;
13318 : }
13319 0 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_addr));
13320 0 : if (_ptr_addr) {
13321 0 : NDR_PULL_ALLOC(ndr, r->addr);
13322 : } else {
13323 0 : r->addr = NULL;
13324 : }
13325 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->addr_len));
13326 0 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_net_addr));
13327 0 : if (_ptr_net_addr) {
13328 0 : NDR_PULL_ALLOC(ndr, r->net_addr);
13329 : } else {
13330 0 : r->net_addr = NULL;
13331 : }
13332 0 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_domain));
13333 0 : if (_ptr_domain) {
13334 0 : NDR_PULL_ALLOC(ndr, r->domain);
13335 : } else {
13336 0 : r->domain = NULL;
13337 : }
13338 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->unknown));
13339 0 : NDR_CHECK(ndr_pull_trailer_align(ndr, 5));
13340 : }
13341 0 : if (ndr_flags & NDR_BUFFERS) {
13342 0 : if (r->name) {
13343 0 : _mem_save_name_0 = NDR_PULL_GET_MEM_CTX(ndr);
13344 0 : NDR_PULL_SET_MEM_CTX(ndr, r->name, 0);
13345 0 : NDR_CHECK(ndr_pull_array_size(ndr, &r->name));
13346 0 : NDR_CHECK(ndr_pull_array_length(ndr, &r->name));
13347 0 : NDR_CHECK(ndr_steal_array_size(ndr, (void*)&r->name, &size_name_1));
13348 0 : NDR_CHECK(ndr_steal_array_length(ndr, (void*)&r->name, &length_name_1));
13349 0 : if (length_name_1 > size_name_1) {
13350 0 : return ndr_pull_error(ndr, NDR_ERR_ARRAY_SIZE, "Bad array size %"PRIu32": should exceed array length %"PRIu32"", size_name_1, length_name_1);
13351 : }
13352 0 : NDR_CHECK(ndr_check_string_terminator(ndr, length_name_1, sizeof(uint16_t)));
13353 0 : NDR_CHECK(ndr_pull_charset(ndr, NDR_SCALARS, &r->name, length_name_1, sizeof(uint16_t), CH_UTF16));
13354 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_name_0, 0);
13355 : }
13356 0 : if (r->addr) {
13357 0 : _mem_save_addr_0 = NDR_PULL_GET_MEM_CTX(ndr);
13358 0 : NDR_PULL_SET_MEM_CTX(ndr, r->addr, 0);
13359 0 : NDR_CHECK(ndr_pull_array_size(ndr, &r->addr));
13360 0 : NDR_CHECK(ndr_get_array_size(ndr, (void*)&r->addr, &size_addr_1));
13361 0 : NDR_PULL_ALLOC_N(ndr, r->addr, size_addr_1);
13362 0 : NDR_CHECK(ndr_pull_array_uint8(ndr, NDR_SCALARS, r->addr, size_addr_1));
13363 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_addr_0, 0);
13364 : }
13365 0 : if (r->net_addr) {
13366 0 : _mem_save_net_addr_0 = NDR_PULL_GET_MEM_CTX(ndr);
13367 0 : NDR_PULL_SET_MEM_CTX(ndr, r->net_addr, 0);
13368 0 : NDR_CHECK(ndr_pull_array_size(ndr, &r->net_addr));
13369 0 : NDR_CHECK(ndr_pull_array_length(ndr, &r->net_addr));
13370 0 : NDR_CHECK(ndr_steal_array_size(ndr, (void*)&r->net_addr, &size_net_addr_1));
13371 0 : NDR_CHECK(ndr_steal_array_length(ndr, (void*)&r->net_addr, &length_net_addr_1));
13372 0 : if (length_net_addr_1 > size_net_addr_1) {
13373 0 : return ndr_pull_error(ndr, NDR_ERR_ARRAY_SIZE, "Bad array size %"PRIu32": should exceed array length %"PRIu32"", size_net_addr_1, length_net_addr_1);
13374 : }
13375 0 : NDR_CHECK(ndr_check_string_terminator(ndr, length_net_addr_1, sizeof(uint16_t)));
13376 0 : NDR_CHECK(ndr_pull_charset(ndr, NDR_SCALARS, &r->net_addr, length_net_addr_1, sizeof(uint16_t), CH_UTF16));
13377 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_net_addr_0, 0);
13378 : }
13379 0 : if (r->domain) {
13380 0 : _mem_save_domain_0 = NDR_PULL_GET_MEM_CTX(ndr);
13381 0 : NDR_PULL_SET_MEM_CTX(ndr, r->domain, 0);
13382 0 : NDR_CHECK(ndr_pull_array_size(ndr, &r->domain));
13383 0 : NDR_CHECK(ndr_pull_array_length(ndr, &r->domain));
13384 0 : NDR_CHECK(ndr_steal_array_size(ndr, (void*)&r->domain, &size_domain_1));
13385 0 : NDR_CHECK(ndr_steal_array_length(ndr, (void*)&r->domain, &length_domain_1));
13386 0 : if (length_domain_1 > size_domain_1) {
13387 0 : return ndr_pull_error(ndr, NDR_ERR_ARRAY_SIZE, "Bad array size %"PRIu32": should exceed array length %"PRIu32"", size_domain_1, length_domain_1);
13388 : }
13389 0 : NDR_CHECK(ndr_check_string_terminator(ndr, length_domain_1, sizeof(uint16_t)));
13390 0 : NDR_CHECK(ndr_pull_charset(ndr, NDR_SCALARS, &r->domain, length_domain_1, sizeof(uint16_t), CH_UTF16));
13391 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_domain_0, 0);
13392 : }
13393 0 : if (r->addr) {
13394 0 : NDR_CHECK(ndr_check_steal_array_size(ndr, (void*)&r->addr, r->addr_len));
13395 : }
13396 : }
13397 0 : return NDR_ERR_SUCCESS;
13398 : }
13399 :
13400 0 : _PUBLIC_ void ndr_print_srvsvc_NetTransportInfo2(struct ndr_print *ndr, const char *name, const struct srvsvc_NetTransportInfo2 *r)
13401 : {
13402 0 : ndr_print_struct(ndr, name, "srvsvc_NetTransportInfo2");
13403 0 : if (r == NULL) { ndr_print_null(ndr); return; }
13404 0 : ndr->depth++;
13405 0 : ndr_print_uint32(ndr, "vcs", r->vcs);
13406 0 : ndr_print_ptr(ndr, "name", r->name);
13407 0 : ndr->depth++;
13408 0 : if (r->name) {
13409 0 : ndr_print_string(ndr, "name", r->name);
13410 : }
13411 0 : ndr->depth--;
13412 0 : ndr_print_ptr(ndr, "addr", r->addr);
13413 0 : ndr->depth++;
13414 0 : if (r->addr) {
13415 0 : ndr_print_array_uint8(ndr, "addr", r->addr, r->addr_len);
13416 : }
13417 0 : ndr->depth--;
13418 0 : ndr_print_uint32(ndr, "addr_len", r->addr_len);
13419 0 : ndr_print_ptr(ndr, "net_addr", r->net_addr);
13420 0 : ndr->depth++;
13421 0 : if (r->net_addr) {
13422 0 : ndr_print_string(ndr, "net_addr", r->net_addr);
13423 : }
13424 0 : ndr->depth--;
13425 0 : ndr_print_ptr(ndr, "domain", r->domain);
13426 0 : ndr->depth++;
13427 0 : if (r->domain) {
13428 0 : ndr_print_string(ndr, "domain", r->domain);
13429 : }
13430 0 : ndr->depth--;
13431 0 : ndr_print_uint32(ndr, "unknown", r->unknown);
13432 0 : ndr->depth--;
13433 : }
13434 :
13435 0 : static enum ndr_err_code ndr_push_srvsvc_NetTransportCtr2(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct srvsvc_NetTransportCtr2 *r)
13436 : {
13437 0 : uint32_t cntr_array_1;
13438 0 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
13439 0 : if (ndr_flags & NDR_SCALARS) {
13440 0 : NDR_CHECK(ndr_push_align(ndr, 5));
13441 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->count));
13442 0 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->array));
13443 0 : NDR_CHECK(ndr_push_trailer_align(ndr, 5));
13444 : }
13445 0 : if (ndr_flags & NDR_BUFFERS) {
13446 0 : if (r->array) {
13447 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, r->count));
13448 0 : for (cntr_array_1 = 0; cntr_array_1 < (r->count); cntr_array_1++) {
13449 0 : NDR_CHECK(ndr_push_srvsvc_NetTransportInfo2(ndr, NDR_SCALARS, &r->array[cntr_array_1]));
13450 : }
13451 0 : for (cntr_array_1 = 0; cntr_array_1 < (r->count); cntr_array_1++) {
13452 0 : NDR_CHECK(ndr_push_srvsvc_NetTransportInfo2(ndr, NDR_BUFFERS, &r->array[cntr_array_1]));
13453 : }
13454 : }
13455 : }
13456 0 : return NDR_ERR_SUCCESS;
13457 : }
13458 :
13459 0 : static enum ndr_err_code ndr_pull_srvsvc_NetTransportCtr2(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct srvsvc_NetTransportCtr2 *r)
13460 : {
13461 0 : uint32_t _ptr_array;
13462 0 : uint32_t size_array_1 = 0;
13463 0 : uint32_t cntr_array_1;
13464 0 : TALLOC_CTX *_mem_save_array_0 = NULL;
13465 0 : TALLOC_CTX *_mem_save_array_1 = NULL;
13466 0 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
13467 0 : if (ndr_flags & NDR_SCALARS) {
13468 0 : NDR_CHECK(ndr_pull_align(ndr, 5));
13469 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->count));
13470 0 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_array));
13471 0 : if (_ptr_array) {
13472 0 : NDR_PULL_ALLOC(ndr, r->array);
13473 : } else {
13474 0 : r->array = NULL;
13475 : }
13476 0 : NDR_CHECK(ndr_pull_trailer_align(ndr, 5));
13477 : }
13478 0 : if (ndr_flags & NDR_BUFFERS) {
13479 0 : if (r->array) {
13480 0 : _mem_save_array_0 = NDR_PULL_GET_MEM_CTX(ndr);
13481 0 : NDR_PULL_SET_MEM_CTX(ndr, r->array, 0);
13482 0 : NDR_CHECK(ndr_pull_array_size(ndr, &r->array));
13483 0 : NDR_CHECK(ndr_get_array_size(ndr, (void*)&r->array, &size_array_1));
13484 0 : NDR_PULL_ALLOC_N(ndr, r->array, size_array_1);
13485 0 : _mem_save_array_1 = NDR_PULL_GET_MEM_CTX(ndr);
13486 0 : NDR_PULL_SET_MEM_CTX(ndr, r->array, 0);
13487 0 : for (cntr_array_1 = 0; cntr_array_1 < (size_array_1); cntr_array_1++) {
13488 0 : NDR_CHECK(ndr_pull_srvsvc_NetTransportInfo2(ndr, NDR_SCALARS, &r->array[cntr_array_1]));
13489 : }
13490 0 : for (cntr_array_1 = 0; cntr_array_1 < (size_array_1); cntr_array_1++) {
13491 0 : NDR_CHECK(ndr_pull_srvsvc_NetTransportInfo2(ndr, NDR_BUFFERS, &r->array[cntr_array_1]));
13492 : }
13493 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_array_1, 0);
13494 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_array_0, 0);
13495 : }
13496 0 : if (r->array) {
13497 0 : NDR_CHECK(ndr_check_array_size(ndr, (void*)&r->array, r->count));
13498 : }
13499 0 : for (cntr_array_1 = 0; cntr_array_1 < (size_array_1); cntr_array_1++) {
13500 0 : }
13501 : }
13502 0 : return NDR_ERR_SUCCESS;
13503 : }
13504 :
13505 0 : _PUBLIC_ void ndr_print_srvsvc_NetTransportCtr2(struct ndr_print *ndr, const char *name, const struct srvsvc_NetTransportCtr2 *r)
13506 : {
13507 0 : uint32_t cntr_array_1;
13508 0 : ndr_print_struct(ndr, name, "srvsvc_NetTransportCtr2");
13509 0 : if (r == NULL) { ndr_print_null(ndr); return; }
13510 0 : ndr->depth++;
13511 0 : ndr_print_uint32(ndr, "count", r->count);
13512 0 : ndr_print_ptr(ndr, "array", r->array);
13513 0 : ndr->depth++;
13514 0 : if (r->array) {
13515 0 : ndr->print(ndr, "%s: ARRAY(%"PRIu32")", "array", (uint32_t)(r->count));
13516 0 : ndr->depth++;
13517 0 : for (cntr_array_1 = 0; cntr_array_1 < (r->count); cntr_array_1++) {
13518 0 : ndr_print_srvsvc_NetTransportInfo2(ndr, "array", &r->array[cntr_array_1]);
13519 : }
13520 0 : ndr->depth--;
13521 : }
13522 0 : ndr->depth--;
13523 0 : ndr->depth--;
13524 : }
13525 :
13526 0 : static enum ndr_err_code ndr_push_srvsvc_NetTransportInfo3(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct srvsvc_NetTransportInfo3 *r)
13527 : {
13528 0 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
13529 0 : if (ndr_flags & NDR_SCALARS) {
13530 0 : NDR_CHECK(ndr_push_align(ndr, 5));
13531 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->vcs));
13532 0 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->name));
13533 0 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->addr));
13534 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->addr_len));
13535 0 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->net_addr));
13536 0 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->domain));
13537 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->unknown1));
13538 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->unknown2));
13539 0 : NDR_CHECK(ndr_push_array_uint8(ndr, NDR_SCALARS, r->unknown3, 256));
13540 0 : NDR_CHECK(ndr_push_trailer_align(ndr, 5));
13541 : }
13542 0 : if (ndr_flags & NDR_BUFFERS) {
13543 0 : if (r->name) {
13544 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->name, CH_UTF16)));
13545 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, 0));
13546 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->name, CH_UTF16)));
13547 0 : NDR_CHECK(ndr_push_charset(ndr, NDR_SCALARS, r->name, ndr_charset_length(r->name, CH_UTF16), sizeof(uint16_t), CH_UTF16));
13548 : }
13549 0 : if (r->addr) {
13550 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, r->addr_len));
13551 0 : NDR_CHECK(ndr_push_array_uint8(ndr, NDR_SCALARS, r->addr, r->addr_len));
13552 : }
13553 0 : if (r->net_addr) {
13554 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->net_addr, CH_UTF16)));
13555 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, 0));
13556 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->net_addr, CH_UTF16)));
13557 0 : NDR_CHECK(ndr_push_charset(ndr, NDR_SCALARS, r->net_addr, ndr_charset_length(r->net_addr, CH_UTF16), sizeof(uint16_t), CH_UTF16));
13558 : }
13559 0 : if (r->domain) {
13560 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->domain, CH_UTF16)));
13561 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, 0));
13562 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->domain, CH_UTF16)));
13563 0 : NDR_CHECK(ndr_push_charset(ndr, NDR_SCALARS, r->domain, ndr_charset_length(r->domain, CH_UTF16), sizeof(uint16_t), CH_UTF16));
13564 : }
13565 : }
13566 0 : return NDR_ERR_SUCCESS;
13567 : }
13568 :
13569 0 : static enum ndr_err_code ndr_pull_srvsvc_NetTransportInfo3(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct srvsvc_NetTransportInfo3 *r)
13570 : {
13571 0 : uint32_t _ptr_name;
13572 0 : uint32_t size_name_1 = 0;
13573 0 : uint32_t length_name_1 = 0;
13574 0 : TALLOC_CTX *_mem_save_name_0 = NULL;
13575 0 : uint32_t _ptr_addr;
13576 0 : uint32_t size_addr_1 = 0;
13577 0 : TALLOC_CTX *_mem_save_addr_0 = NULL;
13578 0 : uint32_t _ptr_net_addr;
13579 0 : uint32_t size_net_addr_1 = 0;
13580 0 : uint32_t length_net_addr_1 = 0;
13581 0 : TALLOC_CTX *_mem_save_net_addr_0 = NULL;
13582 0 : uint32_t _ptr_domain;
13583 0 : uint32_t size_domain_1 = 0;
13584 0 : uint32_t length_domain_1 = 0;
13585 0 : TALLOC_CTX *_mem_save_domain_0 = NULL;
13586 0 : uint32_t size_unknown3_0 = 0;
13587 0 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
13588 0 : if (ndr_flags & NDR_SCALARS) {
13589 0 : NDR_CHECK(ndr_pull_align(ndr, 5));
13590 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->vcs));
13591 0 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_name));
13592 0 : if (_ptr_name) {
13593 0 : NDR_PULL_ALLOC(ndr, r->name);
13594 : } else {
13595 0 : r->name = NULL;
13596 : }
13597 0 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_addr));
13598 0 : if (_ptr_addr) {
13599 0 : NDR_PULL_ALLOC(ndr, r->addr);
13600 : } else {
13601 0 : r->addr = NULL;
13602 : }
13603 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->addr_len));
13604 0 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_net_addr));
13605 0 : if (_ptr_net_addr) {
13606 0 : NDR_PULL_ALLOC(ndr, r->net_addr);
13607 : } else {
13608 0 : r->net_addr = NULL;
13609 : }
13610 0 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_domain));
13611 0 : if (_ptr_domain) {
13612 0 : NDR_PULL_ALLOC(ndr, r->domain);
13613 : } else {
13614 0 : r->domain = NULL;
13615 : }
13616 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->unknown1));
13617 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->unknown2));
13618 0 : size_unknown3_0 = 256;
13619 0 : NDR_CHECK(ndr_pull_array_uint8(ndr, NDR_SCALARS, r->unknown3, size_unknown3_0));
13620 0 : NDR_CHECK(ndr_pull_trailer_align(ndr, 5));
13621 : }
13622 0 : if (ndr_flags & NDR_BUFFERS) {
13623 0 : if (r->name) {
13624 0 : _mem_save_name_0 = NDR_PULL_GET_MEM_CTX(ndr);
13625 0 : NDR_PULL_SET_MEM_CTX(ndr, r->name, 0);
13626 0 : NDR_CHECK(ndr_pull_array_size(ndr, &r->name));
13627 0 : NDR_CHECK(ndr_pull_array_length(ndr, &r->name));
13628 0 : NDR_CHECK(ndr_steal_array_size(ndr, (void*)&r->name, &size_name_1));
13629 0 : NDR_CHECK(ndr_steal_array_length(ndr, (void*)&r->name, &length_name_1));
13630 0 : if (length_name_1 > size_name_1) {
13631 0 : return ndr_pull_error(ndr, NDR_ERR_ARRAY_SIZE, "Bad array size %"PRIu32": should exceed array length %"PRIu32"", size_name_1, length_name_1);
13632 : }
13633 0 : NDR_CHECK(ndr_check_string_terminator(ndr, length_name_1, sizeof(uint16_t)));
13634 0 : NDR_CHECK(ndr_pull_charset(ndr, NDR_SCALARS, &r->name, length_name_1, sizeof(uint16_t), CH_UTF16));
13635 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_name_0, 0);
13636 : }
13637 0 : if (r->addr) {
13638 0 : _mem_save_addr_0 = NDR_PULL_GET_MEM_CTX(ndr);
13639 0 : NDR_PULL_SET_MEM_CTX(ndr, r->addr, 0);
13640 0 : NDR_CHECK(ndr_pull_array_size(ndr, &r->addr));
13641 0 : NDR_CHECK(ndr_get_array_size(ndr, (void*)&r->addr, &size_addr_1));
13642 0 : NDR_PULL_ALLOC_N(ndr, r->addr, size_addr_1);
13643 0 : NDR_CHECK(ndr_pull_array_uint8(ndr, NDR_SCALARS, r->addr, size_addr_1));
13644 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_addr_0, 0);
13645 : }
13646 0 : if (r->net_addr) {
13647 0 : _mem_save_net_addr_0 = NDR_PULL_GET_MEM_CTX(ndr);
13648 0 : NDR_PULL_SET_MEM_CTX(ndr, r->net_addr, 0);
13649 0 : NDR_CHECK(ndr_pull_array_size(ndr, &r->net_addr));
13650 0 : NDR_CHECK(ndr_pull_array_length(ndr, &r->net_addr));
13651 0 : NDR_CHECK(ndr_steal_array_size(ndr, (void*)&r->net_addr, &size_net_addr_1));
13652 0 : NDR_CHECK(ndr_steal_array_length(ndr, (void*)&r->net_addr, &length_net_addr_1));
13653 0 : if (length_net_addr_1 > size_net_addr_1) {
13654 0 : return ndr_pull_error(ndr, NDR_ERR_ARRAY_SIZE, "Bad array size %"PRIu32": should exceed array length %"PRIu32"", size_net_addr_1, length_net_addr_1);
13655 : }
13656 0 : NDR_CHECK(ndr_check_string_terminator(ndr, length_net_addr_1, sizeof(uint16_t)));
13657 0 : NDR_CHECK(ndr_pull_charset(ndr, NDR_SCALARS, &r->net_addr, length_net_addr_1, sizeof(uint16_t), CH_UTF16));
13658 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_net_addr_0, 0);
13659 : }
13660 0 : if (r->domain) {
13661 0 : _mem_save_domain_0 = NDR_PULL_GET_MEM_CTX(ndr);
13662 0 : NDR_PULL_SET_MEM_CTX(ndr, r->domain, 0);
13663 0 : NDR_CHECK(ndr_pull_array_size(ndr, &r->domain));
13664 0 : NDR_CHECK(ndr_pull_array_length(ndr, &r->domain));
13665 0 : NDR_CHECK(ndr_steal_array_size(ndr, (void*)&r->domain, &size_domain_1));
13666 0 : NDR_CHECK(ndr_steal_array_length(ndr, (void*)&r->domain, &length_domain_1));
13667 0 : if (length_domain_1 > size_domain_1) {
13668 0 : return ndr_pull_error(ndr, NDR_ERR_ARRAY_SIZE, "Bad array size %"PRIu32": should exceed array length %"PRIu32"", size_domain_1, length_domain_1);
13669 : }
13670 0 : NDR_CHECK(ndr_check_string_terminator(ndr, length_domain_1, sizeof(uint16_t)));
13671 0 : NDR_CHECK(ndr_pull_charset(ndr, NDR_SCALARS, &r->domain, length_domain_1, sizeof(uint16_t), CH_UTF16));
13672 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_domain_0, 0);
13673 : }
13674 0 : if (r->addr) {
13675 0 : NDR_CHECK(ndr_check_steal_array_size(ndr, (void*)&r->addr, r->addr_len));
13676 : }
13677 : }
13678 0 : return NDR_ERR_SUCCESS;
13679 : }
13680 :
13681 0 : _PUBLIC_ void ndr_print_srvsvc_NetTransportInfo3(struct ndr_print *ndr, const char *name, const struct srvsvc_NetTransportInfo3 *r)
13682 : {
13683 0 : ndr_print_struct(ndr, name, "srvsvc_NetTransportInfo3");
13684 0 : if (r == NULL) { ndr_print_null(ndr); return; }
13685 0 : ndr->depth++;
13686 0 : ndr_print_uint32(ndr, "vcs", r->vcs);
13687 0 : ndr_print_ptr(ndr, "name", r->name);
13688 0 : ndr->depth++;
13689 0 : if (r->name) {
13690 0 : ndr_print_string(ndr, "name", r->name);
13691 : }
13692 0 : ndr->depth--;
13693 0 : ndr_print_ptr(ndr, "addr", r->addr);
13694 0 : ndr->depth++;
13695 0 : if (r->addr) {
13696 0 : ndr_print_array_uint8(ndr, "addr", r->addr, r->addr_len);
13697 : }
13698 0 : ndr->depth--;
13699 0 : ndr_print_uint32(ndr, "addr_len", r->addr_len);
13700 0 : ndr_print_ptr(ndr, "net_addr", r->net_addr);
13701 0 : ndr->depth++;
13702 0 : if (r->net_addr) {
13703 0 : ndr_print_string(ndr, "net_addr", r->net_addr);
13704 : }
13705 0 : ndr->depth--;
13706 0 : ndr_print_ptr(ndr, "domain", r->domain);
13707 0 : ndr->depth++;
13708 0 : if (r->domain) {
13709 0 : ndr_print_string(ndr, "domain", r->domain);
13710 : }
13711 0 : ndr->depth--;
13712 0 : ndr_print_uint32(ndr, "unknown1", r->unknown1);
13713 0 : ndr_print_uint32(ndr, "unknown2", r->unknown2);
13714 0 : ndr_print_array_uint8(ndr, "unknown3", r->unknown3, 256);
13715 0 : ndr->depth--;
13716 : }
13717 :
13718 0 : static enum ndr_err_code ndr_push_srvsvc_NetTransportCtr3(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct srvsvc_NetTransportCtr3 *r)
13719 : {
13720 0 : uint32_t cntr_array_1;
13721 0 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
13722 0 : if (ndr_flags & NDR_SCALARS) {
13723 0 : NDR_CHECK(ndr_push_align(ndr, 5));
13724 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->count));
13725 0 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->array));
13726 0 : NDR_CHECK(ndr_push_trailer_align(ndr, 5));
13727 : }
13728 0 : if (ndr_flags & NDR_BUFFERS) {
13729 0 : if (r->array) {
13730 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, r->count));
13731 0 : for (cntr_array_1 = 0; cntr_array_1 < (r->count); cntr_array_1++) {
13732 0 : NDR_CHECK(ndr_push_srvsvc_NetTransportInfo3(ndr, NDR_SCALARS, &r->array[cntr_array_1]));
13733 : }
13734 0 : for (cntr_array_1 = 0; cntr_array_1 < (r->count); cntr_array_1++) {
13735 0 : NDR_CHECK(ndr_push_srvsvc_NetTransportInfo3(ndr, NDR_BUFFERS, &r->array[cntr_array_1]));
13736 : }
13737 : }
13738 : }
13739 0 : return NDR_ERR_SUCCESS;
13740 : }
13741 :
13742 0 : static enum ndr_err_code ndr_pull_srvsvc_NetTransportCtr3(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct srvsvc_NetTransportCtr3 *r)
13743 : {
13744 0 : uint32_t _ptr_array;
13745 0 : uint32_t size_array_1 = 0;
13746 0 : uint32_t cntr_array_1;
13747 0 : TALLOC_CTX *_mem_save_array_0 = NULL;
13748 0 : TALLOC_CTX *_mem_save_array_1 = NULL;
13749 0 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
13750 0 : if (ndr_flags & NDR_SCALARS) {
13751 0 : NDR_CHECK(ndr_pull_align(ndr, 5));
13752 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->count));
13753 0 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_array));
13754 0 : if (_ptr_array) {
13755 0 : NDR_PULL_ALLOC(ndr, r->array);
13756 : } else {
13757 0 : r->array = NULL;
13758 : }
13759 0 : NDR_CHECK(ndr_pull_trailer_align(ndr, 5));
13760 : }
13761 0 : if (ndr_flags & NDR_BUFFERS) {
13762 0 : if (r->array) {
13763 0 : _mem_save_array_0 = NDR_PULL_GET_MEM_CTX(ndr);
13764 0 : NDR_PULL_SET_MEM_CTX(ndr, r->array, 0);
13765 0 : NDR_CHECK(ndr_pull_array_size(ndr, &r->array));
13766 0 : NDR_CHECK(ndr_get_array_size(ndr, (void*)&r->array, &size_array_1));
13767 0 : NDR_PULL_ALLOC_N(ndr, r->array, size_array_1);
13768 0 : _mem_save_array_1 = NDR_PULL_GET_MEM_CTX(ndr);
13769 0 : NDR_PULL_SET_MEM_CTX(ndr, r->array, 0);
13770 0 : for (cntr_array_1 = 0; cntr_array_1 < (size_array_1); cntr_array_1++) {
13771 0 : NDR_CHECK(ndr_pull_srvsvc_NetTransportInfo3(ndr, NDR_SCALARS, &r->array[cntr_array_1]));
13772 : }
13773 0 : for (cntr_array_1 = 0; cntr_array_1 < (size_array_1); cntr_array_1++) {
13774 0 : NDR_CHECK(ndr_pull_srvsvc_NetTransportInfo3(ndr, NDR_BUFFERS, &r->array[cntr_array_1]));
13775 : }
13776 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_array_1, 0);
13777 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_array_0, 0);
13778 : }
13779 0 : if (r->array) {
13780 0 : NDR_CHECK(ndr_check_array_size(ndr, (void*)&r->array, r->count));
13781 : }
13782 0 : for (cntr_array_1 = 0; cntr_array_1 < (size_array_1); cntr_array_1++) {
13783 0 : }
13784 : }
13785 0 : return NDR_ERR_SUCCESS;
13786 : }
13787 :
13788 0 : _PUBLIC_ void ndr_print_srvsvc_NetTransportCtr3(struct ndr_print *ndr, const char *name, const struct srvsvc_NetTransportCtr3 *r)
13789 : {
13790 0 : uint32_t cntr_array_1;
13791 0 : ndr_print_struct(ndr, name, "srvsvc_NetTransportCtr3");
13792 0 : if (r == NULL) { ndr_print_null(ndr); return; }
13793 0 : ndr->depth++;
13794 0 : ndr_print_uint32(ndr, "count", r->count);
13795 0 : ndr_print_ptr(ndr, "array", r->array);
13796 0 : ndr->depth++;
13797 0 : if (r->array) {
13798 0 : ndr->print(ndr, "%s: ARRAY(%"PRIu32")", "array", (uint32_t)(r->count));
13799 0 : ndr->depth++;
13800 0 : for (cntr_array_1 = 0; cntr_array_1 < (r->count); cntr_array_1++) {
13801 0 : ndr_print_srvsvc_NetTransportInfo3(ndr, "array", &r->array[cntr_array_1]);
13802 : }
13803 0 : ndr->depth--;
13804 : }
13805 0 : ndr->depth--;
13806 0 : ndr->depth--;
13807 : }
13808 :
13809 44 : static enum ndr_err_code ndr_push_srvsvc_NetTransportCtr(struct ndr_push *ndr, ndr_flags_type ndr_flags, const union srvsvc_NetTransportCtr *r)
13810 : {
13811 0 : uint32_t level;
13812 44 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
13813 44 : if (ndr_flags & NDR_SCALARS) {
13814 : /* This token is not used again (except perhaps below in the NDR_BUFFERS case) */
13815 22 : NDR_CHECK(ndr_push_steal_switch_value(ndr, r, &level));
13816 22 : NDR_CHECK(ndr_push_union_align(ndr, 5));
13817 22 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, level));
13818 22 : NDR_CHECK(ndr_push_union_align(ndr, 5));
13819 22 : switch (level) {
13820 13 : case 0: {
13821 13 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->ctr0));
13822 13 : break; }
13823 :
13824 9 : case 1: {
13825 9 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->ctr1));
13826 9 : break; }
13827 :
13828 0 : case 2: {
13829 0 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->ctr2));
13830 0 : break; }
13831 :
13832 0 : case 3: {
13833 0 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->ctr3));
13834 0 : break; }
13835 :
13836 0 : default: {
13837 0 : break; }
13838 :
13839 : }
13840 : }
13841 44 : if (ndr_flags & NDR_BUFFERS) {
13842 22 : if (!(ndr_flags & NDR_SCALARS)) {
13843 : /* We didn't get it above, and the token is not needed after this. */
13844 22 : NDR_CHECK(ndr_push_steal_switch_value(ndr, r, &level));
13845 : }
13846 22 : switch (level) {
13847 13 : case 0:
13848 13 : if (r->ctr0) {
13849 13 : NDR_CHECK(ndr_push_srvsvc_NetTransportCtr0(ndr, NDR_SCALARS|NDR_BUFFERS, r->ctr0));
13850 : }
13851 13 : break;
13852 :
13853 9 : case 1:
13854 9 : if (r->ctr1) {
13855 9 : NDR_CHECK(ndr_push_srvsvc_NetTransportCtr1(ndr, NDR_SCALARS|NDR_BUFFERS, r->ctr1));
13856 : }
13857 9 : break;
13858 :
13859 0 : case 2:
13860 0 : if (r->ctr2) {
13861 0 : NDR_CHECK(ndr_push_srvsvc_NetTransportCtr2(ndr, NDR_SCALARS|NDR_BUFFERS, r->ctr2));
13862 : }
13863 0 : break;
13864 :
13865 0 : case 3:
13866 0 : if (r->ctr3) {
13867 0 : NDR_CHECK(ndr_push_srvsvc_NetTransportCtr3(ndr, NDR_SCALARS|NDR_BUFFERS, r->ctr3));
13868 : }
13869 0 : break;
13870 :
13871 0 : default:
13872 0 : break;
13873 :
13874 : }
13875 : }
13876 44 : return NDR_ERR_SUCCESS;
13877 : }
13878 :
13879 40 : static enum ndr_err_code ndr_pull_srvsvc_NetTransportCtr(struct ndr_pull *ndr, ndr_flags_type ndr_flags, union srvsvc_NetTransportCtr *r)
13880 : {
13881 0 : uint32_t level;
13882 0 : uint32_t _level;
13883 40 : TALLOC_CTX *_mem_save_ctr0_0 = NULL;
13884 0 : uint32_t _ptr_ctr0;
13885 40 : TALLOC_CTX *_mem_save_ctr1_0 = NULL;
13886 0 : uint32_t _ptr_ctr1;
13887 40 : TALLOC_CTX *_mem_save_ctr2_0 = NULL;
13888 0 : uint32_t _ptr_ctr2;
13889 40 : TALLOC_CTX *_mem_save_ctr3_0 = NULL;
13890 0 : uint32_t _ptr_ctr3;
13891 40 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
13892 40 : if (ndr_flags & NDR_SCALARS) {
13893 : /* This token is not used again (except perhaps below in the NDR_BUFFERS case) */
13894 20 : NDR_CHECK(ndr_pull_steal_switch_value(ndr, r, &level));
13895 20 : NDR_CHECK(ndr_pull_union_align(ndr, 5));
13896 20 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &_level));
13897 20 : if (_level != level) {
13898 0 : return ndr_pull_error(ndr, NDR_ERR_BAD_SWITCH, "Bad switch value %"PRIu32" for r at %s", (uint32_t)_level, __location__);
13899 : }
13900 20 : NDR_CHECK(ndr_pull_union_align(ndr, 5));
13901 20 : switch (level) {
13902 12 : case 0: {
13903 12 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_ctr0));
13904 12 : if (_ptr_ctr0) {
13905 12 : NDR_PULL_ALLOC(ndr, r->ctr0);
13906 : } else {
13907 0 : r->ctr0 = NULL;
13908 : }
13909 12 : break; }
13910 :
13911 8 : case 1: {
13912 8 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_ctr1));
13913 8 : if (_ptr_ctr1) {
13914 8 : NDR_PULL_ALLOC(ndr, r->ctr1);
13915 : } else {
13916 0 : r->ctr1 = NULL;
13917 : }
13918 8 : break; }
13919 :
13920 0 : case 2: {
13921 0 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_ctr2));
13922 0 : if (_ptr_ctr2) {
13923 0 : NDR_PULL_ALLOC(ndr, r->ctr2);
13924 : } else {
13925 0 : r->ctr2 = NULL;
13926 : }
13927 0 : break; }
13928 :
13929 0 : case 3: {
13930 0 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_ctr3));
13931 0 : if (_ptr_ctr3) {
13932 0 : NDR_PULL_ALLOC(ndr, r->ctr3);
13933 : } else {
13934 0 : r->ctr3 = NULL;
13935 : }
13936 0 : break; }
13937 :
13938 0 : default: {
13939 0 : break; }
13940 :
13941 : }
13942 : }
13943 40 : if (ndr_flags & NDR_BUFFERS) {
13944 20 : if (!(ndr_flags & NDR_SCALARS)) {
13945 : /* We didn't get it above, and the token is not needed after this. */
13946 20 : NDR_CHECK(ndr_pull_steal_switch_value(ndr, r, &level));
13947 : }
13948 20 : switch (level) {
13949 12 : case 0:
13950 12 : if (r->ctr0) {
13951 12 : _mem_save_ctr0_0 = NDR_PULL_GET_MEM_CTX(ndr);
13952 12 : NDR_PULL_SET_MEM_CTX(ndr, r->ctr0, 0);
13953 12 : NDR_CHECK(ndr_pull_srvsvc_NetTransportCtr0(ndr, NDR_SCALARS|NDR_BUFFERS, r->ctr0));
13954 12 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_ctr0_0, 0);
13955 : }
13956 12 : break;
13957 :
13958 8 : case 1:
13959 8 : if (r->ctr1) {
13960 8 : _mem_save_ctr1_0 = NDR_PULL_GET_MEM_CTX(ndr);
13961 8 : NDR_PULL_SET_MEM_CTX(ndr, r->ctr1, 0);
13962 8 : NDR_CHECK(ndr_pull_srvsvc_NetTransportCtr1(ndr, NDR_SCALARS|NDR_BUFFERS, r->ctr1));
13963 8 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_ctr1_0, 0);
13964 : }
13965 8 : break;
13966 :
13967 0 : case 2:
13968 0 : if (r->ctr2) {
13969 0 : _mem_save_ctr2_0 = NDR_PULL_GET_MEM_CTX(ndr);
13970 0 : NDR_PULL_SET_MEM_CTX(ndr, r->ctr2, 0);
13971 0 : NDR_CHECK(ndr_pull_srvsvc_NetTransportCtr2(ndr, NDR_SCALARS|NDR_BUFFERS, r->ctr2));
13972 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_ctr2_0, 0);
13973 : }
13974 0 : break;
13975 :
13976 0 : case 3:
13977 0 : if (r->ctr3) {
13978 0 : _mem_save_ctr3_0 = NDR_PULL_GET_MEM_CTX(ndr);
13979 0 : NDR_PULL_SET_MEM_CTX(ndr, r->ctr3, 0);
13980 0 : NDR_CHECK(ndr_pull_srvsvc_NetTransportCtr3(ndr, NDR_SCALARS|NDR_BUFFERS, r->ctr3));
13981 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_ctr3_0, 0);
13982 : }
13983 0 : break;
13984 :
13985 0 : default:
13986 0 : break;
13987 :
13988 : }
13989 : }
13990 40 : return NDR_ERR_SUCCESS;
13991 : }
13992 :
13993 4 : _PUBLIC_ void ndr_print_srvsvc_NetTransportCtr(struct ndr_print *ndr, const char *name, const union srvsvc_NetTransportCtr *r)
13994 : {
13995 0 : uint32_t level;
13996 4 : level = ndr_print_steal_switch_value(ndr, r);
13997 4 : ndr_print_union(ndr, name, level, "srvsvc_NetTransportCtr");
13998 4 : switch (level) {
13999 2 : case 0:
14000 2 : ndr_print_ptr(ndr, "ctr0", r->ctr0);
14001 2 : ndr->depth++;
14002 2 : if (r->ctr0) {
14003 2 : ndr_print_srvsvc_NetTransportCtr0(ndr, "ctr0", r->ctr0);
14004 : }
14005 2 : ndr->depth--;
14006 2 : break;
14007 :
14008 2 : case 1:
14009 2 : ndr_print_ptr(ndr, "ctr1", r->ctr1);
14010 2 : ndr->depth++;
14011 2 : if (r->ctr1) {
14012 2 : ndr_print_srvsvc_NetTransportCtr1(ndr, "ctr1", r->ctr1);
14013 : }
14014 2 : ndr->depth--;
14015 2 : break;
14016 :
14017 0 : case 2:
14018 0 : ndr_print_ptr(ndr, "ctr2", r->ctr2);
14019 0 : ndr->depth++;
14020 0 : if (r->ctr2) {
14021 0 : ndr_print_srvsvc_NetTransportCtr2(ndr, "ctr2", r->ctr2);
14022 : }
14023 0 : ndr->depth--;
14024 0 : break;
14025 :
14026 0 : case 3:
14027 0 : ndr_print_ptr(ndr, "ctr3", r->ctr3);
14028 0 : ndr->depth++;
14029 0 : if (r->ctr3) {
14030 0 : ndr_print_srvsvc_NetTransportCtr3(ndr, "ctr3", r->ctr3);
14031 : }
14032 0 : ndr->depth--;
14033 0 : break;
14034 :
14035 0 : default:
14036 0 : break;
14037 :
14038 : }
14039 4 : }
14040 :
14041 22 : static enum ndr_err_code ndr_push_srvsvc_NetTransportInfoCtr(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct srvsvc_NetTransportInfoCtr *r)
14042 : {
14043 22 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
14044 22 : if (ndr_flags & NDR_SCALARS) {
14045 22 : NDR_CHECK(ndr_push_align(ndr, 5));
14046 22 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->level));
14047 22 : NDR_CHECK(ndr_push_set_switch_value(ndr, &r->ctr, r->level));
14048 22 : NDR_CHECK(ndr_push_srvsvc_NetTransportCtr(ndr, NDR_SCALARS, &r->ctr));
14049 22 : NDR_CHECK(ndr_push_trailer_align(ndr, 5));
14050 : }
14051 22 : if (ndr_flags & NDR_BUFFERS) {
14052 22 : NDR_CHECK(ndr_push_set_switch_value(ndr, &r->ctr, r->level));
14053 22 : NDR_CHECK(ndr_push_srvsvc_NetTransportCtr(ndr, NDR_BUFFERS, &r->ctr));
14054 : }
14055 22 : return NDR_ERR_SUCCESS;
14056 : }
14057 :
14058 20 : static enum ndr_err_code ndr_pull_srvsvc_NetTransportInfoCtr(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct srvsvc_NetTransportInfoCtr *r)
14059 : {
14060 20 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
14061 20 : if (ndr_flags & NDR_SCALARS) {
14062 20 : NDR_CHECK(ndr_pull_align(ndr, 5));
14063 20 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->level));
14064 20 : NDR_CHECK(ndr_pull_set_switch_value(ndr, &r->ctr, r->level));
14065 20 : NDR_CHECK(ndr_pull_srvsvc_NetTransportCtr(ndr, NDR_SCALARS, &r->ctr));
14066 20 : NDR_CHECK(ndr_pull_trailer_align(ndr, 5));
14067 : }
14068 20 : if (ndr_flags & NDR_BUFFERS) {
14069 20 : NDR_CHECK(ndr_pull_set_switch_value(ndr, &r->ctr, r->level));
14070 20 : NDR_CHECK(ndr_pull_srvsvc_NetTransportCtr(ndr, NDR_BUFFERS, &r->ctr));
14071 : }
14072 20 : return NDR_ERR_SUCCESS;
14073 : }
14074 :
14075 4 : _PUBLIC_ void ndr_print_srvsvc_NetTransportInfoCtr(struct ndr_print *ndr, const char *name, const struct srvsvc_NetTransportInfoCtr *r)
14076 : {
14077 4 : ndr_print_struct(ndr, name, "srvsvc_NetTransportInfoCtr");
14078 4 : if (r == NULL) { ndr_print_null(ndr); return; }
14079 4 : ndr->depth++;
14080 4 : ndr_print_uint32(ndr, "level", r->level);
14081 4 : ndr_print_set_switch_value(ndr, &r->ctr, r->level);
14082 4 : ndr_print_srvsvc_NetTransportCtr(ndr, "ctr", &r->ctr);
14083 4 : ndr->depth--;
14084 : }
14085 :
14086 34 : static enum ndr_err_code ndr_push_srvsvc_NetRemoteTODInfo(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct srvsvc_NetRemoteTODInfo *r)
14087 : {
14088 34 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
14089 34 : if (ndr_flags & NDR_SCALARS) {
14090 34 : NDR_CHECK(ndr_push_align(ndr, 4));
14091 34 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->elapsed));
14092 34 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->msecs));
14093 34 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->hours));
14094 34 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->mins));
14095 34 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->secs));
14096 34 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->hunds));
14097 34 : NDR_CHECK(ndr_push_int32(ndr, NDR_SCALARS, r->timezone));
14098 34 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->tinterval));
14099 34 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->day));
14100 34 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->month));
14101 34 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->year));
14102 34 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->weekday));
14103 34 : NDR_CHECK(ndr_push_trailer_align(ndr, 4));
14104 : }
14105 34 : if (ndr_flags & NDR_BUFFERS) {
14106 0 : }
14107 34 : return NDR_ERR_SUCCESS;
14108 : }
14109 :
14110 33 : static enum ndr_err_code ndr_pull_srvsvc_NetRemoteTODInfo(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct srvsvc_NetRemoteTODInfo *r)
14111 : {
14112 33 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
14113 33 : if (ndr_flags & NDR_SCALARS) {
14114 33 : NDR_CHECK(ndr_pull_align(ndr, 4));
14115 33 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->elapsed));
14116 33 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->msecs));
14117 33 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->hours));
14118 33 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->mins));
14119 33 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->secs));
14120 33 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->hunds));
14121 33 : NDR_CHECK(ndr_pull_int32(ndr, NDR_SCALARS, &r->timezone));
14122 33 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->tinterval));
14123 33 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->day));
14124 33 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->month));
14125 33 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->year));
14126 33 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->weekday));
14127 33 : NDR_CHECK(ndr_pull_trailer_align(ndr, 4));
14128 : }
14129 33 : if (ndr_flags & NDR_BUFFERS) {
14130 0 : }
14131 33 : return NDR_ERR_SUCCESS;
14132 : }
14133 :
14134 2 : _PUBLIC_ void ndr_print_srvsvc_NetRemoteTODInfo(struct ndr_print *ndr, const char *name, const struct srvsvc_NetRemoteTODInfo *r)
14135 : {
14136 2 : ndr_print_struct(ndr, name, "srvsvc_NetRemoteTODInfo");
14137 2 : if (r == NULL) { ndr_print_null(ndr); return; }
14138 2 : ndr->depth++;
14139 2 : ndr_print_uint32(ndr, "elapsed", r->elapsed);
14140 2 : ndr_print_uint32(ndr, "msecs", r->msecs);
14141 2 : ndr_print_uint32(ndr, "hours", r->hours);
14142 2 : ndr_print_uint32(ndr, "mins", r->mins);
14143 2 : ndr_print_uint32(ndr, "secs", r->secs);
14144 2 : ndr_print_uint32(ndr, "hunds", r->hunds);
14145 2 : ndr_print_int32(ndr, "timezone", r->timezone);
14146 2 : ndr_print_uint32(ndr, "tinterval", r->tinterval);
14147 2 : ndr_print_uint32(ndr, "day", r->day);
14148 2 : ndr_print_uint32(ndr, "month", r->month);
14149 2 : ndr_print_uint32(ndr, "year", r->year);
14150 2 : ndr_print_uint32(ndr, "weekday", r->weekday);
14151 2 : ndr->depth--;
14152 : }
14153 :
14154 0 : static enum ndr_err_code ndr_push_srvsvc_NetTransportInfo(struct ndr_push *ndr, ndr_flags_type ndr_flags, const union srvsvc_NetTransportInfo *r)
14155 : {
14156 0 : uint32_t level;
14157 0 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
14158 0 : if (ndr_flags & NDR_SCALARS) {
14159 : /* This token is not used again (except perhaps below in the NDR_BUFFERS case) */
14160 0 : NDR_CHECK(ndr_push_steal_switch_value(ndr, r, &level));
14161 0 : NDR_CHECK(ndr_push_union_align(ndr, 5));
14162 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, level));
14163 0 : NDR_CHECK(ndr_push_union_align(ndr, 5));
14164 0 : switch (level) {
14165 0 : case 0: {
14166 0 : NDR_CHECK(ndr_push_srvsvc_NetTransportInfo0(ndr, NDR_SCALARS, &r->info0));
14167 0 : break; }
14168 :
14169 0 : case 1: {
14170 0 : NDR_CHECK(ndr_push_srvsvc_NetTransportInfo1(ndr, NDR_SCALARS, &r->info1));
14171 0 : break; }
14172 :
14173 0 : case 2: {
14174 0 : NDR_CHECK(ndr_push_srvsvc_NetTransportInfo2(ndr, NDR_SCALARS, &r->info2));
14175 0 : break; }
14176 :
14177 0 : case 3: {
14178 0 : NDR_CHECK(ndr_push_srvsvc_NetTransportInfo3(ndr, NDR_SCALARS, &r->info3));
14179 0 : break; }
14180 :
14181 0 : default:
14182 0 : return ndr_push_error(ndr, NDR_ERR_BAD_SWITCH, "Bad switch value %"PRIu32, level);
14183 : }
14184 : }
14185 0 : if (ndr_flags & NDR_BUFFERS) {
14186 0 : if (!(ndr_flags & NDR_SCALARS)) {
14187 : /* We didn't get it above, and the token is not needed after this. */
14188 0 : NDR_CHECK(ndr_push_steal_switch_value(ndr, r, &level));
14189 : }
14190 0 : switch (level) {
14191 0 : case 0:
14192 0 : NDR_CHECK(ndr_push_srvsvc_NetTransportInfo0(ndr, NDR_BUFFERS, &r->info0));
14193 0 : break;
14194 :
14195 0 : case 1:
14196 0 : NDR_CHECK(ndr_push_srvsvc_NetTransportInfo1(ndr, NDR_BUFFERS, &r->info1));
14197 0 : break;
14198 :
14199 0 : case 2:
14200 0 : NDR_CHECK(ndr_push_srvsvc_NetTransportInfo2(ndr, NDR_BUFFERS, &r->info2));
14201 0 : break;
14202 :
14203 0 : case 3:
14204 0 : NDR_CHECK(ndr_push_srvsvc_NetTransportInfo3(ndr, NDR_BUFFERS, &r->info3));
14205 0 : break;
14206 :
14207 0 : default:
14208 0 : return ndr_push_error(ndr, NDR_ERR_BAD_SWITCH, "Bad switch value %"PRIu32, level);
14209 : }
14210 : }
14211 0 : return NDR_ERR_SUCCESS;
14212 : }
14213 :
14214 0 : static enum ndr_err_code ndr_pull_srvsvc_NetTransportInfo(struct ndr_pull *ndr, ndr_flags_type ndr_flags, union srvsvc_NetTransportInfo *r)
14215 : {
14216 0 : uint32_t level;
14217 0 : uint32_t _level;
14218 0 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
14219 0 : if (ndr_flags & NDR_SCALARS) {
14220 : /* This token is not used again (except perhaps below in the NDR_BUFFERS case) */
14221 0 : NDR_CHECK(ndr_pull_steal_switch_value(ndr, r, &level));
14222 0 : NDR_CHECK(ndr_pull_union_align(ndr, 5));
14223 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &_level));
14224 0 : if (_level != level) {
14225 0 : return ndr_pull_error(ndr, NDR_ERR_BAD_SWITCH, "Bad switch value %"PRIu32" for r at %s", (uint32_t)_level, __location__);
14226 : }
14227 0 : NDR_CHECK(ndr_pull_union_align(ndr, 5));
14228 0 : switch (level) {
14229 0 : case 0: {
14230 0 : NDR_CHECK(ndr_pull_srvsvc_NetTransportInfo0(ndr, NDR_SCALARS, &r->info0));
14231 0 : break; }
14232 :
14233 0 : case 1: {
14234 0 : NDR_CHECK(ndr_pull_srvsvc_NetTransportInfo1(ndr, NDR_SCALARS, &r->info1));
14235 0 : break; }
14236 :
14237 0 : case 2: {
14238 0 : NDR_CHECK(ndr_pull_srvsvc_NetTransportInfo2(ndr, NDR_SCALARS, &r->info2));
14239 0 : break; }
14240 :
14241 0 : case 3: {
14242 0 : NDR_CHECK(ndr_pull_srvsvc_NetTransportInfo3(ndr, NDR_SCALARS, &r->info3));
14243 0 : break; }
14244 :
14245 0 : default:
14246 0 : return ndr_pull_error(ndr, NDR_ERR_BAD_SWITCH, "Bad switch value %"PRIu32" at %s", level, __location__);
14247 : }
14248 : }
14249 0 : if (ndr_flags & NDR_BUFFERS) {
14250 0 : if (!(ndr_flags & NDR_SCALARS)) {
14251 : /* We didn't get it above, and the token is not needed after this. */
14252 0 : NDR_CHECK(ndr_pull_steal_switch_value(ndr, r, &level));
14253 : }
14254 0 : switch (level) {
14255 0 : case 0:
14256 0 : NDR_CHECK(ndr_pull_srvsvc_NetTransportInfo0(ndr, NDR_BUFFERS, &r->info0));
14257 0 : break;
14258 :
14259 0 : case 1:
14260 0 : NDR_CHECK(ndr_pull_srvsvc_NetTransportInfo1(ndr, NDR_BUFFERS, &r->info1));
14261 0 : break;
14262 :
14263 0 : case 2:
14264 0 : NDR_CHECK(ndr_pull_srvsvc_NetTransportInfo2(ndr, NDR_BUFFERS, &r->info2));
14265 0 : break;
14266 :
14267 0 : case 3:
14268 0 : NDR_CHECK(ndr_pull_srvsvc_NetTransportInfo3(ndr, NDR_BUFFERS, &r->info3));
14269 0 : break;
14270 :
14271 0 : default:
14272 0 : return ndr_pull_error(ndr, NDR_ERR_BAD_SWITCH, "Bad switch value %"PRIu32" at %s", level, __location__);
14273 : }
14274 : }
14275 0 : return NDR_ERR_SUCCESS;
14276 : }
14277 :
14278 0 : _PUBLIC_ void ndr_print_srvsvc_NetTransportInfo(struct ndr_print *ndr, const char *name, const union srvsvc_NetTransportInfo *r)
14279 : {
14280 0 : uint32_t level;
14281 0 : level = ndr_print_steal_switch_value(ndr, r);
14282 0 : ndr_print_union(ndr, name, level, "srvsvc_NetTransportInfo");
14283 0 : switch (level) {
14284 0 : case 0:
14285 0 : ndr_print_srvsvc_NetTransportInfo0(ndr, "info0", &r->info0);
14286 0 : break;
14287 :
14288 0 : case 1:
14289 0 : ndr_print_srvsvc_NetTransportInfo1(ndr, "info1", &r->info1);
14290 0 : break;
14291 :
14292 0 : case 2:
14293 0 : ndr_print_srvsvc_NetTransportInfo2(ndr, "info2", &r->info2);
14294 0 : break;
14295 :
14296 0 : case 3:
14297 0 : ndr_print_srvsvc_NetTransportInfo3(ndr, "info3", &r->info3);
14298 0 : break;
14299 :
14300 0 : default:
14301 0 : ndr_print_bad_level(ndr, name, level);
14302 : }
14303 0 : }
14304 :
14305 22 : static enum ndr_err_code ndr_push_srvsvc_NetCharDevEnum(struct ndr_push *ndr, ndr_flags_type flags, const struct srvsvc_NetCharDevEnum *r)
14306 : {
14307 22 : NDR_PUSH_CHECK_FN_FLAGS(ndr, flags);
14308 22 : if (flags & NDR_IN) {
14309 12 : if (r->in.info_ctr == NULL) {
14310 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
14311 : }
14312 12 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->in.server_unc));
14313 12 : if (r->in.server_unc) {
14314 12 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->in.server_unc, CH_UTF16)));
14315 12 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, 0));
14316 12 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->in.server_unc, CH_UTF16)));
14317 12 : NDR_CHECK(ndr_push_charset(ndr, NDR_SCALARS, r->in.server_unc, ndr_charset_length(r->in.server_unc, CH_UTF16), sizeof(uint16_t), CH_UTF16));
14318 : }
14319 12 : NDR_CHECK(ndr_push_srvsvc_NetCharDevInfoCtr(ndr, NDR_SCALARS|NDR_BUFFERS, r->in.info_ctr));
14320 12 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->in.max_buffer));
14321 12 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->in.resume_handle));
14322 12 : if (r->in.resume_handle) {
14323 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, *r->in.resume_handle));
14324 : }
14325 : }
14326 22 : if (flags & NDR_OUT) {
14327 10 : if (r->out.info_ctr == NULL) {
14328 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
14329 : }
14330 10 : if (r->out.totalentries == NULL) {
14331 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
14332 : }
14333 10 : NDR_CHECK(ndr_push_srvsvc_NetCharDevInfoCtr(ndr, NDR_SCALARS|NDR_BUFFERS, r->out.info_ctr));
14334 10 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, *r->out.totalentries));
14335 10 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->out.resume_handle));
14336 10 : if (r->out.resume_handle) {
14337 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, *r->out.resume_handle));
14338 : }
14339 10 : NDR_CHECK(ndr_push_WERROR(ndr, NDR_SCALARS, r->out.result));
14340 : }
14341 22 : return NDR_ERR_SUCCESS;
14342 : }
14343 :
14344 20 : static enum ndr_err_code ndr_pull_srvsvc_NetCharDevEnum(struct ndr_pull *ndr, ndr_flags_type flags, struct srvsvc_NetCharDevEnum *r)
14345 : {
14346 0 : uint32_t _ptr_server_unc;
14347 20 : uint32_t size_server_unc_1 = 0;
14348 20 : uint32_t length_server_unc_1 = 0;
14349 0 : uint32_t _ptr_resume_handle;
14350 20 : TALLOC_CTX *_mem_save_server_unc_0 = NULL;
14351 20 : TALLOC_CTX *_mem_save_info_ctr_0 = NULL;
14352 20 : TALLOC_CTX *_mem_save_totalentries_0 = NULL;
14353 20 : TALLOC_CTX *_mem_save_resume_handle_0 = NULL;
14354 20 : NDR_PULL_CHECK_FN_FLAGS(ndr, flags);
14355 20 : if (flags & NDR_IN) {
14356 12 : NDR_ZERO_STRUCT(r->out);
14357 :
14358 12 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_server_unc));
14359 12 : if (_ptr_server_unc) {
14360 12 : NDR_PULL_ALLOC(ndr, r->in.server_unc);
14361 : } else {
14362 0 : r->in.server_unc = NULL;
14363 : }
14364 12 : if (r->in.server_unc) {
14365 12 : _mem_save_server_unc_0 = NDR_PULL_GET_MEM_CTX(ndr);
14366 12 : NDR_PULL_SET_MEM_CTX(ndr, r->in.server_unc, 0);
14367 12 : NDR_CHECK(ndr_pull_array_size(ndr, &r->in.server_unc));
14368 12 : NDR_CHECK(ndr_pull_array_length(ndr, &r->in.server_unc));
14369 12 : NDR_CHECK(ndr_steal_array_size(ndr, (void*)&r->in.server_unc, &size_server_unc_1));
14370 12 : NDR_CHECK(ndr_steal_array_length(ndr, (void*)&r->in.server_unc, &length_server_unc_1));
14371 12 : if (length_server_unc_1 > size_server_unc_1) {
14372 0 : return ndr_pull_error(ndr, NDR_ERR_ARRAY_SIZE, "Bad array size %"PRIu32": should exceed array length %"PRIu32"", size_server_unc_1, length_server_unc_1);
14373 : }
14374 12 : NDR_CHECK(ndr_check_string_terminator(ndr, length_server_unc_1, sizeof(uint16_t)));
14375 12 : NDR_CHECK(ndr_pull_charset(ndr, NDR_SCALARS, &r->in.server_unc, length_server_unc_1, sizeof(uint16_t), CH_UTF16));
14376 12 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_server_unc_0, 0);
14377 : }
14378 12 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
14379 12 : NDR_PULL_ALLOC(ndr, r->in.info_ctr);
14380 : }
14381 12 : _mem_save_info_ctr_0 = NDR_PULL_GET_MEM_CTX(ndr);
14382 12 : NDR_PULL_SET_MEM_CTX(ndr, r->in.info_ctr, LIBNDR_FLAG_REF_ALLOC);
14383 12 : NDR_CHECK(ndr_pull_srvsvc_NetCharDevInfoCtr(ndr, NDR_SCALARS|NDR_BUFFERS, r->in.info_ctr));
14384 12 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_info_ctr_0, LIBNDR_FLAG_REF_ALLOC);
14385 12 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->in.max_buffer));
14386 12 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_resume_handle));
14387 12 : if (_ptr_resume_handle) {
14388 0 : NDR_PULL_ALLOC(ndr, r->in.resume_handle);
14389 : } else {
14390 12 : r->in.resume_handle = NULL;
14391 : }
14392 12 : if (r->in.resume_handle) {
14393 0 : _mem_save_resume_handle_0 = NDR_PULL_GET_MEM_CTX(ndr);
14394 0 : NDR_PULL_SET_MEM_CTX(ndr, r->in.resume_handle, 0);
14395 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, r->in.resume_handle));
14396 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_resume_handle_0, 0);
14397 : }
14398 12 : NDR_PULL_ALLOC(ndr, r->out.info_ctr);
14399 12 : *r->out.info_ctr = *r->in.info_ctr;
14400 12 : NDR_PULL_ALLOC(ndr, r->out.totalentries);
14401 12 : NDR_ZERO_STRUCTP(r->out.totalentries);
14402 : }
14403 20 : if (flags & NDR_OUT) {
14404 : #ifdef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION
14405 : if (r->in.info_ctr == NULL) {
14406 : NDR_PULL_ALLOC(ndr, r->in.info_ctr);
14407 : NDR_ZERO_STRUCTP(r->in.info_ctr);
14408 : }
14409 : #endif /* FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION */
14410 8 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
14411 2 : NDR_PULL_ALLOC(ndr, r->out.info_ctr);
14412 : }
14413 8 : _mem_save_info_ctr_0 = NDR_PULL_GET_MEM_CTX(ndr);
14414 8 : NDR_PULL_SET_MEM_CTX(ndr, r->out.info_ctr, LIBNDR_FLAG_REF_ALLOC);
14415 8 : NDR_CHECK(ndr_pull_srvsvc_NetCharDevInfoCtr(ndr, NDR_SCALARS|NDR_BUFFERS, r->out.info_ctr));
14416 8 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_info_ctr_0, LIBNDR_FLAG_REF_ALLOC);
14417 8 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
14418 2 : NDR_PULL_ALLOC(ndr, r->out.totalentries);
14419 : }
14420 8 : _mem_save_totalentries_0 = NDR_PULL_GET_MEM_CTX(ndr);
14421 8 : NDR_PULL_SET_MEM_CTX(ndr, r->out.totalentries, LIBNDR_FLAG_REF_ALLOC);
14422 8 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, r->out.totalentries));
14423 8 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_totalentries_0, LIBNDR_FLAG_REF_ALLOC);
14424 8 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_resume_handle));
14425 8 : if (_ptr_resume_handle) {
14426 0 : NDR_PULL_ALLOC(ndr, r->out.resume_handle);
14427 : } else {
14428 8 : r->out.resume_handle = NULL;
14429 : }
14430 8 : if (r->out.resume_handle) {
14431 0 : _mem_save_resume_handle_0 = NDR_PULL_GET_MEM_CTX(ndr);
14432 0 : NDR_PULL_SET_MEM_CTX(ndr, r->out.resume_handle, 0);
14433 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, r->out.resume_handle));
14434 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_resume_handle_0, 0);
14435 : }
14436 8 : NDR_CHECK(ndr_pull_WERROR(ndr, NDR_SCALARS, &r->out.result));
14437 : }
14438 20 : return NDR_ERR_SUCCESS;
14439 : }
14440 :
14441 4 : _PUBLIC_ void ndr_print_srvsvc_NetCharDevEnum(struct ndr_print *ndr, const char *name, ndr_flags_type flags, const struct srvsvc_NetCharDevEnum *r)
14442 : {
14443 4 : ndr_print_struct(ndr, name, "srvsvc_NetCharDevEnum");
14444 4 : if (r == NULL) { ndr_print_null(ndr); return; }
14445 4 : ndr->depth++;
14446 4 : if (flags & NDR_SET_VALUES) {
14447 0 : ndr->flags |= LIBNDR_PRINT_SET_VALUES;
14448 : }
14449 4 : if (flags & NDR_IN) {
14450 0 : ndr_print_struct(ndr, "in", "srvsvc_NetCharDevEnum");
14451 0 : ndr->depth++;
14452 0 : ndr_print_ptr(ndr, "server_unc", r->in.server_unc);
14453 0 : ndr->depth++;
14454 0 : if (r->in.server_unc) {
14455 0 : ndr_print_string(ndr, "server_unc", r->in.server_unc);
14456 : }
14457 0 : ndr->depth--;
14458 0 : ndr_print_ptr(ndr, "info_ctr", r->in.info_ctr);
14459 0 : ndr->depth++;
14460 0 : ndr_print_srvsvc_NetCharDevInfoCtr(ndr, "info_ctr", r->in.info_ctr);
14461 0 : ndr->depth--;
14462 0 : ndr_print_uint32(ndr, "max_buffer", r->in.max_buffer);
14463 0 : ndr_print_ptr(ndr, "resume_handle", r->in.resume_handle);
14464 0 : ndr->depth++;
14465 0 : if (r->in.resume_handle) {
14466 0 : ndr_print_uint32(ndr, "resume_handle", *r->in.resume_handle);
14467 : }
14468 0 : ndr->depth--;
14469 0 : ndr->depth--;
14470 : }
14471 4 : if (flags & NDR_OUT) {
14472 4 : ndr_print_struct(ndr, "out", "srvsvc_NetCharDevEnum");
14473 4 : ndr->depth++;
14474 4 : ndr_print_ptr(ndr, "info_ctr", r->out.info_ctr);
14475 4 : ndr->depth++;
14476 4 : ndr_print_srvsvc_NetCharDevInfoCtr(ndr, "info_ctr", r->out.info_ctr);
14477 4 : ndr->depth--;
14478 4 : ndr_print_ptr(ndr, "totalentries", r->out.totalentries);
14479 4 : ndr->depth++;
14480 4 : ndr_print_uint32(ndr, "totalentries", *r->out.totalentries);
14481 4 : ndr->depth--;
14482 4 : ndr_print_ptr(ndr, "resume_handle", r->out.resume_handle);
14483 4 : ndr->depth++;
14484 4 : if (r->out.resume_handle) {
14485 0 : ndr_print_uint32(ndr, "resume_handle", *r->out.resume_handle);
14486 : }
14487 4 : ndr->depth--;
14488 4 : ndr_print_WERROR(ndr, "result", r->out.result);
14489 4 : ndr->depth--;
14490 : }
14491 4 : ndr->depth--;
14492 : }
14493 :
14494 0 : static enum ndr_err_code ndr_push_srvsvc_NetCharDevGetInfo(struct ndr_push *ndr, ndr_flags_type flags, const struct srvsvc_NetCharDevGetInfo *r)
14495 : {
14496 0 : NDR_PUSH_CHECK_FN_FLAGS(ndr, flags);
14497 0 : if (flags & NDR_IN) {
14498 0 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->in.server_unc));
14499 0 : if (r->in.server_unc) {
14500 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->in.server_unc, CH_UTF16)));
14501 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, 0));
14502 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->in.server_unc, CH_UTF16)));
14503 0 : NDR_CHECK(ndr_push_charset(ndr, NDR_SCALARS, r->in.server_unc, ndr_charset_length(r->in.server_unc, CH_UTF16), sizeof(uint16_t), CH_UTF16));
14504 : }
14505 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->in.device_name, CH_UTF16)));
14506 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, 0));
14507 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->in.device_name, CH_UTF16)));
14508 0 : NDR_CHECK(ndr_push_charset(ndr, NDR_SCALARS, r->in.device_name, ndr_charset_length(r->in.device_name, CH_UTF16), sizeof(uint16_t), CH_UTF16));
14509 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->in.level));
14510 : }
14511 0 : if (flags & NDR_OUT) {
14512 0 : if (r->out.info == NULL) {
14513 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
14514 : }
14515 0 : NDR_CHECK(ndr_push_set_switch_value(ndr, r->out.info, r->in.level));
14516 0 : NDR_CHECK(ndr_push_srvsvc_NetCharDevInfo(ndr, NDR_SCALARS|NDR_BUFFERS, r->out.info));
14517 0 : NDR_CHECK(ndr_push_WERROR(ndr, NDR_SCALARS, r->out.result));
14518 : }
14519 0 : return NDR_ERR_SUCCESS;
14520 : }
14521 :
14522 0 : static enum ndr_err_code ndr_pull_srvsvc_NetCharDevGetInfo(struct ndr_pull *ndr, ndr_flags_type flags, struct srvsvc_NetCharDevGetInfo *r)
14523 : {
14524 0 : uint32_t _ptr_server_unc;
14525 0 : uint32_t size_server_unc_1 = 0;
14526 0 : uint32_t length_server_unc_1 = 0;
14527 0 : uint32_t size_device_name_0 = 0;
14528 0 : uint32_t length_device_name_0 = 0;
14529 0 : TALLOC_CTX *_mem_save_server_unc_0 = NULL;
14530 0 : TALLOC_CTX *_mem_save_info_0 = NULL;
14531 0 : NDR_PULL_CHECK_FN_FLAGS(ndr, flags);
14532 0 : if (flags & NDR_IN) {
14533 0 : NDR_ZERO_STRUCT(r->out);
14534 :
14535 0 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_server_unc));
14536 0 : if (_ptr_server_unc) {
14537 0 : NDR_PULL_ALLOC(ndr, r->in.server_unc);
14538 : } else {
14539 0 : r->in.server_unc = NULL;
14540 : }
14541 0 : if (r->in.server_unc) {
14542 0 : _mem_save_server_unc_0 = NDR_PULL_GET_MEM_CTX(ndr);
14543 0 : NDR_PULL_SET_MEM_CTX(ndr, r->in.server_unc, 0);
14544 0 : NDR_CHECK(ndr_pull_array_size(ndr, &r->in.server_unc));
14545 0 : NDR_CHECK(ndr_pull_array_length(ndr, &r->in.server_unc));
14546 0 : NDR_CHECK(ndr_steal_array_size(ndr, (void*)&r->in.server_unc, &size_server_unc_1));
14547 0 : NDR_CHECK(ndr_steal_array_length(ndr, (void*)&r->in.server_unc, &length_server_unc_1));
14548 0 : if (length_server_unc_1 > size_server_unc_1) {
14549 0 : return ndr_pull_error(ndr, NDR_ERR_ARRAY_SIZE, "Bad array size %"PRIu32": should exceed array length %"PRIu32"", size_server_unc_1, length_server_unc_1);
14550 : }
14551 0 : NDR_CHECK(ndr_check_string_terminator(ndr, length_server_unc_1, sizeof(uint16_t)));
14552 0 : NDR_CHECK(ndr_pull_charset(ndr, NDR_SCALARS, &r->in.server_unc, length_server_unc_1, sizeof(uint16_t), CH_UTF16));
14553 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_server_unc_0, 0);
14554 : }
14555 0 : NDR_CHECK(ndr_pull_array_size(ndr, &r->in.device_name));
14556 0 : NDR_CHECK(ndr_pull_array_length(ndr, &r->in.device_name));
14557 0 : NDR_CHECK(ndr_steal_array_size(ndr, (void*)&r->in.device_name, &size_device_name_0));
14558 0 : NDR_CHECK(ndr_steal_array_length(ndr, (void*)&r->in.device_name, &length_device_name_0));
14559 0 : if (length_device_name_0 > size_device_name_0) {
14560 0 : return ndr_pull_error(ndr, NDR_ERR_ARRAY_SIZE, "Bad array size %"PRIu32": should exceed array length %"PRIu32"", size_device_name_0, length_device_name_0);
14561 : }
14562 0 : NDR_CHECK(ndr_check_string_terminator(ndr, length_device_name_0, sizeof(uint16_t)));
14563 0 : NDR_CHECK(ndr_pull_charset(ndr, NDR_SCALARS, &r->in.device_name, length_device_name_0, sizeof(uint16_t), CH_UTF16));
14564 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->in.level));
14565 0 : NDR_PULL_ALLOC(ndr, r->out.info);
14566 0 : NDR_ZERO_STRUCTP(r->out.info);
14567 : }
14568 0 : if (flags & NDR_OUT) {
14569 : #ifdef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION
14570 : #endif /* FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION */
14571 0 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
14572 0 : NDR_PULL_ALLOC(ndr, r->out.info);
14573 : }
14574 0 : _mem_save_info_0 = NDR_PULL_GET_MEM_CTX(ndr);
14575 0 : NDR_PULL_SET_MEM_CTX(ndr, r->out.info, LIBNDR_FLAG_REF_ALLOC);
14576 0 : NDR_CHECK(ndr_pull_set_switch_value(ndr, r->out.info, r->in.level));
14577 0 : NDR_CHECK(ndr_pull_srvsvc_NetCharDevInfo(ndr, NDR_SCALARS|NDR_BUFFERS, r->out.info));
14578 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_info_0, LIBNDR_FLAG_REF_ALLOC);
14579 0 : NDR_CHECK(ndr_pull_WERROR(ndr, NDR_SCALARS, &r->out.result));
14580 : }
14581 0 : return NDR_ERR_SUCCESS;
14582 : }
14583 :
14584 0 : _PUBLIC_ void ndr_print_srvsvc_NetCharDevGetInfo(struct ndr_print *ndr, const char *name, ndr_flags_type flags, const struct srvsvc_NetCharDevGetInfo *r)
14585 : {
14586 0 : ndr_print_struct(ndr, name, "srvsvc_NetCharDevGetInfo");
14587 0 : if (r == NULL) { ndr_print_null(ndr); return; }
14588 0 : ndr->depth++;
14589 0 : if (flags & NDR_SET_VALUES) {
14590 0 : ndr->flags |= LIBNDR_PRINT_SET_VALUES;
14591 : }
14592 0 : if (flags & NDR_IN) {
14593 0 : ndr_print_struct(ndr, "in", "srvsvc_NetCharDevGetInfo");
14594 0 : ndr->depth++;
14595 0 : ndr_print_ptr(ndr, "server_unc", r->in.server_unc);
14596 0 : ndr->depth++;
14597 0 : if (r->in.server_unc) {
14598 0 : ndr_print_string(ndr, "server_unc", r->in.server_unc);
14599 : }
14600 0 : ndr->depth--;
14601 0 : ndr_print_string(ndr, "device_name", r->in.device_name);
14602 0 : ndr_print_uint32(ndr, "level", r->in.level);
14603 0 : ndr->depth--;
14604 : }
14605 0 : if (flags & NDR_OUT) {
14606 0 : ndr_print_struct(ndr, "out", "srvsvc_NetCharDevGetInfo");
14607 0 : ndr->depth++;
14608 0 : ndr_print_ptr(ndr, "info", r->out.info);
14609 0 : ndr->depth++;
14610 0 : ndr_print_set_switch_value(ndr, r->out.info, r->in.level);
14611 0 : ndr_print_srvsvc_NetCharDevInfo(ndr, "info", r->out.info);
14612 0 : ndr->depth--;
14613 0 : ndr_print_WERROR(ndr, "result", r->out.result);
14614 0 : ndr->depth--;
14615 : }
14616 0 : ndr->depth--;
14617 : }
14618 :
14619 0 : static enum ndr_err_code ndr_push_srvsvc_NetCharDevControl(struct ndr_push *ndr, ndr_flags_type flags, const struct srvsvc_NetCharDevControl *r)
14620 : {
14621 0 : NDR_PUSH_CHECK_FN_FLAGS(ndr, flags);
14622 0 : if (flags & NDR_IN) {
14623 0 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->in.server_unc));
14624 0 : if (r->in.server_unc) {
14625 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->in.server_unc, CH_UTF16)));
14626 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, 0));
14627 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->in.server_unc, CH_UTF16)));
14628 0 : NDR_CHECK(ndr_push_charset(ndr, NDR_SCALARS, r->in.server_unc, ndr_charset_length(r->in.server_unc, CH_UTF16), sizeof(uint16_t), CH_UTF16));
14629 : }
14630 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->in.device_name, CH_UTF16)));
14631 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, 0));
14632 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->in.device_name, CH_UTF16)));
14633 0 : NDR_CHECK(ndr_push_charset(ndr, NDR_SCALARS, r->in.device_name, ndr_charset_length(r->in.device_name, CH_UTF16), sizeof(uint16_t), CH_UTF16));
14634 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->in.opcode));
14635 : }
14636 0 : if (flags & NDR_OUT) {
14637 0 : NDR_CHECK(ndr_push_WERROR(ndr, NDR_SCALARS, r->out.result));
14638 : }
14639 0 : return NDR_ERR_SUCCESS;
14640 : }
14641 :
14642 0 : static enum ndr_err_code ndr_pull_srvsvc_NetCharDevControl(struct ndr_pull *ndr, ndr_flags_type flags, struct srvsvc_NetCharDevControl *r)
14643 : {
14644 0 : uint32_t _ptr_server_unc;
14645 0 : uint32_t size_server_unc_1 = 0;
14646 0 : uint32_t length_server_unc_1 = 0;
14647 0 : uint32_t size_device_name_0 = 0;
14648 0 : uint32_t length_device_name_0 = 0;
14649 0 : TALLOC_CTX *_mem_save_server_unc_0 = NULL;
14650 0 : NDR_PULL_CHECK_FN_FLAGS(ndr, flags);
14651 0 : if (flags & NDR_IN) {
14652 0 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_server_unc));
14653 0 : if (_ptr_server_unc) {
14654 0 : NDR_PULL_ALLOC(ndr, r->in.server_unc);
14655 : } else {
14656 0 : r->in.server_unc = NULL;
14657 : }
14658 0 : if (r->in.server_unc) {
14659 0 : _mem_save_server_unc_0 = NDR_PULL_GET_MEM_CTX(ndr);
14660 0 : NDR_PULL_SET_MEM_CTX(ndr, r->in.server_unc, 0);
14661 0 : NDR_CHECK(ndr_pull_array_size(ndr, &r->in.server_unc));
14662 0 : NDR_CHECK(ndr_pull_array_length(ndr, &r->in.server_unc));
14663 0 : NDR_CHECK(ndr_steal_array_size(ndr, (void*)&r->in.server_unc, &size_server_unc_1));
14664 0 : NDR_CHECK(ndr_steal_array_length(ndr, (void*)&r->in.server_unc, &length_server_unc_1));
14665 0 : if (length_server_unc_1 > size_server_unc_1) {
14666 0 : return ndr_pull_error(ndr, NDR_ERR_ARRAY_SIZE, "Bad array size %"PRIu32": should exceed array length %"PRIu32"", size_server_unc_1, length_server_unc_1);
14667 : }
14668 0 : NDR_CHECK(ndr_check_string_terminator(ndr, length_server_unc_1, sizeof(uint16_t)));
14669 0 : NDR_CHECK(ndr_pull_charset(ndr, NDR_SCALARS, &r->in.server_unc, length_server_unc_1, sizeof(uint16_t), CH_UTF16));
14670 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_server_unc_0, 0);
14671 : }
14672 0 : NDR_CHECK(ndr_pull_array_size(ndr, &r->in.device_name));
14673 0 : NDR_CHECK(ndr_pull_array_length(ndr, &r->in.device_name));
14674 0 : NDR_CHECK(ndr_steal_array_size(ndr, (void*)&r->in.device_name, &size_device_name_0));
14675 0 : NDR_CHECK(ndr_steal_array_length(ndr, (void*)&r->in.device_name, &length_device_name_0));
14676 0 : if (length_device_name_0 > size_device_name_0) {
14677 0 : return ndr_pull_error(ndr, NDR_ERR_ARRAY_SIZE, "Bad array size %"PRIu32": should exceed array length %"PRIu32"", size_device_name_0, length_device_name_0);
14678 : }
14679 0 : NDR_CHECK(ndr_check_string_terminator(ndr, length_device_name_0, sizeof(uint16_t)));
14680 0 : NDR_CHECK(ndr_pull_charset(ndr, NDR_SCALARS, &r->in.device_name, length_device_name_0, sizeof(uint16_t), CH_UTF16));
14681 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->in.opcode));
14682 : }
14683 0 : if (flags & NDR_OUT) {
14684 : #ifdef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION
14685 : #endif /* FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION */
14686 0 : NDR_CHECK(ndr_pull_WERROR(ndr, NDR_SCALARS, &r->out.result));
14687 : }
14688 0 : return NDR_ERR_SUCCESS;
14689 : }
14690 :
14691 0 : _PUBLIC_ void ndr_print_srvsvc_NetCharDevControl(struct ndr_print *ndr, const char *name, ndr_flags_type flags, const struct srvsvc_NetCharDevControl *r)
14692 : {
14693 0 : ndr_print_struct(ndr, name, "srvsvc_NetCharDevControl");
14694 0 : if (r == NULL) { ndr_print_null(ndr); return; }
14695 0 : ndr->depth++;
14696 0 : if (flags & NDR_SET_VALUES) {
14697 0 : ndr->flags |= LIBNDR_PRINT_SET_VALUES;
14698 : }
14699 0 : if (flags & NDR_IN) {
14700 0 : ndr_print_struct(ndr, "in", "srvsvc_NetCharDevControl");
14701 0 : ndr->depth++;
14702 0 : ndr_print_ptr(ndr, "server_unc", r->in.server_unc);
14703 0 : ndr->depth++;
14704 0 : if (r->in.server_unc) {
14705 0 : ndr_print_string(ndr, "server_unc", r->in.server_unc);
14706 : }
14707 0 : ndr->depth--;
14708 0 : ndr_print_string(ndr, "device_name", r->in.device_name);
14709 0 : ndr_print_uint32(ndr, "opcode", r->in.opcode);
14710 0 : ndr->depth--;
14711 : }
14712 0 : if (flags & NDR_OUT) {
14713 0 : ndr_print_struct(ndr, "out", "srvsvc_NetCharDevControl");
14714 0 : ndr->depth++;
14715 0 : ndr_print_WERROR(ndr, "result", r->out.result);
14716 0 : ndr->depth--;
14717 : }
14718 0 : ndr->depth--;
14719 : }
14720 :
14721 22 : static enum ndr_err_code ndr_push_srvsvc_NetCharDevQEnum(struct ndr_push *ndr, ndr_flags_type flags, const struct srvsvc_NetCharDevQEnum *r)
14722 : {
14723 22 : NDR_PUSH_CHECK_FN_FLAGS(ndr, flags);
14724 22 : if (flags & NDR_IN) {
14725 12 : if (r->in.info_ctr == NULL) {
14726 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
14727 : }
14728 12 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->in.server_unc));
14729 12 : if (r->in.server_unc) {
14730 12 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->in.server_unc, CH_UTF16)));
14731 12 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, 0));
14732 12 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->in.server_unc, CH_UTF16)));
14733 12 : NDR_CHECK(ndr_push_charset(ndr, NDR_SCALARS, r->in.server_unc, ndr_charset_length(r->in.server_unc, CH_UTF16), sizeof(uint16_t), CH_UTF16));
14734 : }
14735 12 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->in.user));
14736 12 : if (r->in.user) {
14737 12 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->in.user, CH_UTF16)));
14738 12 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, 0));
14739 12 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->in.user, CH_UTF16)));
14740 12 : NDR_CHECK(ndr_push_charset(ndr, NDR_SCALARS, r->in.user, ndr_charset_length(r->in.user, CH_UTF16), sizeof(uint16_t), CH_UTF16));
14741 : }
14742 12 : NDR_CHECK(ndr_push_srvsvc_NetCharDevQInfoCtr(ndr, NDR_SCALARS|NDR_BUFFERS, r->in.info_ctr));
14743 12 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->in.max_buffer));
14744 12 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->in.resume_handle));
14745 12 : if (r->in.resume_handle) {
14746 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, *r->in.resume_handle));
14747 : }
14748 : }
14749 22 : if (flags & NDR_OUT) {
14750 10 : if (r->out.info_ctr == NULL) {
14751 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
14752 : }
14753 10 : if (r->out.totalentries == NULL) {
14754 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
14755 : }
14756 10 : NDR_CHECK(ndr_push_srvsvc_NetCharDevQInfoCtr(ndr, NDR_SCALARS|NDR_BUFFERS, r->out.info_ctr));
14757 10 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, *r->out.totalentries));
14758 10 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->out.resume_handle));
14759 10 : if (r->out.resume_handle) {
14760 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, *r->out.resume_handle));
14761 : }
14762 10 : NDR_CHECK(ndr_push_WERROR(ndr, NDR_SCALARS, r->out.result));
14763 : }
14764 22 : return NDR_ERR_SUCCESS;
14765 : }
14766 :
14767 20 : static enum ndr_err_code ndr_pull_srvsvc_NetCharDevQEnum(struct ndr_pull *ndr, ndr_flags_type flags, struct srvsvc_NetCharDevQEnum *r)
14768 : {
14769 0 : uint32_t _ptr_server_unc;
14770 20 : uint32_t size_server_unc_1 = 0;
14771 20 : uint32_t length_server_unc_1 = 0;
14772 0 : uint32_t _ptr_user;
14773 20 : uint32_t size_user_1 = 0;
14774 20 : uint32_t length_user_1 = 0;
14775 0 : uint32_t _ptr_resume_handle;
14776 20 : TALLOC_CTX *_mem_save_server_unc_0 = NULL;
14777 20 : TALLOC_CTX *_mem_save_user_0 = NULL;
14778 20 : TALLOC_CTX *_mem_save_info_ctr_0 = NULL;
14779 20 : TALLOC_CTX *_mem_save_totalentries_0 = NULL;
14780 20 : TALLOC_CTX *_mem_save_resume_handle_0 = NULL;
14781 20 : NDR_PULL_CHECK_FN_FLAGS(ndr, flags);
14782 20 : if (flags & NDR_IN) {
14783 12 : NDR_ZERO_STRUCT(r->out);
14784 :
14785 12 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_server_unc));
14786 12 : if (_ptr_server_unc) {
14787 12 : NDR_PULL_ALLOC(ndr, r->in.server_unc);
14788 : } else {
14789 0 : r->in.server_unc = NULL;
14790 : }
14791 12 : if (r->in.server_unc) {
14792 12 : _mem_save_server_unc_0 = NDR_PULL_GET_MEM_CTX(ndr);
14793 12 : NDR_PULL_SET_MEM_CTX(ndr, r->in.server_unc, 0);
14794 12 : NDR_CHECK(ndr_pull_array_size(ndr, &r->in.server_unc));
14795 12 : NDR_CHECK(ndr_pull_array_length(ndr, &r->in.server_unc));
14796 12 : NDR_CHECK(ndr_steal_array_size(ndr, (void*)&r->in.server_unc, &size_server_unc_1));
14797 12 : NDR_CHECK(ndr_steal_array_length(ndr, (void*)&r->in.server_unc, &length_server_unc_1));
14798 12 : if (length_server_unc_1 > size_server_unc_1) {
14799 0 : return ndr_pull_error(ndr, NDR_ERR_ARRAY_SIZE, "Bad array size %"PRIu32": should exceed array length %"PRIu32"", size_server_unc_1, length_server_unc_1);
14800 : }
14801 12 : NDR_CHECK(ndr_check_string_terminator(ndr, length_server_unc_1, sizeof(uint16_t)));
14802 12 : NDR_CHECK(ndr_pull_charset(ndr, NDR_SCALARS, &r->in.server_unc, length_server_unc_1, sizeof(uint16_t), CH_UTF16));
14803 12 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_server_unc_0, 0);
14804 : }
14805 12 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_user));
14806 12 : if (_ptr_user) {
14807 12 : NDR_PULL_ALLOC(ndr, r->in.user);
14808 : } else {
14809 0 : r->in.user = NULL;
14810 : }
14811 12 : if (r->in.user) {
14812 12 : _mem_save_user_0 = NDR_PULL_GET_MEM_CTX(ndr);
14813 12 : NDR_PULL_SET_MEM_CTX(ndr, r->in.user, 0);
14814 12 : NDR_CHECK(ndr_pull_array_size(ndr, &r->in.user));
14815 12 : NDR_CHECK(ndr_pull_array_length(ndr, &r->in.user));
14816 12 : NDR_CHECK(ndr_steal_array_size(ndr, (void*)&r->in.user, &size_user_1));
14817 12 : NDR_CHECK(ndr_steal_array_length(ndr, (void*)&r->in.user, &length_user_1));
14818 12 : if (length_user_1 > size_user_1) {
14819 0 : return ndr_pull_error(ndr, NDR_ERR_ARRAY_SIZE, "Bad array size %"PRIu32": should exceed array length %"PRIu32"", size_user_1, length_user_1);
14820 : }
14821 12 : NDR_CHECK(ndr_check_string_terminator(ndr, length_user_1, sizeof(uint16_t)));
14822 12 : NDR_CHECK(ndr_pull_charset(ndr, NDR_SCALARS, &r->in.user, length_user_1, sizeof(uint16_t), CH_UTF16));
14823 12 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_user_0, 0);
14824 : }
14825 12 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
14826 12 : NDR_PULL_ALLOC(ndr, r->in.info_ctr);
14827 : }
14828 12 : _mem_save_info_ctr_0 = NDR_PULL_GET_MEM_CTX(ndr);
14829 12 : NDR_PULL_SET_MEM_CTX(ndr, r->in.info_ctr, LIBNDR_FLAG_REF_ALLOC);
14830 12 : NDR_CHECK(ndr_pull_srvsvc_NetCharDevQInfoCtr(ndr, NDR_SCALARS|NDR_BUFFERS, r->in.info_ctr));
14831 12 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_info_ctr_0, LIBNDR_FLAG_REF_ALLOC);
14832 12 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->in.max_buffer));
14833 12 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_resume_handle));
14834 12 : if (_ptr_resume_handle) {
14835 0 : NDR_PULL_ALLOC(ndr, r->in.resume_handle);
14836 : } else {
14837 12 : r->in.resume_handle = NULL;
14838 : }
14839 12 : if (r->in.resume_handle) {
14840 0 : _mem_save_resume_handle_0 = NDR_PULL_GET_MEM_CTX(ndr);
14841 0 : NDR_PULL_SET_MEM_CTX(ndr, r->in.resume_handle, 0);
14842 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, r->in.resume_handle));
14843 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_resume_handle_0, 0);
14844 : }
14845 12 : NDR_PULL_ALLOC(ndr, r->out.info_ctr);
14846 12 : *r->out.info_ctr = *r->in.info_ctr;
14847 12 : NDR_PULL_ALLOC(ndr, r->out.totalentries);
14848 12 : NDR_ZERO_STRUCTP(r->out.totalentries);
14849 : }
14850 20 : if (flags & NDR_OUT) {
14851 : #ifdef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION
14852 : if (r->in.info_ctr == NULL) {
14853 : NDR_PULL_ALLOC(ndr, r->in.info_ctr);
14854 : NDR_ZERO_STRUCTP(r->in.info_ctr);
14855 : }
14856 : #endif /* FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION */
14857 8 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
14858 2 : NDR_PULL_ALLOC(ndr, r->out.info_ctr);
14859 : }
14860 8 : _mem_save_info_ctr_0 = NDR_PULL_GET_MEM_CTX(ndr);
14861 8 : NDR_PULL_SET_MEM_CTX(ndr, r->out.info_ctr, LIBNDR_FLAG_REF_ALLOC);
14862 8 : NDR_CHECK(ndr_pull_srvsvc_NetCharDevQInfoCtr(ndr, NDR_SCALARS|NDR_BUFFERS, r->out.info_ctr));
14863 8 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_info_ctr_0, LIBNDR_FLAG_REF_ALLOC);
14864 8 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
14865 2 : NDR_PULL_ALLOC(ndr, r->out.totalentries);
14866 : }
14867 8 : _mem_save_totalentries_0 = NDR_PULL_GET_MEM_CTX(ndr);
14868 8 : NDR_PULL_SET_MEM_CTX(ndr, r->out.totalentries, LIBNDR_FLAG_REF_ALLOC);
14869 8 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, r->out.totalentries));
14870 8 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_totalentries_0, LIBNDR_FLAG_REF_ALLOC);
14871 8 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_resume_handle));
14872 8 : if (_ptr_resume_handle) {
14873 0 : NDR_PULL_ALLOC(ndr, r->out.resume_handle);
14874 : } else {
14875 8 : r->out.resume_handle = NULL;
14876 : }
14877 8 : if (r->out.resume_handle) {
14878 0 : _mem_save_resume_handle_0 = NDR_PULL_GET_MEM_CTX(ndr);
14879 0 : NDR_PULL_SET_MEM_CTX(ndr, r->out.resume_handle, 0);
14880 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, r->out.resume_handle));
14881 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_resume_handle_0, 0);
14882 : }
14883 8 : NDR_CHECK(ndr_pull_WERROR(ndr, NDR_SCALARS, &r->out.result));
14884 : }
14885 20 : return NDR_ERR_SUCCESS;
14886 : }
14887 :
14888 4 : _PUBLIC_ void ndr_print_srvsvc_NetCharDevQEnum(struct ndr_print *ndr, const char *name, ndr_flags_type flags, const struct srvsvc_NetCharDevQEnum *r)
14889 : {
14890 4 : ndr_print_struct(ndr, name, "srvsvc_NetCharDevQEnum");
14891 4 : if (r == NULL) { ndr_print_null(ndr); return; }
14892 4 : ndr->depth++;
14893 4 : if (flags & NDR_SET_VALUES) {
14894 0 : ndr->flags |= LIBNDR_PRINT_SET_VALUES;
14895 : }
14896 4 : if (flags & NDR_IN) {
14897 0 : ndr_print_struct(ndr, "in", "srvsvc_NetCharDevQEnum");
14898 0 : ndr->depth++;
14899 0 : ndr_print_ptr(ndr, "server_unc", r->in.server_unc);
14900 0 : ndr->depth++;
14901 0 : if (r->in.server_unc) {
14902 0 : ndr_print_string(ndr, "server_unc", r->in.server_unc);
14903 : }
14904 0 : ndr->depth--;
14905 0 : ndr_print_ptr(ndr, "user", r->in.user);
14906 0 : ndr->depth++;
14907 0 : if (r->in.user) {
14908 0 : ndr_print_string(ndr, "user", r->in.user);
14909 : }
14910 0 : ndr->depth--;
14911 0 : ndr_print_ptr(ndr, "info_ctr", r->in.info_ctr);
14912 0 : ndr->depth++;
14913 0 : ndr_print_srvsvc_NetCharDevQInfoCtr(ndr, "info_ctr", r->in.info_ctr);
14914 0 : ndr->depth--;
14915 0 : ndr_print_uint32(ndr, "max_buffer", r->in.max_buffer);
14916 0 : ndr_print_ptr(ndr, "resume_handle", r->in.resume_handle);
14917 0 : ndr->depth++;
14918 0 : if (r->in.resume_handle) {
14919 0 : ndr_print_uint32(ndr, "resume_handle", *r->in.resume_handle);
14920 : }
14921 0 : ndr->depth--;
14922 0 : ndr->depth--;
14923 : }
14924 4 : if (flags & NDR_OUT) {
14925 4 : ndr_print_struct(ndr, "out", "srvsvc_NetCharDevQEnum");
14926 4 : ndr->depth++;
14927 4 : ndr_print_ptr(ndr, "info_ctr", r->out.info_ctr);
14928 4 : ndr->depth++;
14929 4 : ndr_print_srvsvc_NetCharDevQInfoCtr(ndr, "info_ctr", r->out.info_ctr);
14930 4 : ndr->depth--;
14931 4 : ndr_print_ptr(ndr, "totalentries", r->out.totalentries);
14932 4 : ndr->depth++;
14933 4 : ndr_print_uint32(ndr, "totalentries", *r->out.totalentries);
14934 4 : ndr->depth--;
14935 4 : ndr_print_ptr(ndr, "resume_handle", r->out.resume_handle);
14936 4 : ndr->depth++;
14937 4 : if (r->out.resume_handle) {
14938 0 : ndr_print_uint32(ndr, "resume_handle", *r->out.resume_handle);
14939 : }
14940 4 : ndr->depth--;
14941 4 : ndr_print_WERROR(ndr, "result", r->out.result);
14942 4 : ndr->depth--;
14943 : }
14944 4 : ndr->depth--;
14945 : }
14946 :
14947 0 : static enum ndr_err_code ndr_push_srvsvc_NetCharDevQGetInfo(struct ndr_push *ndr, ndr_flags_type flags, const struct srvsvc_NetCharDevQGetInfo *r)
14948 : {
14949 0 : NDR_PUSH_CHECK_FN_FLAGS(ndr, flags);
14950 0 : if (flags & NDR_IN) {
14951 0 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->in.server_unc));
14952 0 : if (r->in.server_unc) {
14953 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->in.server_unc, CH_UTF16)));
14954 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, 0));
14955 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->in.server_unc, CH_UTF16)));
14956 0 : NDR_CHECK(ndr_push_charset(ndr, NDR_SCALARS, r->in.server_unc, ndr_charset_length(r->in.server_unc, CH_UTF16), sizeof(uint16_t), CH_UTF16));
14957 : }
14958 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->in.queue_name, CH_UTF16)));
14959 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, 0));
14960 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->in.queue_name, CH_UTF16)));
14961 0 : NDR_CHECK(ndr_push_charset(ndr, NDR_SCALARS, r->in.queue_name, ndr_charset_length(r->in.queue_name, CH_UTF16), sizeof(uint16_t), CH_UTF16));
14962 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->in.user, CH_UTF16)));
14963 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, 0));
14964 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->in.user, CH_UTF16)));
14965 0 : NDR_CHECK(ndr_push_charset(ndr, NDR_SCALARS, r->in.user, ndr_charset_length(r->in.user, CH_UTF16), sizeof(uint16_t), CH_UTF16));
14966 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->in.level));
14967 : }
14968 0 : if (flags & NDR_OUT) {
14969 0 : if (r->out.info == NULL) {
14970 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
14971 : }
14972 0 : NDR_CHECK(ndr_push_set_switch_value(ndr, r->out.info, r->in.level));
14973 0 : NDR_CHECK(ndr_push_srvsvc_NetCharDevQInfo(ndr, NDR_SCALARS|NDR_BUFFERS, r->out.info));
14974 0 : NDR_CHECK(ndr_push_WERROR(ndr, NDR_SCALARS, r->out.result));
14975 : }
14976 0 : return NDR_ERR_SUCCESS;
14977 : }
14978 :
14979 0 : static enum ndr_err_code ndr_pull_srvsvc_NetCharDevQGetInfo(struct ndr_pull *ndr, ndr_flags_type flags, struct srvsvc_NetCharDevQGetInfo *r)
14980 : {
14981 0 : uint32_t _ptr_server_unc;
14982 0 : uint32_t size_server_unc_1 = 0;
14983 0 : uint32_t length_server_unc_1 = 0;
14984 0 : uint32_t size_queue_name_0 = 0;
14985 0 : uint32_t length_queue_name_0 = 0;
14986 0 : uint32_t size_user_0 = 0;
14987 0 : uint32_t length_user_0 = 0;
14988 0 : TALLOC_CTX *_mem_save_server_unc_0 = NULL;
14989 0 : TALLOC_CTX *_mem_save_info_0 = NULL;
14990 0 : NDR_PULL_CHECK_FN_FLAGS(ndr, flags);
14991 0 : if (flags & NDR_IN) {
14992 0 : NDR_ZERO_STRUCT(r->out);
14993 :
14994 0 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_server_unc));
14995 0 : if (_ptr_server_unc) {
14996 0 : NDR_PULL_ALLOC(ndr, r->in.server_unc);
14997 : } else {
14998 0 : r->in.server_unc = NULL;
14999 : }
15000 0 : if (r->in.server_unc) {
15001 0 : _mem_save_server_unc_0 = NDR_PULL_GET_MEM_CTX(ndr);
15002 0 : NDR_PULL_SET_MEM_CTX(ndr, r->in.server_unc, 0);
15003 0 : NDR_CHECK(ndr_pull_array_size(ndr, &r->in.server_unc));
15004 0 : NDR_CHECK(ndr_pull_array_length(ndr, &r->in.server_unc));
15005 0 : NDR_CHECK(ndr_steal_array_size(ndr, (void*)&r->in.server_unc, &size_server_unc_1));
15006 0 : NDR_CHECK(ndr_steal_array_length(ndr, (void*)&r->in.server_unc, &length_server_unc_1));
15007 0 : if (length_server_unc_1 > size_server_unc_1) {
15008 0 : return ndr_pull_error(ndr, NDR_ERR_ARRAY_SIZE, "Bad array size %"PRIu32": should exceed array length %"PRIu32"", size_server_unc_1, length_server_unc_1);
15009 : }
15010 0 : NDR_CHECK(ndr_check_string_terminator(ndr, length_server_unc_1, sizeof(uint16_t)));
15011 0 : NDR_CHECK(ndr_pull_charset(ndr, NDR_SCALARS, &r->in.server_unc, length_server_unc_1, sizeof(uint16_t), CH_UTF16));
15012 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_server_unc_0, 0);
15013 : }
15014 0 : NDR_CHECK(ndr_pull_array_size(ndr, &r->in.queue_name));
15015 0 : NDR_CHECK(ndr_pull_array_length(ndr, &r->in.queue_name));
15016 0 : NDR_CHECK(ndr_steal_array_size(ndr, (void*)&r->in.queue_name, &size_queue_name_0));
15017 0 : NDR_CHECK(ndr_steal_array_length(ndr, (void*)&r->in.queue_name, &length_queue_name_0));
15018 0 : if (length_queue_name_0 > size_queue_name_0) {
15019 0 : return ndr_pull_error(ndr, NDR_ERR_ARRAY_SIZE, "Bad array size %"PRIu32": should exceed array length %"PRIu32"", size_queue_name_0, length_queue_name_0);
15020 : }
15021 0 : NDR_CHECK(ndr_check_string_terminator(ndr, length_queue_name_0, sizeof(uint16_t)));
15022 0 : NDR_CHECK(ndr_pull_charset(ndr, NDR_SCALARS, &r->in.queue_name, length_queue_name_0, sizeof(uint16_t), CH_UTF16));
15023 0 : NDR_CHECK(ndr_pull_array_size(ndr, &r->in.user));
15024 0 : NDR_CHECK(ndr_pull_array_length(ndr, &r->in.user));
15025 0 : NDR_CHECK(ndr_steal_array_size(ndr, (void*)&r->in.user, &size_user_0));
15026 0 : NDR_CHECK(ndr_steal_array_length(ndr, (void*)&r->in.user, &length_user_0));
15027 0 : if (length_user_0 > size_user_0) {
15028 0 : return ndr_pull_error(ndr, NDR_ERR_ARRAY_SIZE, "Bad array size %"PRIu32": should exceed array length %"PRIu32"", size_user_0, length_user_0);
15029 : }
15030 0 : NDR_CHECK(ndr_check_string_terminator(ndr, length_user_0, sizeof(uint16_t)));
15031 0 : NDR_CHECK(ndr_pull_charset(ndr, NDR_SCALARS, &r->in.user, length_user_0, sizeof(uint16_t), CH_UTF16));
15032 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->in.level));
15033 0 : NDR_PULL_ALLOC(ndr, r->out.info);
15034 0 : NDR_ZERO_STRUCTP(r->out.info);
15035 : }
15036 0 : if (flags & NDR_OUT) {
15037 : #ifdef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION
15038 : #endif /* FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION */
15039 0 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
15040 0 : NDR_PULL_ALLOC(ndr, r->out.info);
15041 : }
15042 0 : _mem_save_info_0 = NDR_PULL_GET_MEM_CTX(ndr);
15043 0 : NDR_PULL_SET_MEM_CTX(ndr, r->out.info, LIBNDR_FLAG_REF_ALLOC);
15044 0 : NDR_CHECK(ndr_pull_set_switch_value(ndr, r->out.info, r->in.level));
15045 0 : NDR_CHECK(ndr_pull_srvsvc_NetCharDevQInfo(ndr, NDR_SCALARS|NDR_BUFFERS, r->out.info));
15046 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_info_0, LIBNDR_FLAG_REF_ALLOC);
15047 0 : NDR_CHECK(ndr_pull_WERROR(ndr, NDR_SCALARS, &r->out.result));
15048 : }
15049 0 : return NDR_ERR_SUCCESS;
15050 : }
15051 :
15052 0 : _PUBLIC_ void ndr_print_srvsvc_NetCharDevQGetInfo(struct ndr_print *ndr, const char *name, ndr_flags_type flags, const struct srvsvc_NetCharDevQGetInfo *r)
15053 : {
15054 0 : ndr_print_struct(ndr, name, "srvsvc_NetCharDevQGetInfo");
15055 0 : if (r == NULL) { ndr_print_null(ndr); return; }
15056 0 : ndr->depth++;
15057 0 : if (flags & NDR_SET_VALUES) {
15058 0 : ndr->flags |= LIBNDR_PRINT_SET_VALUES;
15059 : }
15060 0 : if (flags & NDR_IN) {
15061 0 : ndr_print_struct(ndr, "in", "srvsvc_NetCharDevQGetInfo");
15062 0 : ndr->depth++;
15063 0 : ndr_print_ptr(ndr, "server_unc", r->in.server_unc);
15064 0 : ndr->depth++;
15065 0 : if (r->in.server_unc) {
15066 0 : ndr_print_string(ndr, "server_unc", r->in.server_unc);
15067 : }
15068 0 : ndr->depth--;
15069 0 : ndr_print_string(ndr, "queue_name", r->in.queue_name);
15070 0 : ndr_print_string(ndr, "user", r->in.user);
15071 0 : ndr_print_uint32(ndr, "level", r->in.level);
15072 0 : ndr->depth--;
15073 : }
15074 0 : if (flags & NDR_OUT) {
15075 0 : ndr_print_struct(ndr, "out", "srvsvc_NetCharDevQGetInfo");
15076 0 : ndr->depth++;
15077 0 : ndr_print_ptr(ndr, "info", r->out.info);
15078 0 : ndr->depth++;
15079 0 : ndr_print_set_switch_value(ndr, r->out.info, r->in.level);
15080 0 : ndr_print_srvsvc_NetCharDevQInfo(ndr, "info", r->out.info);
15081 0 : ndr->depth--;
15082 0 : ndr_print_WERROR(ndr, "result", r->out.result);
15083 0 : ndr->depth--;
15084 : }
15085 0 : ndr->depth--;
15086 : }
15087 :
15088 0 : static enum ndr_err_code ndr_push_srvsvc_NetCharDevQSetInfo(struct ndr_push *ndr, ndr_flags_type flags, const struct srvsvc_NetCharDevQSetInfo *r)
15089 : {
15090 0 : NDR_PUSH_CHECK_FN_FLAGS(ndr, flags);
15091 0 : if (flags & NDR_IN) {
15092 0 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->in.server_unc));
15093 0 : if (r->in.server_unc) {
15094 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->in.server_unc, CH_UTF16)));
15095 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, 0));
15096 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->in.server_unc, CH_UTF16)));
15097 0 : NDR_CHECK(ndr_push_charset(ndr, NDR_SCALARS, r->in.server_unc, ndr_charset_length(r->in.server_unc, CH_UTF16), sizeof(uint16_t), CH_UTF16));
15098 : }
15099 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->in.queue_name, CH_UTF16)));
15100 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, 0));
15101 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->in.queue_name, CH_UTF16)));
15102 0 : NDR_CHECK(ndr_push_charset(ndr, NDR_SCALARS, r->in.queue_name, ndr_charset_length(r->in.queue_name, CH_UTF16), sizeof(uint16_t), CH_UTF16));
15103 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->in.level));
15104 0 : NDR_CHECK(ndr_push_set_switch_value(ndr, &r->in.info, r->in.level));
15105 0 : NDR_CHECK(ndr_push_srvsvc_NetCharDevQInfo(ndr, NDR_SCALARS|NDR_BUFFERS, &r->in.info));
15106 0 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->in.parm_error));
15107 0 : if (r->in.parm_error) {
15108 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, *r->in.parm_error));
15109 : }
15110 : }
15111 0 : if (flags & NDR_OUT) {
15112 0 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->out.parm_error));
15113 0 : if (r->out.parm_error) {
15114 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, *r->out.parm_error));
15115 : }
15116 0 : NDR_CHECK(ndr_push_WERROR(ndr, NDR_SCALARS, r->out.result));
15117 : }
15118 0 : return NDR_ERR_SUCCESS;
15119 : }
15120 :
15121 0 : static enum ndr_err_code ndr_pull_srvsvc_NetCharDevQSetInfo(struct ndr_pull *ndr, ndr_flags_type flags, struct srvsvc_NetCharDevQSetInfo *r)
15122 : {
15123 0 : uint32_t _ptr_server_unc;
15124 0 : uint32_t size_server_unc_1 = 0;
15125 0 : uint32_t length_server_unc_1 = 0;
15126 0 : uint32_t size_queue_name_0 = 0;
15127 0 : uint32_t length_queue_name_0 = 0;
15128 0 : uint32_t _ptr_parm_error;
15129 0 : TALLOC_CTX *_mem_save_server_unc_0 = NULL;
15130 0 : TALLOC_CTX *_mem_save_parm_error_0 = NULL;
15131 0 : NDR_PULL_CHECK_FN_FLAGS(ndr, flags);
15132 0 : if (flags & NDR_IN) {
15133 0 : NDR_ZERO_STRUCT(r->out);
15134 :
15135 0 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_server_unc));
15136 0 : if (_ptr_server_unc) {
15137 0 : NDR_PULL_ALLOC(ndr, r->in.server_unc);
15138 : } else {
15139 0 : r->in.server_unc = NULL;
15140 : }
15141 0 : if (r->in.server_unc) {
15142 0 : _mem_save_server_unc_0 = NDR_PULL_GET_MEM_CTX(ndr);
15143 0 : NDR_PULL_SET_MEM_CTX(ndr, r->in.server_unc, 0);
15144 0 : NDR_CHECK(ndr_pull_array_size(ndr, &r->in.server_unc));
15145 0 : NDR_CHECK(ndr_pull_array_length(ndr, &r->in.server_unc));
15146 0 : NDR_CHECK(ndr_steal_array_size(ndr, (void*)&r->in.server_unc, &size_server_unc_1));
15147 0 : NDR_CHECK(ndr_steal_array_length(ndr, (void*)&r->in.server_unc, &length_server_unc_1));
15148 0 : if (length_server_unc_1 > size_server_unc_1) {
15149 0 : return ndr_pull_error(ndr, NDR_ERR_ARRAY_SIZE, "Bad array size %"PRIu32": should exceed array length %"PRIu32"", size_server_unc_1, length_server_unc_1);
15150 : }
15151 0 : NDR_CHECK(ndr_check_string_terminator(ndr, length_server_unc_1, sizeof(uint16_t)));
15152 0 : NDR_CHECK(ndr_pull_charset(ndr, NDR_SCALARS, &r->in.server_unc, length_server_unc_1, sizeof(uint16_t), CH_UTF16));
15153 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_server_unc_0, 0);
15154 : }
15155 0 : NDR_CHECK(ndr_pull_array_size(ndr, &r->in.queue_name));
15156 0 : NDR_CHECK(ndr_pull_array_length(ndr, &r->in.queue_name));
15157 0 : NDR_CHECK(ndr_steal_array_size(ndr, (void*)&r->in.queue_name, &size_queue_name_0));
15158 0 : NDR_CHECK(ndr_steal_array_length(ndr, (void*)&r->in.queue_name, &length_queue_name_0));
15159 0 : if (length_queue_name_0 > size_queue_name_0) {
15160 0 : return ndr_pull_error(ndr, NDR_ERR_ARRAY_SIZE, "Bad array size %"PRIu32": should exceed array length %"PRIu32"", size_queue_name_0, length_queue_name_0);
15161 : }
15162 0 : NDR_CHECK(ndr_check_string_terminator(ndr, length_queue_name_0, sizeof(uint16_t)));
15163 0 : NDR_CHECK(ndr_pull_charset(ndr, NDR_SCALARS, &r->in.queue_name, length_queue_name_0, sizeof(uint16_t), CH_UTF16));
15164 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->in.level));
15165 0 : NDR_CHECK(ndr_pull_set_switch_value(ndr, &r->in.info, r->in.level));
15166 0 : NDR_CHECK(ndr_pull_srvsvc_NetCharDevQInfo(ndr, NDR_SCALARS|NDR_BUFFERS, &r->in.info));
15167 0 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_parm_error));
15168 0 : if (_ptr_parm_error) {
15169 0 : NDR_PULL_ALLOC(ndr, r->in.parm_error);
15170 : } else {
15171 0 : r->in.parm_error = NULL;
15172 : }
15173 0 : if (r->in.parm_error) {
15174 0 : _mem_save_parm_error_0 = NDR_PULL_GET_MEM_CTX(ndr);
15175 0 : NDR_PULL_SET_MEM_CTX(ndr, r->in.parm_error, 0);
15176 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, r->in.parm_error));
15177 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_parm_error_0, 0);
15178 : }
15179 : }
15180 0 : if (flags & NDR_OUT) {
15181 : #ifdef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION
15182 : #endif /* FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION */
15183 0 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_parm_error));
15184 0 : if (_ptr_parm_error) {
15185 0 : NDR_PULL_ALLOC(ndr, r->out.parm_error);
15186 : } else {
15187 0 : r->out.parm_error = NULL;
15188 : }
15189 0 : if (r->out.parm_error) {
15190 0 : _mem_save_parm_error_0 = NDR_PULL_GET_MEM_CTX(ndr);
15191 0 : NDR_PULL_SET_MEM_CTX(ndr, r->out.parm_error, 0);
15192 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, r->out.parm_error));
15193 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_parm_error_0, 0);
15194 : }
15195 0 : NDR_CHECK(ndr_pull_WERROR(ndr, NDR_SCALARS, &r->out.result));
15196 : }
15197 0 : return NDR_ERR_SUCCESS;
15198 : }
15199 :
15200 0 : _PUBLIC_ void ndr_print_srvsvc_NetCharDevQSetInfo(struct ndr_print *ndr, const char *name, ndr_flags_type flags, const struct srvsvc_NetCharDevQSetInfo *r)
15201 : {
15202 0 : ndr_print_struct(ndr, name, "srvsvc_NetCharDevQSetInfo");
15203 0 : if (r == NULL) { ndr_print_null(ndr); return; }
15204 0 : ndr->depth++;
15205 0 : if (flags & NDR_SET_VALUES) {
15206 0 : ndr->flags |= LIBNDR_PRINT_SET_VALUES;
15207 : }
15208 0 : if (flags & NDR_IN) {
15209 0 : ndr_print_struct(ndr, "in", "srvsvc_NetCharDevQSetInfo");
15210 0 : ndr->depth++;
15211 0 : ndr_print_ptr(ndr, "server_unc", r->in.server_unc);
15212 0 : ndr->depth++;
15213 0 : if (r->in.server_unc) {
15214 0 : ndr_print_string(ndr, "server_unc", r->in.server_unc);
15215 : }
15216 0 : ndr->depth--;
15217 0 : ndr_print_string(ndr, "queue_name", r->in.queue_name);
15218 0 : ndr_print_uint32(ndr, "level", r->in.level);
15219 0 : ndr_print_set_switch_value(ndr, &r->in.info, r->in.level);
15220 0 : ndr_print_srvsvc_NetCharDevQInfo(ndr, "info", &r->in.info);
15221 0 : ndr_print_ptr(ndr, "parm_error", r->in.parm_error);
15222 0 : ndr->depth++;
15223 0 : if (r->in.parm_error) {
15224 0 : ndr_print_uint32(ndr, "parm_error", *r->in.parm_error);
15225 : }
15226 0 : ndr->depth--;
15227 0 : ndr->depth--;
15228 : }
15229 0 : if (flags & NDR_OUT) {
15230 0 : ndr_print_struct(ndr, "out", "srvsvc_NetCharDevQSetInfo");
15231 0 : ndr->depth++;
15232 0 : ndr_print_ptr(ndr, "parm_error", r->out.parm_error);
15233 0 : ndr->depth++;
15234 0 : if (r->out.parm_error) {
15235 0 : ndr_print_uint32(ndr, "parm_error", *r->out.parm_error);
15236 : }
15237 0 : ndr->depth--;
15238 0 : ndr_print_WERROR(ndr, "result", r->out.result);
15239 0 : ndr->depth--;
15240 : }
15241 0 : ndr->depth--;
15242 : }
15243 :
15244 0 : static enum ndr_err_code ndr_push_srvsvc_NetCharDevQPurge(struct ndr_push *ndr, ndr_flags_type flags, const struct srvsvc_NetCharDevQPurge *r)
15245 : {
15246 0 : NDR_PUSH_CHECK_FN_FLAGS(ndr, flags);
15247 0 : if (flags & NDR_IN) {
15248 0 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->in.server_unc));
15249 0 : if (r->in.server_unc) {
15250 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->in.server_unc, CH_UTF16)));
15251 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, 0));
15252 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->in.server_unc, CH_UTF16)));
15253 0 : NDR_CHECK(ndr_push_charset(ndr, NDR_SCALARS, r->in.server_unc, ndr_charset_length(r->in.server_unc, CH_UTF16), sizeof(uint16_t), CH_UTF16));
15254 : }
15255 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->in.queue_name, CH_UTF16)));
15256 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, 0));
15257 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->in.queue_name, CH_UTF16)));
15258 0 : NDR_CHECK(ndr_push_charset(ndr, NDR_SCALARS, r->in.queue_name, ndr_charset_length(r->in.queue_name, CH_UTF16), sizeof(uint16_t), CH_UTF16));
15259 : }
15260 0 : if (flags & NDR_OUT) {
15261 0 : NDR_CHECK(ndr_push_WERROR(ndr, NDR_SCALARS, r->out.result));
15262 : }
15263 0 : return NDR_ERR_SUCCESS;
15264 : }
15265 :
15266 0 : static enum ndr_err_code ndr_pull_srvsvc_NetCharDevQPurge(struct ndr_pull *ndr, ndr_flags_type flags, struct srvsvc_NetCharDevQPurge *r)
15267 : {
15268 0 : uint32_t _ptr_server_unc;
15269 0 : uint32_t size_server_unc_1 = 0;
15270 0 : uint32_t length_server_unc_1 = 0;
15271 0 : uint32_t size_queue_name_0 = 0;
15272 0 : uint32_t length_queue_name_0 = 0;
15273 0 : TALLOC_CTX *_mem_save_server_unc_0 = NULL;
15274 0 : NDR_PULL_CHECK_FN_FLAGS(ndr, flags);
15275 0 : if (flags & NDR_IN) {
15276 0 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_server_unc));
15277 0 : if (_ptr_server_unc) {
15278 0 : NDR_PULL_ALLOC(ndr, r->in.server_unc);
15279 : } else {
15280 0 : r->in.server_unc = NULL;
15281 : }
15282 0 : if (r->in.server_unc) {
15283 0 : _mem_save_server_unc_0 = NDR_PULL_GET_MEM_CTX(ndr);
15284 0 : NDR_PULL_SET_MEM_CTX(ndr, r->in.server_unc, 0);
15285 0 : NDR_CHECK(ndr_pull_array_size(ndr, &r->in.server_unc));
15286 0 : NDR_CHECK(ndr_pull_array_length(ndr, &r->in.server_unc));
15287 0 : NDR_CHECK(ndr_steal_array_size(ndr, (void*)&r->in.server_unc, &size_server_unc_1));
15288 0 : NDR_CHECK(ndr_steal_array_length(ndr, (void*)&r->in.server_unc, &length_server_unc_1));
15289 0 : if (length_server_unc_1 > size_server_unc_1) {
15290 0 : return ndr_pull_error(ndr, NDR_ERR_ARRAY_SIZE, "Bad array size %"PRIu32": should exceed array length %"PRIu32"", size_server_unc_1, length_server_unc_1);
15291 : }
15292 0 : NDR_CHECK(ndr_check_string_terminator(ndr, length_server_unc_1, sizeof(uint16_t)));
15293 0 : NDR_CHECK(ndr_pull_charset(ndr, NDR_SCALARS, &r->in.server_unc, length_server_unc_1, sizeof(uint16_t), CH_UTF16));
15294 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_server_unc_0, 0);
15295 : }
15296 0 : NDR_CHECK(ndr_pull_array_size(ndr, &r->in.queue_name));
15297 0 : NDR_CHECK(ndr_pull_array_length(ndr, &r->in.queue_name));
15298 0 : NDR_CHECK(ndr_steal_array_size(ndr, (void*)&r->in.queue_name, &size_queue_name_0));
15299 0 : NDR_CHECK(ndr_steal_array_length(ndr, (void*)&r->in.queue_name, &length_queue_name_0));
15300 0 : if (length_queue_name_0 > size_queue_name_0) {
15301 0 : return ndr_pull_error(ndr, NDR_ERR_ARRAY_SIZE, "Bad array size %"PRIu32": should exceed array length %"PRIu32"", size_queue_name_0, length_queue_name_0);
15302 : }
15303 0 : NDR_CHECK(ndr_check_string_terminator(ndr, length_queue_name_0, sizeof(uint16_t)));
15304 0 : NDR_CHECK(ndr_pull_charset(ndr, NDR_SCALARS, &r->in.queue_name, length_queue_name_0, sizeof(uint16_t), CH_UTF16));
15305 : }
15306 0 : if (flags & NDR_OUT) {
15307 : #ifdef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION
15308 : #endif /* FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION */
15309 0 : NDR_CHECK(ndr_pull_WERROR(ndr, NDR_SCALARS, &r->out.result));
15310 : }
15311 0 : return NDR_ERR_SUCCESS;
15312 : }
15313 :
15314 0 : _PUBLIC_ void ndr_print_srvsvc_NetCharDevQPurge(struct ndr_print *ndr, const char *name, ndr_flags_type flags, const struct srvsvc_NetCharDevQPurge *r)
15315 : {
15316 0 : ndr_print_struct(ndr, name, "srvsvc_NetCharDevQPurge");
15317 0 : if (r == NULL) { ndr_print_null(ndr); return; }
15318 0 : ndr->depth++;
15319 0 : if (flags & NDR_SET_VALUES) {
15320 0 : ndr->flags |= LIBNDR_PRINT_SET_VALUES;
15321 : }
15322 0 : if (flags & NDR_IN) {
15323 0 : ndr_print_struct(ndr, "in", "srvsvc_NetCharDevQPurge");
15324 0 : ndr->depth++;
15325 0 : ndr_print_ptr(ndr, "server_unc", r->in.server_unc);
15326 0 : ndr->depth++;
15327 0 : if (r->in.server_unc) {
15328 0 : ndr_print_string(ndr, "server_unc", r->in.server_unc);
15329 : }
15330 0 : ndr->depth--;
15331 0 : ndr_print_string(ndr, "queue_name", r->in.queue_name);
15332 0 : ndr->depth--;
15333 : }
15334 0 : if (flags & NDR_OUT) {
15335 0 : ndr_print_struct(ndr, "out", "srvsvc_NetCharDevQPurge");
15336 0 : ndr->depth++;
15337 0 : ndr_print_WERROR(ndr, "result", r->out.result);
15338 0 : ndr->depth--;
15339 : }
15340 0 : ndr->depth--;
15341 : }
15342 :
15343 0 : static enum ndr_err_code ndr_push_srvsvc_NetCharDevQPurgeSelf(struct ndr_push *ndr, ndr_flags_type flags, const struct srvsvc_NetCharDevQPurgeSelf *r)
15344 : {
15345 0 : NDR_PUSH_CHECK_FN_FLAGS(ndr, flags);
15346 0 : if (flags & NDR_IN) {
15347 0 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->in.server_unc));
15348 0 : if (r->in.server_unc) {
15349 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->in.server_unc, CH_UTF16)));
15350 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, 0));
15351 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->in.server_unc, CH_UTF16)));
15352 0 : NDR_CHECK(ndr_push_charset(ndr, NDR_SCALARS, r->in.server_unc, ndr_charset_length(r->in.server_unc, CH_UTF16), sizeof(uint16_t), CH_UTF16));
15353 : }
15354 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->in.queue_name, CH_UTF16)));
15355 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, 0));
15356 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->in.queue_name, CH_UTF16)));
15357 0 : NDR_CHECK(ndr_push_charset(ndr, NDR_SCALARS, r->in.queue_name, ndr_charset_length(r->in.queue_name, CH_UTF16), sizeof(uint16_t), CH_UTF16));
15358 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->in.computer_name, CH_UTF16)));
15359 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, 0));
15360 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->in.computer_name, CH_UTF16)));
15361 0 : NDR_CHECK(ndr_push_charset(ndr, NDR_SCALARS, r->in.computer_name, ndr_charset_length(r->in.computer_name, CH_UTF16), sizeof(uint16_t), CH_UTF16));
15362 : }
15363 0 : if (flags & NDR_OUT) {
15364 0 : NDR_CHECK(ndr_push_WERROR(ndr, NDR_SCALARS, r->out.result));
15365 : }
15366 0 : return NDR_ERR_SUCCESS;
15367 : }
15368 :
15369 0 : static enum ndr_err_code ndr_pull_srvsvc_NetCharDevQPurgeSelf(struct ndr_pull *ndr, ndr_flags_type flags, struct srvsvc_NetCharDevQPurgeSelf *r)
15370 : {
15371 0 : uint32_t _ptr_server_unc;
15372 0 : uint32_t size_server_unc_1 = 0;
15373 0 : uint32_t length_server_unc_1 = 0;
15374 0 : uint32_t size_queue_name_0 = 0;
15375 0 : uint32_t length_queue_name_0 = 0;
15376 0 : uint32_t size_computer_name_0 = 0;
15377 0 : uint32_t length_computer_name_0 = 0;
15378 0 : TALLOC_CTX *_mem_save_server_unc_0 = NULL;
15379 0 : NDR_PULL_CHECK_FN_FLAGS(ndr, flags);
15380 0 : if (flags & NDR_IN) {
15381 0 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_server_unc));
15382 0 : if (_ptr_server_unc) {
15383 0 : NDR_PULL_ALLOC(ndr, r->in.server_unc);
15384 : } else {
15385 0 : r->in.server_unc = NULL;
15386 : }
15387 0 : if (r->in.server_unc) {
15388 0 : _mem_save_server_unc_0 = NDR_PULL_GET_MEM_CTX(ndr);
15389 0 : NDR_PULL_SET_MEM_CTX(ndr, r->in.server_unc, 0);
15390 0 : NDR_CHECK(ndr_pull_array_size(ndr, &r->in.server_unc));
15391 0 : NDR_CHECK(ndr_pull_array_length(ndr, &r->in.server_unc));
15392 0 : NDR_CHECK(ndr_steal_array_size(ndr, (void*)&r->in.server_unc, &size_server_unc_1));
15393 0 : NDR_CHECK(ndr_steal_array_length(ndr, (void*)&r->in.server_unc, &length_server_unc_1));
15394 0 : if (length_server_unc_1 > size_server_unc_1) {
15395 0 : return ndr_pull_error(ndr, NDR_ERR_ARRAY_SIZE, "Bad array size %"PRIu32": should exceed array length %"PRIu32"", size_server_unc_1, length_server_unc_1);
15396 : }
15397 0 : NDR_CHECK(ndr_check_string_terminator(ndr, length_server_unc_1, sizeof(uint16_t)));
15398 0 : NDR_CHECK(ndr_pull_charset(ndr, NDR_SCALARS, &r->in.server_unc, length_server_unc_1, sizeof(uint16_t), CH_UTF16));
15399 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_server_unc_0, 0);
15400 : }
15401 0 : NDR_CHECK(ndr_pull_array_size(ndr, &r->in.queue_name));
15402 0 : NDR_CHECK(ndr_pull_array_length(ndr, &r->in.queue_name));
15403 0 : NDR_CHECK(ndr_steal_array_size(ndr, (void*)&r->in.queue_name, &size_queue_name_0));
15404 0 : NDR_CHECK(ndr_steal_array_length(ndr, (void*)&r->in.queue_name, &length_queue_name_0));
15405 0 : if (length_queue_name_0 > size_queue_name_0) {
15406 0 : return ndr_pull_error(ndr, NDR_ERR_ARRAY_SIZE, "Bad array size %"PRIu32": should exceed array length %"PRIu32"", size_queue_name_0, length_queue_name_0);
15407 : }
15408 0 : NDR_CHECK(ndr_check_string_terminator(ndr, length_queue_name_0, sizeof(uint16_t)));
15409 0 : NDR_CHECK(ndr_pull_charset(ndr, NDR_SCALARS, &r->in.queue_name, length_queue_name_0, sizeof(uint16_t), CH_UTF16));
15410 0 : NDR_CHECK(ndr_pull_array_size(ndr, &r->in.computer_name));
15411 0 : NDR_CHECK(ndr_pull_array_length(ndr, &r->in.computer_name));
15412 0 : NDR_CHECK(ndr_steal_array_size(ndr, (void*)&r->in.computer_name, &size_computer_name_0));
15413 0 : NDR_CHECK(ndr_steal_array_length(ndr, (void*)&r->in.computer_name, &length_computer_name_0));
15414 0 : if (length_computer_name_0 > size_computer_name_0) {
15415 0 : return ndr_pull_error(ndr, NDR_ERR_ARRAY_SIZE, "Bad array size %"PRIu32": should exceed array length %"PRIu32"", size_computer_name_0, length_computer_name_0);
15416 : }
15417 0 : NDR_CHECK(ndr_check_string_terminator(ndr, length_computer_name_0, sizeof(uint16_t)));
15418 0 : NDR_CHECK(ndr_pull_charset(ndr, NDR_SCALARS, &r->in.computer_name, length_computer_name_0, sizeof(uint16_t), CH_UTF16));
15419 : }
15420 0 : if (flags & NDR_OUT) {
15421 : #ifdef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION
15422 : #endif /* FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION */
15423 0 : NDR_CHECK(ndr_pull_WERROR(ndr, NDR_SCALARS, &r->out.result));
15424 : }
15425 0 : return NDR_ERR_SUCCESS;
15426 : }
15427 :
15428 0 : _PUBLIC_ void ndr_print_srvsvc_NetCharDevQPurgeSelf(struct ndr_print *ndr, const char *name, ndr_flags_type flags, const struct srvsvc_NetCharDevQPurgeSelf *r)
15429 : {
15430 0 : ndr_print_struct(ndr, name, "srvsvc_NetCharDevQPurgeSelf");
15431 0 : if (r == NULL) { ndr_print_null(ndr); return; }
15432 0 : ndr->depth++;
15433 0 : if (flags & NDR_SET_VALUES) {
15434 0 : ndr->flags |= LIBNDR_PRINT_SET_VALUES;
15435 : }
15436 0 : if (flags & NDR_IN) {
15437 0 : ndr_print_struct(ndr, "in", "srvsvc_NetCharDevQPurgeSelf");
15438 0 : ndr->depth++;
15439 0 : ndr_print_ptr(ndr, "server_unc", r->in.server_unc);
15440 0 : ndr->depth++;
15441 0 : if (r->in.server_unc) {
15442 0 : ndr_print_string(ndr, "server_unc", r->in.server_unc);
15443 : }
15444 0 : ndr->depth--;
15445 0 : ndr_print_string(ndr, "queue_name", r->in.queue_name);
15446 0 : ndr_print_string(ndr, "computer_name", r->in.computer_name);
15447 0 : ndr->depth--;
15448 : }
15449 0 : if (flags & NDR_OUT) {
15450 0 : ndr_print_struct(ndr, "out", "srvsvc_NetCharDevQPurgeSelf");
15451 0 : ndr->depth++;
15452 0 : ndr_print_WERROR(ndr, "result", r->out.result);
15453 0 : ndr->depth--;
15454 : }
15455 0 : ndr->depth--;
15456 : }
15457 :
15458 34 : static enum ndr_err_code ndr_push_srvsvc_NetConnEnum(struct ndr_push *ndr, ndr_flags_type flags, const struct srvsvc_NetConnEnum *r)
15459 : {
15460 34 : NDR_PUSH_CHECK_FN_FLAGS(ndr, flags);
15461 34 : if (flags & NDR_IN) {
15462 16 : if (r->in.info_ctr == NULL) {
15463 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
15464 : }
15465 16 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->in.server_unc));
15466 16 : if (r->in.server_unc) {
15467 16 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->in.server_unc, CH_UTF16)));
15468 16 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, 0));
15469 16 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->in.server_unc, CH_UTF16)));
15470 16 : NDR_CHECK(ndr_push_charset(ndr, NDR_SCALARS, r->in.server_unc, ndr_charset_length(r->in.server_unc, CH_UTF16), sizeof(uint16_t), CH_UTF16));
15471 : }
15472 16 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->in.path));
15473 16 : if (r->in.path) {
15474 16 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->in.path, CH_UTF16)));
15475 16 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, 0));
15476 16 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->in.path, CH_UTF16)));
15477 16 : NDR_CHECK(ndr_push_charset(ndr, NDR_SCALARS, r->in.path, ndr_charset_length(r->in.path, CH_UTF16), sizeof(uint16_t), CH_UTF16));
15478 : }
15479 16 : NDR_CHECK(ndr_push_srvsvc_NetConnInfoCtr(ndr, NDR_SCALARS|NDR_BUFFERS, r->in.info_ctr));
15480 16 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->in.max_buffer));
15481 16 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->in.resume_handle));
15482 16 : if (r->in.resume_handle) {
15483 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, *r->in.resume_handle));
15484 : }
15485 : }
15486 34 : if (flags & NDR_OUT) {
15487 18 : if (r->out.info_ctr == NULL) {
15488 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
15489 : }
15490 18 : if (r->out.totalentries == NULL) {
15491 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
15492 : }
15493 18 : NDR_CHECK(ndr_push_srvsvc_NetConnInfoCtr(ndr, NDR_SCALARS|NDR_BUFFERS, r->out.info_ctr));
15494 18 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, *r->out.totalentries));
15495 18 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->out.resume_handle));
15496 18 : if (r->out.resume_handle) {
15497 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, *r->out.resume_handle));
15498 : }
15499 18 : NDR_CHECK(ndr_push_WERROR(ndr, NDR_SCALARS, r->out.result));
15500 : }
15501 34 : return NDR_ERR_SUCCESS;
15502 : }
15503 :
15504 32 : static enum ndr_err_code ndr_pull_srvsvc_NetConnEnum(struct ndr_pull *ndr, ndr_flags_type flags, struct srvsvc_NetConnEnum *r)
15505 : {
15506 0 : uint32_t _ptr_server_unc;
15507 32 : uint32_t size_server_unc_1 = 0;
15508 32 : uint32_t length_server_unc_1 = 0;
15509 0 : uint32_t _ptr_path;
15510 32 : uint32_t size_path_1 = 0;
15511 32 : uint32_t length_path_1 = 0;
15512 0 : uint32_t _ptr_resume_handle;
15513 32 : TALLOC_CTX *_mem_save_server_unc_0 = NULL;
15514 32 : TALLOC_CTX *_mem_save_path_0 = NULL;
15515 32 : TALLOC_CTX *_mem_save_info_ctr_0 = NULL;
15516 32 : TALLOC_CTX *_mem_save_totalentries_0 = NULL;
15517 32 : TALLOC_CTX *_mem_save_resume_handle_0 = NULL;
15518 32 : NDR_PULL_CHECK_FN_FLAGS(ndr, flags);
15519 32 : if (flags & NDR_IN) {
15520 16 : NDR_ZERO_STRUCT(r->out);
15521 :
15522 16 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_server_unc));
15523 16 : if (_ptr_server_unc) {
15524 16 : NDR_PULL_ALLOC(ndr, r->in.server_unc);
15525 : } else {
15526 0 : r->in.server_unc = NULL;
15527 : }
15528 16 : if (r->in.server_unc) {
15529 16 : _mem_save_server_unc_0 = NDR_PULL_GET_MEM_CTX(ndr);
15530 16 : NDR_PULL_SET_MEM_CTX(ndr, r->in.server_unc, 0);
15531 16 : NDR_CHECK(ndr_pull_array_size(ndr, &r->in.server_unc));
15532 16 : NDR_CHECK(ndr_pull_array_length(ndr, &r->in.server_unc));
15533 16 : NDR_CHECK(ndr_steal_array_size(ndr, (void*)&r->in.server_unc, &size_server_unc_1));
15534 16 : NDR_CHECK(ndr_steal_array_length(ndr, (void*)&r->in.server_unc, &length_server_unc_1));
15535 16 : if (length_server_unc_1 > size_server_unc_1) {
15536 0 : return ndr_pull_error(ndr, NDR_ERR_ARRAY_SIZE, "Bad array size %"PRIu32": should exceed array length %"PRIu32"", size_server_unc_1, length_server_unc_1);
15537 : }
15538 16 : NDR_CHECK(ndr_check_string_terminator(ndr, length_server_unc_1, sizeof(uint16_t)));
15539 16 : NDR_CHECK(ndr_pull_charset(ndr, NDR_SCALARS, &r->in.server_unc, length_server_unc_1, sizeof(uint16_t), CH_UTF16));
15540 16 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_server_unc_0, 0);
15541 : }
15542 16 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_path));
15543 16 : if (_ptr_path) {
15544 16 : NDR_PULL_ALLOC(ndr, r->in.path);
15545 : } else {
15546 0 : r->in.path = NULL;
15547 : }
15548 16 : if (r->in.path) {
15549 16 : _mem_save_path_0 = NDR_PULL_GET_MEM_CTX(ndr);
15550 16 : NDR_PULL_SET_MEM_CTX(ndr, r->in.path, 0);
15551 16 : NDR_CHECK(ndr_pull_array_size(ndr, &r->in.path));
15552 16 : NDR_CHECK(ndr_pull_array_length(ndr, &r->in.path));
15553 16 : NDR_CHECK(ndr_steal_array_size(ndr, (void*)&r->in.path, &size_path_1));
15554 16 : NDR_CHECK(ndr_steal_array_length(ndr, (void*)&r->in.path, &length_path_1));
15555 16 : if (length_path_1 > size_path_1) {
15556 0 : return ndr_pull_error(ndr, NDR_ERR_ARRAY_SIZE, "Bad array size %"PRIu32": should exceed array length %"PRIu32"", size_path_1, length_path_1);
15557 : }
15558 16 : NDR_CHECK(ndr_check_string_terminator(ndr, length_path_1, sizeof(uint16_t)));
15559 16 : NDR_CHECK(ndr_pull_charset(ndr, NDR_SCALARS, &r->in.path, length_path_1, sizeof(uint16_t), CH_UTF16));
15560 16 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_path_0, 0);
15561 : }
15562 16 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
15563 16 : NDR_PULL_ALLOC(ndr, r->in.info_ctr);
15564 : }
15565 16 : _mem_save_info_ctr_0 = NDR_PULL_GET_MEM_CTX(ndr);
15566 16 : NDR_PULL_SET_MEM_CTX(ndr, r->in.info_ctr, LIBNDR_FLAG_REF_ALLOC);
15567 16 : NDR_CHECK(ndr_pull_srvsvc_NetConnInfoCtr(ndr, NDR_SCALARS|NDR_BUFFERS, r->in.info_ctr));
15568 16 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_info_ctr_0, LIBNDR_FLAG_REF_ALLOC);
15569 16 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->in.max_buffer));
15570 16 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_resume_handle));
15571 16 : if (_ptr_resume_handle) {
15572 0 : NDR_PULL_ALLOC(ndr, r->in.resume_handle);
15573 : } else {
15574 16 : r->in.resume_handle = NULL;
15575 : }
15576 16 : if (r->in.resume_handle) {
15577 0 : _mem_save_resume_handle_0 = NDR_PULL_GET_MEM_CTX(ndr);
15578 0 : NDR_PULL_SET_MEM_CTX(ndr, r->in.resume_handle, 0);
15579 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, r->in.resume_handle));
15580 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_resume_handle_0, 0);
15581 : }
15582 16 : NDR_PULL_ALLOC(ndr, r->out.info_ctr);
15583 16 : *r->out.info_ctr = *r->in.info_ctr;
15584 16 : NDR_PULL_ALLOC(ndr, r->out.totalentries);
15585 16 : NDR_ZERO_STRUCTP(r->out.totalentries);
15586 : }
15587 32 : if (flags & NDR_OUT) {
15588 : #ifdef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION
15589 : if (r->in.info_ctr == NULL) {
15590 : NDR_PULL_ALLOC(ndr, r->in.info_ctr);
15591 : NDR_ZERO_STRUCTP(r->in.info_ctr);
15592 : }
15593 : #endif /* FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION */
15594 16 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
15595 2 : NDR_PULL_ALLOC(ndr, r->out.info_ctr);
15596 : }
15597 16 : _mem_save_info_ctr_0 = NDR_PULL_GET_MEM_CTX(ndr);
15598 16 : NDR_PULL_SET_MEM_CTX(ndr, r->out.info_ctr, LIBNDR_FLAG_REF_ALLOC);
15599 16 : NDR_CHECK(ndr_pull_srvsvc_NetConnInfoCtr(ndr, NDR_SCALARS|NDR_BUFFERS, r->out.info_ctr));
15600 16 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_info_ctr_0, LIBNDR_FLAG_REF_ALLOC);
15601 16 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
15602 2 : NDR_PULL_ALLOC(ndr, r->out.totalentries);
15603 : }
15604 16 : _mem_save_totalentries_0 = NDR_PULL_GET_MEM_CTX(ndr);
15605 16 : NDR_PULL_SET_MEM_CTX(ndr, r->out.totalentries, LIBNDR_FLAG_REF_ALLOC);
15606 16 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, r->out.totalentries));
15607 16 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_totalentries_0, LIBNDR_FLAG_REF_ALLOC);
15608 16 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_resume_handle));
15609 16 : if (_ptr_resume_handle) {
15610 0 : NDR_PULL_ALLOC(ndr, r->out.resume_handle);
15611 : } else {
15612 16 : r->out.resume_handle = NULL;
15613 : }
15614 16 : if (r->out.resume_handle) {
15615 0 : _mem_save_resume_handle_0 = NDR_PULL_GET_MEM_CTX(ndr);
15616 0 : NDR_PULL_SET_MEM_CTX(ndr, r->out.resume_handle, 0);
15617 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, r->out.resume_handle));
15618 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_resume_handle_0, 0);
15619 : }
15620 16 : NDR_CHECK(ndr_pull_WERROR(ndr, NDR_SCALARS, &r->out.result));
15621 : }
15622 32 : return NDR_ERR_SUCCESS;
15623 : }
15624 :
15625 4 : _PUBLIC_ void ndr_print_srvsvc_NetConnEnum(struct ndr_print *ndr, const char *name, ndr_flags_type flags, const struct srvsvc_NetConnEnum *r)
15626 : {
15627 4 : ndr_print_struct(ndr, name, "srvsvc_NetConnEnum");
15628 4 : if (r == NULL) { ndr_print_null(ndr); return; }
15629 4 : ndr->depth++;
15630 4 : if (flags & NDR_SET_VALUES) {
15631 0 : ndr->flags |= LIBNDR_PRINT_SET_VALUES;
15632 : }
15633 4 : if (flags & NDR_IN) {
15634 0 : ndr_print_struct(ndr, "in", "srvsvc_NetConnEnum");
15635 0 : ndr->depth++;
15636 0 : ndr_print_ptr(ndr, "server_unc", r->in.server_unc);
15637 0 : ndr->depth++;
15638 0 : if (r->in.server_unc) {
15639 0 : ndr_print_string(ndr, "server_unc", r->in.server_unc);
15640 : }
15641 0 : ndr->depth--;
15642 0 : ndr_print_ptr(ndr, "path", r->in.path);
15643 0 : ndr->depth++;
15644 0 : if (r->in.path) {
15645 0 : ndr_print_string(ndr, "path", r->in.path);
15646 : }
15647 0 : ndr->depth--;
15648 0 : ndr_print_ptr(ndr, "info_ctr", r->in.info_ctr);
15649 0 : ndr->depth++;
15650 0 : ndr_print_srvsvc_NetConnInfoCtr(ndr, "info_ctr", r->in.info_ctr);
15651 0 : ndr->depth--;
15652 0 : ndr_print_uint32(ndr, "max_buffer", r->in.max_buffer);
15653 0 : ndr_print_ptr(ndr, "resume_handle", r->in.resume_handle);
15654 0 : ndr->depth++;
15655 0 : if (r->in.resume_handle) {
15656 0 : ndr_print_uint32(ndr, "resume_handle", *r->in.resume_handle);
15657 : }
15658 0 : ndr->depth--;
15659 0 : ndr->depth--;
15660 : }
15661 4 : if (flags & NDR_OUT) {
15662 4 : ndr_print_struct(ndr, "out", "srvsvc_NetConnEnum");
15663 4 : ndr->depth++;
15664 4 : ndr_print_ptr(ndr, "info_ctr", r->out.info_ctr);
15665 4 : ndr->depth++;
15666 4 : ndr_print_srvsvc_NetConnInfoCtr(ndr, "info_ctr", r->out.info_ctr);
15667 4 : ndr->depth--;
15668 4 : ndr_print_ptr(ndr, "totalentries", r->out.totalentries);
15669 4 : ndr->depth++;
15670 4 : ndr_print_uint32(ndr, "totalentries", *r->out.totalentries);
15671 4 : ndr->depth--;
15672 4 : ndr_print_ptr(ndr, "resume_handle", r->out.resume_handle);
15673 4 : ndr->depth++;
15674 4 : if (r->out.resume_handle) {
15675 0 : ndr_print_uint32(ndr, "resume_handle", *r->out.resume_handle);
15676 : }
15677 4 : ndr->depth--;
15678 4 : ndr_print_WERROR(ndr, "result", r->out.result);
15679 4 : ndr->depth--;
15680 : }
15681 4 : ndr->depth--;
15682 : }
15683 :
15684 38 : static enum ndr_err_code ndr_push_srvsvc_NetFileEnum(struct ndr_push *ndr, ndr_flags_type flags, const struct srvsvc_NetFileEnum *r)
15685 : {
15686 38 : NDR_PUSH_CHECK_FN_FLAGS(ndr, flags);
15687 38 : if (flags & NDR_IN) {
15688 18 : if (r->in.info_ctr == NULL) {
15689 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
15690 : }
15691 18 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->in.server_unc));
15692 18 : if (r->in.server_unc) {
15693 18 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->in.server_unc, CH_UTF16)));
15694 18 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, 0));
15695 18 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->in.server_unc, CH_UTF16)));
15696 18 : NDR_CHECK(ndr_push_charset(ndr, NDR_SCALARS, r->in.server_unc, ndr_charset_length(r->in.server_unc, CH_UTF16), sizeof(uint16_t), CH_UTF16));
15697 : }
15698 18 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->in.path));
15699 18 : if (r->in.path) {
15700 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->in.path, CH_UTF16)));
15701 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, 0));
15702 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->in.path, CH_UTF16)));
15703 0 : NDR_CHECK(ndr_push_charset(ndr, NDR_SCALARS, r->in.path, ndr_charset_length(r->in.path, CH_UTF16), sizeof(uint16_t), CH_UTF16));
15704 : }
15705 18 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->in.user));
15706 18 : if (r->in.user) {
15707 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->in.user, CH_UTF16)));
15708 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, 0));
15709 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->in.user, CH_UTF16)));
15710 0 : NDR_CHECK(ndr_push_charset(ndr, NDR_SCALARS, r->in.user, ndr_charset_length(r->in.user, CH_UTF16), sizeof(uint16_t), CH_UTF16));
15711 : }
15712 18 : NDR_CHECK(ndr_push_srvsvc_NetFileInfoCtr(ndr, NDR_SCALARS|NDR_BUFFERS, r->in.info_ctr));
15713 18 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->in.max_buffer));
15714 18 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->in.resume_handle));
15715 18 : if (r->in.resume_handle) {
15716 2 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, *r->in.resume_handle));
15717 : }
15718 : }
15719 38 : if (flags & NDR_OUT) {
15720 20 : if (r->out.info_ctr == NULL) {
15721 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
15722 : }
15723 20 : if (r->out.totalentries == NULL) {
15724 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
15725 : }
15726 20 : NDR_CHECK(ndr_push_srvsvc_NetFileInfoCtr(ndr, NDR_SCALARS|NDR_BUFFERS, r->out.info_ctr));
15727 20 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, *r->out.totalentries));
15728 20 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->out.resume_handle));
15729 20 : if (r->out.resume_handle) {
15730 2 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, *r->out.resume_handle));
15731 : }
15732 20 : NDR_CHECK(ndr_push_WERROR(ndr, NDR_SCALARS, r->out.result));
15733 : }
15734 38 : return NDR_ERR_SUCCESS;
15735 : }
15736 :
15737 36 : static enum ndr_err_code ndr_pull_srvsvc_NetFileEnum(struct ndr_pull *ndr, ndr_flags_type flags, struct srvsvc_NetFileEnum *r)
15738 : {
15739 0 : uint32_t _ptr_server_unc;
15740 36 : uint32_t size_server_unc_1 = 0;
15741 36 : uint32_t length_server_unc_1 = 0;
15742 0 : uint32_t _ptr_path;
15743 36 : uint32_t size_path_1 = 0;
15744 36 : uint32_t length_path_1 = 0;
15745 0 : uint32_t _ptr_user;
15746 36 : uint32_t size_user_1 = 0;
15747 36 : uint32_t length_user_1 = 0;
15748 0 : uint32_t _ptr_resume_handle;
15749 36 : TALLOC_CTX *_mem_save_server_unc_0 = NULL;
15750 36 : TALLOC_CTX *_mem_save_path_0 = NULL;
15751 36 : TALLOC_CTX *_mem_save_user_0 = NULL;
15752 36 : TALLOC_CTX *_mem_save_info_ctr_0 = NULL;
15753 36 : TALLOC_CTX *_mem_save_totalentries_0 = NULL;
15754 36 : TALLOC_CTX *_mem_save_resume_handle_0 = NULL;
15755 36 : NDR_PULL_CHECK_FN_FLAGS(ndr, flags);
15756 36 : if (flags & NDR_IN) {
15757 18 : NDR_ZERO_STRUCT(r->out);
15758 :
15759 18 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_server_unc));
15760 18 : if (_ptr_server_unc) {
15761 18 : NDR_PULL_ALLOC(ndr, r->in.server_unc);
15762 : } else {
15763 0 : r->in.server_unc = NULL;
15764 : }
15765 18 : if (r->in.server_unc) {
15766 18 : _mem_save_server_unc_0 = NDR_PULL_GET_MEM_CTX(ndr);
15767 18 : NDR_PULL_SET_MEM_CTX(ndr, r->in.server_unc, 0);
15768 18 : NDR_CHECK(ndr_pull_array_size(ndr, &r->in.server_unc));
15769 18 : NDR_CHECK(ndr_pull_array_length(ndr, &r->in.server_unc));
15770 18 : NDR_CHECK(ndr_steal_array_size(ndr, (void*)&r->in.server_unc, &size_server_unc_1));
15771 18 : NDR_CHECK(ndr_steal_array_length(ndr, (void*)&r->in.server_unc, &length_server_unc_1));
15772 18 : if (length_server_unc_1 > size_server_unc_1) {
15773 0 : return ndr_pull_error(ndr, NDR_ERR_ARRAY_SIZE, "Bad array size %"PRIu32": should exceed array length %"PRIu32"", size_server_unc_1, length_server_unc_1);
15774 : }
15775 18 : NDR_CHECK(ndr_check_string_terminator(ndr, length_server_unc_1, sizeof(uint16_t)));
15776 18 : NDR_CHECK(ndr_pull_charset(ndr, NDR_SCALARS, &r->in.server_unc, length_server_unc_1, sizeof(uint16_t), CH_UTF16));
15777 18 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_server_unc_0, 0);
15778 : }
15779 18 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_path));
15780 18 : if (_ptr_path) {
15781 0 : NDR_PULL_ALLOC(ndr, r->in.path);
15782 : } else {
15783 18 : r->in.path = NULL;
15784 : }
15785 18 : if (r->in.path) {
15786 0 : _mem_save_path_0 = NDR_PULL_GET_MEM_CTX(ndr);
15787 0 : NDR_PULL_SET_MEM_CTX(ndr, r->in.path, 0);
15788 0 : NDR_CHECK(ndr_pull_array_size(ndr, &r->in.path));
15789 0 : NDR_CHECK(ndr_pull_array_length(ndr, &r->in.path));
15790 0 : NDR_CHECK(ndr_steal_array_size(ndr, (void*)&r->in.path, &size_path_1));
15791 0 : NDR_CHECK(ndr_steal_array_length(ndr, (void*)&r->in.path, &length_path_1));
15792 0 : if (length_path_1 > size_path_1) {
15793 0 : return ndr_pull_error(ndr, NDR_ERR_ARRAY_SIZE, "Bad array size %"PRIu32": should exceed array length %"PRIu32"", size_path_1, length_path_1);
15794 : }
15795 0 : NDR_CHECK(ndr_check_string_terminator(ndr, length_path_1, sizeof(uint16_t)));
15796 0 : NDR_CHECK(ndr_pull_charset(ndr, NDR_SCALARS, &r->in.path, length_path_1, sizeof(uint16_t), CH_UTF16));
15797 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_path_0, 0);
15798 : }
15799 18 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_user));
15800 18 : if (_ptr_user) {
15801 0 : NDR_PULL_ALLOC(ndr, r->in.user);
15802 : } else {
15803 18 : r->in.user = NULL;
15804 : }
15805 18 : if (r->in.user) {
15806 0 : _mem_save_user_0 = NDR_PULL_GET_MEM_CTX(ndr);
15807 0 : NDR_PULL_SET_MEM_CTX(ndr, r->in.user, 0);
15808 0 : NDR_CHECK(ndr_pull_array_size(ndr, &r->in.user));
15809 0 : NDR_CHECK(ndr_pull_array_length(ndr, &r->in.user));
15810 0 : NDR_CHECK(ndr_steal_array_size(ndr, (void*)&r->in.user, &size_user_1));
15811 0 : NDR_CHECK(ndr_steal_array_length(ndr, (void*)&r->in.user, &length_user_1));
15812 0 : if (length_user_1 > size_user_1) {
15813 0 : return ndr_pull_error(ndr, NDR_ERR_ARRAY_SIZE, "Bad array size %"PRIu32": should exceed array length %"PRIu32"", size_user_1, length_user_1);
15814 : }
15815 0 : NDR_CHECK(ndr_check_string_terminator(ndr, length_user_1, sizeof(uint16_t)));
15816 0 : NDR_CHECK(ndr_pull_charset(ndr, NDR_SCALARS, &r->in.user, length_user_1, sizeof(uint16_t), CH_UTF16));
15817 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_user_0, 0);
15818 : }
15819 18 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
15820 18 : NDR_PULL_ALLOC(ndr, r->in.info_ctr);
15821 : }
15822 18 : _mem_save_info_ctr_0 = NDR_PULL_GET_MEM_CTX(ndr);
15823 18 : NDR_PULL_SET_MEM_CTX(ndr, r->in.info_ctr, LIBNDR_FLAG_REF_ALLOC);
15824 18 : NDR_CHECK(ndr_pull_srvsvc_NetFileInfoCtr(ndr, NDR_SCALARS|NDR_BUFFERS, r->in.info_ctr));
15825 18 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_info_ctr_0, LIBNDR_FLAG_REF_ALLOC);
15826 18 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->in.max_buffer));
15827 18 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_resume_handle));
15828 18 : if (_ptr_resume_handle) {
15829 2 : NDR_PULL_ALLOC(ndr, r->in.resume_handle);
15830 : } else {
15831 16 : r->in.resume_handle = NULL;
15832 : }
15833 18 : if (r->in.resume_handle) {
15834 2 : _mem_save_resume_handle_0 = NDR_PULL_GET_MEM_CTX(ndr);
15835 2 : NDR_PULL_SET_MEM_CTX(ndr, r->in.resume_handle, 0);
15836 2 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, r->in.resume_handle));
15837 2 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_resume_handle_0, 0);
15838 : }
15839 18 : NDR_PULL_ALLOC(ndr, r->out.info_ctr);
15840 18 : *r->out.info_ctr = *r->in.info_ctr;
15841 18 : NDR_PULL_ALLOC(ndr, r->out.totalentries);
15842 18 : NDR_ZERO_STRUCTP(r->out.totalentries);
15843 : }
15844 36 : if (flags & NDR_OUT) {
15845 : #ifdef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION
15846 : if (r->in.info_ctr == NULL) {
15847 : NDR_PULL_ALLOC(ndr, r->in.info_ctr);
15848 : NDR_ZERO_STRUCTP(r->in.info_ctr);
15849 : }
15850 : #endif /* FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION */
15851 18 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
15852 4 : NDR_PULL_ALLOC(ndr, r->out.info_ctr);
15853 : }
15854 18 : _mem_save_info_ctr_0 = NDR_PULL_GET_MEM_CTX(ndr);
15855 18 : NDR_PULL_SET_MEM_CTX(ndr, r->out.info_ctr, LIBNDR_FLAG_REF_ALLOC);
15856 18 : NDR_CHECK(ndr_pull_srvsvc_NetFileInfoCtr(ndr, NDR_SCALARS|NDR_BUFFERS, r->out.info_ctr));
15857 18 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_info_ctr_0, LIBNDR_FLAG_REF_ALLOC);
15858 18 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
15859 4 : NDR_PULL_ALLOC(ndr, r->out.totalentries);
15860 : }
15861 18 : _mem_save_totalentries_0 = NDR_PULL_GET_MEM_CTX(ndr);
15862 18 : NDR_PULL_SET_MEM_CTX(ndr, r->out.totalentries, LIBNDR_FLAG_REF_ALLOC);
15863 18 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, r->out.totalentries));
15864 18 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_totalentries_0, LIBNDR_FLAG_REF_ALLOC);
15865 18 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_resume_handle));
15866 18 : if (_ptr_resume_handle) {
15867 2 : NDR_PULL_ALLOC(ndr, r->out.resume_handle);
15868 : } else {
15869 16 : r->out.resume_handle = NULL;
15870 : }
15871 18 : if (r->out.resume_handle) {
15872 2 : _mem_save_resume_handle_0 = NDR_PULL_GET_MEM_CTX(ndr);
15873 2 : NDR_PULL_SET_MEM_CTX(ndr, r->out.resume_handle, 0);
15874 2 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, r->out.resume_handle));
15875 2 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_resume_handle_0, 0);
15876 : }
15877 18 : NDR_CHECK(ndr_pull_WERROR(ndr, NDR_SCALARS, &r->out.result));
15878 : }
15879 36 : return NDR_ERR_SUCCESS;
15880 : }
15881 :
15882 4 : _PUBLIC_ void ndr_print_srvsvc_NetFileEnum(struct ndr_print *ndr, const char *name, ndr_flags_type flags, const struct srvsvc_NetFileEnum *r)
15883 : {
15884 4 : ndr_print_struct(ndr, name, "srvsvc_NetFileEnum");
15885 4 : if (r == NULL) { ndr_print_null(ndr); return; }
15886 4 : ndr->depth++;
15887 4 : if (flags & NDR_SET_VALUES) {
15888 0 : ndr->flags |= LIBNDR_PRINT_SET_VALUES;
15889 : }
15890 4 : if (flags & NDR_IN) {
15891 0 : ndr_print_struct(ndr, "in", "srvsvc_NetFileEnum");
15892 0 : ndr->depth++;
15893 0 : ndr_print_ptr(ndr, "server_unc", r->in.server_unc);
15894 0 : ndr->depth++;
15895 0 : if (r->in.server_unc) {
15896 0 : ndr_print_string(ndr, "server_unc", r->in.server_unc);
15897 : }
15898 0 : ndr->depth--;
15899 0 : ndr_print_ptr(ndr, "path", r->in.path);
15900 0 : ndr->depth++;
15901 0 : if (r->in.path) {
15902 0 : ndr_print_string(ndr, "path", r->in.path);
15903 : }
15904 0 : ndr->depth--;
15905 0 : ndr_print_ptr(ndr, "user", r->in.user);
15906 0 : ndr->depth++;
15907 0 : if (r->in.user) {
15908 0 : ndr_print_string(ndr, "user", r->in.user);
15909 : }
15910 0 : ndr->depth--;
15911 0 : ndr_print_ptr(ndr, "info_ctr", r->in.info_ctr);
15912 0 : ndr->depth++;
15913 0 : ndr_print_srvsvc_NetFileInfoCtr(ndr, "info_ctr", r->in.info_ctr);
15914 0 : ndr->depth--;
15915 0 : ndr_print_uint32(ndr, "max_buffer", r->in.max_buffer);
15916 0 : ndr_print_ptr(ndr, "resume_handle", r->in.resume_handle);
15917 0 : ndr->depth++;
15918 0 : if (r->in.resume_handle) {
15919 0 : ndr_print_uint32(ndr, "resume_handle", *r->in.resume_handle);
15920 : }
15921 0 : ndr->depth--;
15922 0 : ndr->depth--;
15923 : }
15924 4 : if (flags & NDR_OUT) {
15925 4 : ndr_print_struct(ndr, "out", "srvsvc_NetFileEnum");
15926 4 : ndr->depth++;
15927 4 : ndr_print_ptr(ndr, "info_ctr", r->out.info_ctr);
15928 4 : ndr->depth++;
15929 4 : ndr_print_srvsvc_NetFileInfoCtr(ndr, "info_ctr", r->out.info_ctr);
15930 4 : ndr->depth--;
15931 4 : ndr_print_ptr(ndr, "totalentries", r->out.totalentries);
15932 4 : ndr->depth++;
15933 4 : ndr_print_uint32(ndr, "totalentries", *r->out.totalentries);
15934 4 : ndr->depth--;
15935 4 : ndr_print_ptr(ndr, "resume_handle", r->out.resume_handle);
15936 4 : ndr->depth++;
15937 4 : if (r->out.resume_handle) {
15938 0 : ndr_print_uint32(ndr, "resume_handle", *r->out.resume_handle);
15939 : }
15940 4 : ndr->depth--;
15941 4 : ndr_print_WERROR(ndr, "result", r->out.result);
15942 4 : ndr->depth--;
15943 : }
15944 4 : ndr->depth--;
15945 : }
15946 :
15947 0 : static enum ndr_err_code ndr_push_srvsvc_NetFileGetInfo(struct ndr_push *ndr, ndr_flags_type flags, const struct srvsvc_NetFileGetInfo *r)
15948 : {
15949 0 : NDR_PUSH_CHECK_FN_FLAGS(ndr, flags);
15950 0 : if (flags & NDR_IN) {
15951 0 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->in.server_unc));
15952 0 : if (r->in.server_unc) {
15953 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->in.server_unc, CH_UTF16)));
15954 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, 0));
15955 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->in.server_unc, CH_UTF16)));
15956 0 : NDR_CHECK(ndr_push_charset(ndr, NDR_SCALARS, r->in.server_unc, ndr_charset_length(r->in.server_unc, CH_UTF16), sizeof(uint16_t), CH_UTF16));
15957 : }
15958 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->in.fid));
15959 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->in.level));
15960 : }
15961 0 : if (flags & NDR_OUT) {
15962 0 : if (r->out.info == NULL) {
15963 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
15964 : }
15965 0 : NDR_CHECK(ndr_push_set_switch_value(ndr, r->out.info, r->in.level));
15966 0 : NDR_CHECK(ndr_push_srvsvc_NetFileInfo(ndr, NDR_SCALARS|NDR_BUFFERS, r->out.info));
15967 0 : NDR_CHECK(ndr_push_WERROR(ndr, NDR_SCALARS, r->out.result));
15968 : }
15969 0 : return NDR_ERR_SUCCESS;
15970 : }
15971 :
15972 0 : static enum ndr_err_code ndr_pull_srvsvc_NetFileGetInfo(struct ndr_pull *ndr, ndr_flags_type flags, struct srvsvc_NetFileGetInfo *r)
15973 : {
15974 0 : uint32_t _ptr_server_unc;
15975 0 : uint32_t size_server_unc_1 = 0;
15976 0 : uint32_t length_server_unc_1 = 0;
15977 0 : TALLOC_CTX *_mem_save_server_unc_0 = NULL;
15978 0 : TALLOC_CTX *_mem_save_info_0 = NULL;
15979 0 : NDR_PULL_CHECK_FN_FLAGS(ndr, flags);
15980 0 : if (flags & NDR_IN) {
15981 0 : NDR_ZERO_STRUCT(r->out);
15982 :
15983 0 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_server_unc));
15984 0 : if (_ptr_server_unc) {
15985 0 : NDR_PULL_ALLOC(ndr, r->in.server_unc);
15986 : } else {
15987 0 : r->in.server_unc = NULL;
15988 : }
15989 0 : if (r->in.server_unc) {
15990 0 : _mem_save_server_unc_0 = NDR_PULL_GET_MEM_CTX(ndr);
15991 0 : NDR_PULL_SET_MEM_CTX(ndr, r->in.server_unc, 0);
15992 0 : NDR_CHECK(ndr_pull_array_size(ndr, &r->in.server_unc));
15993 0 : NDR_CHECK(ndr_pull_array_length(ndr, &r->in.server_unc));
15994 0 : NDR_CHECK(ndr_steal_array_size(ndr, (void*)&r->in.server_unc, &size_server_unc_1));
15995 0 : NDR_CHECK(ndr_steal_array_length(ndr, (void*)&r->in.server_unc, &length_server_unc_1));
15996 0 : if (length_server_unc_1 > size_server_unc_1) {
15997 0 : return ndr_pull_error(ndr, NDR_ERR_ARRAY_SIZE, "Bad array size %"PRIu32": should exceed array length %"PRIu32"", size_server_unc_1, length_server_unc_1);
15998 : }
15999 0 : NDR_CHECK(ndr_check_string_terminator(ndr, length_server_unc_1, sizeof(uint16_t)));
16000 0 : NDR_CHECK(ndr_pull_charset(ndr, NDR_SCALARS, &r->in.server_unc, length_server_unc_1, sizeof(uint16_t), CH_UTF16));
16001 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_server_unc_0, 0);
16002 : }
16003 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->in.fid));
16004 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->in.level));
16005 0 : NDR_PULL_ALLOC(ndr, r->out.info);
16006 0 : NDR_ZERO_STRUCTP(r->out.info);
16007 : }
16008 0 : if (flags & NDR_OUT) {
16009 : #ifdef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION
16010 : #endif /* FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION */
16011 0 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
16012 0 : NDR_PULL_ALLOC(ndr, r->out.info);
16013 : }
16014 0 : _mem_save_info_0 = NDR_PULL_GET_MEM_CTX(ndr);
16015 0 : NDR_PULL_SET_MEM_CTX(ndr, r->out.info, LIBNDR_FLAG_REF_ALLOC);
16016 0 : NDR_CHECK(ndr_pull_set_switch_value(ndr, r->out.info, r->in.level));
16017 0 : NDR_CHECK(ndr_pull_srvsvc_NetFileInfo(ndr, NDR_SCALARS|NDR_BUFFERS, r->out.info));
16018 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_info_0, LIBNDR_FLAG_REF_ALLOC);
16019 0 : NDR_CHECK(ndr_pull_WERROR(ndr, NDR_SCALARS, &r->out.result));
16020 : }
16021 0 : return NDR_ERR_SUCCESS;
16022 : }
16023 :
16024 0 : _PUBLIC_ void ndr_print_srvsvc_NetFileGetInfo(struct ndr_print *ndr, const char *name, ndr_flags_type flags, const struct srvsvc_NetFileGetInfo *r)
16025 : {
16026 0 : ndr_print_struct(ndr, name, "srvsvc_NetFileGetInfo");
16027 0 : if (r == NULL) { ndr_print_null(ndr); return; }
16028 0 : ndr->depth++;
16029 0 : if (flags & NDR_SET_VALUES) {
16030 0 : ndr->flags |= LIBNDR_PRINT_SET_VALUES;
16031 : }
16032 0 : if (flags & NDR_IN) {
16033 0 : ndr_print_struct(ndr, "in", "srvsvc_NetFileGetInfo");
16034 0 : ndr->depth++;
16035 0 : ndr_print_ptr(ndr, "server_unc", r->in.server_unc);
16036 0 : ndr->depth++;
16037 0 : if (r->in.server_unc) {
16038 0 : ndr_print_string(ndr, "server_unc", r->in.server_unc);
16039 : }
16040 0 : ndr->depth--;
16041 0 : ndr_print_uint32(ndr, "fid", r->in.fid);
16042 0 : ndr_print_uint32(ndr, "level", r->in.level);
16043 0 : ndr->depth--;
16044 : }
16045 0 : if (flags & NDR_OUT) {
16046 0 : ndr_print_struct(ndr, "out", "srvsvc_NetFileGetInfo");
16047 0 : ndr->depth++;
16048 0 : ndr_print_ptr(ndr, "info", r->out.info);
16049 0 : ndr->depth++;
16050 0 : ndr_print_set_switch_value(ndr, r->out.info, r->in.level);
16051 0 : ndr_print_srvsvc_NetFileInfo(ndr, "info", r->out.info);
16052 0 : ndr->depth--;
16053 0 : ndr_print_WERROR(ndr, "result", r->out.result);
16054 0 : ndr->depth--;
16055 : }
16056 0 : ndr->depth--;
16057 : }
16058 :
16059 0 : static enum ndr_err_code ndr_push_srvsvc_NetFileClose(struct ndr_push *ndr, ndr_flags_type flags, const struct srvsvc_NetFileClose *r)
16060 : {
16061 0 : NDR_PUSH_CHECK_FN_FLAGS(ndr, flags);
16062 0 : if (flags & NDR_IN) {
16063 0 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->in.server_unc));
16064 0 : if (r->in.server_unc) {
16065 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->in.server_unc, CH_UTF16)));
16066 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, 0));
16067 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->in.server_unc, CH_UTF16)));
16068 0 : NDR_CHECK(ndr_push_charset(ndr, NDR_SCALARS, r->in.server_unc, ndr_charset_length(r->in.server_unc, CH_UTF16), sizeof(uint16_t), CH_UTF16));
16069 : }
16070 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->in.fid));
16071 : }
16072 0 : if (flags & NDR_OUT) {
16073 0 : NDR_CHECK(ndr_push_WERROR(ndr, NDR_SCALARS, r->out.result));
16074 : }
16075 0 : return NDR_ERR_SUCCESS;
16076 : }
16077 :
16078 0 : static enum ndr_err_code ndr_pull_srvsvc_NetFileClose(struct ndr_pull *ndr, ndr_flags_type flags, struct srvsvc_NetFileClose *r)
16079 : {
16080 0 : uint32_t _ptr_server_unc;
16081 0 : uint32_t size_server_unc_1 = 0;
16082 0 : uint32_t length_server_unc_1 = 0;
16083 0 : TALLOC_CTX *_mem_save_server_unc_0 = NULL;
16084 0 : NDR_PULL_CHECK_FN_FLAGS(ndr, flags);
16085 0 : if (flags & NDR_IN) {
16086 0 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_server_unc));
16087 0 : if (_ptr_server_unc) {
16088 0 : NDR_PULL_ALLOC(ndr, r->in.server_unc);
16089 : } else {
16090 0 : r->in.server_unc = NULL;
16091 : }
16092 0 : if (r->in.server_unc) {
16093 0 : _mem_save_server_unc_0 = NDR_PULL_GET_MEM_CTX(ndr);
16094 0 : NDR_PULL_SET_MEM_CTX(ndr, r->in.server_unc, 0);
16095 0 : NDR_CHECK(ndr_pull_array_size(ndr, &r->in.server_unc));
16096 0 : NDR_CHECK(ndr_pull_array_length(ndr, &r->in.server_unc));
16097 0 : NDR_CHECK(ndr_steal_array_size(ndr, (void*)&r->in.server_unc, &size_server_unc_1));
16098 0 : NDR_CHECK(ndr_steal_array_length(ndr, (void*)&r->in.server_unc, &length_server_unc_1));
16099 0 : if (length_server_unc_1 > size_server_unc_1) {
16100 0 : return ndr_pull_error(ndr, NDR_ERR_ARRAY_SIZE, "Bad array size %"PRIu32": should exceed array length %"PRIu32"", size_server_unc_1, length_server_unc_1);
16101 : }
16102 0 : NDR_CHECK(ndr_check_string_terminator(ndr, length_server_unc_1, sizeof(uint16_t)));
16103 0 : NDR_CHECK(ndr_pull_charset(ndr, NDR_SCALARS, &r->in.server_unc, length_server_unc_1, sizeof(uint16_t), CH_UTF16));
16104 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_server_unc_0, 0);
16105 : }
16106 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->in.fid));
16107 : }
16108 0 : if (flags & NDR_OUT) {
16109 : #ifdef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION
16110 : #endif /* FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION */
16111 0 : NDR_CHECK(ndr_pull_WERROR(ndr, NDR_SCALARS, &r->out.result));
16112 : }
16113 0 : return NDR_ERR_SUCCESS;
16114 : }
16115 :
16116 0 : _PUBLIC_ void ndr_print_srvsvc_NetFileClose(struct ndr_print *ndr, const char *name, ndr_flags_type flags, const struct srvsvc_NetFileClose *r)
16117 : {
16118 0 : ndr_print_struct(ndr, name, "srvsvc_NetFileClose");
16119 0 : if (r == NULL) { ndr_print_null(ndr); return; }
16120 0 : ndr->depth++;
16121 0 : if (flags & NDR_SET_VALUES) {
16122 0 : ndr->flags |= LIBNDR_PRINT_SET_VALUES;
16123 : }
16124 0 : if (flags & NDR_IN) {
16125 0 : ndr_print_struct(ndr, "in", "srvsvc_NetFileClose");
16126 0 : ndr->depth++;
16127 0 : ndr_print_ptr(ndr, "server_unc", r->in.server_unc);
16128 0 : ndr->depth++;
16129 0 : if (r->in.server_unc) {
16130 0 : ndr_print_string(ndr, "server_unc", r->in.server_unc);
16131 : }
16132 0 : ndr->depth--;
16133 0 : ndr_print_uint32(ndr, "fid", r->in.fid);
16134 0 : ndr->depth--;
16135 : }
16136 0 : if (flags & NDR_OUT) {
16137 0 : ndr_print_struct(ndr, "out", "srvsvc_NetFileClose");
16138 0 : ndr->depth++;
16139 0 : ndr_print_WERROR(ndr, "result", r->out.result);
16140 0 : ndr->depth--;
16141 : }
16142 0 : ndr->depth--;
16143 : }
16144 :
16145 113 : static enum ndr_err_code ndr_push_srvsvc_NetSessEnum(struct ndr_push *ndr, ndr_flags_type flags, const struct srvsvc_NetSessEnum *r)
16146 : {
16147 113 : NDR_PUSH_CHECK_FN_FLAGS(ndr, flags);
16148 113 : if (flags & NDR_IN) {
16149 54 : if (r->in.info_ctr == NULL) {
16150 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
16151 : }
16152 54 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->in.server_unc));
16153 54 : if (r->in.server_unc) {
16154 54 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->in.server_unc, CH_UTF16)));
16155 54 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, 0));
16156 54 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->in.server_unc, CH_UTF16)));
16157 54 : NDR_CHECK(ndr_push_charset(ndr, NDR_SCALARS, r->in.server_unc, ndr_charset_length(r->in.server_unc, CH_UTF16), sizeof(uint16_t), CH_UTF16));
16158 : }
16159 54 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->in.client));
16160 54 : if (r->in.client) {
16161 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->in.client, CH_UTF16)));
16162 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, 0));
16163 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->in.client, CH_UTF16)));
16164 0 : NDR_CHECK(ndr_push_charset(ndr, NDR_SCALARS, r->in.client, ndr_charset_length(r->in.client, CH_UTF16), sizeof(uint16_t), CH_UTF16));
16165 : }
16166 54 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->in.user));
16167 54 : if (r->in.user) {
16168 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->in.user, CH_UTF16)));
16169 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, 0));
16170 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->in.user, CH_UTF16)));
16171 0 : NDR_CHECK(ndr_push_charset(ndr, NDR_SCALARS, r->in.user, ndr_charset_length(r->in.user, CH_UTF16), sizeof(uint16_t), CH_UTF16));
16172 : }
16173 54 : NDR_CHECK(ndr_push_srvsvc_NetSessInfoCtr(ndr, NDR_SCALARS|NDR_BUFFERS, r->in.info_ctr));
16174 54 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->in.max_buffer));
16175 54 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->in.resume_handle));
16176 54 : if (r->in.resume_handle) {
16177 8 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, *r->in.resume_handle));
16178 : }
16179 : }
16180 113 : if (flags & NDR_OUT) {
16181 59 : if (r->out.info_ctr == NULL) {
16182 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
16183 : }
16184 59 : if (r->out.totalentries == NULL) {
16185 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
16186 : }
16187 59 : NDR_CHECK(ndr_push_srvsvc_NetSessInfoCtr(ndr, NDR_SCALARS|NDR_BUFFERS, r->out.info_ctr));
16188 59 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, *r->out.totalentries));
16189 59 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->out.resume_handle));
16190 59 : if (r->out.resume_handle) {
16191 8 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, *r->out.resume_handle));
16192 : }
16193 59 : NDR_CHECK(ndr_push_WERROR(ndr, NDR_SCALARS, r->out.result));
16194 : }
16195 113 : return NDR_ERR_SUCCESS;
16196 : }
16197 :
16198 108 : static enum ndr_err_code ndr_pull_srvsvc_NetSessEnum(struct ndr_pull *ndr, ndr_flags_type flags, struct srvsvc_NetSessEnum *r)
16199 : {
16200 0 : uint32_t _ptr_server_unc;
16201 108 : uint32_t size_server_unc_1 = 0;
16202 108 : uint32_t length_server_unc_1 = 0;
16203 0 : uint32_t _ptr_client;
16204 108 : uint32_t size_client_1 = 0;
16205 108 : uint32_t length_client_1 = 0;
16206 0 : uint32_t _ptr_user;
16207 108 : uint32_t size_user_1 = 0;
16208 108 : uint32_t length_user_1 = 0;
16209 0 : uint32_t _ptr_resume_handle;
16210 108 : TALLOC_CTX *_mem_save_server_unc_0 = NULL;
16211 108 : TALLOC_CTX *_mem_save_client_0 = NULL;
16212 108 : TALLOC_CTX *_mem_save_user_0 = NULL;
16213 108 : TALLOC_CTX *_mem_save_info_ctr_0 = NULL;
16214 108 : TALLOC_CTX *_mem_save_totalentries_0 = NULL;
16215 108 : TALLOC_CTX *_mem_save_resume_handle_0 = NULL;
16216 108 : NDR_PULL_CHECK_FN_FLAGS(ndr, flags);
16217 108 : if (flags & NDR_IN) {
16218 54 : NDR_ZERO_STRUCT(r->out);
16219 :
16220 54 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_server_unc));
16221 54 : if (_ptr_server_unc) {
16222 54 : NDR_PULL_ALLOC(ndr, r->in.server_unc);
16223 : } else {
16224 0 : r->in.server_unc = NULL;
16225 : }
16226 54 : if (r->in.server_unc) {
16227 54 : _mem_save_server_unc_0 = NDR_PULL_GET_MEM_CTX(ndr);
16228 54 : NDR_PULL_SET_MEM_CTX(ndr, r->in.server_unc, 0);
16229 54 : NDR_CHECK(ndr_pull_array_size(ndr, &r->in.server_unc));
16230 54 : NDR_CHECK(ndr_pull_array_length(ndr, &r->in.server_unc));
16231 54 : NDR_CHECK(ndr_steal_array_size(ndr, (void*)&r->in.server_unc, &size_server_unc_1));
16232 54 : NDR_CHECK(ndr_steal_array_length(ndr, (void*)&r->in.server_unc, &length_server_unc_1));
16233 54 : if (length_server_unc_1 > size_server_unc_1) {
16234 0 : return ndr_pull_error(ndr, NDR_ERR_ARRAY_SIZE, "Bad array size %"PRIu32": should exceed array length %"PRIu32"", size_server_unc_1, length_server_unc_1);
16235 : }
16236 54 : NDR_CHECK(ndr_check_string_terminator(ndr, length_server_unc_1, sizeof(uint16_t)));
16237 54 : NDR_CHECK(ndr_pull_charset(ndr, NDR_SCALARS, &r->in.server_unc, length_server_unc_1, sizeof(uint16_t), CH_UTF16));
16238 54 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_server_unc_0, 0);
16239 : }
16240 54 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_client));
16241 54 : if (_ptr_client) {
16242 0 : NDR_PULL_ALLOC(ndr, r->in.client);
16243 : } else {
16244 54 : r->in.client = NULL;
16245 : }
16246 54 : if (r->in.client) {
16247 0 : _mem_save_client_0 = NDR_PULL_GET_MEM_CTX(ndr);
16248 0 : NDR_PULL_SET_MEM_CTX(ndr, r->in.client, 0);
16249 0 : NDR_CHECK(ndr_pull_array_size(ndr, &r->in.client));
16250 0 : NDR_CHECK(ndr_pull_array_length(ndr, &r->in.client));
16251 0 : NDR_CHECK(ndr_steal_array_size(ndr, (void*)&r->in.client, &size_client_1));
16252 0 : NDR_CHECK(ndr_steal_array_length(ndr, (void*)&r->in.client, &length_client_1));
16253 0 : if (length_client_1 > size_client_1) {
16254 0 : return ndr_pull_error(ndr, NDR_ERR_ARRAY_SIZE, "Bad array size %"PRIu32": should exceed array length %"PRIu32"", size_client_1, length_client_1);
16255 : }
16256 0 : NDR_CHECK(ndr_check_string_terminator(ndr, length_client_1, sizeof(uint16_t)));
16257 0 : NDR_CHECK(ndr_pull_charset(ndr, NDR_SCALARS, &r->in.client, length_client_1, sizeof(uint16_t), CH_UTF16));
16258 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_client_0, 0);
16259 : }
16260 54 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_user));
16261 54 : if (_ptr_user) {
16262 0 : NDR_PULL_ALLOC(ndr, r->in.user);
16263 : } else {
16264 54 : r->in.user = NULL;
16265 : }
16266 54 : if (r->in.user) {
16267 0 : _mem_save_user_0 = NDR_PULL_GET_MEM_CTX(ndr);
16268 0 : NDR_PULL_SET_MEM_CTX(ndr, r->in.user, 0);
16269 0 : NDR_CHECK(ndr_pull_array_size(ndr, &r->in.user));
16270 0 : NDR_CHECK(ndr_pull_array_length(ndr, &r->in.user));
16271 0 : NDR_CHECK(ndr_steal_array_size(ndr, (void*)&r->in.user, &size_user_1));
16272 0 : NDR_CHECK(ndr_steal_array_length(ndr, (void*)&r->in.user, &length_user_1));
16273 0 : if (length_user_1 > size_user_1) {
16274 0 : return ndr_pull_error(ndr, NDR_ERR_ARRAY_SIZE, "Bad array size %"PRIu32": should exceed array length %"PRIu32"", size_user_1, length_user_1);
16275 : }
16276 0 : NDR_CHECK(ndr_check_string_terminator(ndr, length_user_1, sizeof(uint16_t)));
16277 0 : NDR_CHECK(ndr_pull_charset(ndr, NDR_SCALARS, &r->in.user, length_user_1, sizeof(uint16_t), CH_UTF16));
16278 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_user_0, 0);
16279 : }
16280 54 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
16281 54 : NDR_PULL_ALLOC(ndr, r->in.info_ctr);
16282 : }
16283 54 : _mem_save_info_ctr_0 = NDR_PULL_GET_MEM_CTX(ndr);
16284 54 : NDR_PULL_SET_MEM_CTX(ndr, r->in.info_ctr, LIBNDR_FLAG_REF_ALLOC);
16285 54 : NDR_CHECK(ndr_pull_srvsvc_NetSessInfoCtr(ndr, NDR_SCALARS|NDR_BUFFERS, r->in.info_ctr));
16286 54 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_info_ctr_0, LIBNDR_FLAG_REF_ALLOC);
16287 54 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->in.max_buffer));
16288 54 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_resume_handle));
16289 54 : if (_ptr_resume_handle) {
16290 8 : NDR_PULL_ALLOC(ndr, r->in.resume_handle);
16291 : } else {
16292 46 : r->in.resume_handle = NULL;
16293 : }
16294 54 : if (r->in.resume_handle) {
16295 8 : _mem_save_resume_handle_0 = NDR_PULL_GET_MEM_CTX(ndr);
16296 8 : NDR_PULL_SET_MEM_CTX(ndr, r->in.resume_handle, 0);
16297 8 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, r->in.resume_handle));
16298 8 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_resume_handle_0, 0);
16299 : }
16300 54 : NDR_PULL_ALLOC(ndr, r->out.info_ctr);
16301 54 : *r->out.info_ctr = *r->in.info_ctr;
16302 54 : NDR_PULL_ALLOC(ndr, r->out.totalentries);
16303 54 : NDR_ZERO_STRUCTP(r->out.totalentries);
16304 : }
16305 108 : if (flags & NDR_OUT) {
16306 : #ifdef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION
16307 : if (r->in.info_ctr == NULL) {
16308 : NDR_PULL_ALLOC(ndr, r->in.info_ctr);
16309 : NDR_ZERO_STRUCTP(r->in.info_ctr);
16310 : }
16311 : #endif /* FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION */
16312 54 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
16313 19 : NDR_PULL_ALLOC(ndr, r->out.info_ctr);
16314 : }
16315 54 : _mem_save_info_ctr_0 = NDR_PULL_GET_MEM_CTX(ndr);
16316 54 : NDR_PULL_SET_MEM_CTX(ndr, r->out.info_ctr, LIBNDR_FLAG_REF_ALLOC);
16317 54 : NDR_CHECK(ndr_pull_srvsvc_NetSessInfoCtr(ndr, NDR_SCALARS|NDR_BUFFERS, r->out.info_ctr));
16318 54 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_info_ctr_0, LIBNDR_FLAG_REF_ALLOC);
16319 54 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
16320 19 : NDR_PULL_ALLOC(ndr, r->out.totalentries);
16321 : }
16322 54 : _mem_save_totalentries_0 = NDR_PULL_GET_MEM_CTX(ndr);
16323 54 : NDR_PULL_SET_MEM_CTX(ndr, r->out.totalentries, LIBNDR_FLAG_REF_ALLOC);
16324 54 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, r->out.totalentries));
16325 54 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_totalentries_0, LIBNDR_FLAG_REF_ALLOC);
16326 54 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_resume_handle));
16327 54 : if (_ptr_resume_handle) {
16328 8 : NDR_PULL_ALLOC(ndr, r->out.resume_handle);
16329 : } else {
16330 46 : r->out.resume_handle = NULL;
16331 : }
16332 54 : if (r->out.resume_handle) {
16333 8 : _mem_save_resume_handle_0 = NDR_PULL_GET_MEM_CTX(ndr);
16334 8 : NDR_PULL_SET_MEM_CTX(ndr, r->out.resume_handle, 0);
16335 8 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, r->out.resume_handle));
16336 8 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_resume_handle_0, 0);
16337 : }
16338 54 : NDR_CHECK(ndr_pull_WERROR(ndr, NDR_SCALARS, &r->out.result));
16339 : }
16340 108 : return NDR_ERR_SUCCESS;
16341 : }
16342 :
16343 10 : _PUBLIC_ void ndr_print_srvsvc_NetSessEnum(struct ndr_print *ndr, const char *name, ndr_flags_type flags, const struct srvsvc_NetSessEnum *r)
16344 : {
16345 10 : ndr_print_struct(ndr, name, "srvsvc_NetSessEnum");
16346 10 : if (r == NULL) { ndr_print_null(ndr); return; }
16347 10 : ndr->depth++;
16348 10 : if (flags & NDR_SET_VALUES) {
16349 0 : ndr->flags |= LIBNDR_PRINT_SET_VALUES;
16350 : }
16351 10 : if (flags & NDR_IN) {
16352 0 : ndr_print_struct(ndr, "in", "srvsvc_NetSessEnum");
16353 0 : ndr->depth++;
16354 0 : ndr_print_ptr(ndr, "server_unc", r->in.server_unc);
16355 0 : ndr->depth++;
16356 0 : if (r->in.server_unc) {
16357 0 : ndr_print_string(ndr, "server_unc", r->in.server_unc);
16358 : }
16359 0 : ndr->depth--;
16360 0 : ndr_print_ptr(ndr, "client", r->in.client);
16361 0 : ndr->depth++;
16362 0 : if (r->in.client) {
16363 0 : ndr_print_string(ndr, "client", r->in.client);
16364 : }
16365 0 : ndr->depth--;
16366 0 : ndr_print_ptr(ndr, "user", r->in.user);
16367 0 : ndr->depth++;
16368 0 : if (r->in.user) {
16369 0 : ndr_print_string(ndr, "user", r->in.user);
16370 : }
16371 0 : ndr->depth--;
16372 0 : ndr_print_ptr(ndr, "info_ctr", r->in.info_ctr);
16373 0 : ndr->depth++;
16374 0 : ndr_print_srvsvc_NetSessInfoCtr(ndr, "info_ctr", r->in.info_ctr);
16375 0 : ndr->depth--;
16376 0 : ndr_print_uint32(ndr, "max_buffer", r->in.max_buffer);
16377 0 : ndr_print_ptr(ndr, "resume_handle", r->in.resume_handle);
16378 0 : ndr->depth++;
16379 0 : if (r->in.resume_handle) {
16380 0 : ndr_print_uint32(ndr, "resume_handle", *r->in.resume_handle);
16381 : }
16382 0 : ndr->depth--;
16383 0 : ndr->depth--;
16384 : }
16385 10 : if (flags & NDR_OUT) {
16386 10 : ndr_print_struct(ndr, "out", "srvsvc_NetSessEnum");
16387 10 : ndr->depth++;
16388 10 : ndr_print_ptr(ndr, "info_ctr", r->out.info_ctr);
16389 10 : ndr->depth++;
16390 10 : ndr_print_srvsvc_NetSessInfoCtr(ndr, "info_ctr", r->out.info_ctr);
16391 10 : ndr->depth--;
16392 10 : ndr_print_ptr(ndr, "totalentries", r->out.totalentries);
16393 10 : ndr->depth++;
16394 10 : ndr_print_uint32(ndr, "totalentries", *r->out.totalentries);
16395 10 : ndr->depth--;
16396 10 : ndr_print_ptr(ndr, "resume_handle", r->out.resume_handle);
16397 10 : ndr->depth++;
16398 10 : if (r->out.resume_handle) {
16399 0 : ndr_print_uint32(ndr, "resume_handle", *r->out.resume_handle);
16400 : }
16401 10 : ndr->depth--;
16402 10 : ndr_print_WERROR(ndr, "result", r->out.result);
16403 10 : ndr->depth--;
16404 : }
16405 10 : ndr->depth--;
16406 : }
16407 :
16408 0 : static enum ndr_err_code ndr_push_srvsvc_NetSessDel(struct ndr_push *ndr, ndr_flags_type flags, const struct srvsvc_NetSessDel *r)
16409 : {
16410 0 : NDR_PUSH_CHECK_FN_FLAGS(ndr, flags);
16411 0 : if (flags & NDR_IN) {
16412 0 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->in.server_unc));
16413 0 : if (r->in.server_unc) {
16414 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->in.server_unc, CH_UTF16)));
16415 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, 0));
16416 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->in.server_unc, CH_UTF16)));
16417 0 : NDR_CHECK(ndr_push_charset(ndr, NDR_SCALARS, r->in.server_unc, ndr_charset_length(r->in.server_unc, CH_UTF16), sizeof(uint16_t), CH_UTF16));
16418 : }
16419 0 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->in.client));
16420 0 : if (r->in.client) {
16421 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->in.client, CH_UTF16)));
16422 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, 0));
16423 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->in.client, CH_UTF16)));
16424 0 : NDR_CHECK(ndr_push_charset(ndr, NDR_SCALARS, r->in.client, ndr_charset_length(r->in.client, CH_UTF16), sizeof(uint16_t), CH_UTF16));
16425 : }
16426 0 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->in.user));
16427 0 : if (r->in.user) {
16428 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->in.user, CH_UTF16)));
16429 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, 0));
16430 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->in.user, CH_UTF16)));
16431 0 : NDR_CHECK(ndr_push_charset(ndr, NDR_SCALARS, r->in.user, ndr_charset_length(r->in.user, CH_UTF16), sizeof(uint16_t), CH_UTF16));
16432 : }
16433 : }
16434 0 : if (flags & NDR_OUT) {
16435 0 : NDR_CHECK(ndr_push_WERROR(ndr, NDR_SCALARS, r->out.result));
16436 : }
16437 0 : return NDR_ERR_SUCCESS;
16438 : }
16439 :
16440 0 : static enum ndr_err_code ndr_pull_srvsvc_NetSessDel(struct ndr_pull *ndr, ndr_flags_type flags, struct srvsvc_NetSessDel *r)
16441 : {
16442 0 : uint32_t _ptr_server_unc;
16443 0 : uint32_t size_server_unc_1 = 0;
16444 0 : uint32_t length_server_unc_1 = 0;
16445 0 : uint32_t _ptr_client;
16446 0 : uint32_t size_client_1 = 0;
16447 0 : uint32_t length_client_1 = 0;
16448 0 : uint32_t _ptr_user;
16449 0 : uint32_t size_user_1 = 0;
16450 0 : uint32_t length_user_1 = 0;
16451 0 : TALLOC_CTX *_mem_save_server_unc_0 = NULL;
16452 0 : TALLOC_CTX *_mem_save_client_0 = NULL;
16453 0 : TALLOC_CTX *_mem_save_user_0 = NULL;
16454 0 : NDR_PULL_CHECK_FN_FLAGS(ndr, flags);
16455 0 : if (flags & NDR_IN) {
16456 0 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_server_unc));
16457 0 : if (_ptr_server_unc) {
16458 0 : NDR_PULL_ALLOC(ndr, r->in.server_unc);
16459 : } else {
16460 0 : r->in.server_unc = NULL;
16461 : }
16462 0 : if (r->in.server_unc) {
16463 0 : _mem_save_server_unc_0 = NDR_PULL_GET_MEM_CTX(ndr);
16464 0 : NDR_PULL_SET_MEM_CTX(ndr, r->in.server_unc, 0);
16465 0 : NDR_CHECK(ndr_pull_array_size(ndr, &r->in.server_unc));
16466 0 : NDR_CHECK(ndr_pull_array_length(ndr, &r->in.server_unc));
16467 0 : NDR_CHECK(ndr_steal_array_size(ndr, (void*)&r->in.server_unc, &size_server_unc_1));
16468 0 : NDR_CHECK(ndr_steal_array_length(ndr, (void*)&r->in.server_unc, &length_server_unc_1));
16469 0 : if (length_server_unc_1 > size_server_unc_1) {
16470 0 : return ndr_pull_error(ndr, NDR_ERR_ARRAY_SIZE, "Bad array size %"PRIu32": should exceed array length %"PRIu32"", size_server_unc_1, length_server_unc_1);
16471 : }
16472 0 : NDR_CHECK(ndr_check_string_terminator(ndr, length_server_unc_1, sizeof(uint16_t)));
16473 0 : NDR_CHECK(ndr_pull_charset(ndr, NDR_SCALARS, &r->in.server_unc, length_server_unc_1, sizeof(uint16_t), CH_UTF16));
16474 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_server_unc_0, 0);
16475 : }
16476 0 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_client));
16477 0 : if (_ptr_client) {
16478 0 : NDR_PULL_ALLOC(ndr, r->in.client);
16479 : } else {
16480 0 : r->in.client = NULL;
16481 : }
16482 0 : if (r->in.client) {
16483 0 : _mem_save_client_0 = NDR_PULL_GET_MEM_CTX(ndr);
16484 0 : NDR_PULL_SET_MEM_CTX(ndr, r->in.client, 0);
16485 0 : NDR_CHECK(ndr_pull_array_size(ndr, &r->in.client));
16486 0 : NDR_CHECK(ndr_pull_array_length(ndr, &r->in.client));
16487 0 : NDR_CHECK(ndr_steal_array_size(ndr, (void*)&r->in.client, &size_client_1));
16488 0 : NDR_CHECK(ndr_steal_array_length(ndr, (void*)&r->in.client, &length_client_1));
16489 0 : if (length_client_1 > size_client_1) {
16490 0 : return ndr_pull_error(ndr, NDR_ERR_ARRAY_SIZE, "Bad array size %"PRIu32": should exceed array length %"PRIu32"", size_client_1, length_client_1);
16491 : }
16492 0 : NDR_CHECK(ndr_check_string_terminator(ndr, length_client_1, sizeof(uint16_t)));
16493 0 : NDR_CHECK(ndr_pull_charset(ndr, NDR_SCALARS, &r->in.client, length_client_1, sizeof(uint16_t), CH_UTF16));
16494 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_client_0, 0);
16495 : }
16496 0 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_user));
16497 0 : if (_ptr_user) {
16498 0 : NDR_PULL_ALLOC(ndr, r->in.user);
16499 : } else {
16500 0 : r->in.user = NULL;
16501 : }
16502 0 : if (r->in.user) {
16503 0 : _mem_save_user_0 = NDR_PULL_GET_MEM_CTX(ndr);
16504 0 : NDR_PULL_SET_MEM_CTX(ndr, r->in.user, 0);
16505 0 : NDR_CHECK(ndr_pull_array_size(ndr, &r->in.user));
16506 0 : NDR_CHECK(ndr_pull_array_length(ndr, &r->in.user));
16507 0 : NDR_CHECK(ndr_steal_array_size(ndr, (void*)&r->in.user, &size_user_1));
16508 0 : NDR_CHECK(ndr_steal_array_length(ndr, (void*)&r->in.user, &length_user_1));
16509 0 : if (length_user_1 > size_user_1) {
16510 0 : return ndr_pull_error(ndr, NDR_ERR_ARRAY_SIZE, "Bad array size %"PRIu32": should exceed array length %"PRIu32"", size_user_1, length_user_1);
16511 : }
16512 0 : NDR_CHECK(ndr_check_string_terminator(ndr, length_user_1, sizeof(uint16_t)));
16513 0 : NDR_CHECK(ndr_pull_charset(ndr, NDR_SCALARS, &r->in.user, length_user_1, sizeof(uint16_t), CH_UTF16));
16514 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_user_0, 0);
16515 : }
16516 : }
16517 0 : if (flags & NDR_OUT) {
16518 : #ifdef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION
16519 : #endif /* FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION */
16520 0 : NDR_CHECK(ndr_pull_WERROR(ndr, NDR_SCALARS, &r->out.result));
16521 : }
16522 0 : return NDR_ERR_SUCCESS;
16523 : }
16524 :
16525 0 : _PUBLIC_ void ndr_print_srvsvc_NetSessDel(struct ndr_print *ndr, const char *name, ndr_flags_type flags, const struct srvsvc_NetSessDel *r)
16526 : {
16527 0 : ndr_print_struct(ndr, name, "srvsvc_NetSessDel");
16528 0 : if (r == NULL) { ndr_print_null(ndr); return; }
16529 0 : ndr->depth++;
16530 0 : if (flags & NDR_SET_VALUES) {
16531 0 : ndr->flags |= LIBNDR_PRINT_SET_VALUES;
16532 : }
16533 0 : if (flags & NDR_IN) {
16534 0 : ndr_print_struct(ndr, "in", "srvsvc_NetSessDel");
16535 0 : ndr->depth++;
16536 0 : ndr_print_ptr(ndr, "server_unc", r->in.server_unc);
16537 0 : ndr->depth++;
16538 0 : if (r->in.server_unc) {
16539 0 : ndr_print_string(ndr, "server_unc", r->in.server_unc);
16540 : }
16541 0 : ndr->depth--;
16542 0 : ndr_print_ptr(ndr, "client", r->in.client);
16543 0 : ndr->depth++;
16544 0 : if (r->in.client) {
16545 0 : ndr_print_string(ndr, "client", r->in.client);
16546 : }
16547 0 : ndr->depth--;
16548 0 : ndr_print_ptr(ndr, "user", r->in.user);
16549 0 : ndr->depth++;
16550 0 : if (r->in.user) {
16551 0 : ndr_print_string(ndr, "user", r->in.user);
16552 : }
16553 0 : ndr->depth--;
16554 0 : ndr->depth--;
16555 : }
16556 0 : if (flags & NDR_OUT) {
16557 0 : ndr_print_struct(ndr, "out", "srvsvc_NetSessDel");
16558 0 : ndr->depth++;
16559 0 : ndr_print_WERROR(ndr, "result", r->out.result);
16560 0 : ndr->depth--;
16561 : }
16562 0 : ndr->depth--;
16563 : }
16564 :
16565 10 : static enum ndr_err_code ndr_push_srvsvc_NetShareAdd(struct ndr_push *ndr, ndr_flags_type flags, const struct srvsvc_NetShareAdd *r)
16566 : {
16567 10 : NDR_PUSH_CHECK_FN_FLAGS(ndr, flags);
16568 10 : if (flags & NDR_IN) {
16569 5 : if (r->in.info == NULL) {
16570 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
16571 : }
16572 5 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->in.server_unc));
16573 5 : if (r->in.server_unc) {
16574 5 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->in.server_unc, CH_UTF16)));
16575 5 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, 0));
16576 5 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->in.server_unc, CH_UTF16)));
16577 5 : NDR_CHECK(ndr_push_charset(ndr, NDR_SCALARS, r->in.server_unc, ndr_charset_length(r->in.server_unc, CH_UTF16), sizeof(uint16_t), CH_UTF16));
16578 : }
16579 5 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->in.level));
16580 5 : NDR_CHECK(ndr_push_set_switch_value(ndr, r->in.info, r->in.level));
16581 5 : NDR_CHECK(ndr_push_srvsvc_NetShareInfo(ndr, NDR_SCALARS|NDR_BUFFERS, r->in.info));
16582 5 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->in.parm_error));
16583 5 : if (r->in.parm_error) {
16584 3 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, *r->in.parm_error));
16585 : }
16586 : }
16587 10 : if (flags & NDR_OUT) {
16588 5 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->out.parm_error));
16589 5 : if (r->out.parm_error) {
16590 2 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, *r->out.parm_error));
16591 : }
16592 5 : NDR_CHECK(ndr_push_WERROR(ndr, NDR_SCALARS, r->out.result));
16593 : }
16594 10 : return NDR_ERR_SUCCESS;
16595 : }
16596 :
16597 9 : static enum ndr_err_code ndr_pull_srvsvc_NetShareAdd(struct ndr_pull *ndr, ndr_flags_type flags, struct srvsvc_NetShareAdd *r)
16598 : {
16599 0 : uint32_t _ptr_server_unc;
16600 9 : uint32_t size_server_unc_1 = 0;
16601 9 : uint32_t length_server_unc_1 = 0;
16602 0 : uint32_t _ptr_parm_error;
16603 9 : TALLOC_CTX *_mem_save_server_unc_0 = NULL;
16604 9 : TALLOC_CTX *_mem_save_info_0 = NULL;
16605 9 : TALLOC_CTX *_mem_save_parm_error_0 = NULL;
16606 9 : NDR_PULL_CHECK_FN_FLAGS(ndr, flags);
16607 9 : if (flags & NDR_IN) {
16608 4 : NDR_ZERO_STRUCT(r->out);
16609 :
16610 4 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_server_unc));
16611 4 : if (_ptr_server_unc) {
16612 4 : NDR_PULL_ALLOC(ndr, r->in.server_unc);
16613 : } else {
16614 0 : r->in.server_unc = NULL;
16615 : }
16616 4 : if (r->in.server_unc) {
16617 4 : _mem_save_server_unc_0 = NDR_PULL_GET_MEM_CTX(ndr);
16618 4 : NDR_PULL_SET_MEM_CTX(ndr, r->in.server_unc, 0);
16619 4 : NDR_CHECK(ndr_pull_array_size(ndr, &r->in.server_unc));
16620 4 : NDR_CHECK(ndr_pull_array_length(ndr, &r->in.server_unc));
16621 4 : NDR_CHECK(ndr_steal_array_size(ndr, (void*)&r->in.server_unc, &size_server_unc_1));
16622 4 : NDR_CHECK(ndr_steal_array_length(ndr, (void*)&r->in.server_unc, &length_server_unc_1));
16623 4 : if (length_server_unc_1 > size_server_unc_1) {
16624 0 : return ndr_pull_error(ndr, NDR_ERR_ARRAY_SIZE, "Bad array size %"PRIu32": should exceed array length %"PRIu32"", size_server_unc_1, length_server_unc_1);
16625 : }
16626 4 : NDR_CHECK(ndr_check_string_terminator(ndr, length_server_unc_1, sizeof(uint16_t)));
16627 4 : NDR_CHECK(ndr_pull_charset(ndr, NDR_SCALARS, &r->in.server_unc, length_server_unc_1, sizeof(uint16_t), CH_UTF16));
16628 4 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_server_unc_0, 0);
16629 : }
16630 4 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->in.level));
16631 4 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
16632 4 : NDR_PULL_ALLOC(ndr, r->in.info);
16633 : }
16634 4 : _mem_save_info_0 = NDR_PULL_GET_MEM_CTX(ndr);
16635 4 : NDR_PULL_SET_MEM_CTX(ndr, r->in.info, LIBNDR_FLAG_REF_ALLOC);
16636 4 : NDR_CHECK(ndr_pull_set_switch_value(ndr, r->in.info, r->in.level));
16637 4 : NDR_CHECK(ndr_pull_srvsvc_NetShareInfo(ndr, NDR_SCALARS|NDR_BUFFERS, r->in.info));
16638 4 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_info_0, LIBNDR_FLAG_REF_ALLOC);
16639 4 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_parm_error));
16640 4 : if (_ptr_parm_error) {
16641 2 : NDR_PULL_ALLOC(ndr, r->in.parm_error);
16642 : } else {
16643 2 : r->in.parm_error = NULL;
16644 : }
16645 4 : if (r->in.parm_error) {
16646 2 : _mem_save_parm_error_0 = NDR_PULL_GET_MEM_CTX(ndr);
16647 2 : NDR_PULL_SET_MEM_CTX(ndr, r->in.parm_error, 0);
16648 2 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, r->in.parm_error));
16649 2 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_parm_error_0, 0);
16650 : }
16651 : }
16652 9 : if (flags & NDR_OUT) {
16653 : #ifdef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION
16654 : if (r->in.info == NULL) {
16655 : NDR_PULL_ALLOC(ndr, r->in.info);
16656 : NDR_ZERO_STRUCTP(r->in.info);
16657 : }
16658 : #endif /* FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION */
16659 5 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_parm_error));
16660 5 : if (_ptr_parm_error) {
16661 3 : NDR_PULL_ALLOC(ndr, r->out.parm_error);
16662 : } else {
16663 2 : r->out.parm_error = NULL;
16664 : }
16665 5 : if (r->out.parm_error) {
16666 3 : _mem_save_parm_error_0 = NDR_PULL_GET_MEM_CTX(ndr);
16667 3 : NDR_PULL_SET_MEM_CTX(ndr, r->out.parm_error, 0);
16668 3 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, r->out.parm_error));
16669 3 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_parm_error_0, 0);
16670 : }
16671 5 : NDR_CHECK(ndr_pull_WERROR(ndr, NDR_SCALARS, &r->out.result));
16672 : }
16673 9 : return NDR_ERR_SUCCESS;
16674 : }
16675 :
16676 2 : _PUBLIC_ void ndr_print_srvsvc_NetShareAdd(struct ndr_print *ndr, const char *name, ndr_flags_type flags, const struct srvsvc_NetShareAdd *r)
16677 : {
16678 2 : ndr_print_struct(ndr, name, "srvsvc_NetShareAdd");
16679 2 : if (r == NULL) { ndr_print_null(ndr); return; }
16680 2 : ndr->depth++;
16681 2 : if (flags & NDR_SET_VALUES) {
16682 0 : ndr->flags |= LIBNDR_PRINT_SET_VALUES;
16683 : }
16684 2 : if (flags & NDR_IN) {
16685 0 : ndr_print_struct(ndr, "in", "srvsvc_NetShareAdd");
16686 0 : ndr->depth++;
16687 0 : ndr_print_ptr(ndr, "server_unc", r->in.server_unc);
16688 0 : ndr->depth++;
16689 0 : if (r->in.server_unc) {
16690 0 : ndr_print_string(ndr, "server_unc", r->in.server_unc);
16691 : }
16692 0 : ndr->depth--;
16693 0 : ndr_print_uint32(ndr, "level", r->in.level);
16694 0 : ndr_print_ptr(ndr, "info", r->in.info);
16695 0 : ndr->depth++;
16696 0 : ndr_print_set_switch_value(ndr, r->in.info, r->in.level);
16697 0 : ndr_print_srvsvc_NetShareInfo(ndr, "info", r->in.info);
16698 0 : ndr->depth--;
16699 0 : ndr_print_ptr(ndr, "parm_error", r->in.parm_error);
16700 0 : ndr->depth++;
16701 0 : if (r->in.parm_error) {
16702 0 : ndr_print_uint32(ndr, "parm_error", *r->in.parm_error);
16703 : }
16704 0 : ndr->depth--;
16705 0 : ndr->depth--;
16706 : }
16707 2 : if (flags & NDR_OUT) {
16708 2 : ndr_print_struct(ndr, "out", "srvsvc_NetShareAdd");
16709 2 : ndr->depth++;
16710 2 : ndr_print_ptr(ndr, "parm_error", r->out.parm_error);
16711 2 : ndr->depth++;
16712 2 : if (r->out.parm_error) {
16713 0 : ndr_print_uint32(ndr, "parm_error", *r->out.parm_error);
16714 : }
16715 2 : ndr->depth--;
16716 2 : ndr_print_WERROR(ndr, "result", r->out.result);
16717 2 : ndr->depth--;
16718 : }
16719 2 : ndr->depth--;
16720 : }
16721 :
16722 362 : static enum ndr_err_code ndr_push_srvsvc_NetShareEnumAll(struct ndr_push *ndr, ndr_flags_type flags, const struct srvsvc_NetShareEnumAll *r)
16723 : {
16724 362 : NDR_PUSH_CHECK_FN_FLAGS(ndr, flags);
16725 362 : if (flags & NDR_IN) {
16726 184 : if (r->in.info_ctr == NULL) {
16727 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
16728 : }
16729 184 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->in.server_unc));
16730 184 : if (r->in.server_unc) {
16731 184 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->in.server_unc, CH_UTF16)));
16732 184 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, 0));
16733 184 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->in.server_unc, CH_UTF16)));
16734 184 : NDR_CHECK(ndr_push_charset(ndr, NDR_SCALARS, r->in.server_unc, ndr_charset_length(r->in.server_unc, CH_UTF16), sizeof(uint16_t), CH_UTF16));
16735 : }
16736 184 : NDR_CHECK(ndr_push_srvsvc_NetShareInfoCtr(ndr, NDR_SCALARS|NDR_BUFFERS, r->in.info_ctr));
16737 184 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->in.max_buffer));
16738 184 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->in.resume_handle));
16739 184 : if (r->in.resume_handle) {
16740 172 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, *r->in.resume_handle));
16741 : }
16742 : }
16743 362 : if (flags & NDR_OUT) {
16744 178 : if (r->out.info_ctr == NULL) {
16745 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
16746 : }
16747 178 : if (r->out.totalentries == NULL) {
16748 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
16749 : }
16750 178 : NDR_CHECK(ndr_push_srvsvc_NetShareInfoCtr(ndr, NDR_SCALARS|NDR_BUFFERS, r->out.info_ctr));
16751 178 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, *r->out.totalentries));
16752 178 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->out.resume_handle));
16753 178 : if (r->out.resume_handle) {
16754 114 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, *r->out.resume_handle));
16755 : }
16756 178 : NDR_CHECK(ndr_push_WERROR(ndr, NDR_SCALARS, r->out.result));
16757 : }
16758 362 : return NDR_ERR_SUCCESS;
16759 : }
16760 :
16761 352 : static enum ndr_err_code ndr_pull_srvsvc_NetShareEnumAll(struct ndr_pull *ndr, ndr_flags_type flags, struct srvsvc_NetShareEnumAll *r)
16762 : {
16763 0 : uint32_t _ptr_server_unc;
16764 352 : uint32_t size_server_unc_1 = 0;
16765 352 : uint32_t length_server_unc_1 = 0;
16766 0 : uint32_t _ptr_resume_handle;
16767 352 : TALLOC_CTX *_mem_save_server_unc_0 = NULL;
16768 352 : TALLOC_CTX *_mem_save_info_ctr_0 = NULL;
16769 352 : TALLOC_CTX *_mem_save_totalentries_0 = NULL;
16770 352 : TALLOC_CTX *_mem_save_resume_handle_0 = NULL;
16771 352 : NDR_PULL_CHECK_FN_FLAGS(ndr, flags);
16772 352 : if (flags & NDR_IN) {
16773 168 : NDR_ZERO_STRUCT(r->out);
16774 :
16775 168 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_server_unc));
16776 168 : if (_ptr_server_unc) {
16777 168 : NDR_PULL_ALLOC(ndr, r->in.server_unc);
16778 : } else {
16779 0 : r->in.server_unc = NULL;
16780 : }
16781 168 : if (r->in.server_unc) {
16782 168 : _mem_save_server_unc_0 = NDR_PULL_GET_MEM_CTX(ndr);
16783 168 : NDR_PULL_SET_MEM_CTX(ndr, r->in.server_unc, 0);
16784 168 : NDR_CHECK(ndr_pull_array_size(ndr, &r->in.server_unc));
16785 168 : NDR_CHECK(ndr_pull_array_length(ndr, &r->in.server_unc));
16786 168 : NDR_CHECK(ndr_steal_array_size(ndr, (void*)&r->in.server_unc, &size_server_unc_1));
16787 168 : NDR_CHECK(ndr_steal_array_length(ndr, (void*)&r->in.server_unc, &length_server_unc_1));
16788 168 : if (length_server_unc_1 > size_server_unc_1) {
16789 0 : return ndr_pull_error(ndr, NDR_ERR_ARRAY_SIZE, "Bad array size %"PRIu32": should exceed array length %"PRIu32"", size_server_unc_1, length_server_unc_1);
16790 : }
16791 168 : NDR_CHECK(ndr_check_string_terminator(ndr, length_server_unc_1, sizeof(uint16_t)));
16792 168 : NDR_CHECK(ndr_pull_charset(ndr, NDR_SCALARS, &r->in.server_unc, length_server_unc_1, sizeof(uint16_t), CH_UTF16));
16793 168 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_server_unc_0, 0);
16794 : }
16795 168 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
16796 168 : NDR_PULL_ALLOC(ndr, r->in.info_ctr);
16797 : }
16798 168 : _mem_save_info_ctr_0 = NDR_PULL_GET_MEM_CTX(ndr);
16799 168 : NDR_PULL_SET_MEM_CTX(ndr, r->in.info_ctr, LIBNDR_FLAG_REF_ALLOC);
16800 168 : NDR_CHECK(ndr_pull_srvsvc_NetShareInfoCtr(ndr, NDR_SCALARS|NDR_BUFFERS, r->in.info_ctr));
16801 168 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_info_ctr_0, LIBNDR_FLAG_REF_ALLOC);
16802 168 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->in.max_buffer));
16803 168 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_resume_handle));
16804 168 : if (_ptr_resume_handle) {
16805 156 : NDR_PULL_ALLOC(ndr, r->in.resume_handle);
16806 : } else {
16807 12 : r->in.resume_handle = NULL;
16808 : }
16809 168 : if (r->in.resume_handle) {
16810 156 : _mem_save_resume_handle_0 = NDR_PULL_GET_MEM_CTX(ndr);
16811 156 : NDR_PULL_SET_MEM_CTX(ndr, r->in.resume_handle, 0);
16812 156 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, r->in.resume_handle));
16813 156 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_resume_handle_0, 0);
16814 : }
16815 168 : NDR_PULL_ALLOC(ndr, r->out.info_ctr);
16816 168 : *r->out.info_ctr = *r->in.info_ctr;
16817 168 : NDR_PULL_ALLOC(ndr, r->out.totalentries);
16818 168 : NDR_ZERO_STRUCTP(r->out.totalentries);
16819 : }
16820 352 : if (flags & NDR_OUT) {
16821 : #ifdef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION
16822 : if (r->in.info_ctr == NULL) {
16823 : NDR_PULL_ALLOC(ndr, r->in.info_ctr);
16824 : NDR_ZERO_STRUCTP(r->in.info_ctr);
16825 : }
16826 : #endif /* FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION */
16827 184 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
16828 123 : NDR_PULL_ALLOC(ndr, r->out.info_ctr);
16829 : }
16830 184 : _mem_save_info_ctr_0 = NDR_PULL_GET_MEM_CTX(ndr);
16831 184 : NDR_PULL_SET_MEM_CTX(ndr, r->out.info_ctr, LIBNDR_FLAG_REF_ALLOC);
16832 184 : NDR_CHECK(ndr_pull_srvsvc_NetShareInfoCtr(ndr, NDR_SCALARS|NDR_BUFFERS, r->out.info_ctr));
16833 184 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_info_ctr_0, LIBNDR_FLAG_REF_ALLOC);
16834 184 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
16835 123 : NDR_PULL_ALLOC(ndr, r->out.totalentries);
16836 : }
16837 184 : _mem_save_totalentries_0 = NDR_PULL_GET_MEM_CTX(ndr);
16838 184 : NDR_PULL_SET_MEM_CTX(ndr, r->out.totalentries, LIBNDR_FLAG_REF_ALLOC);
16839 184 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, r->out.totalentries));
16840 184 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_totalentries_0, LIBNDR_FLAG_REF_ALLOC);
16841 184 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_resume_handle));
16842 184 : if (_ptr_resume_handle) {
16843 130 : NDR_PULL_ALLOC(ndr, r->out.resume_handle);
16844 : } else {
16845 54 : r->out.resume_handle = NULL;
16846 : }
16847 184 : if (r->out.resume_handle) {
16848 130 : _mem_save_resume_handle_0 = NDR_PULL_GET_MEM_CTX(ndr);
16849 130 : NDR_PULL_SET_MEM_CTX(ndr, r->out.resume_handle, 0);
16850 130 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, r->out.resume_handle));
16851 130 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_resume_handle_0, 0);
16852 : }
16853 184 : NDR_CHECK(ndr_pull_WERROR(ndr, NDR_SCALARS, &r->out.result));
16854 : }
16855 352 : return NDR_ERR_SUCCESS;
16856 : }
16857 :
16858 20 : _PUBLIC_ void ndr_print_srvsvc_NetShareEnumAll(struct ndr_print *ndr, const char *name, ndr_flags_type flags, const struct srvsvc_NetShareEnumAll *r)
16859 : {
16860 20 : ndr_print_struct(ndr, name, "srvsvc_NetShareEnumAll");
16861 20 : if (r == NULL) { ndr_print_null(ndr); return; }
16862 20 : ndr->depth++;
16863 20 : if (flags & NDR_SET_VALUES) {
16864 0 : ndr->flags |= LIBNDR_PRINT_SET_VALUES;
16865 : }
16866 20 : if (flags & NDR_IN) {
16867 0 : ndr_print_struct(ndr, "in", "srvsvc_NetShareEnumAll");
16868 0 : ndr->depth++;
16869 0 : ndr_print_ptr(ndr, "server_unc", r->in.server_unc);
16870 0 : ndr->depth++;
16871 0 : if (r->in.server_unc) {
16872 0 : ndr_print_string(ndr, "server_unc", r->in.server_unc);
16873 : }
16874 0 : ndr->depth--;
16875 0 : ndr_print_ptr(ndr, "info_ctr", r->in.info_ctr);
16876 0 : ndr->depth++;
16877 0 : ndr_print_srvsvc_NetShareInfoCtr(ndr, "info_ctr", r->in.info_ctr);
16878 0 : ndr->depth--;
16879 0 : ndr_print_uint32(ndr, "max_buffer", r->in.max_buffer);
16880 0 : ndr_print_ptr(ndr, "resume_handle", r->in.resume_handle);
16881 0 : ndr->depth++;
16882 0 : if (r->in.resume_handle) {
16883 0 : ndr_print_uint32(ndr, "resume_handle", *r->in.resume_handle);
16884 : }
16885 0 : ndr->depth--;
16886 0 : ndr->depth--;
16887 : }
16888 20 : if (flags & NDR_OUT) {
16889 20 : ndr_print_struct(ndr, "out", "srvsvc_NetShareEnumAll");
16890 20 : ndr->depth++;
16891 20 : ndr_print_ptr(ndr, "info_ctr", r->out.info_ctr);
16892 20 : ndr->depth++;
16893 20 : ndr_print_srvsvc_NetShareInfoCtr(ndr, "info_ctr", r->out.info_ctr);
16894 20 : ndr->depth--;
16895 20 : ndr_print_ptr(ndr, "totalentries", r->out.totalentries);
16896 20 : ndr->depth++;
16897 20 : ndr_print_uint32(ndr, "totalentries", *r->out.totalentries);
16898 20 : ndr->depth--;
16899 20 : ndr_print_ptr(ndr, "resume_handle", r->out.resume_handle);
16900 20 : ndr->depth++;
16901 20 : if (r->out.resume_handle) {
16902 0 : ndr_print_uint32(ndr, "resume_handle", *r->out.resume_handle);
16903 : }
16904 20 : ndr->depth--;
16905 20 : ndr_print_WERROR(ndr, "result", r->out.result);
16906 20 : ndr->depth--;
16907 : }
16908 20 : ndr->depth--;
16909 : }
16910 :
16911 2225 : static enum ndr_err_code ndr_push_srvsvc_NetShareGetInfo(struct ndr_push *ndr, ndr_flags_type flags, const struct srvsvc_NetShareGetInfo *r)
16912 : {
16913 2225 : NDR_PUSH_CHECK_FN_FLAGS(ndr, flags);
16914 2225 : if (flags & NDR_IN) {
16915 1680 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->in.server_unc));
16916 1680 : if (r->in.server_unc) {
16917 1680 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->in.server_unc, CH_UTF16)));
16918 1680 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, 0));
16919 1680 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->in.server_unc, CH_UTF16)));
16920 1680 : NDR_CHECK(ndr_push_charset(ndr, NDR_SCALARS, r->in.server_unc, ndr_charset_length(r->in.server_unc, CH_UTF16), sizeof(uint16_t), CH_UTF16));
16921 : }
16922 1680 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->in.share_name, CH_UTF16)));
16923 1680 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, 0));
16924 1680 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->in.share_name, CH_UTF16)));
16925 1680 : NDR_CHECK(ndr_push_charset(ndr, NDR_SCALARS, r->in.share_name, ndr_charset_length(r->in.share_name, CH_UTF16), sizeof(uint16_t), CH_UTF16));
16926 1680 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->in.level));
16927 : }
16928 2225 : if (flags & NDR_OUT) {
16929 545 : if (r->out.info == NULL) {
16930 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
16931 : }
16932 545 : NDR_CHECK(ndr_push_set_switch_value(ndr, r->out.info, r->in.level));
16933 545 : NDR_CHECK(ndr_push_srvsvc_NetShareInfo(ndr, NDR_SCALARS|NDR_BUFFERS, r->out.info));
16934 545 : NDR_CHECK(ndr_push_WERROR(ndr, NDR_SCALARS, r->out.result));
16935 : }
16936 2225 : return NDR_ERR_SUCCESS;
16937 : }
16938 :
16939 2135 : static enum ndr_err_code ndr_pull_srvsvc_NetShareGetInfo(struct ndr_pull *ndr, ndr_flags_type flags, struct srvsvc_NetShareGetInfo *r)
16940 : {
16941 0 : uint32_t _ptr_server_unc;
16942 2135 : uint32_t size_server_unc_1 = 0;
16943 2135 : uint32_t length_server_unc_1 = 0;
16944 2135 : uint32_t size_share_name_0 = 0;
16945 2135 : uint32_t length_share_name_0 = 0;
16946 2135 : TALLOC_CTX *_mem_save_server_unc_0 = NULL;
16947 2135 : TALLOC_CTX *_mem_save_info_0 = NULL;
16948 2135 : NDR_PULL_CHECK_FN_FLAGS(ndr, flags);
16949 2135 : if (flags & NDR_IN) {
16950 455 : NDR_ZERO_STRUCT(r->out);
16951 :
16952 455 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_server_unc));
16953 455 : if (_ptr_server_unc) {
16954 455 : NDR_PULL_ALLOC(ndr, r->in.server_unc);
16955 : } else {
16956 0 : r->in.server_unc = NULL;
16957 : }
16958 455 : if (r->in.server_unc) {
16959 455 : _mem_save_server_unc_0 = NDR_PULL_GET_MEM_CTX(ndr);
16960 455 : NDR_PULL_SET_MEM_CTX(ndr, r->in.server_unc, 0);
16961 455 : NDR_CHECK(ndr_pull_array_size(ndr, &r->in.server_unc));
16962 455 : NDR_CHECK(ndr_pull_array_length(ndr, &r->in.server_unc));
16963 455 : NDR_CHECK(ndr_steal_array_size(ndr, (void*)&r->in.server_unc, &size_server_unc_1));
16964 455 : NDR_CHECK(ndr_steal_array_length(ndr, (void*)&r->in.server_unc, &length_server_unc_1));
16965 455 : if (length_server_unc_1 > size_server_unc_1) {
16966 0 : return ndr_pull_error(ndr, NDR_ERR_ARRAY_SIZE, "Bad array size %"PRIu32": should exceed array length %"PRIu32"", size_server_unc_1, length_server_unc_1);
16967 : }
16968 455 : NDR_CHECK(ndr_check_string_terminator(ndr, length_server_unc_1, sizeof(uint16_t)));
16969 455 : NDR_CHECK(ndr_pull_charset(ndr, NDR_SCALARS, &r->in.server_unc, length_server_unc_1, sizeof(uint16_t), CH_UTF16));
16970 455 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_server_unc_0, 0);
16971 : }
16972 455 : NDR_CHECK(ndr_pull_array_size(ndr, &r->in.share_name));
16973 455 : NDR_CHECK(ndr_pull_array_length(ndr, &r->in.share_name));
16974 455 : NDR_CHECK(ndr_steal_array_size(ndr, (void*)&r->in.share_name, &size_share_name_0));
16975 455 : NDR_CHECK(ndr_steal_array_length(ndr, (void*)&r->in.share_name, &length_share_name_0));
16976 455 : if (length_share_name_0 > size_share_name_0) {
16977 0 : return ndr_pull_error(ndr, NDR_ERR_ARRAY_SIZE, "Bad array size %"PRIu32": should exceed array length %"PRIu32"", size_share_name_0, length_share_name_0);
16978 : }
16979 455 : NDR_CHECK(ndr_check_string_terminator(ndr, length_share_name_0, sizeof(uint16_t)));
16980 455 : NDR_CHECK(ndr_pull_charset(ndr, NDR_SCALARS, &r->in.share_name, length_share_name_0, sizeof(uint16_t), CH_UTF16));
16981 455 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->in.level));
16982 455 : NDR_PULL_ALLOC(ndr, r->out.info);
16983 455 : NDR_ZERO_STRUCTP(r->out.info);
16984 : }
16985 2135 : if (flags & NDR_OUT) {
16986 : #ifdef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION
16987 : #endif /* FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION */
16988 1680 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
16989 1330 : NDR_PULL_ALLOC(ndr, r->out.info);
16990 : }
16991 1680 : _mem_save_info_0 = NDR_PULL_GET_MEM_CTX(ndr);
16992 1680 : NDR_PULL_SET_MEM_CTX(ndr, r->out.info, LIBNDR_FLAG_REF_ALLOC);
16993 1680 : NDR_CHECK(ndr_pull_set_switch_value(ndr, r->out.info, r->in.level));
16994 1680 : NDR_CHECK(ndr_pull_srvsvc_NetShareInfo(ndr, NDR_SCALARS|NDR_BUFFERS, r->out.info));
16995 1680 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_info_0, LIBNDR_FLAG_REF_ALLOC);
16996 1680 : NDR_CHECK(ndr_pull_WERROR(ndr, NDR_SCALARS, &r->out.result));
16997 : }
16998 2135 : return NDR_ERR_SUCCESS;
16999 : }
17000 :
17001 180 : _PUBLIC_ void ndr_print_srvsvc_NetShareGetInfo(struct ndr_print *ndr, const char *name, ndr_flags_type flags, const struct srvsvc_NetShareGetInfo *r)
17002 : {
17003 180 : ndr_print_struct(ndr, name, "srvsvc_NetShareGetInfo");
17004 180 : if (r == NULL) { ndr_print_null(ndr); return; }
17005 180 : ndr->depth++;
17006 180 : if (flags & NDR_SET_VALUES) {
17007 0 : ndr->flags |= LIBNDR_PRINT_SET_VALUES;
17008 : }
17009 180 : if (flags & NDR_IN) {
17010 0 : ndr_print_struct(ndr, "in", "srvsvc_NetShareGetInfo");
17011 0 : ndr->depth++;
17012 0 : ndr_print_ptr(ndr, "server_unc", r->in.server_unc);
17013 0 : ndr->depth++;
17014 0 : if (r->in.server_unc) {
17015 0 : ndr_print_string(ndr, "server_unc", r->in.server_unc);
17016 : }
17017 0 : ndr->depth--;
17018 0 : ndr_print_string(ndr, "share_name", r->in.share_name);
17019 0 : ndr_print_uint32(ndr, "level", r->in.level);
17020 0 : ndr->depth--;
17021 : }
17022 180 : if (flags & NDR_OUT) {
17023 180 : ndr_print_struct(ndr, "out", "srvsvc_NetShareGetInfo");
17024 180 : ndr->depth++;
17025 180 : ndr_print_ptr(ndr, "info", r->out.info);
17026 180 : ndr->depth++;
17027 180 : ndr_print_set_switch_value(ndr, r->out.info, r->in.level);
17028 180 : ndr_print_srvsvc_NetShareInfo(ndr, "info", r->out.info);
17029 180 : ndr->depth--;
17030 180 : ndr_print_WERROR(ndr, "result", r->out.result);
17031 180 : ndr->depth--;
17032 : }
17033 180 : ndr->depth--;
17034 : }
17035 :
17036 59 : static enum ndr_err_code ndr_push_srvsvc_NetShareSetInfo(struct ndr_push *ndr, ndr_flags_type flags, const struct srvsvc_NetShareSetInfo *r)
17037 : {
17038 59 : NDR_PUSH_CHECK_FN_FLAGS(ndr, flags);
17039 59 : if (flags & NDR_IN) {
17040 33 : if (r->in.info == NULL) {
17041 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
17042 : }
17043 33 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->in.server_unc));
17044 33 : if (r->in.server_unc) {
17045 33 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->in.server_unc, CH_UTF16)));
17046 33 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, 0));
17047 33 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->in.server_unc, CH_UTF16)));
17048 33 : NDR_CHECK(ndr_push_charset(ndr, NDR_SCALARS, r->in.server_unc, ndr_charset_length(r->in.server_unc, CH_UTF16), sizeof(uint16_t), CH_UTF16));
17049 : }
17050 33 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->in.share_name, CH_UTF16)));
17051 33 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, 0));
17052 33 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->in.share_name, CH_UTF16)));
17053 33 : NDR_CHECK(ndr_push_charset(ndr, NDR_SCALARS, r->in.share_name, ndr_charset_length(r->in.share_name, CH_UTF16), sizeof(uint16_t), CH_UTF16));
17054 33 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->in.level));
17055 33 : NDR_CHECK(ndr_push_set_switch_value(ndr, r->in.info, r->in.level));
17056 33 : NDR_CHECK(ndr_push_srvsvc_NetShareInfo(ndr, NDR_SCALARS|NDR_BUFFERS, r->in.info));
17057 33 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->in.parm_error));
17058 33 : if (r->in.parm_error) {
17059 27 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, *r->in.parm_error));
17060 : }
17061 : }
17062 59 : if (flags & NDR_OUT) {
17063 26 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->out.parm_error));
17064 26 : if (r->out.parm_error) {
17065 26 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, *r->out.parm_error));
17066 : }
17067 26 : NDR_CHECK(ndr_push_WERROR(ndr, NDR_SCALARS, r->out.result));
17068 : }
17069 59 : return NDR_ERR_SUCCESS;
17070 : }
17071 :
17072 59 : static enum ndr_err_code ndr_pull_srvsvc_NetShareSetInfo(struct ndr_pull *ndr, ndr_flags_type flags, struct srvsvc_NetShareSetInfo *r)
17073 : {
17074 0 : uint32_t _ptr_server_unc;
17075 59 : uint32_t size_server_unc_1 = 0;
17076 59 : uint32_t length_server_unc_1 = 0;
17077 59 : uint32_t size_share_name_0 = 0;
17078 59 : uint32_t length_share_name_0 = 0;
17079 0 : uint32_t _ptr_parm_error;
17080 59 : TALLOC_CTX *_mem_save_server_unc_0 = NULL;
17081 59 : TALLOC_CTX *_mem_save_info_0 = NULL;
17082 59 : TALLOC_CTX *_mem_save_parm_error_0 = NULL;
17083 59 : NDR_PULL_CHECK_FN_FLAGS(ndr, flags);
17084 59 : if (flags & NDR_IN) {
17085 26 : NDR_ZERO_STRUCT(r->out);
17086 :
17087 26 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_server_unc));
17088 26 : if (_ptr_server_unc) {
17089 26 : NDR_PULL_ALLOC(ndr, r->in.server_unc);
17090 : } else {
17091 0 : r->in.server_unc = NULL;
17092 : }
17093 26 : if (r->in.server_unc) {
17094 26 : _mem_save_server_unc_0 = NDR_PULL_GET_MEM_CTX(ndr);
17095 26 : NDR_PULL_SET_MEM_CTX(ndr, r->in.server_unc, 0);
17096 26 : NDR_CHECK(ndr_pull_array_size(ndr, &r->in.server_unc));
17097 26 : NDR_CHECK(ndr_pull_array_length(ndr, &r->in.server_unc));
17098 26 : NDR_CHECK(ndr_steal_array_size(ndr, (void*)&r->in.server_unc, &size_server_unc_1));
17099 26 : NDR_CHECK(ndr_steal_array_length(ndr, (void*)&r->in.server_unc, &length_server_unc_1));
17100 26 : if (length_server_unc_1 > size_server_unc_1) {
17101 0 : return ndr_pull_error(ndr, NDR_ERR_ARRAY_SIZE, "Bad array size %"PRIu32": should exceed array length %"PRIu32"", size_server_unc_1, length_server_unc_1);
17102 : }
17103 26 : NDR_CHECK(ndr_check_string_terminator(ndr, length_server_unc_1, sizeof(uint16_t)));
17104 26 : NDR_CHECK(ndr_pull_charset(ndr, NDR_SCALARS, &r->in.server_unc, length_server_unc_1, sizeof(uint16_t), CH_UTF16));
17105 26 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_server_unc_0, 0);
17106 : }
17107 26 : NDR_CHECK(ndr_pull_array_size(ndr, &r->in.share_name));
17108 26 : NDR_CHECK(ndr_pull_array_length(ndr, &r->in.share_name));
17109 26 : NDR_CHECK(ndr_steal_array_size(ndr, (void*)&r->in.share_name, &size_share_name_0));
17110 26 : NDR_CHECK(ndr_steal_array_length(ndr, (void*)&r->in.share_name, &length_share_name_0));
17111 26 : if (length_share_name_0 > size_share_name_0) {
17112 0 : return ndr_pull_error(ndr, NDR_ERR_ARRAY_SIZE, "Bad array size %"PRIu32": should exceed array length %"PRIu32"", size_share_name_0, length_share_name_0);
17113 : }
17114 26 : NDR_CHECK(ndr_check_string_terminator(ndr, length_share_name_0, sizeof(uint16_t)));
17115 26 : NDR_CHECK(ndr_pull_charset(ndr, NDR_SCALARS, &r->in.share_name, length_share_name_0, sizeof(uint16_t), CH_UTF16));
17116 26 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->in.level));
17117 26 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
17118 26 : NDR_PULL_ALLOC(ndr, r->in.info);
17119 : }
17120 26 : _mem_save_info_0 = NDR_PULL_GET_MEM_CTX(ndr);
17121 26 : NDR_PULL_SET_MEM_CTX(ndr, r->in.info, LIBNDR_FLAG_REF_ALLOC);
17122 26 : NDR_CHECK(ndr_pull_set_switch_value(ndr, r->in.info, r->in.level));
17123 26 : NDR_CHECK(ndr_pull_srvsvc_NetShareInfo(ndr, NDR_SCALARS|NDR_BUFFERS, r->in.info));
17124 26 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_info_0, LIBNDR_FLAG_REF_ALLOC);
17125 26 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_parm_error));
17126 26 : if (_ptr_parm_error) {
17127 26 : NDR_PULL_ALLOC(ndr, r->in.parm_error);
17128 : } else {
17129 0 : r->in.parm_error = NULL;
17130 : }
17131 26 : if (r->in.parm_error) {
17132 26 : _mem_save_parm_error_0 = NDR_PULL_GET_MEM_CTX(ndr);
17133 26 : NDR_PULL_SET_MEM_CTX(ndr, r->in.parm_error, 0);
17134 26 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, r->in.parm_error));
17135 26 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_parm_error_0, 0);
17136 : }
17137 : }
17138 59 : if (flags & NDR_OUT) {
17139 : #ifdef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION
17140 : if (r->in.info == NULL) {
17141 : NDR_PULL_ALLOC(ndr, r->in.info);
17142 : NDR_ZERO_STRUCTP(r->in.info);
17143 : }
17144 : #endif /* FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION */
17145 33 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_parm_error));
17146 33 : if (_ptr_parm_error) {
17147 27 : NDR_PULL_ALLOC(ndr, r->out.parm_error);
17148 : } else {
17149 6 : r->out.parm_error = NULL;
17150 : }
17151 33 : if (r->out.parm_error) {
17152 27 : _mem_save_parm_error_0 = NDR_PULL_GET_MEM_CTX(ndr);
17153 27 : NDR_PULL_SET_MEM_CTX(ndr, r->out.parm_error, 0);
17154 27 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, r->out.parm_error));
17155 27 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_parm_error_0, 0);
17156 : }
17157 33 : NDR_CHECK(ndr_pull_WERROR(ndr, NDR_SCALARS, &r->out.result));
17158 : }
17159 59 : return NDR_ERR_SUCCESS;
17160 : }
17161 :
17162 0 : _PUBLIC_ void ndr_print_srvsvc_NetShareSetInfo(struct ndr_print *ndr, const char *name, ndr_flags_type flags, const struct srvsvc_NetShareSetInfo *r)
17163 : {
17164 0 : ndr_print_struct(ndr, name, "srvsvc_NetShareSetInfo");
17165 0 : if (r == NULL) { ndr_print_null(ndr); return; }
17166 0 : ndr->depth++;
17167 0 : if (flags & NDR_SET_VALUES) {
17168 0 : ndr->flags |= LIBNDR_PRINT_SET_VALUES;
17169 : }
17170 0 : if (flags & NDR_IN) {
17171 0 : ndr_print_struct(ndr, "in", "srvsvc_NetShareSetInfo");
17172 0 : ndr->depth++;
17173 0 : ndr_print_ptr(ndr, "server_unc", r->in.server_unc);
17174 0 : ndr->depth++;
17175 0 : if (r->in.server_unc) {
17176 0 : ndr_print_string(ndr, "server_unc", r->in.server_unc);
17177 : }
17178 0 : ndr->depth--;
17179 0 : ndr_print_string(ndr, "share_name", r->in.share_name);
17180 0 : ndr_print_uint32(ndr, "level", r->in.level);
17181 0 : ndr_print_ptr(ndr, "info", r->in.info);
17182 0 : ndr->depth++;
17183 0 : ndr_print_set_switch_value(ndr, r->in.info, r->in.level);
17184 0 : ndr_print_srvsvc_NetShareInfo(ndr, "info", r->in.info);
17185 0 : ndr->depth--;
17186 0 : ndr_print_ptr(ndr, "parm_error", r->in.parm_error);
17187 0 : ndr->depth++;
17188 0 : if (r->in.parm_error) {
17189 0 : ndr_print_uint32(ndr, "parm_error", *r->in.parm_error);
17190 : }
17191 0 : ndr->depth--;
17192 0 : ndr->depth--;
17193 : }
17194 0 : if (flags & NDR_OUT) {
17195 0 : ndr_print_struct(ndr, "out", "srvsvc_NetShareSetInfo");
17196 0 : ndr->depth++;
17197 0 : ndr_print_ptr(ndr, "parm_error", r->out.parm_error);
17198 0 : ndr->depth++;
17199 0 : if (r->out.parm_error) {
17200 0 : ndr_print_uint32(ndr, "parm_error", *r->out.parm_error);
17201 : }
17202 0 : ndr->depth--;
17203 0 : ndr_print_WERROR(ndr, "result", r->out.result);
17204 0 : ndr->depth--;
17205 : }
17206 0 : ndr->depth--;
17207 : }
17208 :
17209 7 : static enum ndr_err_code ndr_push_srvsvc_NetShareDel(struct ndr_push *ndr, ndr_flags_type flags, const struct srvsvc_NetShareDel *r)
17210 : {
17211 7 : NDR_PUSH_CHECK_FN_FLAGS(ndr, flags);
17212 7 : if (flags & NDR_IN) {
17213 4 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->in.server_unc));
17214 4 : if (r->in.server_unc) {
17215 4 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->in.server_unc, CH_UTF16)));
17216 4 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, 0));
17217 4 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->in.server_unc, CH_UTF16)));
17218 4 : NDR_CHECK(ndr_push_charset(ndr, NDR_SCALARS, r->in.server_unc, ndr_charset_length(r->in.server_unc, CH_UTF16), sizeof(uint16_t), CH_UTF16));
17219 : }
17220 4 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->in.share_name, CH_UTF16)));
17221 4 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, 0));
17222 4 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->in.share_name, CH_UTF16)));
17223 4 : NDR_CHECK(ndr_push_charset(ndr, NDR_SCALARS, r->in.share_name, ndr_charset_length(r->in.share_name, CH_UTF16), sizeof(uint16_t), CH_UTF16));
17224 4 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->in.reserved));
17225 : }
17226 7 : if (flags & NDR_OUT) {
17227 3 : NDR_CHECK(ndr_push_WERROR(ndr, NDR_SCALARS, r->out.result));
17228 : }
17229 7 : return NDR_ERR_SUCCESS;
17230 : }
17231 :
17232 7 : static enum ndr_err_code ndr_pull_srvsvc_NetShareDel(struct ndr_pull *ndr, ndr_flags_type flags, struct srvsvc_NetShareDel *r)
17233 : {
17234 0 : uint32_t _ptr_server_unc;
17235 7 : uint32_t size_server_unc_1 = 0;
17236 7 : uint32_t length_server_unc_1 = 0;
17237 7 : uint32_t size_share_name_0 = 0;
17238 7 : uint32_t length_share_name_0 = 0;
17239 7 : TALLOC_CTX *_mem_save_server_unc_0 = NULL;
17240 7 : NDR_PULL_CHECK_FN_FLAGS(ndr, flags);
17241 7 : if (flags & NDR_IN) {
17242 3 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_server_unc));
17243 3 : if (_ptr_server_unc) {
17244 3 : NDR_PULL_ALLOC(ndr, r->in.server_unc);
17245 : } else {
17246 0 : r->in.server_unc = NULL;
17247 : }
17248 3 : if (r->in.server_unc) {
17249 3 : _mem_save_server_unc_0 = NDR_PULL_GET_MEM_CTX(ndr);
17250 3 : NDR_PULL_SET_MEM_CTX(ndr, r->in.server_unc, 0);
17251 3 : NDR_CHECK(ndr_pull_array_size(ndr, &r->in.server_unc));
17252 3 : NDR_CHECK(ndr_pull_array_length(ndr, &r->in.server_unc));
17253 3 : NDR_CHECK(ndr_steal_array_size(ndr, (void*)&r->in.server_unc, &size_server_unc_1));
17254 3 : NDR_CHECK(ndr_steal_array_length(ndr, (void*)&r->in.server_unc, &length_server_unc_1));
17255 3 : if (length_server_unc_1 > size_server_unc_1) {
17256 0 : return ndr_pull_error(ndr, NDR_ERR_ARRAY_SIZE, "Bad array size %"PRIu32": should exceed array length %"PRIu32"", size_server_unc_1, length_server_unc_1);
17257 : }
17258 3 : NDR_CHECK(ndr_check_string_terminator(ndr, length_server_unc_1, sizeof(uint16_t)));
17259 3 : NDR_CHECK(ndr_pull_charset(ndr, NDR_SCALARS, &r->in.server_unc, length_server_unc_1, sizeof(uint16_t), CH_UTF16));
17260 3 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_server_unc_0, 0);
17261 : }
17262 3 : NDR_CHECK(ndr_pull_array_size(ndr, &r->in.share_name));
17263 3 : NDR_CHECK(ndr_pull_array_length(ndr, &r->in.share_name));
17264 3 : NDR_CHECK(ndr_steal_array_size(ndr, (void*)&r->in.share_name, &size_share_name_0));
17265 3 : NDR_CHECK(ndr_steal_array_length(ndr, (void*)&r->in.share_name, &length_share_name_0));
17266 3 : if (length_share_name_0 > size_share_name_0) {
17267 0 : return ndr_pull_error(ndr, NDR_ERR_ARRAY_SIZE, "Bad array size %"PRIu32": should exceed array length %"PRIu32"", size_share_name_0, length_share_name_0);
17268 : }
17269 3 : NDR_CHECK(ndr_check_string_terminator(ndr, length_share_name_0, sizeof(uint16_t)));
17270 3 : NDR_CHECK(ndr_pull_charset(ndr, NDR_SCALARS, &r->in.share_name, length_share_name_0, sizeof(uint16_t), CH_UTF16));
17271 3 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->in.reserved));
17272 : }
17273 7 : if (flags & NDR_OUT) {
17274 : #ifdef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION
17275 : #endif /* FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION */
17276 4 : NDR_CHECK(ndr_pull_WERROR(ndr, NDR_SCALARS, &r->out.result));
17277 : }
17278 7 : return NDR_ERR_SUCCESS;
17279 : }
17280 :
17281 0 : _PUBLIC_ void ndr_print_srvsvc_NetShareDel(struct ndr_print *ndr, const char *name, ndr_flags_type flags, const struct srvsvc_NetShareDel *r)
17282 : {
17283 0 : ndr_print_struct(ndr, name, "srvsvc_NetShareDel");
17284 0 : if (r == NULL) { ndr_print_null(ndr); return; }
17285 0 : ndr->depth++;
17286 0 : if (flags & NDR_SET_VALUES) {
17287 0 : ndr->flags |= LIBNDR_PRINT_SET_VALUES;
17288 : }
17289 0 : if (flags & NDR_IN) {
17290 0 : ndr_print_struct(ndr, "in", "srvsvc_NetShareDel");
17291 0 : ndr->depth++;
17292 0 : ndr_print_ptr(ndr, "server_unc", r->in.server_unc);
17293 0 : ndr->depth++;
17294 0 : if (r->in.server_unc) {
17295 0 : ndr_print_string(ndr, "server_unc", r->in.server_unc);
17296 : }
17297 0 : ndr->depth--;
17298 0 : ndr_print_string(ndr, "share_name", r->in.share_name);
17299 0 : ndr_print_uint32(ndr, "reserved", r->in.reserved);
17300 0 : ndr->depth--;
17301 : }
17302 0 : if (flags & NDR_OUT) {
17303 0 : ndr_print_struct(ndr, "out", "srvsvc_NetShareDel");
17304 0 : ndr->depth++;
17305 0 : ndr_print_WERROR(ndr, "result", r->out.result);
17306 0 : ndr->depth--;
17307 : }
17308 0 : ndr->depth--;
17309 : }
17310 :
17311 0 : static enum ndr_err_code ndr_push_srvsvc_NetShareDelSticky(struct ndr_push *ndr, ndr_flags_type flags, const struct srvsvc_NetShareDelSticky *r)
17312 : {
17313 0 : NDR_PUSH_CHECK_FN_FLAGS(ndr, flags);
17314 0 : if (flags & NDR_IN) {
17315 0 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->in.server_unc));
17316 0 : if (r->in.server_unc) {
17317 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->in.server_unc, CH_UTF16)));
17318 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, 0));
17319 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->in.server_unc, CH_UTF16)));
17320 0 : NDR_CHECK(ndr_push_charset(ndr, NDR_SCALARS, r->in.server_unc, ndr_charset_length(r->in.server_unc, CH_UTF16), sizeof(uint16_t), CH_UTF16));
17321 : }
17322 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->in.share_name, CH_UTF16)));
17323 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, 0));
17324 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->in.share_name, CH_UTF16)));
17325 0 : NDR_CHECK(ndr_push_charset(ndr, NDR_SCALARS, r->in.share_name, ndr_charset_length(r->in.share_name, CH_UTF16), sizeof(uint16_t), CH_UTF16));
17326 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->in.reserved));
17327 : }
17328 0 : if (flags & NDR_OUT) {
17329 0 : NDR_CHECK(ndr_push_WERROR(ndr, NDR_SCALARS, r->out.result));
17330 : }
17331 0 : return NDR_ERR_SUCCESS;
17332 : }
17333 :
17334 0 : static enum ndr_err_code ndr_pull_srvsvc_NetShareDelSticky(struct ndr_pull *ndr, ndr_flags_type flags, struct srvsvc_NetShareDelSticky *r)
17335 : {
17336 0 : uint32_t _ptr_server_unc;
17337 0 : uint32_t size_server_unc_1 = 0;
17338 0 : uint32_t length_server_unc_1 = 0;
17339 0 : uint32_t size_share_name_0 = 0;
17340 0 : uint32_t length_share_name_0 = 0;
17341 0 : TALLOC_CTX *_mem_save_server_unc_0 = NULL;
17342 0 : NDR_PULL_CHECK_FN_FLAGS(ndr, flags);
17343 0 : if (flags & NDR_IN) {
17344 0 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_server_unc));
17345 0 : if (_ptr_server_unc) {
17346 0 : NDR_PULL_ALLOC(ndr, r->in.server_unc);
17347 : } else {
17348 0 : r->in.server_unc = NULL;
17349 : }
17350 0 : if (r->in.server_unc) {
17351 0 : _mem_save_server_unc_0 = NDR_PULL_GET_MEM_CTX(ndr);
17352 0 : NDR_PULL_SET_MEM_CTX(ndr, r->in.server_unc, 0);
17353 0 : NDR_CHECK(ndr_pull_array_size(ndr, &r->in.server_unc));
17354 0 : NDR_CHECK(ndr_pull_array_length(ndr, &r->in.server_unc));
17355 0 : NDR_CHECK(ndr_steal_array_size(ndr, (void*)&r->in.server_unc, &size_server_unc_1));
17356 0 : NDR_CHECK(ndr_steal_array_length(ndr, (void*)&r->in.server_unc, &length_server_unc_1));
17357 0 : if (length_server_unc_1 > size_server_unc_1) {
17358 0 : return ndr_pull_error(ndr, NDR_ERR_ARRAY_SIZE, "Bad array size %"PRIu32": should exceed array length %"PRIu32"", size_server_unc_1, length_server_unc_1);
17359 : }
17360 0 : NDR_CHECK(ndr_check_string_terminator(ndr, length_server_unc_1, sizeof(uint16_t)));
17361 0 : NDR_CHECK(ndr_pull_charset(ndr, NDR_SCALARS, &r->in.server_unc, length_server_unc_1, sizeof(uint16_t), CH_UTF16));
17362 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_server_unc_0, 0);
17363 : }
17364 0 : NDR_CHECK(ndr_pull_array_size(ndr, &r->in.share_name));
17365 0 : NDR_CHECK(ndr_pull_array_length(ndr, &r->in.share_name));
17366 0 : NDR_CHECK(ndr_steal_array_size(ndr, (void*)&r->in.share_name, &size_share_name_0));
17367 0 : NDR_CHECK(ndr_steal_array_length(ndr, (void*)&r->in.share_name, &length_share_name_0));
17368 0 : if (length_share_name_0 > size_share_name_0) {
17369 0 : return ndr_pull_error(ndr, NDR_ERR_ARRAY_SIZE, "Bad array size %"PRIu32": should exceed array length %"PRIu32"", size_share_name_0, length_share_name_0);
17370 : }
17371 0 : NDR_CHECK(ndr_check_string_terminator(ndr, length_share_name_0, sizeof(uint16_t)));
17372 0 : NDR_CHECK(ndr_pull_charset(ndr, NDR_SCALARS, &r->in.share_name, length_share_name_0, sizeof(uint16_t), CH_UTF16));
17373 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->in.reserved));
17374 : }
17375 0 : if (flags & NDR_OUT) {
17376 : #ifdef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION
17377 : #endif /* FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION */
17378 0 : NDR_CHECK(ndr_pull_WERROR(ndr, NDR_SCALARS, &r->out.result));
17379 : }
17380 0 : return NDR_ERR_SUCCESS;
17381 : }
17382 :
17383 0 : _PUBLIC_ void ndr_print_srvsvc_NetShareDelSticky(struct ndr_print *ndr, const char *name, ndr_flags_type flags, const struct srvsvc_NetShareDelSticky *r)
17384 : {
17385 0 : ndr_print_struct(ndr, name, "srvsvc_NetShareDelSticky");
17386 0 : if (r == NULL) { ndr_print_null(ndr); return; }
17387 0 : ndr->depth++;
17388 0 : if (flags & NDR_SET_VALUES) {
17389 0 : ndr->flags |= LIBNDR_PRINT_SET_VALUES;
17390 : }
17391 0 : if (flags & NDR_IN) {
17392 0 : ndr_print_struct(ndr, "in", "srvsvc_NetShareDelSticky");
17393 0 : ndr->depth++;
17394 0 : ndr_print_ptr(ndr, "server_unc", r->in.server_unc);
17395 0 : ndr->depth++;
17396 0 : if (r->in.server_unc) {
17397 0 : ndr_print_string(ndr, "server_unc", r->in.server_unc);
17398 : }
17399 0 : ndr->depth--;
17400 0 : ndr_print_string(ndr, "share_name", r->in.share_name);
17401 0 : ndr_print_uint32(ndr, "reserved", r->in.reserved);
17402 0 : ndr->depth--;
17403 : }
17404 0 : if (flags & NDR_OUT) {
17405 0 : ndr_print_struct(ndr, "out", "srvsvc_NetShareDelSticky");
17406 0 : ndr->depth++;
17407 0 : ndr_print_WERROR(ndr, "result", r->out.result);
17408 0 : ndr->depth--;
17409 : }
17410 0 : ndr->depth--;
17411 : }
17412 :
17413 134 : static enum ndr_err_code ndr_push_srvsvc_NetShareCheck(struct ndr_push *ndr, ndr_flags_type flags, const struct srvsvc_NetShareCheck *r)
17414 : {
17415 134 : NDR_PUSH_CHECK_FN_FLAGS(ndr, flags);
17416 134 : if (flags & NDR_IN) {
17417 64 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->in.server_unc));
17418 64 : if (r->in.server_unc) {
17419 64 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->in.server_unc, CH_UTF16)));
17420 64 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, 0));
17421 64 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->in.server_unc, CH_UTF16)));
17422 64 : NDR_CHECK(ndr_push_charset(ndr, NDR_SCALARS, r->in.server_unc, ndr_charset_length(r->in.server_unc, CH_UTF16), sizeof(uint16_t), CH_UTF16));
17423 : }
17424 64 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->in.device_name, CH_UTF16)));
17425 64 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, 0));
17426 64 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->in.device_name, CH_UTF16)));
17427 64 : NDR_CHECK(ndr_push_charset(ndr, NDR_SCALARS, r->in.device_name, ndr_charset_length(r->in.device_name, CH_UTF16), sizeof(uint16_t), CH_UTF16));
17428 : }
17429 134 : if (flags & NDR_OUT) {
17430 70 : if (r->out.type == NULL) {
17431 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
17432 : }
17433 70 : NDR_CHECK(ndr_push_srvsvc_ShareType(ndr, NDR_SCALARS, *r->out.type));
17434 70 : NDR_CHECK(ndr_push_WERROR(ndr, NDR_SCALARS, r->out.result));
17435 : }
17436 134 : return NDR_ERR_SUCCESS;
17437 : }
17438 :
17439 120 : static enum ndr_err_code ndr_pull_srvsvc_NetShareCheck(struct ndr_pull *ndr, ndr_flags_type flags, struct srvsvc_NetShareCheck *r)
17440 : {
17441 0 : uint32_t _ptr_server_unc;
17442 120 : uint32_t size_server_unc_1 = 0;
17443 120 : uint32_t length_server_unc_1 = 0;
17444 120 : uint32_t size_device_name_0 = 0;
17445 120 : uint32_t length_device_name_0 = 0;
17446 120 : TALLOC_CTX *_mem_save_server_unc_0 = NULL;
17447 120 : TALLOC_CTX *_mem_save_type_0 = NULL;
17448 120 : NDR_PULL_CHECK_FN_FLAGS(ndr, flags);
17449 120 : if (flags & NDR_IN) {
17450 64 : NDR_ZERO_STRUCT(r->out);
17451 :
17452 64 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_server_unc));
17453 64 : if (_ptr_server_unc) {
17454 64 : NDR_PULL_ALLOC(ndr, r->in.server_unc);
17455 : } else {
17456 0 : r->in.server_unc = NULL;
17457 : }
17458 64 : if (r->in.server_unc) {
17459 64 : _mem_save_server_unc_0 = NDR_PULL_GET_MEM_CTX(ndr);
17460 64 : NDR_PULL_SET_MEM_CTX(ndr, r->in.server_unc, 0);
17461 64 : NDR_CHECK(ndr_pull_array_size(ndr, &r->in.server_unc));
17462 64 : NDR_CHECK(ndr_pull_array_length(ndr, &r->in.server_unc));
17463 64 : NDR_CHECK(ndr_steal_array_size(ndr, (void*)&r->in.server_unc, &size_server_unc_1));
17464 64 : NDR_CHECK(ndr_steal_array_length(ndr, (void*)&r->in.server_unc, &length_server_unc_1));
17465 64 : if (length_server_unc_1 > size_server_unc_1) {
17466 0 : return ndr_pull_error(ndr, NDR_ERR_ARRAY_SIZE, "Bad array size %"PRIu32": should exceed array length %"PRIu32"", size_server_unc_1, length_server_unc_1);
17467 : }
17468 64 : NDR_CHECK(ndr_check_string_terminator(ndr, length_server_unc_1, sizeof(uint16_t)));
17469 64 : NDR_CHECK(ndr_pull_charset(ndr, NDR_SCALARS, &r->in.server_unc, length_server_unc_1, sizeof(uint16_t), CH_UTF16));
17470 64 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_server_unc_0, 0);
17471 : }
17472 64 : NDR_CHECK(ndr_pull_array_size(ndr, &r->in.device_name));
17473 64 : NDR_CHECK(ndr_pull_array_length(ndr, &r->in.device_name));
17474 64 : NDR_CHECK(ndr_steal_array_size(ndr, (void*)&r->in.device_name, &size_device_name_0));
17475 64 : NDR_CHECK(ndr_steal_array_length(ndr, (void*)&r->in.device_name, &length_device_name_0));
17476 64 : if (length_device_name_0 > size_device_name_0) {
17477 0 : return ndr_pull_error(ndr, NDR_ERR_ARRAY_SIZE, "Bad array size %"PRIu32": should exceed array length %"PRIu32"", size_device_name_0, length_device_name_0);
17478 : }
17479 64 : NDR_CHECK(ndr_check_string_terminator(ndr, length_device_name_0, sizeof(uint16_t)));
17480 64 : NDR_CHECK(ndr_pull_charset(ndr, NDR_SCALARS, &r->in.device_name, length_device_name_0, sizeof(uint16_t), CH_UTF16));
17481 64 : NDR_PULL_ALLOC(ndr, r->out.type);
17482 64 : NDR_ZERO_STRUCTP(r->out.type);
17483 : }
17484 120 : if (flags & NDR_OUT) {
17485 : #ifdef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION
17486 : #endif /* FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION */
17487 56 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
17488 14 : NDR_PULL_ALLOC(ndr, r->out.type);
17489 : }
17490 56 : _mem_save_type_0 = NDR_PULL_GET_MEM_CTX(ndr);
17491 56 : NDR_PULL_SET_MEM_CTX(ndr, r->out.type, LIBNDR_FLAG_REF_ALLOC);
17492 56 : NDR_CHECK(ndr_pull_srvsvc_ShareType(ndr, NDR_SCALARS, r->out.type));
17493 56 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_type_0, LIBNDR_FLAG_REF_ALLOC);
17494 56 : NDR_CHECK(ndr_pull_WERROR(ndr, NDR_SCALARS, &r->out.result));
17495 : }
17496 120 : return NDR_ERR_SUCCESS;
17497 : }
17498 :
17499 28 : _PUBLIC_ void ndr_print_srvsvc_NetShareCheck(struct ndr_print *ndr, const char *name, ndr_flags_type flags, const struct srvsvc_NetShareCheck *r)
17500 : {
17501 28 : ndr_print_struct(ndr, name, "srvsvc_NetShareCheck");
17502 28 : if (r == NULL) { ndr_print_null(ndr); return; }
17503 28 : ndr->depth++;
17504 28 : if (flags & NDR_SET_VALUES) {
17505 0 : ndr->flags |= LIBNDR_PRINT_SET_VALUES;
17506 : }
17507 28 : if (flags & NDR_IN) {
17508 0 : ndr_print_struct(ndr, "in", "srvsvc_NetShareCheck");
17509 0 : ndr->depth++;
17510 0 : ndr_print_ptr(ndr, "server_unc", r->in.server_unc);
17511 0 : ndr->depth++;
17512 0 : if (r->in.server_unc) {
17513 0 : ndr_print_string(ndr, "server_unc", r->in.server_unc);
17514 : }
17515 0 : ndr->depth--;
17516 0 : ndr_print_string(ndr, "device_name", r->in.device_name);
17517 0 : ndr->depth--;
17518 : }
17519 28 : if (flags & NDR_OUT) {
17520 28 : ndr_print_struct(ndr, "out", "srvsvc_NetShareCheck");
17521 28 : ndr->depth++;
17522 28 : ndr_print_ptr(ndr, "type", r->out.type);
17523 28 : ndr->depth++;
17524 28 : ndr_print_srvsvc_ShareType(ndr, "type", *r->out.type);
17525 28 : ndr->depth--;
17526 28 : ndr_print_WERROR(ndr, "result", r->out.result);
17527 28 : ndr->depth--;
17528 : }
17529 28 : ndr->depth--;
17530 : }
17531 :
17532 143 : static enum ndr_err_code ndr_push_srvsvc_NetSrvGetInfo(struct ndr_push *ndr, ndr_flags_type flags, const struct srvsvc_NetSrvGetInfo *r)
17533 : {
17534 143 : NDR_PUSH_CHECK_FN_FLAGS(ndr, flags);
17535 143 : if (flags & NDR_IN) {
17536 69 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->in.server_unc));
17537 69 : if (r->in.server_unc) {
17538 41 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->in.server_unc, CH_UTF16)));
17539 41 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, 0));
17540 41 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->in.server_unc, CH_UTF16)));
17541 41 : NDR_CHECK(ndr_push_charset(ndr, NDR_SCALARS, r->in.server_unc, ndr_charset_length(r->in.server_unc, CH_UTF16), sizeof(uint16_t), CH_UTF16));
17542 : }
17543 69 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->in.level));
17544 : }
17545 143 : if (flags & NDR_OUT) {
17546 74 : if (r->out.info == NULL) {
17547 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
17548 : }
17549 74 : NDR_CHECK(ndr_push_set_switch_value(ndr, r->out.info, r->in.level));
17550 74 : NDR_CHECK(ndr_push_srvsvc_NetSrvInfo(ndr, NDR_SCALARS|NDR_BUFFERS, r->out.info));
17551 74 : NDR_CHECK(ndr_push_WERROR(ndr, NDR_SCALARS, r->out.result));
17552 : }
17553 143 : return NDR_ERR_SUCCESS;
17554 : }
17555 :
17556 138 : static enum ndr_err_code ndr_pull_srvsvc_NetSrvGetInfo(struct ndr_pull *ndr, ndr_flags_type flags, struct srvsvc_NetSrvGetInfo *r)
17557 : {
17558 0 : uint32_t _ptr_server_unc;
17559 138 : uint32_t size_server_unc_1 = 0;
17560 138 : uint32_t length_server_unc_1 = 0;
17561 138 : TALLOC_CTX *_mem_save_server_unc_0 = NULL;
17562 138 : TALLOC_CTX *_mem_save_info_0 = NULL;
17563 138 : NDR_PULL_CHECK_FN_FLAGS(ndr, flags);
17564 138 : if (flags & NDR_IN) {
17565 69 : NDR_ZERO_STRUCT(r->out);
17566 :
17567 69 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_server_unc));
17568 69 : if (_ptr_server_unc) {
17569 41 : NDR_PULL_ALLOC(ndr, r->in.server_unc);
17570 : } else {
17571 28 : r->in.server_unc = NULL;
17572 : }
17573 69 : if (r->in.server_unc) {
17574 41 : _mem_save_server_unc_0 = NDR_PULL_GET_MEM_CTX(ndr);
17575 41 : NDR_PULL_SET_MEM_CTX(ndr, r->in.server_unc, 0);
17576 41 : NDR_CHECK(ndr_pull_array_size(ndr, &r->in.server_unc));
17577 41 : NDR_CHECK(ndr_pull_array_length(ndr, &r->in.server_unc));
17578 41 : NDR_CHECK(ndr_steal_array_size(ndr, (void*)&r->in.server_unc, &size_server_unc_1));
17579 41 : NDR_CHECK(ndr_steal_array_length(ndr, (void*)&r->in.server_unc, &length_server_unc_1));
17580 41 : if (length_server_unc_1 > size_server_unc_1) {
17581 0 : return ndr_pull_error(ndr, NDR_ERR_ARRAY_SIZE, "Bad array size %"PRIu32": should exceed array length %"PRIu32"", size_server_unc_1, length_server_unc_1);
17582 : }
17583 41 : NDR_CHECK(ndr_check_string_terminator(ndr, length_server_unc_1, sizeof(uint16_t)));
17584 41 : NDR_CHECK(ndr_pull_charset(ndr, NDR_SCALARS, &r->in.server_unc, length_server_unc_1, sizeof(uint16_t), CH_UTF16));
17585 41 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_server_unc_0, 0);
17586 : }
17587 69 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->in.level));
17588 69 : NDR_PULL_ALLOC(ndr, r->out.info);
17589 69 : NDR_ZERO_STRUCTP(r->out.info);
17590 : }
17591 138 : if (flags & NDR_OUT) {
17592 : #ifdef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION
17593 : #endif /* FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION */
17594 69 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
17595 30 : NDR_PULL_ALLOC(ndr, r->out.info);
17596 : }
17597 69 : _mem_save_info_0 = NDR_PULL_GET_MEM_CTX(ndr);
17598 69 : NDR_PULL_SET_MEM_CTX(ndr, r->out.info, LIBNDR_FLAG_REF_ALLOC);
17599 69 : NDR_CHECK(ndr_pull_set_switch_value(ndr, r->out.info, r->in.level));
17600 69 : NDR_CHECK(ndr_pull_srvsvc_NetSrvInfo(ndr, NDR_SCALARS|NDR_BUFFERS, r->out.info));
17601 69 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_info_0, LIBNDR_FLAG_REF_ALLOC);
17602 69 : NDR_CHECK(ndr_pull_WERROR(ndr, NDR_SCALARS, &r->out.result));
17603 : }
17604 138 : return NDR_ERR_SUCCESS;
17605 : }
17606 :
17607 10 : _PUBLIC_ void ndr_print_srvsvc_NetSrvGetInfo(struct ndr_print *ndr, const char *name, ndr_flags_type flags, const struct srvsvc_NetSrvGetInfo *r)
17608 : {
17609 10 : ndr_print_struct(ndr, name, "srvsvc_NetSrvGetInfo");
17610 10 : if (r == NULL) { ndr_print_null(ndr); return; }
17611 10 : ndr->depth++;
17612 10 : if (flags & NDR_SET_VALUES) {
17613 0 : ndr->flags |= LIBNDR_PRINT_SET_VALUES;
17614 : }
17615 10 : if (flags & NDR_IN) {
17616 0 : ndr_print_struct(ndr, "in", "srvsvc_NetSrvGetInfo");
17617 0 : ndr->depth++;
17618 0 : ndr_print_ptr(ndr, "server_unc", r->in.server_unc);
17619 0 : ndr->depth++;
17620 0 : if (r->in.server_unc) {
17621 0 : ndr_print_string(ndr, "server_unc", r->in.server_unc);
17622 : }
17623 0 : ndr->depth--;
17624 0 : ndr_print_uint32(ndr, "level", r->in.level);
17625 0 : ndr->depth--;
17626 : }
17627 10 : if (flags & NDR_OUT) {
17628 10 : ndr_print_struct(ndr, "out", "srvsvc_NetSrvGetInfo");
17629 10 : ndr->depth++;
17630 10 : ndr_print_ptr(ndr, "info", r->out.info);
17631 10 : ndr->depth++;
17632 10 : ndr_print_set_switch_value(ndr, r->out.info, r->in.level);
17633 10 : ndr_print_srvsvc_NetSrvInfo(ndr, "info", r->out.info);
17634 10 : ndr->depth--;
17635 10 : ndr_print_WERROR(ndr, "result", r->out.result);
17636 10 : ndr->depth--;
17637 : }
17638 10 : ndr->depth--;
17639 : }
17640 :
17641 0 : static enum ndr_err_code ndr_push_srvsvc_NetSrvSetInfo(struct ndr_push *ndr, ndr_flags_type flags, const struct srvsvc_NetSrvSetInfo *r)
17642 : {
17643 0 : NDR_PUSH_CHECK_FN_FLAGS(ndr, flags);
17644 0 : if (flags & NDR_IN) {
17645 0 : if (r->in.info == NULL) {
17646 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
17647 : }
17648 0 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->in.server_unc));
17649 0 : if (r->in.server_unc) {
17650 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->in.server_unc, CH_UTF16)));
17651 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, 0));
17652 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->in.server_unc, CH_UTF16)));
17653 0 : NDR_CHECK(ndr_push_charset(ndr, NDR_SCALARS, r->in.server_unc, ndr_charset_length(r->in.server_unc, CH_UTF16), sizeof(uint16_t), CH_UTF16));
17654 : }
17655 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->in.level));
17656 0 : NDR_CHECK(ndr_push_set_switch_value(ndr, r->in.info, r->in.level));
17657 0 : NDR_CHECK(ndr_push_srvsvc_NetSrvInfo(ndr, NDR_SCALARS|NDR_BUFFERS, r->in.info));
17658 0 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->in.parm_error));
17659 0 : if (r->in.parm_error) {
17660 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, *r->in.parm_error));
17661 : }
17662 : }
17663 0 : if (flags & NDR_OUT) {
17664 0 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->out.parm_error));
17665 0 : if (r->out.parm_error) {
17666 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, *r->out.parm_error));
17667 : }
17668 0 : NDR_CHECK(ndr_push_WERROR(ndr, NDR_SCALARS, r->out.result));
17669 : }
17670 0 : return NDR_ERR_SUCCESS;
17671 : }
17672 :
17673 0 : static enum ndr_err_code ndr_pull_srvsvc_NetSrvSetInfo(struct ndr_pull *ndr, ndr_flags_type flags, struct srvsvc_NetSrvSetInfo *r)
17674 : {
17675 0 : uint32_t _ptr_server_unc;
17676 0 : uint32_t size_server_unc_1 = 0;
17677 0 : uint32_t length_server_unc_1 = 0;
17678 0 : uint32_t _ptr_parm_error;
17679 0 : TALLOC_CTX *_mem_save_server_unc_0 = NULL;
17680 0 : TALLOC_CTX *_mem_save_info_0 = NULL;
17681 0 : TALLOC_CTX *_mem_save_parm_error_0 = NULL;
17682 0 : NDR_PULL_CHECK_FN_FLAGS(ndr, flags);
17683 0 : if (flags & NDR_IN) {
17684 0 : NDR_ZERO_STRUCT(r->out);
17685 :
17686 0 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_server_unc));
17687 0 : if (_ptr_server_unc) {
17688 0 : NDR_PULL_ALLOC(ndr, r->in.server_unc);
17689 : } else {
17690 0 : r->in.server_unc = NULL;
17691 : }
17692 0 : if (r->in.server_unc) {
17693 0 : _mem_save_server_unc_0 = NDR_PULL_GET_MEM_CTX(ndr);
17694 0 : NDR_PULL_SET_MEM_CTX(ndr, r->in.server_unc, 0);
17695 0 : NDR_CHECK(ndr_pull_array_size(ndr, &r->in.server_unc));
17696 0 : NDR_CHECK(ndr_pull_array_length(ndr, &r->in.server_unc));
17697 0 : NDR_CHECK(ndr_steal_array_size(ndr, (void*)&r->in.server_unc, &size_server_unc_1));
17698 0 : NDR_CHECK(ndr_steal_array_length(ndr, (void*)&r->in.server_unc, &length_server_unc_1));
17699 0 : if (length_server_unc_1 > size_server_unc_1) {
17700 0 : return ndr_pull_error(ndr, NDR_ERR_ARRAY_SIZE, "Bad array size %"PRIu32": should exceed array length %"PRIu32"", size_server_unc_1, length_server_unc_1);
17701 : }
17702 0 : NDR_CHECK(ndr_check_string_terminator(ndr, length_server_unc_1, sizeof(uint16_t)));
17703 0 : NDR_CHECK(ndr_pull_charset(ndr, NDR_SCALARS, &r->in.server_unc, length_server_unc_1, sizeof(uint16_t), CH_UTF16));
17704 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_server_unc_0, 0);
17705 : }
17706 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->in.level));
17707 0 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
17708 0 : NDR_PULL_ALLOC(ndr, r->in.info);
17709 : }
17710 0 : _mem_save_info_0 = NDR_PULL_GET_MEM_CTX(ndr);
17711 0 : NDR_PULL_SET_MEM_CTX(ndr, r->in.info, LIBNDR_FLAG_REF_ALLOC);
17712 0 : NDR_CHECK(ndr_pull_set_switch_value(ndr, r->in.info, r->in.level));
17713 0 : NDR_CHECK(ndr_pull_srvsvc_NetSrvInfo(ndr, NDR_SCALARS|NDR_BUFFERS, r->in.info));
17714 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_info_0, LIBNDR_FLAG_REF_ALLOC);
17715 0 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_parm_error));
17716 0 : if (_ptr_parm_error) {
17717 0 : NDR_PULL_ALLOC(ndr, r->in.parm_error);
17718 : } else {
17719 0 : r->in.parm_error = NULL;
17720 : }
17721 0 : if (r->in.parm_error) {
17722 0 : _mem_save_parm_error_0 = NDR_PULL_GET_MEM_CTX(ndr);
17723 0 : NDR_PULL_SET_MEM_CTX(ndr, r->in.parm_error, 0);
17724 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, r->in.parm_error));
17725 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_parm_error_0, 0);
17726 : }
17727 : }
17728 0 : if (flags & NDR_OUT) {
17729 : #ifdef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION
17730 : if (r->in.info == NULL) {
17731 : NDR_PULL_ALLOC(ndr, r->in.info);
17732 : NDR_ZERO_STRUCTP(r->in.info);
17733 : }
17734 : #endif /* FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION */
17735 0 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_parm_error));
17736 0 : if (_ptr_parm_error) {
17737 0 : NDR_PULL_ALLOC(ndr, r->out.parm_error);
17738 : } else {
17739 0 : r->out.parm_error = NULL;
17740 : }
17741 0 : if (r->out.parm_error) {
17742 0 : _mem_save_parm_error_0 = NDR_PULL_GET_MEM_CTX(ndr);
17743 0 : NDR_PULL_SET_MEM_CTX(ndr, r->out.parm_error, 0);
17744 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, r->out.parm_error));
17745 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_parm_error_0, 0);
17746 : }
17747 0 : NDR_CHECK(ndr_pull_WERROR(ndr, NDR_SCALARS, &r->out.result));
17748 : }
17749 0 : return NDR_ERR_SUCCESS;
17750 : }
17751 :
17752 0 : _PUBLIC_ void ndr_print_srvsvc_NetSrvSetInfo(struct ndr_print *ndr, const char *name, ndr_flags_type flags, const struct srvsvc_NetSrvSetInfo *r)
17753 : {
17754 0 : ndr_print_struct(ndr, name, "srvsvc_NetSrvSetInfo");
17755 0 : if (r == NULL) { ndr_print_null(ndr); return; }
17756 0 : ndr->depth++;
17757 0 : if (flags & NDR_SET_VALUES) {
17758 0 : ndr->flags |= LIBNDR_PRINT_SET_VALUES;
17759 : }
17760 0 : if (flags & NDR_IN) {
17761 0 : ndr_print_struct(ndr, "in", "srvsvc_NetSrvSetInfo");
17762 0 : ndr->depth++;
17763 0 : ndr_print_ptr(ndr, "server_unc", r->in.server_unc);
17764 0 : ndr->depth++;
17765 0 : if (r->in.server_unc) {
17766 0 : ndr_print_string(ndr, "server_unc", r->in.server_unc);
17767 : }
17768 0 : ndr->depth--;
17769 0 : ndr_print_uint32(ndr, "level", r->in.level);
17770 0 : ndr_print_ptr(ndr, "info", r->in.info);
17771 0 : ndr->depth++;
17772 0 : ndr_print_set_switch_value(ndr, r->in.info, r->in.level);
17773 0 : ndr_print_srvsvc_NetSrvInfo(ndr, "info", r->in.info);
17774 0 : ndr->depth--;
17775 0 : ndr_print_ptr(ndr, "parm_error", r->in.parm_error);
17776 0 : ndr->depth++;
17777 0 : if (r->in.parm_error) {
17778 0 : ndr_print_uint32(ndr, "parm_error", *r->in.parm_error);
17779 : }
17780 0 : ndr->depth--;
17781 0 : ndr->depth--;
17782 : }
17783 0 : if (flags & NDR_OUT) {
17784 0 : ndr_print_struct(ndr, "out", "srvsvc_NetSrvSetInfo");
17785 0 : ndr->depth++;
17786 0 : ndr_print_ptr(ndr, "parm_error", r->out.parm_error);
17787 0 : ndr->depth++;
17788 0 : if (r->out.parm_error) {
17789 0 : ndr_print_uint32(ndr, "parm_error", *r->out.parm_error);
17790 : }
17791 0 : ndr->depth--;
17792 0 : ndr_print_WERROR(ndr, "result", r->out.result);
17793 0 : ndr->depth--;
17794 : }
17795 0 : ndr->depth--;
17796 : }
17797 :
17798 17 : static enum ndr_err_code ndr_push_srvsvc_NetDiskEnum(struct ndr_push *ndr, ndr_flags_type flags, const struct srvsvc_NetDiskEnum *r)
17799 : {
17800 17 : NDR_PUSH_CHECK_FN_FLAGS(ndr, flags);
17801 17 : if (flags & NDR_IN) {
17802 8 : if (r->in.info == NULL) {
17803 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
17804 : }
17805 8 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->in.server_unc));
17806 8 : if (r->in.server_unc) {
17807 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->in.server_unc, CH_UTF16)));
17808 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, 0));
17809 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->in.server_unc, CH_UTF16)));
17810 0 : NDR_CHECK(ndr_push_charset(ndr, NDR_SCALARS, r->in.server_unc, ndr_charset_length(r->in.server_unc, CH_UTF16), sizeof(uint16_t), CH_UTF16));
17811 : }
17812 8 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->in.level));
17813 8 : NDR_CHECK(ndr_push_srvsvc_NetDiskInfo(ndr, NDR_SCALARS|NDR_BUFFERS, r->in.info));
17814 8 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->in.maxlen));
17815 8 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->in.resume_handle));
17816 8 : if (r->in.resume_handle) {
17817 8 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, *r->in.resume_handle));
17818 : }
17819 : }
17820 17 : if (flags & NDR_OUT) {
17821 9 : if (r->out.info == NULL) {
17822 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
17823 : }
17824 9 : if (r->out.totalentries == NULL) {
17825 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
17826 : }
17827 9 : NDR_CHECK(ndr_push_srvsvc_NetDiskInfo(ndr, NDR_SCALARS|NDR_BUFFERS, r->out.info));
17828 9 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, *r->out.totalentries));
17829 9 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->out.resume_handle));
17830 9 : if (r->out.resume_handle) {
17831 9 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, *r->out.resume_handle));
17832 : }
17833 9 : NDR_CHECK(ndr_push_WERROR(ndr, NDR_SCALARS, r->out.result));
17834 : }
17835 17 : return NDR_ERR_SUCCESS;
17836 : }
17837 :
17838 16 : static enum ndr_err_code ndr_pull_srvsvc_NetDiskEnum(struct ndr_pull *ndr, ndr_flags_type flags, struct srvsvc_NetDiskEnum *r)
17839 : {
17840 0 : uint32_t _ptr_server_unc;
17841 16 : uint32_t size_server_unc_1 = 0;
17842 16 : uint32_t length_server_unc_1 = 0;
17843 0 : uint32_t _ptr_resume_handle;
17844 16 : TALLOC_CTX *_mem_save_server_unc_0 = NULL;
17845 16 : TALLOC_CTX *_mem_save_info_0 = NULL;
17846 16 : TALLOC_CTX *_mem_save_totalentries_0 = NULL;
17847 16 : TALLOC_CTX *_mem_save_resume_handle_0 = NULL;
17848 16 : NDR_PULL_CHECK_FN_FLAGS(ndr, flags);
17849 16 : if (flags & NDR_IN) {
17850 8 : NDR_ZERO_STRUCT(r->out);
17851 :
17852 8 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_server_unc));
17853 8 : if (_ptr_server_unc) {
17854 0 : NDR_PULL_ALLOC(ndr, r->in.server_unc);
17855 : } else {
17856 8 : r->in.server_unc = NULL;
17857 : }
17858 8 : if (r->in.server_unc) {
17859 0 : _mem_save_server_unc_0 = NDR_PULL_GET_MEM_CTX(ndr);
17860 0 : NDR_PULL_SET_MEM_CTX(ndr, r->in.server_unc, 0);
17861 0 : NDR_CHECK(ndr_pull_array_size(ndr, &r->in.server_unc));
17862 0 : NDR_CHECK(ndr_pull_array_length(ndr, &r->in.server_unc));
17863 0 : NDR_CHECK(ndr_steal_array_size(ndr, (void*)&r->in.server_unc, &size_server_unc_1));
17864 0 : NDR_CHECK(ndr_steal_array_length(ndr, (void*)&r->in.server_unc, &length_server_unc_1));
17865 0 : if (length_server_unc_1 > size_server_unc_1) {
17866 0 : return ndr_pull_error(ndr, NDR_ERR_ARRAY_SIZE, "Bad array size %"PRIu32": should exceed array length %"PRIu32"", size_server_unc_1, length_server_unc_1);
17867 : }
17868 0 : NDR_CHECK(ndr_check_string_terminator(ndr, length_server_unc_1, sizeof(uint16_t)));
17869 0 : NDR_CHECK(ndr_pull_charset(ndr, NDR_SCALARS, &r->in.server_unc, length_server_unc_1, sizeof(uint16_t), CH_UTF16));
17870 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_server_unc_0, 0);
17871 : }
17872 8 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->in.level));
17873 8 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
17874 8 : NDR_PULL_ALLOC(ndr, r->in.info);
17875 : }
17876 8 : _mem_save_info_0 = NDR_PULL_GET_MEM_CTX(ndr);
17877 8 : NDR_PULL_SET_MEM_CTX(ndr, r->in.info, LIBNDR_FLAG_REF_ALLOC);
17878 8 : NDR_CHECK(ndr_pull_srvsvc_NetDiskInfo(ndr, NDR_SCALARS|NDR_BUFFERS, r->in.info));
17879 8 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_info_0, LIBNDR_FLAG_REF_ALLOC);
17880 8 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->in.maxlen));
17881 8 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_resume_handle));
17882 8 : if (_ptr_resume_handle) {
17883 8 : NDR_PULL_ALLOC(ndr, r->in.resume_handle);
17884 : } else {
17885 0 : r->in.resume_handle = NULL;
17886 : }
17887 8 : if (r->in.resume_handle) {
17888 8 : _mem_save_resume_handle_0 = NDR_PULL_GET_MEM_CTX(ndr);
17889 8 : NDR_PULL_SET_MEM_CTX(ndr, r->in.resume_handle, 0);
17890 8 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, r->in.resume_handle));
17891 8 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_resume_handle_0, 0);
17892 : }
17893 8 : NDR_PULL_ALLOC(ndr, r->out.info);
17894 8 : *r->out.info = *r->in.info;
17895 8 : NDR_PULL_ALLOC(ndr, r->out.totalentries);
17896 8 : NDR_ZERO_STRUCTP(r->out.totalentries);
17897 : }
17898 16 : if (flags & NDR_OUT) {
17899 : #ifdef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION
17900 : if (r->in.info == NULL) {
17901 : NDR_PULL_ALLOC(ndr, r->in.info);
17902 : NDR_ZERO_STRUCTP(r->in.info);
17903 : }
17904 : #endif /* FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION */
17905 8 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
17906 1 : NDR_PULL_ALLOC(ndr, r->out.info);
17907 : }
17908 8 : _mem_save_info_0 = NDR_PULL_GET_MEM_CTX(ndr);
17909 8 : NDR_PULL_SET_MEM_CTX(ndr, r->out.info, LIBNDR_FLAG_REF_ALLOC);
17910 8 : NDR_CHECK(ndr_pull_srvsvc_NetDiskInfo(ndr, NDR_SCALARS|NDR_BUFFERS, r->out.info));
17911 8 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_info_0, LIBNDR_FLAG_REF_ALLOC);
17912 8 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
17913 1 : NDR_PULL_ALLOC(ndr, r->out.totalentries);
17914 : }
17915 8 : _mem_save_totalentries_0 = NDR_PULL_GET_MEM_CTX(ndr);
17916 8 : NDR_PULL_SET_MEM_CTX(ndr, r->out.totalentries, LIBNDR_FLAG_REF_ALLOC);
17917 8 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, r->out.totalentries));
17918 8 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_totalentries_0, LIBNDR_FLAG_REF_ALLOC);
17919 8 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_resume_handle));
17920 8 : if (_ptr_resume_handle) {
17921 8 : NDR_PULL_ALLOC(ndr, r->out.resume_handle);
17922 : } else {
17923 0 : r->out.resume_handle = NULL;
17924 : }
17925 8 : if (r->out.resume_handle) {
17926 8 : _mem_save_resume_handle_0 = NDR_PULL_GET_MEM_CTX(ndr);
17927 8 : NDR_PULL_SET_MEM_CTX(ndr, r->out.resume_handle, 0);
17928 8 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, r->out.resume_handle));
17929 8 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_resume_handle_0, 0);
17930 : }
17931 8 : NDR_CHECK(ndr_pull_WERROR(ndr, NDR_SCALARS, &r->out.result));
17932 : }
17933 16 : return NDR_ERR_SUCCESS;
17934 : }
17935 :
17936 2 : _PUBLIC_ void ndr_print_srvsvc_NetDiskEnum(struct ndr_print *ndr, const char *name, ndr_flags_type flags, const struct srvsvc_NetDiskEnum *r)
17937 : {
17938 2 : ndr_print_struct(ndr, name, "srvsvc_NetDiskEnum");
17939 2 : if (r == NULL) { ndr_print_null(ndr); return; }
17940 2 : ndr->depth++;
17941 2 : if (flags & NDR_SET_VALUES) {
17942 0 : ndr->flags |= LIBNDR_PRINT_SET_VALUES;
17943 : }
17944 2 : if (flags & NDR_IN) {
17945 0 : ndr_print_struct(ndr, "in", "srvsvc_NetDiskEnum");
17946 0 : ndr->depth++;
17947 0 : ndr_print_ptr(ndr, "server_unc", r->in.server_unc);
17948 0 : ndr->depth++;
17949 0 : if (r->in.server_unc) {
17950 0 : ndr_print_string(ndr, "server_unc", r->in.server_unc);
17951 : }
17952 0 : ndr->depth--;
17953 0 : ndr_print_uint32(ndr, "level", r->in.level);
17954 0 : ndr_print_ptr(ndr, "info", r->in.info);
17955 0 : ndr->depth++;
17956 0 : ndr_print_srvsvc_NetDiskInfo(ndr, "info", r->in.info);
17957 0 : ndr->depth--;
17958 0 : ndr_print_uint32(ndr, "maxlen", r->in.maxlen);
17959 0 : ndr_print_ptr(ndr, "resume_handle", r->in.resume_handle);
17960 0 : ndr->depth++;
17961 0 : if (r->in.resume_handle) {
17962 0 : ndr_print_uint32(ndr, "resume_handle", *r->in.resume_handle);
17963 : }
17964 0 : ndr->depth--;
17965 0 : ndr->depth--;
17966 : }
17967 2 : if (flags & NDR_OUT) {
17968 2 : ndr_print_struct(ndr, "out", "srvsvc_NetDiskEnum");
17969 2 : ndr->depth++;
17970 2 : ndr_print_ptr(ndr, "info", r->out.info);
17971 2 : ndr->depth++;
17972 2 : ndr_print_srvsvc_NetDiskInfo(ndr, "info", r->out.info);
17973 2 : ndr->depth--;
17974 2 : ndr_print_ptr(ndr, "totalentries", r->out.totalentries);
17975 2 : ndr->depth++;
17976 2 : ndr_print_uint32(ndr, "totalentries", *r->out.totalentries);
17977 2 : ndr->depth--;
17978 2 : ndr_print_ptr(ndr, "resume_handle", r->out.resume_handle);
17979 2 : ndr->depth++;
17980 2 : if (r->out.resume_handle) {
17981 2 : ndr_print_uint32(ndr, "resume_handle", *r->out.resume_handle);
17982 : }
17983 2 : ndr->depth--;
17984 2 : ndr_print_WERROR(ndr, "result", r->out.result);
17985 2 : ndr->depth--;
17986 : }
17987 2 : ndr->depth--;
17988 : }
17989 :
17990 0 : static enum ndr_err_code ndr_push_srvsvc_NetServerStatisticsGet(struct ndr_push *ndr, ndr_flags_type flags, const struct srvsvc_NetServerStatisticsGet *r)
17991 : {
17992 0 : NDR_PUSH_CHECK_FN_FLAGS(ndr, flags);
17993 0 : if (flags & NDR_IN) {
17994 0 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->in.server_unc));
17995 0 : if (r->in.server_unc) {
17996 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->in.server_unc, CH_UTF16)));
17997 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, 0));
17998 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->in.server_unc, CH_UTF16)));
17999 0 : NDR_CHECK(ndr_push_charset(ndr, NDR_SCALARS, r->in.server_unc, ndr_charset_length(r->in.server_unc, CH_UTF16), sizeof(uint16_t), CH_UTF16));
18000 : }
18001 0 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->in.service));
18002 0 : if (r->in.service) {
18003 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->in.service, CH_UTF16)));
18004 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, 0));
18005 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->in.service, CH_UTF16)));
18006 0 : NDR_CHECK(ndr_push_charset(ndr, NDR_SCALARS, r->in.service, ndr_charset_length(r->in.service, CH_UTF16), sizeof(uint16_t), CH_UTF16));
18007 : }
18008 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->in.level));
18009 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->in.options));
18010 : }
18011 0 : if (flags & NDR_OUT) {
18012 0 : if (r->out.stats == NULL) {
18013 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
18014 : }
18015 0 : NDR_CHECK(ndr_push_unique_ptr(ndr, *r->out.stats));
18016 0 : if (*r->out.stats) {
18017 0 : NDR_CHECK(ndr_push_srvsvc_Statistics(ndr, NDR_SCALARS, *r->out.stats));
18018 : }
18019 0 : NDR_CHECK(ndr_push_WERROR(ndr, NDR_SCALARS, r->out.result));
18020 : }
18021 0 : return NDR_ERR_SUCCESS;
18022 : }
18023 :
18024 0 : static enum ndr_err_code ndr_pull_srvsvc_NetServerStatisticsGet(struct ndr_pull *ndr, ndr_flags_type flags, struct srvsvc_NetServerStatisticsGet *r)
18025 : {
18026 0 : uint32_t _ptr_server_unc;
18027 0 : uint32_t size_server_unc_1 = 0;
18028 0 : uint32_t length_server_unc_1 = 0;
18029 0 : uint32_t _ptr_service;
18030 0 : uint32_t size_service_1 = 0;
18031 0 : uint32_t length_service_1 = 0;
18032 0 : uint32_t _ptr_stats;
18033 0 : TALLOC_CTX *_mem_save_server_unc_0 = NULL;
18034 0 : TALLOC_CTX *_mem_save_service_0 = NULL;
18035 0 : TALLOC_CTX *_mem_save_stats_0 = NULL;
18036 0 : TALLOC_CTX *_mem_save_stats_1 = NULL;
18037 0 : NDR_PULL_CHECK_FN_FLAGS(ndr, flags);
18038 0 : if (flags & NDR_IN) {
18039 0 : NDR_ZERO_STRUCT(r->out);
18040 :
18041 0 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_server_unc));
18042 0 : if (_ptr_server_unc) {
18043 0 : NDR_PULL_ALLOC(ndr, r->in.server_unc);
18044 : } else {
18045 0 : r->in.server_unc = NULL;
18046 : }
18047 0 : if (r->in.server_unc) {
18048 0 : _mem_save_server_unc_0 = NDR_PULL_GET_MEM_CTX(ndr);
18049 0 : NDR_PULL_SET_MEM_CTX(ndr, r->in.server_unc, 0);
18050 0 : NDR_CHECK(ndr_pull_array_size(ndr, &r->in.server_unc));
18051 0 : NDR_CHECK(ndr_pull_array_length(ndr, &r->in.server_unc));
18052 0 : NDR_CHECK(ndr_steal_array_size(ndr, (void*)&r->in.server_unc, &size_server_unc_1));
18053 0 : NDR_CHECK(ndr_steal_array_length(ndr, (void*)&r->in.server_unc, &length_server_unc_1));
18054 0 : if (length_server_unc_1 > size_server_unc_1) {
18055 0 : return ndr_pull_error(ndr, NDR_ERR_ARRAY_SIZE, "Bad array size %"PRIu32": should exceed array length %"PRIu32"", size_server_unc_1, length_server_unc_1);
18056 : }
18057 0 : NDR_CHECK(ndr_check_string_terminator(ndr, length_server_unc_1, sizeof(uint16_t)));
18058 0 : NDR_CHECK(ndr_pull_charset(ndr, NDR_SCALARS, &r->in.server_unc, length_server_unc_1, sizeof(uint16_t), CH_UTF16));
18059 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_server_unc_0, 0);
18060 : }
18061 0 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_service));
18062 0 : if (_ptr_service) {
18063 0 : NDR_PULL_ALLOC(ndr, r->in.service);
18064 : } else {
18065 0 : r->in.service = NULL;
18066 : }
18067 0 : if (r->in.service) {
18068 0 : _mem_save_service_0 = NDR_PULL_GET_MEM_CTX(ndr);
18069 0 : NDR_PULL_SET_MEM_CTX(ndr, r->in.service, 0);
18070 0 : NDR_CHECK(ndr_pull_array_size(ndr, &r->in.service));
18071 0 : NDR_CHECK(ndr_pull_array_length(ndr, &r->in.service));
18072 0 : NDR_CHECK(ndr_steal_array_size(ndr, (void*)&r->in.service, &size_service_1));
18073 0 : NDR_CHECK(ndr_steal_array_length(ndr, (void*)&r->in.service, &length_service_1));
18074 0 : if (length_service_1 > size_service_1) {
18075 0 : return ndr_pull_error(ndr, NDR_ERR_ARRAY_SIZE, "Bad array size %"PRIu32": should exceed array length %"PRIu32"", size_service_1, length_service_1);
18076 : }
18077 0 : NDR_CHECK(ndr_check_string_terminator(ndr, length_service_1, sizeof(uint16_t)));
18078 0 : NDR_CHECK(ndr_pull_charset(ndr, NDR_SCALARS, &r->in.service, length_service_1, sizeof(uint16_t), CH_UTF16));
18079 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_service_0, 0);
18080 : }
18081 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->in.level));
18082 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->in.options));
18083 0 : NDR_PULL_ALLOC(ndr, r->out.stats);
18084 0 : NDR_ZERO_STRUCTP(r->out.stats);
18085 : }
18086 0 : if (flags & NDR_OUT) {
18087 : #ifdef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION
18088 : #endif /* FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION */
18089 0 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
18090 0 : NDR_PULL_ALLOC(ndr, r->out.stats);
18091 : }
18092 0 : _mem_save_stats_0 = NDR_PULL_GET_MEM_CTX(ndr);
18093 0 : NDR_PULL_SET_MEM_CTX(ndr, r->out.stats, LIBNDR_FLAG_REF_ALLOC);
18094 0 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_stats));
18095 0 : if (_ptr_stats) {
18096 0 : NDR_PULL_ALLOC(ndr, *r->out.stats);
18097 : } else {
18098 0 : *r->out.stats = NULL;
18099 : }
18100 0 : if (*r->out.stats) {
18101 0 : _mem_save_stats_1 = NDR_PULL_GET_MEM_CTX(ndr);
18102 0 : NDR_PULL_SET_MEM_CTX(ndr, *r->out.stats, 0);
18103 0 : NDR_CHECK(ndr_pull_srvsvc_Statistics(ndr, NDR_SCALARS, *r->out.stats));
18104 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_stats_1, 0);
18105 : }
18106 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_stats_0, LIBNDR_FLAG_REF_ALLOC);
18107 0 : NDR_CHECK(ndr_pull_WERROR(ndr, NDR_SCALARS, &r->out.result));
18108 : }
18109 0 : return NDR_ERR_SUCCESS;
18110 : }
18111 :
18112 0 : _PUBLIC_ void ndr_print_srvsvc_NetServerStatisticsGet(struct ndr_print *ndr, const char *name, ndr_flags_type flags, const struct srvsvc_NetServerStatisticsGet *r)
18113 : {
18114 0 : ndr_print_struct(ndr, name, "srvsvc_NetServerStatisticsGet");
18115 0 : if (r == NULL) { ndr_print_null(ndr); return; }
18116 0 : ndr->depth++;
18117 0 : if (flags & NDR_SET_VALUES) {
18118 0 : ndr->flags |= LIBNDR_PRINT_SET_VALUES;
18119 : }
18120 0 : if (flags & NDR_IN) {
18121 0 : ndr_print_struct(ndr, "in", "srvsvc_NetServerStatisticsGet");
18122 0 : ndr->depth++;
18123 0 : ndr_print_ptr(ndr, "server_unc", r->in.server_unc);
18124 0 : ndr->depth++;
18125 0 : if (r->in.server_unc) {
18126 0 : ndr_print_string(ndr, "server_unc", r->in.server_unc);
18127 : }
18128 0 : ndr->depth--;
18129 0 : ndr_print_ptr(ndr, "service", r->in.service);
18130 0 : ndr->depth++;
18131 0 : if (r->in.service) {
18132 0 : ndr_print_string(ndr, "service", r->in.service);
18133 : }
18134 0 : ndr->depth--;
18135 0 : ndr_print_uint32(ndr, "level", r->in.level);
18136 0 : ndr_print_uint32(ndr, "options", r->in.options);
18137 0 : ndr->depth--;
18138 : }
18139 0 : if (flags & NDR_OUT) {
18140 0 : ndr_print_struct(ndr, "out", "srvsvc_NetServerStatisticsGet");
18141 0 : ndr->depth++;
18142 0 : ndr_print_ptr(ndr, "stats", r->out.stats);
18143 0 : ndr->depth++;
18144 0 : ndr_print_ptr(ndr, "stats", *r->out.stats);
18145 0 : ndr->depth++;
18146 0 : if (*r->out.stats) {
18147 0 : ndr_print_srvsvc_Statistics(ndr, "stats", *r->out.stats);
18148 : }
18149 0 : ndr->depth--;
18150 0 : ndr->depth--;
18151 0 : ndr_print_WERROR(ndr, "result", r->out.result);
18152 0 : ndr->depth--;
18153 : }
18154 0 : ndr->depth--;
18155 : }
18156 :
18157 0 : static enum ndr_err_code ndr_push_srvsvc_NetTransportAdd(struct ndr_push *ndr, ndr_flags_type flags, const struct srvsvc_NetTransportAdd *r)
18158 : {
18159 0 : NDR_PUSH_CHECK_FN_FLAGS(ndr, flags);
18160 0 : if (flags & NDR_IN) {
18161 0 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->in.server_unc));
18162 0 : if (r->in.server_unc) {
18163 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->in.server_unc, CH_UTF16)));
18164 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, 0));
18165 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->in.server_unc, CH_UTF16)));
18166 0 : NDR_CHECK(ndr_push_charset(ndr, NDR_SCALARS, r->in.server_unc, ndr_charset_length(r->in.server_unc, CH_UTF16), sizeof(uint16_t), CH_UTF16));
18167 : }
18168 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->in.level));
18169 0 : NDR_CHECK(ndr_push_set_switch_value(ndr, &r->in.info, r->in.level));
18170 0 : NDR_CHECK(ndr_push_srvsvc_NetTransportInfo(ndr, NDR_SCALARS|NDR_BUFFERS, &r->in.info));
18171 : }
18172 0 : if (flags & NDR_OUT) {
18173 0 : NDR_CHECK(ndr_push_WERROR(ndr, NDR_SCALARS, r->out.result));
18174 : }
18175 0 : return NDR_ERR_SUCCESS;
18176 : }
18177 :
18178 0 : static enum ndr_err_code ndr_pull_srvsvc_NetTransportAdd(struct ndr_pull *ndr, ndr_flags_type flags, struct srvsvc_NetTransportAdd *r)
18179 : {
18180 0 : uint32_t _ptr_server_unc;
18181 0 : uint32_t size_server_unc_1 = 0;
18182 0 : uint32_t length_server_unc_1 = 0;
18183 0 : TALLOC_CTX *_mem_save_server_unc_0 = NULL;
18184 0 : NDR_PULL_CHECK_FN_FLAGS(ndr, flags);
18185 0 : if (flags & NDR_IN) {
18186 0 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_server_unc));
18187 0 : if (_ptr_server_unc) {
18188 0 : NDR_PULL_ALLOC(ndr, r->in.server_unc);
18189 : } else {
18190 0 : r->in.server_unc = NULL;
18191 : }
18192 0 : if (r->in.server_unc) {
18193 0 : _mem_save_server_unc_0 = NDR_PULL_GET_MEM_CTX(ndr);
18194 0 : NDR_PULL_SET_MEM_CTX(ndr, r->in.server_unc, 0);
18195 0 : NDR_CHECK(ndr_pull_array_size(ndr, &r->in.server_unc));
18196 0 : NDR_CHECK(ndr_pull_array_length(ndr, &r->in.server_unc));
18197 0 : NDR_CHECK(ndr_steal_array_size(ndr, (void*)&r->in.server_unc, &size_server_unc_1));
18198 0 : NDR_CHECK(ndr_steal_array_length(ndr, (void*)&r->in.server_unc, &length_server_unc_1));
18199 0 : if (length_server_unc_1 > size_server_unc_1) {
18200 0 : return ndr_pull_error(ndr, NDR_ERR_ARRAY_SIZE, "Bad array size %"PRIu32": should exceed array length %"PRIu32"", size_server_unc_1, length_server_unc_1);
18201 : }
18202 0 : NDR_CHECK(ndr_check_string_terminator(ndr, length_server_unc_1, sizeof(uint16_t)));
18203 0 : NDR_CHECK(ndr_pull_charset(ndr, NDR_SCALARS, &r->in.server_unc, length_server_unc_1, sizeof(uint16_t), CH_UTF16));
18204 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_server_unc_0, 0);
18205 : }
18206 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->in.level));
18207 0 : NDR_CHECK(ndr_pull_set_switch_value(ndr, &r->in.info, r->in.level));
18208 0 : NDR_CHECK(ndr_pull_srvsvc_NetTransportInfo(ndr, NDR_SCALARS|NDR_BUFFERS, &r->in.info));
18209 : }
18210 0 : if (flags & NDR_OUT) {
18211 : #ifdef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION
18212 : #endif /* FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION */
18213 0 : NDR_CHECK(ndr_pull_WERROR(ndr, NDR_SCALARS, &r->out.result));
18214 : }
18215 0 : return NDR_ERR_SUCCESS;
18216 : }
18217 :
18218 0 : _PUBLIC_ void ndr_print_srvsvc_NetTransportAdd(struct ndr_print *ndr, const char *name, ndr_flags_type flags, const struct srvsvc_NetTransportAdd *r)
18219 : {
18220 0 : ndr_print_struct(ndr, name, "srvsvc_NetTransportAdd");
18221 0 : if (r == NULL) { ndr_print_null(ndr); return; }
18222 0 : ndr->depth++;
18223 0 : if (flags & NDR_SET_VALUES) {
18224 0 : ndr->flags |= LIBNDR_PRINT_SET_VALUES;
18225 : }
18226 0 : if (flags & NDR_IN) {
18227 0 : ndr_print_struct(ndr, "in", "srvsvc_NetTransportAdd");
18228 0 : ndr->depth++;
18229 0 : ndr_print_ptr(ndr, "server_unc", r->in.server_unc);
18230 0 : ndr->depth++;
18231 0 : if (r->in.server_unc) {
18232 0 : ndr_print_string(ndr, "server_unc", r->in.server_unc);
18233 : }
18234 0 : ndr->depth--;
18235 0 : ndr_print_uint32(ndr, "level", r->in.level);
18236 0 : ndr_print_set_switch_value(ndr, &r->in.info, r->in.level);
18237 0 : ndr_print_srvsvc_NetTransportInfo(ndr, "info", &r->in.info);
18238 0 : ndr->depth--;
18239 : }
18240 0 : if (flags & NDR_OUT) {
18241 0 : ndr_print_struct(ndr, "out", "srvsvc_NetTransportAdd");
18242 0 : ndr->depth++;
18243 0 : ndr_print_WERROR(ndr, "result", r->out.result);
18244 0 : ndr->depth--;
18245 : }
18246 0 : ndr->depth--;
18247 : }
18248 :
18249 22 : static enum ndr_err_code ndr_push_srvsvc_NetTransportEnum(struct ndr_push *ndr, ndr_flags_type flags, const struct srvsvc_NetTransportEnum *r)
18250 : {
18251 22 : NDR_PUSH_CHECK_FN_FLAGS(ndr, flags);
18252 22 : if (flags & NDR_IN) {
18253 12 : if (r->in.transports == NULL) {
18254 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
18255 : }
18256 12 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->in.server_unc));
18257 12 : if (r->in.server_unc) {
18258 12 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->in.server_unc, CH_UTF16)));
18259 12 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, 0));
18260 12 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->in.server_unc, CH_UTF16)));
18261 12 : NDR_CHECK(ndr_push_charset(ndr, NDR_SCALARS, r->in.server_unc, ndr_charset_length(r->in.server_unc, CH_UTF16), sizeof(uint16_t), CH_UTF16));
18262 : }
18263 12 : NDR_CHECK(ndr_push_srvsvc_NetTransportInfoCtr(ndr, NDR_SCALARS|NDR_BUFFERS, r->in.transports));
18264 12 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->in.max_buffer));
18265 12 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->in.resume_handle));
18266 12 : if (r->in.resume_handle) {
18267 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, *r->in.resume_handle));
18268 : }
18269 : }
18270 22 : if (flags & NDR_OUT) {
18271 10 : if (r->out.transports == NULL) {
18272 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
18273 : }
18274 10 : if (r->out.totalentries == NULL) {
18275 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
18276 : }
18277 10 : NDR_CHECK(ndr_push_srvsvc_NetTransportInfoCtr(ndr, NDR_SCALARS|NDR_BUFFERS, r->out.transports));
18278 10 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, *r->out.totalentries));
18279 10 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->out.resume_handle));
18280 10 : if (r->out.resume_handle) {
18281 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, *r->out.resume_handle));
18282 : }
18283 10 : NDR_CHECK(ndr_push_WERROR(ndr, NDR_SCALARS, r->out.result));
18284 : }
18285 22 : return NDR_ERR_SUCCESS;
18286 : }
18287 :
18288 20 : static enum ndr_err_code ndr_pull_srvsvc_NetTransportEnum(struct ndr_pull *ndr, ndr_flags_type flags, struct srvsvc_NetTransportEnum *r)
18289 : {
18290 0 : uint32_t _ptr_server_unc;
18291 20 : uint32_t size_server_unc_1 = 0;
18292 20 : uint32_t length_server_unc_1 = 0;
18293 0 : uint32_t _ptr_resume_handle;
18294 20 : TALLOC_CTX *_mem_save_server_unc_0 = NULL;
18295 20 : TALLOC_CTX *_mem_save_transports_0 = NULL;
18296 20 : TALLOC_CTX *_mem_save_totalentries_0 = NULL;
18297 20 : TALLOC_CTX *_mem_save_resume_handle_0 = NULL;
18298 20 : NDR_PULL_CHECK_FN_FLAGS(ndr, flags);
18299 20 : if (flags & NDR_IN) {
18300 12 : NDR_ZERO_STRUCT(r->out);
18301 :
18302 12 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_server_unc));
18303 12 : if (_ptr_server_unc) {
18304 12 : NDR_PULL_ALLOC(ndr, r->in.server_unc);
18305 : } else {
18306 0 : r->in.server_unc = NULL;
18307 : }
18308 12 : if (r->in.server_unc) {
18309 12 : _mem_save_server_unc_0 = NDR_PULL_GET_MEM_CTX(ndr);
18310 12 : NDR_PULL_SET_MEM_CTX(ndr, r->in.server_unc, 0);
18311 12 : NDR_CHECK(ndr_pull_array_size(ndr, &r->in.server_unc));
18312 12 : NDR_CHECK(ndr_pull_array_length(ndr, &r->in.server_unc));
18313 12 : NDR_CHECK(ndr_steal_array_size(ndr, (void*)&r->in.server_unc, &size_server_unc_1));
18314 12 : NDR_CHECK(ndr_steal_array_length(ndr, (void*)&r->in.server_unc, &length_server_unc_1));
18315 12 : if (length_server_unc_1 > size_server_unc_1) {
18316 0 : return ndr_pull_error(ndr, NDR_ERR_ARRAY_SIZE, "Bad array size %"PRIu32": should exceed array length %"PRIu32"", size_server_unc_1, length_server_unc_1);
18317 : }
18318 12 : NDR_CHECK(ndr_check_string_terminator(ndr, length_server_unc_1, sizeof(uint16_t)));
18319 12 : NDR_CHECK(ndr_pull_charset(ndr, NDR_SCALARS, &r->in.server_unc, length_server_unc_1, sizeof(uint16_t), CH_UTF16));
18320 12 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_server_unc_0, 0);
18321 : }
18322 12 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
18323 12 : NDR_PULL_ALLOC(ndr, r->in.transports);
18324 : }
18325 12 : _mem_save_transports_0 = NDR_PULL_GET_MEM_CTX(ndr);
18326 12 : NDR_PULL_SET_MEM_CTX(ndr, r->in.transports, LIBNDR_FLAG_REF_ALLOC);
18327 12 : NDR_CHECK(ndr_pull_srvsvc_NetTransportInfoCtr(ndr, NDR_SCALARS|NDR_BUFFERS, r->in.transports));
18328 12 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_transports_0, LIBNDR_FLAG_REF_ALLOC);
18329 12 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->in.max_buffer));
18330 12 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_resume_handle));
18331 12 : if (_ptr_resume_handle) {
18332 0 : NDR_PULL_ALLOC(ndr, r->in.resume_handle);
18333 : } else {
18334 12 : r->in.resume_handle = NULL;
18335 : }
18336 12 : if (r->in.resume_handle) {
18337 0 : _mem_save_resume_handle_0 = NDR_PULL_GET_MEM_CTX(ndr);
18338 0 : NDR_PULL_SET_MEM_CTX(ndr, r->in.resume_handle, 0);
18339 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, r->in.resume_handle));
18340 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_resume_handle_0, 0);
18341 : }
18342 12 : NDR_PULL_ALLOC(ndr, r->out.transports);
18343 12 : *r->out.transports = *r->in.transports;
18344 12 : NDR_PULL_ALLOC(ndr, r->out.totalentries);
18345 12 : NDR_ZERO_STRUCTP(r->out.totalentries);
18346 : }
18347 20 : if (flags & NDR_OUT) {
18348 : #ifdef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION
18349 : if (r->in.transports == NULL) {
18350 : NDR_PULL_ALLOC(ndr, r->in.transports);
18351 : NDR_ZERO_STRUCTP(r->in.transports);
18352 : }
18353 : #endif /* FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION */
18354 8 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
18355 2 : NDR_PULL_ALLOC(ndr, r->out.transports);
18356 : }
18357 8 : _mem_save_transports_0 = NDR_PULL_GET_MEM_CTX(ndr);
18358 8 : NDR_PULL_SET_MEM_CTX(ndr, r->out.transports, LIBNDR_FLAG_REF_ALLOC);
18359 8 : NDR_CHECK(ndr_pull_srvsvc_NetTransportInfoCtr(ndr, NDR_SCALARS|NDR_BUFFERS, r->out.transports));
18360 8 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_transports_0, LIBNDR_FLAG_REF_ALLOC);
18361 8 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
18362 2 : NDR_PULL_ALLOC(ndr, r->out.totalentries);
18363 : }
18364 8 : _mem_save_totalentries_0 = NDR_PULL_GET_MEM_CTX(ndr);
18365 8 : NDR_PULL_SET_MEM_CTX(ndr, r->out.totalentries, LIBNDR_FLAG_REF_ALLOC);
18366 8 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, r->out.totalentries));
18367 8 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_totalentries_0, LIBNDR_FLAG_REF_ALLOC);
18368 8 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_resume_handle));
18369 8 : if (_ptr_resume_handle) {
18370 0 : NDR_PULL_ALLOC(ndr, r->out.resume_handle);
18371 : } else {
18372 8 : r->out.resume_handle = NULL;
18373 : }
18374 8 : if (r->out.resume_handle) {
18375 0 : _mem_save_resume_handle_0 = NDR_PULL_GET_MEM_CTX(ndr);
18376 0 : NDR_PULL_SET_MEM_CTX(ndr, r->out.resume_handle, 0);
18377 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, r->out.resume_handle));
18378 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_resume_handle_0, 0);
18379 : }
18380 8 : NDR_CHECK(ndr_pull_WERROR(ndr, NDR_SCALARS, &r->out.result));
18381 : }
18382 20 : return NDR_ERR_SUCCESS;
18383 : }
18384 :
18385 4 : _PUBLIC_ void ndr_print_srvsvc_NetTransportEnum(struct ndr_print *ndr, const char *name, ndr_flags_type flags, const struct srvsvc_NetTransportEnum *r)
18386 : {
18387 4 : ndr_print_struct(ndr, name, "srvsvc_NetTransportEnum");
18388 4 : if (r == NULL) { ndr_print_null(ndr); return; }
18389 4 : ndr->depth++;
18390 4 : if (flags & NDR_SET_VALUES) {
18391 0 : ndr->flags |= LIBNDR_PRINT_SET_VALUES;
18392 : }
18393 4 : if (flags & NDR_IN) {
18394 0 : ndr_print_struct(ndr, "in", "srvsvc_NetTransportEnum");
18395 0 : ndr->depth++;
18396 0 : ndr_print_ptr(ndr, "server_unc", r->in.server_unc);
18397 0 : ndr->depth++;
18398 0 : if (r->in.server_unc) {
18399 0 : ndr_print_string(ndr, "server_unc", r->in.server_unc);
18400 : }
18401 0 : ndr->depth--;
18402 0 : ndr_print_ptr(ndr, "transports", r->in.transports);
18403 0 : ndr->depth++;
18404 0 : ndr_print_srvsvc_NetTransportInfoCtr(ndr, "transports", r->in.transports);
18405 0 : ndr->depth--;
18406 0 : ndr_print_uint32(ndr, "max_buffer", r->in.max_buffer);
18407 0 : ndr_print_ptr(ndr, "resume_handle", r->in.resume_handle);
18408 0 : ndr->depth++;
18409 0 : if (r->in.resume_handle) {
18410 0 : ndr_print_uint32(ndr, "resume_handle", *r->in.resume_handle);
18411 : }
18412 0 : ndr->depth--;
18413 0 : ndr->depth--;
18414 : }
18415 4 : if (flags & NDR_OUT) {
18416 4 : ndr_print_struct(ndr, "out", "srvsvc_NetTransportEnum");
18417 4 : ndr->depth++;
18418 4 : ndr_print_ptr(ndr, "transports", r->out.transports);
18419 4 : ndr->depth++;
18420 4 : ndr_print_srvsvc_NetTransportInfoCtr(ndr, "transports", r->out.transports);
18421 4 : ndr->depth--;
18422 4 : ndr_print_ptr(ndr, "totalentries", r->out.totalentries);
18423 4 : ndr->depth++;
18424 4 : ndr_print_uint32(ndr, "totalentries", *r->out.totalentries);
18425 4 : ndr->depth--;
18426 4 : ndr_print_ptr(ndr, "resume_handle", r->out.resume_handle);
18427 4 : ndr->depth++;
18428 4 : if (r->out.resume_handle) {
18429 0 : ndr_print_uint32(ndr, "resume_handle", *r->out.resume_handle);
18430 : }
18431 4 : ndr->depth--;
18432 4 : ndr_print_WERROR(ndr, "result", r->out.result);
18433 4 : ndr->depth--;
18434 : }
18435 4 : ndr->depth--;
18436 : }
18437 :
18438 0 : static enum ndr_err_code ndr_push_srvsvc_NetTransportDel(struct ndr_push *ndr, ndr_flags_type flags, const struct srvsvc_NetTransportDel *r)
18439 : {
18440 0 : NDR_PUSH_CHECK_FN_FLAGS(ndr, flags);
18441 0 : if (flags & NDR_IN) {
18442 0 : if (r->in.info0 == NULL) {
18443 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
18444 : }
18445 0 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->in.server_unc));
18446 0 : if (r->in.server_unc) {
18447 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->in.server_unc, CH_UTF16)));
18448 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, 0));
18449 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->in.server_unc, CH_UTF16)));
18450 0 : NDR_CHECK(ndr_push_charset(ndr, NDR_SCALARS, r->in.server_unc, ndr_charset_length(r->in.server_unc, CH_UTF16), sizeof(uint16_t), CH_UTF16));
18451 : }
18452 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->in.level));
18453 0 : NDR_CHECK(ndr_push_srvsvc_NetTransportInfo0(ndr, NDR_SCALARS|NDR_BUFFERS, r->in.info0));
18454 : }
18455 0 : if (flags & NDR_OUT) {
18456 0 : NDR_CHECK(ndr_push_WERROR(ndr, NDR_SCALARS, r->out.result));
18457 : }
18458 0 : return NDR_ERR_SUCCESS;
18459 : }
18460 :
18461 0 : static enum ndr_err_code ndr_pull_srvsvc_NetTransportDel(struct ndr_pull *ndr, ndr_flags_type flags, struct srvsvc_NetTransportDel *r)
18462 : {
18463 0 : uint32_t _ptr_server_unc;
18464 0 : uint32_t size_server_unc_1 = 0;
18465 0 : uint32_t length_server_unc_1 = 0;
18466 0 : TALLOC_CTX *_mem_save_server_unc_0 = NULL;
18467 0 : TALLOC_CTX *_mem_save_info0_0 = NULL;
18468 0 : NDR_PULL_CHECK_FN_FLAGS(ndr, flags);
18469 0 : if (flags & NDR_IN) {
18470 0 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_server_unc));
18471 0 : if (_ptr_server_unc) {
18472 0 : NDR_PULL_ALLOC(ndr, r->in.server_unc);
18473 : } else {
18474 0 : r->in.server_unc = NULL;
18475 : }
18476 0 : if (r->in.server_unc) {
18477 0 : _mem_save_server_unc_0 = NDR_PULL_GET_MEM_CTX(ndr);
18478 0 : NDR_PULL_SET_MEM_CTX(ndr, r->in.server_unc, 0);
18479 0 : NDR_CHECK(ndr_pull_array_size(ndr, &r->in.server_unc));
18480 0 : NDR_CHECK(ndr_pull_array_length(ndr, &r->in.server_unc));
18481 0 : NDR_CHECK(ndr_steal_array_size(ndr, (void*)&r->in.server_unc, &size_server_unc_1));
18482 0 : NDR_CHECK(ndr_steal_array_length(ndr, (void*)&r->in.server_unc, &length_server_unc_1));
18483 0 : if (length_server_unc_1 > size_server_unc_1) {
18484 0 : return ndr_pull_error(ndr, NDR_ERR_ARRAY_SIZE, "Bad array size %"PRIu32": should exceed array length %"PRIu32"", size_server_unc_1, length_server_unc_1);
18485 : }
18486 0 : NDR_CHECK(ndr_check_string_terminator(ndr, length_server_unc_1, sizeof(uint16_t)));
18487 0 : NDR_CHECK(ndr_pull_charset(ndr, NDR_SCALARS, &r->in.server_unc, length_server_unc_1, sizeof(uint16_t), CH_UTF16));
18488 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_server_unc_0, 0);
18489 : }
18490 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->in.level));
18491 0 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
18492 0 : NDR_PULL_ALLOC(ndr, r->in.info0);
18493 : }
18494 0 : _mem_save_info0_0 = NDR_PULL_GET_MEM_CTX(ndr);
18495 0 : NDR_PULL_SET_MEM_CTX(ndr, r->in.info0, LIBNDR_FLAG_REF_ALLOC);
18496 0 : NDR_CHECK(ndr_pull_srvsvc_NetTransportInfo0(ndr, NDR_SCALARS|NDR_BUFFERS, r->in.info0));
18497 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_info0_0, LIBNDR_FLAG_REF_ALLOC);
18498 : }
18499 0 : if (flags & NDR_OUT) {
18500 : #ifdef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION
18501 : if (r->in.info0 == NULL) {
18502 : NDR_PULL_ALLOC(ndr, r->in.info0);
18503 : NDR_ZERO_STRUCTP(r->in.info0);
18504 : }
18505 : #endif /* FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION */
18506 0 : NDR_CHECK(ndr_pull_WERROR(ndr, NDR_SCALARS, &r->out.result));
18507 : }
18508 0 : return NDR_ERR_SUCCESS;
18509 : }
18510 :
18511 0 : _PUBLIC_ void ndr_print_srvsvc_NetTransportDel(struct ndr_print *ndr, const char *name, ndr_flags_type flags, const struct srvsvc_NetTransportDel *r)
18512 : {
18513 0 : ndr_print_struct(ndr, name, "srvsvc_NetTransportDel");
18514 0 : if (r == NULL) { ndr_print_null(ndr); return; }
18515 0 : ndr->depth++;
18516 0 : if (flags & NDR_SET_VALUES) {
18517 0 : ndr->flags |= LIBNDR_PRINT_SET_VALUES;
18518 : }
18519 0 : if (flags & NDR_IN) {
18520 0 : ndr_print_struct(ndr, "in", "srvsvc_NetTransportDel");
18521 0 : ndr->depth++;
18522 0 : ndr_print_ptr(ndr, "server_unc", r->in.server_unc);
18523 0 : ndr->depth++;
18524 0 : if (r->in.server_unc) {
18525 0 : ndr_print_string(ndr, "server_unc", r->in.server_unc);
18526 : }
18527 0 : ndr->depth--;
18528 0 : ndr_print_uint32(ndr, "level", r->in.level);
18529 0 : ndr_print_ptr(ndr, "info0", r->in.info0);
18530 0 : ndr->depth++;
18531 0 : ndr_print_srvsvc_NetTransportInfo0(ndr, "info0", r->in.info0);
18532 0 : ndr->depth--;
18533 0 : ndr->depth--;
18534 : }
18535 0 : if (flags & NDR_OUT) {
18536 0 : ndr_print_struct(ndr, "out", "srvsvc_NetTransportDel");
18537 0 : ndr->depth++;
18538 0 : ndr_print_WERROR(ndr, "result", r->out.result);
18539 0 : ndr->depth--;
18540 : }
18541 0 : ndr->depth--;
18542 : }
18543 :
18544 67 : static enum ndr_err_code ndr_push_srvsvc_NetRemoteTOD(struct ndr_push *ndr, ndr_flags_type flags, const struct srvsvc_NetRemoteTOD *r)
18545 : {
18546 67 : NDR_PUSH_CHECK_FN_FLAGS(ndr, flags);
18547 67 : if (flags & NDR_IN) {
18548 33 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->in.server_unc));
18549 33 : if (r->in.server_unc) {
18550 33 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->in.server_unc, CH_UTF16)));
18551 33 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, 0));
18552 33 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->in.server_unc, CH_UTF16)));
18553 33 : NDR_CHECK(ndr_push_charset(ndr, NDR_SCALARS, r->in.server_unc, ndr_charset_length(r->in.server_unc, CH_UTF16), sizeof(uint16_t), CH_UTF16));
18554 : }
18555 : }
18556 67 : if (flags & NDR_OUT) {
18557 34 : if (r->out.info == NULL) {
18558 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
18559 : }
18560 34 : NDR_CHECK(ndr_push_unique_ptr(ndr, *r->out.info));
18561 34 : if (*r->out.info) {
18562 34 : NDR_CHECK(ndr_push_srvsvc_NetRemoteTODInfo(ndr, NDR_SCALARS, *r->out.info));
18563 : }
18564 34 : NDR_CHECK(ndr_push_WERROR(ndr, NDR_SCALARS, r->out.result));
18565 : }
18566 67 : return NDR_ERR_SUCCESS;
18567 : }
18568 :
18569 66 : static enum ndr_err_code ndr_pull_srvsvc_NetRemoteTOD(struct ndr_pull *ndr, ndr_flags_type flags, struct srvsvc_NetRemoteTOD *r)
18570 : {
18571 0 : uint32_t _ptr_server_unc;
18572 66 : uint32_t size_server_unc_1 = 0;
18573 66 : uint32_t length_server_unc_1 = 0;
18574 0 : uint32_t _ptr_info;
18575 66 : TALLOC_CTX *_mem_save_server_unc_0 = NULL;
18576 66 : TALLOC_CTX *_mem_save_info_0 = NULL;
18577 66 : TALLOC_CTX *_mem_save_info_1 = NULL;
18578 66 : NDR_PULL_CHECK_FN_FLAGS(ndr, flags);
18579 66 : if (flags & NDR_IN) {
18580 33 : NDR_ZERO_STRUCT(r->out);
18581 :
18582 33 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_server_unc));
18583 33 : if (_ptr_server_unc) {
18584 33 : NDR_PULL_ALLOC(ndr, r->in.server_unc);
18585 : } else {
18586 0 : r->in.server_unc = NULL;
18587 : }
18588 33 : if (r->in.server_unc) {
18589 33 : _mem_save_server_unc_0 = NDR_PULL_GET_MEM_CTX(ndr);
18590 33 : NDR_PULL_SET_MEM_CTX(ndr, r->in.server_unc, 0);
18591 33 : NDR_CHECK(ndr_pull_array_size(ndr, &r->in.server_unc));
18592 33 : NDR_CHECK(ndr_pull_array_length(ndr, &r->in.server_unc));
18593 33 : NDR_CHECK(ndr_steal_array_size(ndr, (void*)&r->in.server_unc, &size_server_unc_1));
18594 33 : NDR_CHECK(ndr_steal_array_length(ndr, (void*)&r->in.server_unc, &length_server_unc_1));
18595 33 : if (length_server_unc_1 > size_server_unc_1) {
18596 0 : return ndr_pull_error(ndr, NDR_ERR_ARRAY_SIZE, "Bad array size %"PRIu32": should exceed array length %"PRIu32"", size_server_unc_1, length_server_unc_1);
18597 : }
18598 33 : NDR_CHECK(ndr_check_string_terminator(ndr, length_server_unc_1, sizeof(uint16_t)));
18599 33 : NDR_CHECK(ndr_pull_charset(ndr, NDR_SCALARS, &r->in.server_unc, length_server_unc_1, sizeof(uint16_t), CH_UTF16));
18600 33 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_server_unc_0, 0);
18601 : }
18602 33 : NDR_PULL_ALLOC(ndr, r->out.info);
18603 33 : NDR_ZERO_STRUCTP(r->out.info);
18604 : }
18605 66 : if (flags & NDR_OUT) {
18606 : #ifdef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION
18607 : #endif /* FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION */
18608 33 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
18609 12 : NDR_PULL_ALLOC(ndr, r->out.info);
18610 : }
18611 33 : _mem_save_info_0 = NDR_PULL_GET_MEM_CTX(ndr);
18612 33 : NDR_PULL_SET_MEM_CTX(ndr, r->out.info, LIBNDR_FLAG_REF_ALLOC);
18613 33 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_info));
18614 33 : if (_ptr_info) {
18615 33 : NDR_PULL_ALLOC(ndr, *r->out.info);
18616 : } else {
18617 0 : *r->out.info = NULL;
18618 : }
18619 33 : if (*r->out.info) {
18620 33 : _mem_save_info_1 = NDR_PULL_GET_MEM_CTX(ndr);
18621 33 : NDR_PULL_SET_MEM_CTX(ndr, *r->out.info, 0);
18622 33 : NDR_CHECK(ndr_pull_srvsvc_NetRemoteTODInfo(ndr, NDR_SCALARS, *r->out.info));
18623 33 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_info_1, 0);
18624 : }
18625 33 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_info_0, LIBNDR_FLAG_REF_ALLOC);
18626 33 : NDR_CHECK(ndr_pull_WERROR(ndr, NDR_SCALARS, &r->out.result));
18627 : }
18628 66 : return NDR_ERR_SUCCESS;
18629 : }
18630 :
18631 2 : _PUBLIC_ void ndr_print_srvsvc_NetRemoteTOD(struct ndr_print *ndr, const char *name, ndr_flags_type flags, const struct srvsvc_NetRemoteTOD *r)
18632 : {
18633 2 : ndr_print_struct(ndr, name, "srvsvc_NetRemoteTOD");
18634 2 : if (r == NULL) { ndr_print_null(ndr); return; }
18635 2 : ndr->depth++;
18636 2 : if (flags & NDR_SET_VALUES) {
18637 0 : ndr->flags |= LIBNDR_PRINT_SET_VALUES;
18638 : }
18639 2 : if (flags & NDR_IN) {
18640 0 : ndr_print_struct(ndr, "in", "srvsvc_NetRemoteTOD");
18641 0 : ndr->depth++;
18642 0 : ndr_print_ptr(ndr, "server_unc", r->in.server_unc);
18643 0 : ndr->depth++;
18644 0 : if (r->in.server_unc) {
18645 0 : ndr_print_string(ndr, "server_unc", r->in.server_unc);
18646 : }
18647 0 : ndr->depth--;
18648 0 : ndr->depth--;
18649 : }
18650 2 : if (flags & NDR_OUT) {
18651 2 : ndr_print_struct(ndr, "out", "srvsvc_NetRemoteTOD");
18652 2 : ndr->depth++;
18653 2 : ndr_print_ptr(ndr, "info", r->out.info);
18654 2 : ndr->depth++;
18655 2 : ndr_print_ptr(ndr, "info", *r->out.info);
18656 2 : ndr->depth++;
18657 2 : if (*r->out.info) {
18658 2 : ndr_print_srvsvc_NetRemoteTODInfo(ndr, "info", *r->out.info);
18659 : }
18660 2 : ndr->depth--;
18661 2 : ndr->depth--;
18662 2 : ndr_print_WERROR(ndr, "result", r->out.result);
18663 2 : ndr->depth--;
18664 : }
18665 2 : ndr->depth--;
18666 : }
18667 :
18668 0 : static enum ndr_err_code ndr_push_srvsvc_NetSetServiceBits(struct ndr_push *ndr, ndr_flags_type flags, const struct srvsvc_NetSetServiceBits *r)
18669 : {
18670 0 : NDR_PUSH_CHECK_FN_FLAGS(ndr, flags);
18671 0 : if (flags & NDR_IN) {
18672 0 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->in.server_unc));
18673 0 : if (r->in.server_unc) {
18674 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->in.server_unc, CH_UTF16)));
18675 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, 0));
18676 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->in.server_unc, CH_UTF16)));
18677 0 : NDR_CHECK(ndr_push_charset(ndr, NDR_SCALARS, r->in.server_unc, ndr_charset_length(r->in.server_unc, CH_UTF16), sizeof(uint16_t), CH_UTF16));
18678 : }
18679 0 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->in.transport));
18680 0 : if (r->in.transport) {
18681 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->in.transport, CH_UTF16)));
18682 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, 0));
18683 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->in.transport, CH_UTF16)));
18684 0 : NDR_CHECK(ndr_push_charset(ndr, NDR_SCALARS, r->in.transport, ndr_charset_length(r->in.transport, CH_UTF16), sizeof(uint16_t), CH_UTF16));
18685 : }
18686 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->in.servicebits));
18687 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->in.updateimmediately));
18688 : }
18689 0 : if (flags & NDR_OUT) {
18690 0 : NDR_CHECK(ndr_push_WERROR(ndr, NDR_SCALARS, r->out.result));
18691 : }
18692 0 : return NDR_ERR_SUCCESS;
18693 : }
18694 :
18695 0 : static enum ndr_err_code ndr_pull_srvsvc_NetSetServiceBits(struct ndr_pull *ndr, ndr_flags_type flags, struct srvsvc_NetSetServiceBits *r)
18696 : {
18697 0 : uint32_t _ptr_server_unc;
18698 0 : uint32_t size_server_unc_1 = 0;
18699 0 : uint32_t length_server_unc_1 = 0;
18700 0 : uint32_t _ptr_transport;
18701 0 : uint32_t size_transport_1 = 0;
18702 0 : uint32_t length_transport_1 = 0;
18703 0 : TALLOC_CTX *_mem_save_server_unc_0 = NULL;
18704 0 : TALLOC_CTX *_mem_save_transport_0 = NULL;
18705 0 : NDR_PULL_CHECK_FN_FLAGS(ndr, flags);
18706 0 : if (flags & NDR_IN) {
18707 0 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_server_unc));
18708 0 : if (_ptr_server_unc) {
18709 0 : NDR_PULL_ALLOC(ndr, r->in.server_unc);
18710 : } else {
18711 0 : r->in.server_unc = NULL;
18712 : }
18713 0 : if (r->in.server_unc) {
18714 0 : _mem_save_server_unc_0 = NDR_PULL_GET_MEM_CTX(ndr);
18715 0 : NDR_PULL_SET_MEM_CTX(ndr, r->in.server_unc, 0);
18716 0 : NDR_CHECK(ndr_pull_array_size(ndr, &r->in.server_unc));
18717 0 : NDR_CHECK(ndr_pull_array_length(ndr, &r->in.server_unc));
18718 0 : NDR_CHECK(ndr_steal_array_size(ndr, (void*)&r->in.server_unc, &size_server_unc_1));
18719 0 : NDR_CHECK(ndr_steal_array_length(ndr, (void*)&r->in.server_unc, &length_server_unc_1));
18720 0 : if (length_server_unc_1 > size_server_unc_1) {
18721 0 : return ndr_pull_error(ndr, NDR_ERR_ARRAY_SIZE, "Bad array size %"PRIu32": should exceed array length %"PRIu32"", size_server_unc_1, length_server_unc_1);
18722 : }
18723 0 : NDR_CHECK(ndr_check_string_terminator(ndr, length_server_unc_1, sizeof(uint16_t)));
18724 0 : NDR_CHECK(ndr_pull_charset(ndr, NDR_SCALARS, &r->in.server_unc, length_server_unc_1, sizeof(uint16_t), CH_UTF16));
18725 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_server_unc_0, 0);
18726 : }
18727 0 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_transport));
18728 0 : if (_ptr_transport) {
18729 0 : NDR_PULL_ALLOC(ndr, r->in.transport);
18730 : } else {
18731 0 : r->in.transport = NULL;
18732 : }
18733 0 : if (r->in.transport) {
18734 0 : _mem_save_transport_0 = NDR_PULL_GET_MEM_CTX(ndr);
18735 0 : NDR_PULL_SET_MEM_CTX(ndr, r->in.transport, 0);
18736 0 : NDR_CHECK(ndr_pull_array_size(ndr, &r->in.transport));
18737 0 : NDR_CHECK(ndr_pull_array_length(ndr, &r->in.transport));
18738 0 : NDR_CHECK(ndr_steal_array_size(ndr, (void*)&r->in.transport, &size_transport_1));
18739 0 : NDR_CHECK(ndr_steal_array_length(ndr, (void*)&r->in.transport, &length_transport_1));
18740 0 : if (length_transport_1 > size_transport_1) {
18741 0 : return ndr_pull_error(ndr, NDR_ERR_ARRAY_SIZE, "Bad array size %"PRIu32": should exceed array length %"PRIu32"", size_transport_1, length_transport_1);
18742 : }
18743 0 : NDR_CHECK(ndr_check_string_terminator(ndr, length_transport_1, sizeof(uint16_t)));
18744 0 : NDR_CHECK(ndr_pull_charset(ndr, NDR_SCALARS, &r->in.transport, length_transport_1, sizeof(uint16_t), CH_UTF16));
18745 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_transport_0, 0);
18746 : }
18747 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->in.servicebits));
18748 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->in.updateimmediately));
18749 : }
18750 0 : if (flags & NDR_OUT) {
18751 : #ifdef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION
18752 : #endif /* FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION */
18753 0 : NDR_CHECK(ndr_pull_WERROR(ndr, NDR_SCALARS, &r->out.result));
18754 : }
18755 0 : return NDR_ERR_SUCCESS;
18756 : }
18757 :
18758 0 : _PUBLIC_ void ndr_print_srvsvc_NetSetServiceBits(struct ndr_print *ndr, const char *name, ndr_flags_type flags, const struct srvsvc_NetSetServiceBits *r)
18759 : {
18760 0 : ndr_print_struct(ndr, name, "srvsvc_NetSetServiceBits");
18761 0 : if (r == NULL) { ndr_print_null(ndr); return; }
18762 0 : ndr->depth++;
18763 0 : if (flags & NDR_SET_VALUES) {
18764 0 : ndr->flags |= LIBNDR_PRINT_SET_VALUES;
18765 : }
18766 0 : if (flags & NDR_IN) {
18767 0 : ndr_print_struct(ndr, "in", "srvsvc_NetSetServiceBits");
18768 0 : ndr->depth++;
18769 0 : ndr_print_ptr(ndr, "server_unc", r->in.server_unc);
18770 0 : ndr->depth++;
18771 0 : if (r->in.server_unc) {
18772 0 : ndr_print_string(ndr, "server_unc", r->in.server_unc);
18773 : }
18774 0 : ndr->depth--;
18775 0 : ndr_print_ptr(ndr, "transport", r->in.transport);
18776 0 : ndr->depth++;
18777 0 : if (r->in.transport) {
18778 0 : ndr_print_string(ndr, "transport", r->in.transport);
18779 : }
18780 0 : ndr->depth--;
18781 0 : ndr_print_uint32(ndr, "servicebits", r->in.servicebits);
18782 0 : ndr_print_uint32(ndr, "updateimmediately", r->in.updateimmediately);
18783 0 : ndr->depth--;
18784 : }
18785 0 : if (flags & NDR_OUT) {
18786 0 : ndr_print_struct(ndr, "out", "srvsvc_NetSetServiceBits");
18787 0 : ndr->depth++;
18788 0 : ndr_print_WERROR(ndr, "result", r->out.result);
18789 0 : ndr->depth--;
18790 : }
18791 0 : ndr->depth--;
18792 : }
18793 :
18794 0 : static enum ndr_err_code ndr_push_srvsvc_NetPathType(struct ndr_push *ndr, ndr_flags_type flags, const struct srvsvc_NetPathType *r)
18795 : {
18796 0 : NDR_PUSH_CHECK_FN_FLAGS(ndr, flags);
18797 0 : if (flags & NDR_IN) {
18798 0 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->in.server_unc));
18799 0 : if (r->in.server_unc) {
18800 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->in.server_unc, CH_UTF16)));
18801 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, 0));
18802 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->in.server_unc, CH_UTF16)));
18803 0 : NDR_CHECK(ndr_push_charset(ndr, NDR_SCALARS, r->in.server_unc, ndr_charset_length(r->in.server_unc, CH_UTF16), sizeof(uint16_t), CH_UTF16));
18804 : }
18805 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->in.path, CH_UTF16)));
18806 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, 0));
18807 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->in.path, CH_UTF16)));
18808 0 : NDR_CHECK(ndr_push_charset(ndr, NDR_SCALARS, r->in.path, ndr_charset_length(r->in.path, CH_UTF16), sizeof(uint16_t), CH_UTF16));
18809 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->in.pathflags));
18810 : }
18811 0 : if (flags & NDR_OUT) {
18812 0 : if (r->out.pathtype == NULL) {
18813 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
18814 : }
18815 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, *r->out.pathtype));
18816 0 : NDR_CHECK(ndr_push_WERROR(ndr, NDR_SCALARS, r->out.result));
18817 : }
18818 0 : return NDR_ERR_SUCCESS;
18819 : }
18820 :
18821 0 : static enum ndr_err_code ndr_pull_srvsvc_NetPathType(struct ndr_pull *ndr, ndr_flags_type flags, struct srvsvc_NetPathType *r)
18822 : {
18823 0 : uint32_t _ptr_server_unc;
18824 0 : uint32_t size_server_unc_1 = 0;
18825 0 : uint32_t length_server_unc_1 = 0;
18826 0 : uint32_t size_path_0 = 0;
18827 0 : uint32_t length_path_0 = 0;
18828 0 : TALLOC_CTX *_mem_save_server_unc_0 = NULL;
18829 0 : TALLOC_CTX *_mem_save_pathtype_0 = NULL;
18830 0 : NDR_PULL_CHECK_FN_FLAGS(ndr, flags);
18831 0 : if (flags & NDR_IN) {
18832 0 : NDR_ZERO_STRUCT(r->out);
18833 :
18834 0 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_server_unc));
18835 0 : if (_ptr_server_unc) {
18836 0 : NDR_PULL_ALLOC(ndr, r->in.server_unc);
18837 : } else {
18838 0 : r->in.server_unc = NULL;
18839 : }
18840 0 : if (r->in.server_unc) {
18841 0 : _mem_save_server_unc_0 = NDR_PULL_GET_MEM_CTX(ndr);
18842 0 : NDR_PULL_SET_MEM_CTX(ndr, r->in.server_unc, 0);
18843 0 : NDR_CHECK(ndr_pull_array_size(ndr, &r->in.server_unc));
18844 0 : NDR_CHECK(ndr_pull_array_length(ndr, &r->in.server_unc));
18845 0 : NDR_CHECK(ndr_steal_array_size(ndr, (void*)&r->in.server_unc, &size_server_unc_1));
18846 0 : NDR_CHECK(ndr_steal_array_length(ndr, (void*)&r->in.server_unc, &length_server_unc_1));
18847 0 : if (length_server_unc_1 > size_server_unc_1) {
18848 0 : return ndr_pull_error(ndr, NDR_ERR_ARRAY_SIZE, "Bad array size %"PRIu32": should exceed array length %"PRIu32"", size_server_unc_1, length_server_unc_1);
18849 : }
18850 0 : NDR_CHECK(ndr_check_string_terminator(ndr, length_server_unc_1, sizeof(uint16_t)));
18851 0 : NDR_CHECK(ndr_pull_charset(ndr, NDR_SCALARS, &r->in.server_unc, length_server_unc_1, sizeof(uint16_t), CH_UTF16));
18852 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_server_unc_0, 0);
18853 : }
18854 0 : NDR_CHECK(ndr_pull_array_size(ndr, &r->in.path));
18855 0 : NDR_CHECK(ndr_pull_array_length(ndr, &r->in.path));
18856 0 : NDR_CHECK(ndr_steal_array_size(ndr, (void*)&r->in.path, &size_path_0));
18857 0 : NDR_CHECK(ndr_steal_array_length(ndr, (void*)&r->in.path, &length_path_0));
18858 0 : if (length_path_0 > size_path_0) {
18859 0 : return ndr_pull_error(ndr, NDR_ERR_ARRAY_SIZE, "Bad array size %"PRIu32": should exceed array length %"PRIu32"", size_path_0, length_path_0);
18860 : }
18861 0 : NDR_CHECK(ndr_check_string_terminator(ndr, length_path_0, sizeof(uint16_t)));
18862 0 : NDR_CHECK(ndr_pull_charset(ndr, NDR_SCALARS, &r->in.path, length_path_0, sizeof(uint16_t), CH_UTF16));
18863 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->in.pathflags));
18864 0 : NDR_PULL_ALLOC(ndr, r->out.pathtype);
18865 0 : NDR_ZERO_STRUCTP(r->out.pathtype);
18866 : }
18867 0 : if (flags & NDR_OUT) {
18868 : #ifdef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION
18869 : #endif /* FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION */
18870 0 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
18871 0 : NDR_PULL_ALLOC(ndr, r->out.pathtype);
18872 : }
18873 0 : _mem_save_pathtype_0 = NDR_PULL_GET_MEM_CTX(ndr);
18874 0 : NDR_PULL_SET_MEM_CTX(ndr, r->out.pathtype, LIBNDR_FLAG_REF_ALLOC);
18875 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, r->out.pathtype));
18876 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_pathtype_0, LIBNDR_FLAG_REF_ALLOC);
18877 0 : NDR_CHECK(ndr_pull_WERROR(ndr, NDR_SCALARS, &r->out.result));
18878 : }
18879 0 : return NDR_ERR_SUCCESS;
18880 : }
18881 :
18882 0 : _PUBLIC_ void ndr_print_srvsvc_NetPathType(struct ndr_print *ndr, const char *name, ndr_flags_type flags, const struct srvsvc_NetPathType *r)
18883 : {
18884 0 : ndr_print_struct(ndr, name, "srvsvc_NetPathType");
18885 0 : if (r == NULL) { ndr_print_null(ndr); return; }
18886 0 : ndr->depth++;
18887 0 : if (flags & NDR_SET_VALUES) {
18888 0 : ndr->flags |= LIBNDR_PRINT_SET_VALUES;
18889 : }
18890 0 : if (flags & NDR_IN) {
18891 0 : ndr_print_struct(ndr, "in", "srvsvc_NetPathType");
18892 0 : ndr->depth++;
18893 0 : ndr_print_ptr(ndr, "server_unc", r->in.server_unc);
18894 0 : ndr->depth++;
18895 0 : if (r->in.server_unc) {
18896 0 : ndr_print_string(ndr, "server_unc", r->in.server_unc);
18897 : }
18898 0 : ndr->depth--;
18899 0 : ndr_print_string(ndr, "path", r->in.path);
18900 0 : ndr_print_uint32(ndr, "pathflags", r->in.pathflags);
18901 0 : ndr->depth--;
18902 : }
18903 0 : if (flags & NDR_OUT) {
18904 0 : ndr_print_struct(ndr, "out", "srvsvc_NetPathType");
18905 0 : ndr->depth++;
18906 0 : ndr_print_ptr(ndr, "pathtype", r->out.pathtype);
18907 0 : ndr->depth++;
18908 0 : ndr_print_uint32(ndr, "pathtype", *r->out.pathtype);
18909 0 : ndr->depth--;
18910 0 : ndr_print_WERROR(ndr, "result", r->out.result);
18911 0 : ndr->depth--;
18912 : }
18913 0 : ndr->depth--;
18914 : }
18915 :
18916 0 : static enum ndr_err_code ndr_push_srvsvc_NetPathCanonicalize(struct ndr_push *ndr, ndr_flags_type flags, const struct srvsvc_NetPathCanonicalize *r)
18917 : {
18918 0 : NDR_PUSH_CHECK_FN_FLAGS(ndr, flags);
18919 0 : if (flags & NDR_IN) {
18920 0 : if (r->in.pathtype == NULL) {
18921 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
18922 : }
18923 0 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->in.server_unc));
18924 0 : if (r->in.server_unc) {
18925 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->in.server_unc, CH_UTF16)));
18926 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, 0));
18927 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->in.server_unc, CH_UTF16)));
18928 0 : NDR_CHECK(ndr_push_charset(ndr, NDR_SCALARS, r->in.server_unc, ndr_charset_length(r->in.server_unc, CH_UTF16), sizeof(uint16_t), CH_UTF16));
18929 : }
18930 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->in.path, CH_UTF16)));
18931 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, 0));
18932 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->in.path, CH_UTF16)));
18933 0 : NDR_CHECK(ndr_push_charset(ndr, NDR_SCALARS, r->in.path, ndr_charset_length(r->in.path, CH_UTF16), sizeof(uint16_t), CH_UTF16));
18934 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->in.maxbuf));
18935 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->in.prefix, CH_UTF16)));
18936 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, 0));
18937 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->in.prefix, CH_UTF16)));
18938 0 : NDR_CHECK(ndr_push_charset(ndr, NDR_SCALARS, r->in.prefix, ndr_charset_length(r->in.prefix, CH_UTF16), sizeof(uint16_t), CH_UTF16));
18939 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, *r->in.pathtype));
18940 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->in.pathflags));
18941 : }
18942 0 : if (flags & NDR_OUT) {
18943 0 : if (r->out.pathtype == NULL) {
18944 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
18945 : }
18946 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, r->in.maxbuf));
18947 0 : NDR_CHECK(ndr_push_array_uint8(ndr, NDR_SCALARS, r->out.can_path, r->in.maxbuf));
18948 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, *r->out.pathtype));
18949 0 : NDR_CHECK(ndr_push_WERROR(ndr, NDR_SCALARS, r->out.result));
18950 : }
18951 0 : return NDR_ERR_SUCCESS;
18952 : }
18953 :
18954 0 : static enum ndr_err_code ndr_pull_srvsvc_NetPathCanonicalize(struct ndr_pull *ndr, ndr_flags_type flags, struct srvsvc_NetPathCanonicalize *r)
18955 : {
18956 0 : uint32_t _ptr_server_unc;
18957 0 : uint32_t size_server_unc_1 = 0;
18958 0 : uint32_t length_server_unc_1 = 0;
18959 0 : uint32_t size_path_0 = 0;
18960 0 : uint32_t length_path_0 = 0;
18961 0 : uint32_t size_can_path_0 = 0;
18962 0 : uint32_t size_prefix_0 = 0;
18963 0 : uint32_t length_prefix_0 = 0;
18964 0 : TALLOC_CTX *_mem_save_server_unc_0 = NULL;
18965 0 : TALLOC_CTX *_mem_save_pathtype_0 = NULL;
18966 0 : NDR_PULL_CHECK_FN_FLAGS(ndr, flags);
18967 0 : if (flags & NDR_IN) {
18968 0 : NDR_ZERO_STRUCT(r->out);
18969 :
18970 0 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_server_unc));
18971 0 : if (_ptr_server_unc) {
18972 0 : NDR_PULL_ALLOC(ndr, r->in.server_unc);
18973 : } else {
18974 0 : r->in.server_unc = NULL;
18975 : }
18976 0 : if (r->in.server_unc) {
18977 0 : _mem_save_server_unc_0 = NDR_PULL_GET_MEM_CTX(ndr);
18978 0 : NDR_PULL_SET_MEM_CTX(ndr, r->in.server_unc, 0);
18979 0 : NDR_CHECK(ndr_pull_array_size(ndr, &r->in.server_unc));
18980 0 : NDR_CHECK(ndr_pull_array_length(ndr, &r->in.server_unc));
18981 0 : NDR_CHECK(ndr_steal_array_size(ndr, (void*)&r->in.server_unc, &size_server_unc_1));
18982 0 : NDR_CHECK(ndr_steal_array_length(ndr, (void*)&r->in.server_unc, &length_server_unc_1));
18983 0 : if (length_server_unc_1 > size_server_unc_1) {
18984 0 : return ndr_pull_error(ndr, NDR_ERR_ARRAY_SIZE, "Bad array size %"PRIu32": should exceed array length %"PRIu32"", size_server_unc_1, length_server_unc_1);
18985 : }
18986 0 : NDR_CHECK(ndr_check_string_terminator(ndr, length_server_unc_1, sizeof(uint16_t)));
18987 0 : NDR_CHECK(ndr_pull_charset(ndr, NDR_SCALARS, &r->in.server_unc, length_server_unc_1, sizeof(uint16_t), CH_UTF16));
18988 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_server_unc_0, 0);
18989 : }
18990 0 : NDR_CHECK(ndr_pull_array_size(ndr, &r->in.path));
18991 0 : NDR_CHECK(ndr_pull_array_length(ndr, &r->in.path));
18992 0 : NDR_CHECK(ndr_steal_array_size(ndr, (void*)&r->in.path, &size_path_0));
18993 0 : NDR_CHECK(ndr_steal_array_length(ndr, (void*)&r->in.path, &length_path_0));
18994 0 : if (length_path_0 > size_path_0) {
18995 0 : return ndr_pull_error(ndr, NDR_ERR_ARRAY_SIZE, "Bad array size %"PRIu32": should exceed array length %"PRIu32"", size_path_0, length_path_0);
18996 : }
18997 0 : NDR_CHECK(ndr_check_string_terminator(ndr, length_path_0, sizeof(uint16_t)));
18998 0 : NDR_CHECK(ndr_pull_charset(ndr, NDR_SCALARS, &r->in.path, length_path_0, sizeof(uint16_t), CH_UTF16));
18999 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->in.maxbuf));
19000 0 : NDR_CHECK(ndr_pull_array_size(ndr, &r->in.prefix));
19001 0 : NDR_CHECK(ndr_pull_array_length(ndr, &r->in.prefix));
19002 0 : NDR_CHECK(ndr_steal_array_size(ndr, (void*)&r->in.prefix, &size_prefix_0));
19003 0 : NDR_CHECK(ndr_steal_array_length(ndr, (void*)&r->in.prefix, &length_prefix_0));
19004 0 : if (length_prefix_0 > size_prefix_0) {
19005 0 : return ndr_pull_error(ndr, NDR_ERR_ARRAY_SIZE, "Bad array size %"PRIu32": should exceed array length %"PRIu32"", size_prefix_0, length_prefix_0);
19006 : }
19007 0 : NDR_CHECK(ndr_check_string_terminator(ndr, length_prefix_0, sizeof(uint16_t)));
19008 0 : NDR_CHECK(ndr_pull_charset(ndr, NDR_SCALARS, &r->in.prefix, length_prefix_0, sizeof(uint16_t), CH_UTF16));
19009 0 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
19010 0 : NDR_PULL_ALLOC(ndr, r->in.pathtype);
19011 : }
19012 0 : _mem_save_pathtype_0 = NDR_PULL_GET_MEM_CTX(ndr);
19013 0 : NDR_PULL_SET_MEM_CTX(ndr, r->in.pathtype, LIBNDR_FLAG_REF_ALLOC);
19014 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, r->in.pathtype));
19015 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_pathtype_0, LIBNDR_FLAG_REF_ALLOC);
19016 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->in.pathflags));
19017 0 : NDR_PULL_ALLOC(ndr, r->out.pathtype);
19018 0 : *r->out.pathtype = *r->in.pathtype;
19019 : }
19020 0 : if (flags & NDR_OUT) {
19021 : #ifdef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION
19022 : if (r->in.pathtype == NULL) {
19023 : NDR_PULL_ALLOC(ndr, r->in.pathtype);
19024 : NDR_ZERO_STRUCTP(r->in.pathtype);
19025 : }
19026 : #endif /* FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION */
19027 0 : NDR_CHECK(ndr_pull_array_size(ndr, &r->out.can_path));
19028 0 : NDR_CHECK(ndr_get_array_size(ndr, (void*)&r->out.can_path, &size_can_path_0));
19029 0 : NDR_PULL_ALLOC_N(ndr, r->out.can_path, size_can_path_0);
19030 0 : NDR_CHECK(ndr_pull_array_uint8(ndr, NDR_SCALARS, r->out.can_path, size_can_path_0));
19031 0 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
19032 0 : NDR_PULL_ALLOC(ndr, r->out.pathtype);
19033 : }
19034 0 : _mem_save_pathtype_0 = NDR_PULL_GET_MEM_CTX(ndr);
19035 0 : NDR_PULL_SET_MEM_CTX(ndr, r->out.pathtype, LIBNDR_FLAG_REF_ALLOC);
19036 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, r->out.pathtype));
19037 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_pathtype_0, LIBNDR_FLAG_REF_ALLOC);
19038 0 : NDR_CHECK(ndr_pull_WERROR(ndr, NDR_SCALARS, &r->out.result));
19039 0 : if (r->out.can_path) {
19040 0 : NDR_CHECK(ndr_check_steal_array_size(ndr, (void*)&r->out.can_path, r->in.maxbuf));
19041 : }
19042 : }
19043 0 : return NDR_ERR_SUCCESS;
19044 : }
19045 :
19046 0 : _PUBLIC_ void ndr_print_srvsvc_NetPathCanonicalize(struct ndr_print *ndr, const char *name, ndr_flags_type flags, const struct srvsvc_NetPathCanonicalize *r)
19047 : {
19048 0 : ndr_print_struct(ndr, name, "srvsvc_NetPathCanonicalize");
19049 0 : if (r == NULL) { ndr_print_null(ndr); return; }
19050 0 : ndr->depth++;
19051 0 : if (flags & NDR_SET_VALUES) {
19052 0 : ndr->flags |= LIBNDR_PRINT_SET_VALUES;
19053 : }
19054 0 : if (flags & NDR_IN) {
19055 0 : ndr_print_struct(ndr, "in", "srvsvc_NetPathCanonicalize");
19056 0 : ndr->depth++;
19057 0 : ndr_print_ptr(ndr, "server_unc", r->in.server_unc);
19058 0 : ndr->depth++;
19059 0 : if (r->in.server_unc) {
19060 0 : ndr_print_string(ndr, "server_unc", r->in.server_unc);
19061 : }
19062 0 : ndr->depth--;
19063 0 : ndr_print_string(ndr, "path", r->in.path);
19064 0 : ndr_print_uint32(ndr, "maxbuf", r->in.maxbuf);
19065 0 : ndr_print_string(ndr, "prefix", r->in.prefix);
19066 0 : ndr_print_ptr(ndr, "pathtype", r->in.pathtype);
19067 0 : ndr->depth++;
19068 0 : ndr_print_uint32(ndr, "pathtype", *r->in.pathtype);
19069 0 : ndr->depth--;
19070 0 : ndr_print_uint32(ndr, "pathflags", r->in.pathflags);
19071 0 : ndr->depth--;
19072 : }
19073 0 : if (flags & NDR_OUT) {
19074 0 : ndr_print_struct(ndr, "out", "srvsvc_NetPathCanonicalize");
19075 0 : ndr->depth++;
19076 0 : ndr_print_array_uint8(ndr, "can_path", r->out.can_path, r->in.maxbuf);
19077 0 : ndr_print_ptr(ndr, "pathtype", r->out.pathtype);
19078 0 : ndr->depth++;
19079 0 : ndr_print_uint32(ndr, "pathtype", *r->out.pathtype);
19080 0 : ndr->depth--;
19081 0 : ndr_print_WERROR(ndr, "result", r->out.result);
19082 0 : ndr->depth--;
19083 : }
19084 0 : ndr->depth--;
19085 : }
19086 :
19087 0 : static enum ndr_err_code ndr_push_srvsvc_NetPathCompare(struct ndr_push *ndr, ndr_flags_type flags, const struct srvsvc_NetPathCompare *r)
19088 : {
19089 0 : NDR_PUSH_CHECK_FN_FLAGS(ndr, flags);
19090 0 : if (flags & NDR_IN) {
19091 0 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->in.server_unc));
19092 0 : if (r->in.server_unc) {
19093 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->in.server_unc, CH_UTF16)));
19094 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, 0));
19095 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->in.server_unc, CH_UTF16)));
19096 0 : NDR_CHECK(ndr_push_charset(ndr, NDR_SCALARS, r->in.server_unc, ndr_charset_length(r->in.server_unc, CH_UTF16), sizeof(uint16_t), CH_UTF16));
19097 : }
19098 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->in.path1, CH_UTF16)));
19099 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, 0));
19100 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->in.path1, CH_UTF16)));
19101 0 : NDR_CHECK(ndr_push_charset(ndr, NDR_SCALARS, r->in.path1, ndr_charset_length(r->in.path1, CH_UTF16), sizeof(uint16_t), CH_UTF16));
19102 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->in.path2, CH_UTF16)));
19103 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, 0));
19104 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->in.path2, CH_UTF16)));
19105 0 : NDR_CHECK(ndr_push_charset(ndr, NDR_SCALARS, r->in.path2, ndr_charset_length(r->in.path2, CH_UTF16), sizeof(uint16_t), CH_UTF16));
19106 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->in.pathtype));
19107 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->in.pathflags));
19108 : }
19109 0 : if (flags & NDR_OUT) {
19110 0 : NDR_CHECK(ndr_push_WERROR(ndr, NDR_SCALARS, r->out.result));
19111 : }
19112 0 : return NDR_ERR_SUCCESS;
19113 : }
19114 :
19115 0 : static enum ndr_err_code ndr_pull_srvsvc_NetPathCompare(struct ndr_pull *ndr, ndr_flags_type flags, struct srvsvc_NetPathCompare *r)
19116 : {
19117 0 : uint32_t _ptr_server_unc;
19118 0 : uint32_t size_server_unc_1 = 0;
19119 0 : uint32_t length_server_unc_1 = 0;
19120 0 : uint32_t size_path1_0 = 0;
19121 0 : uint32_t length_path1_0 = 0;
19122 0 : uint32_t size_path2_0 = 0;
19123 0 : uint32_t length_path2_0 = 0;
19124 0 : TALLOC_CTX *_mem_save_server_unc_0 = NULL;
19125 0 : NDR_PULL_CHECK_FN_FLAGS(ndr, flags);
19126 0 : if (flags & NDR_IN) {
19127 0 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_server_unc));
19128 0 : if (_ptr_server_unc) {
19129 0 : NDR_PULL_ALLOC(ndr, r->in.server_unc);
19130 : } else {
19131 0 : r->in.server_unc = NULL;
19132 : }
19133 0 : if (r->in.server_unc) {
19134 0 : _mem_save_server_unc_0 = NDR_PULL_GET_MEM_CTX(ndr);
19135 0 : NDR_PULL_SET_MEM_CTX(ndr, r->in.server_unc, 0);
19136 0 : NDR_CHECK(ndr_pull_array_size(ndr, &r->in.server_unc));
19137 0 : NDR_CHECK(ndr_pull_array_length(ndr, &r->in.server_unc));
19138 0 : NDR_CHECK(ndr_steal_array_size(ndr, (void*)&r->in.server_unc, &size_server_unc_1));
19139 0 : NDR_CHECK(ndr_steal_array_length(ndr, (void*)&r->in.server_unc, &length_server_unc_1));
19140 0 : if (length_server_unc_1 > size_server_unc_1) {
19141 0 : return ndr_pull_error(ndr, NDR_ERR_ARRAY_SIZE, "Bad array size %"PRIu32": should exceed array length %"PRIu32"", size_server_unc_1, length_server_unc_1);
19142 : }
19143 0 : NDR_CHECK(ndr_check_string_terminator(ndr, length_server_unc_1, sizeof(uint16_t)));
19144 0 : NDR_CHECK(ndr_pull_charset(ndr, NDR_SCALARS, &r->in.server_unc, length_server_unc_1, sizeof(uint16_t), CH_UTF16));
19145 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_server_unc_0, 0);
19146 : }
19147 0 : NDR_CHECK(ndr_pull_array_size(ndr, &r->in.path1));
19148 0 : NDR_CHECK(ndr_pull_array_length(ndr, &r->in.path1));
19149 0 : NDR_CHECK(ndr_steal_array_size(ndr, (void*)&r->in.path1, &size_path1_0));
19150 0 : NDR_CHECK(ndr_steal_array_length(ndr, (void*)&r->in.path1, &length_path1_0));
19151 0 : if (length_path1_0 > size_path1_0) {
19152 0 : return ndr_pull_error(ndr, NDR_ERR_ARRAY_SIZE, "Bad array size %"PRIu32": should exceed array length %"PRIu32"", size_path1_0, length_path1_0);
19153 : }
19154 0 : NDR_CHECK(ndr_check_string_terminator(ndr, length_path1_0, sizeof(uint16_t)));
19155 0 : NDR_CHECK(ndr_pull_charset(ndr, NDR_SCALARS, &r->in.path1, length_path1_0, sizeof(uint16_t), CH_UTF16));
19156 0 : NDR_CHECK(ndr_pull_array_size(ndr, &r->in.path2));
19157 0 : NDR_CHECK(ndr_pull_array_length(ndr, &r->in.path2));
19158 0 : NDR_CHECK(ndr_steal_array_size(ndr, (void*)&r->in.path2, &size_path2_0));
19159 0 : NDR_CHECK(ndr_steal_array_length(ndr, (void*)&r->in.path2, &length_path2_0));
19160 0 : if (length_path2_0 > size_path2_0) {
19161 0 : return ndr_pull_error(ndr, NDR_ERR_ARRAY_SIZE, "Bad array size %"PRIu32": should exceed array length %"PRIu32"", size_path2_0, length_path2_0);
19162 : }
19163 0 : NDR_CHECK(ndr_check_string_terminator(ndr, length_path2_0, sizeof(uint16_t)));
19164 0 : NDR_CHECK(ndr_pull_charset(ndr, NDR_SCALARS, &r->in.path2, length_path2_0, sizeof(uint16_t), CH_UTF16));
19165 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->in.pathtype));
19166 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->in.pathflags));
19167 : }
19168 0 : if (flags & NDR_OUT) {
19169 : #ifdef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION
19170 : #endif /* FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION */
19171 0 : NDR_CHECK(ndr_pull_WERROR(ndr, NDR_SCALARS, &r->out.result));
19172 : }
19173 0 : return NDR_ERR_SUCCESS;
19174 : }
19175 :
19176 0 : _PUBLIC_ void ndr_print_srvsvc_NetPathCompare(struct ndr_print *ndr, const char *name, ndr_flags_type flags, const struct srvsvc_NetPathCompare *r)
19177 : {
19178 0 : ndr_print_struct(ndr, name, "srvsvc_NetPathCompare");
19179 0 : if (r == NULL) { ndr_print_null(ndr); return; }
19180 0 : ndr->depth++;
19181 0 : if (flags & NDR_SET_VALUES) {
19182 0 : ndr->flags |= LIBNDR_PRINT_SET_VALUES;
19183 : }
19184 0 : if (flags & NDR_IN) {
19185 0 : ndr_print_struct(ndr, "in", "srvsvc_NetPathCompare");
19186 0 : ndr->depth++;
19187 0 : ndr_print_ptr(ndr, "server_unc", r->in.server_unc);
19188 0 : ndr->depth++;
19189 0 : if (r->in.server_unc) {
19190 0 : ndr_print_string(ndr, "server_unc", r->in.server_unc);
19191 : }
19192 0 : ndr->depth--;
19193 0 : ndr_print_string(ndr, "path1", r->in.path1);
19194 0 : ndr_print_string(ndr, "path2", r->in.path2);
19195 0 : ndr_print_uint32(ndr, "pathtype", r->in.pathtype);
19196 0 : ndr_print_uint32(ndr, "pathflags", r->in.pathflags);
19197 0 : ndr->depth--;
19198 : }
19199 0 : if (flags & NDR_OUT) {
19200 0 : ndr_print_struct(ndr, "out", "srvsvc_NetPathCompare");
19201 0 : ndr->depth++;
19202 0 : ndr_print_WERROR(ndr, "result", r->out.result);
19203 0 : ndr->depth--;
19204 : }
19205 0 : ndr->depth--;
19206 : }
19207 :
19208 47528 : static enum ndr_err_code ndr_push_srvsvc_NetNameValidate(struct ndr_push *ndr, ndr_flags_type flags, const struct srvsvc_NetNameValidate *r)
19209 : {
19210 47528 : NDR_PUSH_CHECK_FN_FLAGS(ndr, flags);
19211 47528 : if (flags & NDR_IN) {
19212 22360 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->in.server_unc));
19213 22360 : if (r->in.server_unc) {
19214 22360 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->in.server_unc, CH_UTF16)));
19215 22360 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, 0));
19216 22360 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->in.server_unc, CH_UTF16)));
19217 22360 : NDR_CHECK(ndr_push_charset(ndr, NDR_SCALARS, r->in.server_unc, ndr_charset_length(r->in.server_unc, CH_UTF16), sizeof(uint16_t), CH_UTF16));
19218 : }
19219 22360 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->in.name, CH_UTF16)));
19220 22360 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, 0));
19221 22360 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->in.name, CH_UTF16)));
19222 22360 : NDR_CHECK(ndr_push_charset(ndr, NDR_SCALARS, r->in.name, ndr_charset_length(r->in.name, CH_UTF16), sizeof(uint16_t), CH_UTF16));
19223 22360 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->in.name_type));
19224 22360 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->in.flags));
19225 : }
19226 47528 : if (flags & NDR_OUT) {
19227 25168 : NDR_CHECK(ndr_push_WERROR(ndr, NDR_SCALARS, r->out.result));
19228 : }
19229 47528 : return NDR_ERR_SUCCESS;
19230 : }
19231 :
19232 44720 : static enum ndr_err_code ndr_pull_srvsvc_NetNameValidate(struct ndr_pull *ndr, ndr_flags_type flags, struct srvsvc_NetNameValidate *r)
19233 : {
19234 0 : uint32_t _ptr_server_unc;
19235 44720 : uint32_t size_server_unc_1 = 0;
19236 44720 : uint32_t length_server_unc_1 = 0;
19237 44720 : uint32_t size_name_0 = 0;
19238 44720 : uint32_t length_name_0 = 0;
19239 44720 : TALLOC_CTX *_mem_save_server_unc_0 = NULL;
19240 44720 : NDR_PULL_CHECK_FN_FLAGS(ndr, flags);
19241 44720 : if (flags & NDR_IN) {
19242 22360 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_server_unc));
19243 22360 : if (_ptr_server_unc) {
19244 22360 : NDR_PULL_ALLOC(ndr, r->in.server_unc);
19245 : } else {
19246 0 : r->in.server_unc = NULL;
19247 : }
19248 22360 : if (r->in.server_unc) {
19249 22360 : _mem_save_server_unc_0 = NDR_PULL_GET_MEM_CTX(ndr);
19250 22360 : NDR_PULL_SET_MEM_CTX(ndr, r->in.server_unc, 0);
19251 22360 : NDR_CHECK(ndr_pull_array_size(ndr, &r->in.server_unc));
19252 22360 : NDR_CHECK(ndr_pull_array_length(ndr, &r->in.server_unc));
19253 22360 : NDR_CHECK(ndr_steal_array_size(ndr, (void*)&r->in.server_unc, &size_server_unc_1));
19254 22360 : NDR_CHECK(ndr_steal_array_length(ndr, (void*)&r->in.server_unc, &length_server_unc_1));
19255 22360 : if (length_server_unc_1 > size_server_unc_1) {
19256 0 : return ndr_pull_error(ndr, NDR_ERR_ARRAY_SIZE, "Bad array size %"PRIu32": should exceed array length %"PRIu32"", size_server_unc_1, length_server_unc_1);
19257 : }
19258 22360 : NDR_CHECK(ndr_check_string_terminator(ndr, length_server_unc_1, sizeof(uint16_t)));
19259 22360 : NDR_CHECK(ndr_pull_charset(ndr, NDR_SCALARS, &r->in.server_unc, length_server_unc_1, sizeof(uint16_t), CH_UTF16));
19260 22360 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_server_unc_0, 0);
19261 : }
19262 22360 : NDR_CHECK(ndr_pull_array_size(ndr, &r->in.name));
19263 22360 : NDR_CHECK(ndr_pull_array_length(ndr, &r->in.name));
19264 22360 : NDR_CHECK(ndr_steal_array_size(ndr, (void*)&r->in.name, &size_name_0));
19265 22360 : NDR_CHECK(ndr_steal_array_length(ndr, (void*)&r->in.name, &length_name_0));
19266 22360 : if (length_name_0 > size_name_0) {
19267 0 : return ndr_pull_error(ndr, NDR_ERR_ARRAY_SIZE, "Bad array size %"PRIu32": should exceed array length %"PRIu32"", size_name_0, length_name_0);
19268 : }
19269 22360 : NDR_CHECK(ndr_check_string_terminator(ndr, length_name_0, sizeof(uint16_t)));
19270 22360 : NDR_CHECK(ndr_pull_charset(ndr, NDR_SCALARS, &r->in.name, length_name_0, sizeof(uint16_t), CH_UTF16));
19271 22360 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->in.name_type));
19272 22360 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->in.flags));
19273 : }
19274 44720 : if (flags & NDR_OUT) {
19275 : #ifdef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION
19276 : #endif /* FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION */
19277 22360 : NDR_CHECK(ndr_pull_WERROR(ndr, NDR_SCALARS, &r->out.result));
19278 : }
19279 44720 : return NDR_ERR_SUCCESS;
19280 : }
19281 :
19282 5616 : _PUBLIC_ void ndr_print_srvsvc_NetNameValidate(struct ndr_print *ndr, const char *name, ndr_flags_type flags, const struct srvsvc_NetNameValidate *r)
19283 : {
19284 5616 : ndr_print_struct(ndr, name, "srvsvc_NetNameValidate");
19285 5616 : if (r == NULL) { ndr_print_null(ndr); return; }
19286 5616 : ndr->depth++;
19287 5616 : if (flags & NDR_SET_VALUES) {
19288 0 : ndr->flags |= LIBNDR_PRINT_SET_VALUES;
19289 : }
19290 5616 : if (flags & NDR_IN) {
19291 0 : ndr_print_struct(ndr, "in", "srvsvc_NetNameValidate");
19292 0 : ndr->depth++;
19293 0 : ndr_print_ptr(ndr, "server_unc", r->in.server_unc);
19294 0 : ndr->depth++;
19295 0 : if (r->in.server_unc) {
19296 0 : ndr_print_string(ndr, "server_unc", r->in.server_unc);
19297 : }
19298 0 : ndr->depth--;
19299 0 : ndr_print_string(ndr, "name", r->in.name);
19300 0 : ndr_print_uint32(ndr, "name_type", r->in.name_type);
19301 0 : ndr_print_uint32(ndr, "flags", r->in.flags);
19302 0 : ndr->depth--;
19303 : }
19304 5616 : if (flags & NDR_OUT) {
19305 5616 : ndr_print_struct(ndr, "out", "srvsvc_NetNameValidate");
19306 5616 : ndr->depth++;
19307 5616 : ndr_print_WERROR(ndr, "result", r->out.result);
19308 5616 : ndr->depth--;
19309 : }
19310 5616 : ndr->depth--;
19311 : }
19312 :
19313 0 : static enum ndr_err_code ndr_push_srvsvc_NETRPRNAMECANONICALIZE(struct ndr_push *ndr, ndr_flags_type flags, const struct srvsvc_NETRPRNAMECANONICALIZE *r)
19314 : {
19315 0 : NDR_PUSH_CHECK_FN_FLAGS(ndr, flags);
19316 0 : if (flags & NDR_IN) {
19317 0 : }
19318 0 : if (flags & NDR_OUT) {
19319 0 : NDR_CHECK(ndr_push_WERROR(ndr, NDR_SCALARS, r->out.result));
19320 : }
19321 0 : return NDR_ERR_SUCCESS;
19322 : }
19323 :
19324 0 : static enum ndr_err_code ndr_pull_srvsvc_NETRPRNAMECANONICALIZE(struct ndr_pull *ndr, ndr_flags_type flags, struct srvsvc_NETRPRNAMECANONICALIZE *r)
19325 : {
19326 0 : NDR_PULL_CHECK_FN_FLAGS(ndr, flags);
19327 0 : if (flags & NDR_IN) {
19328 0 : }
19329 0 : if (flags & NDR_OUT) {
19330 : #ifdef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION
19331 : #endif /* FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION */
19332 0 : NDR_CHECK(ndr_pull_WERROR(ndr, NDR_SCALARS, &r->out.result));
19333 : }
19334 0 : return NDR_ERR_SUCCESS;
19335 : }
19336 :
19337 0 : _PUBLIC_ void ndr_print_srvsvc_NETRPRNAMECANONICALIZE(struct ndr_print *ndr, const char *name, ndr_flags_type flags, const struct srvsvc_NETRPRNAMECANONICALIZE *r)
19338 : {
19339 0 : ndr_print_struct(ndr, name, "srvsvc_NETRPRNAMECANONICALIZE");
19340 0 : if (r == NULL) { ndr_print_null(ndr); return; }
19341 0 : ndr->depth++;
19342 0 : if (flags & NDR_SET_VALUES) {
19343 0 : ndr->flags |= LIBNDR_PRINT_SET_VALUES;
19344 : }
19345 0 : if (flags & NDR_IN) {
19346 0 : ndr_print_struct(ndr, "in", "srvsvc_NETRPRNAMECANONICALIZE");
19347 0 : ndr->depth++;
19348 0 : ndr->depth--;
19349 : }
19350 0 : if (flags & NDR_OUT) {
19351 0 : ndr_print_struct(ndr, "out", "srvsvc_NETRPRNAMECANONICALIZE");
19352 0 : ndr->depth++;
19353 0 : ndr_print_WERROR(ndr, "result", r->out.result);
19354 0 : ndr->depth--;
19355 : }
19356 0 : ndr->depth--;
19357 : }
19358 :
19359 0 : static enum ndr_err_code ndr_push_srvsvc_NetPRNameCompare(struct ndr_push *ndr, ndr_flags_type flags, const struct srvsvc_NetPRNameCompare *r)
19360 : {
19361 0 : NDR_PUSH_CHECK_FN_FLAGS(ndr, flags);
19362 0 : if (flags & NDR_IN) {
19363 0 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->in.server_unc));
19364 0 : if (r->in.server_unc) {
19365 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->in.server_unc, CH_UTF16)));
19366 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, 0));
19367 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->in.server_unc, CH_UTF16)));
19368 0 : NDR_CHECK(ndr_push_charset(ndr, NDR_SCALARS, r->in.server_unc, ndr_charset_length(r->in.server_unc, CH_UTF16), sizeof(uint16_t), CH_UTF16));
19369 : }
19370 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->in.name1, CH_UTF16)));
19371 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, 0));
19372 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->in.name1, CH_UTF16)));
19373 0 : NDR_CHECK(ndr_push_charset(ndr, NDR_SCALARS, r->in.name1, ndr_charset_length(r->in.name1, CH_UTF16), sizeof(uint16_t), CH_UTF16));
19374 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->in.name2, CH_UTF16)));
19375 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, 0));
19376 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->in.name2, CH_UTF16)));
19377 0 : NDR_CHECK(ndr_push_charset(ndr, NDR_SCALARS, r->in.name2, ndr_charset_length(r->in.name2, CH_UTF16), sizeof(uint16_t), CH_UTF16));
19378 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->in.name_type));
19379 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->in.flags));
19380 : }
19381 0 : if (flags & NDR_OUT) {
19382 0 : NDR_CHECK(ndr_push_WERROR(ndr, NDR_SCALARS, r->out.result));
19383 : }
19384 0 : return NDR_ERR_SUCCESS;
19385 : }
19386 :
19387 0 : static enum ndr_err_code ndr_pull_srvsvc_NetPRNameCompare(struct ndr_pull *ndr, ndr_flags_type flags, struct srvsvc_NetPRNameCompare *r)
19388 : {
19389 0 : uint32_t _ptr_server_unc;
19390 0 : uint32_t size_server_unc_1 = 0;
19391 0 : uint32_t length_server_unc_1 = 0;
19392 0 : uint32_t size_name1_0 = 0;
19393 0 : uint32_t length_name1_0 = 0;
19394 0 : uint32_t size_name2_0 = 0;
19395 0 : uint32_t length_name2_0 = 0;
19396 0 : TALLOC_CTX *_mem_save_server_unc_0 = NULL;
19397 0 : NDR_PULL_CHECK_FN_FLAGS(ndr, flags);
19398 0 : if (flags & NDR_IN) {
19399 0 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_server_unc));
19400 0 : if (_ptr_server_unc) {
19401 0 : NDR_PULL_ALLOC(ndr, r->in.server_unc);
19402 : } else {
19403 0 : r->in.server_unc = NULL;
19404 : }
19405 0 : if (r->in.server_unc) {
19406 0 : _mem_save_server_unc_0 = NDR_PULL_GET_MEM_CTX(ndr);
19407 0 : NDR_PULL_SET_MEM_CTX(ndr, r->in.server_unc, 0);
19408 0 : NDR_CHECK(ndr_pull_array_size(ndr, &r->in.server_unc));
19409 0 : NDR_CHECK(ndr_pull_array_length(ndr, &r->in.server_unc));
19410 0 : NDR_CHECK(ndr_steal_array_size(ndr, (void*)&r->in.server_unc, &size_server_unc_1));
19411 0 : NDR_CHECK(ndr_steal_array_length(ndr, (void*)&r->in.server_unc, &length_server_unc_1));
19412 0 : if (length_server_unc_1 > size_server_unc_1) {
19413 0 : return ndr_pull_error(ndr, NDR_ERR_ARRAY_SIZE, "Bad array size %"PRIu32": should exceed array length %"PRIu32"", size_server_unc_1, length_server_unc_1);
19414 : }
19415 0 : NDR_CHECK(ndr_check_string_terminator(ndr, length_server_unc_1, sizeof(uint16_t)));
19416 0 : NDR_CHECK(ndr_pull_charset(ndr, NDR_SCALARS, &r->in.server_unc, length_server_unc_1, sizeof(uint16_t), CH_UTF16));
19417 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_server_unc_0, 0);
19418 : }
19419 0 : NDR_CHECK(ndr_pull_array_size(ndr, &r->in.name1));
19420 0 : NDR_CHECK(ndr_pull_array_length(ndr, &r->in.name1));
19421 0 : NDR_CHECK(ndr_steal_array_size(ndr, (void*)&r->in.name1, &size_name1_0));
19422 0 : NDR_CHECK(ndr_steal_array_length(ndr, (void*)&r->in.name1, &length_name1_0));
19423 0 : if (length_name1_0 > size_name1_0) {
19424 0 : return ndr_pull_error(ndr, NDR_ERR_ARRAY_SIZE, "Bad array size %"PRIu32": should exceed array length %"PRIu32"", size_name1_0, length_name1_0);
19425 : }
19426 0 : NDR_CHECK(ndr_check_string_terminator(ndr, length_name1_0, sizeof(uint16_t)));
19427 0 : NDR_CHECK(ndr_pull_charset(ndr, NDR_SCALARS, &r->in.name1, length_name1_0, sizeof(uint16_t), CH_UTF16));
19428 0 : NDR_CHECK(ndr_pull_array_size(ndr, &r->in.name2));
19429 0 : NDR_CHECK(ndr_pull_array_length(ndr, &r->in.name2));
19430 0 : NDR_CHECK(ndr_steal_array_size(ndr, (void*)&r->in.name2, &size_name2_0));
19431 0 : NDR_CHECK(ndr_steal_array_length(ndr, (void*)&r->in.name2, &length_name2_0));
19432 0 : if (length_name2_0 > size_name2_0) {
19433 0 : return ndr_pull_error(ndr, NDR_ERR_ARRAY_SIZE, "Bad array size %"PRIu32": should exceed array length %"PRIu32"", size_name2_0, length_name2_0);
19434 : }
19435 0 : NDR_CHECK(ndr_check_string_terminator(ndr, length_name2_0, sizeof(uint16_t)));
19436 0 : NDR_CHECK(ndr_pull_charset(ndr, NDR_SCALARS, &r->in.name2, length_name2_0, sizeof(uint16_t), CH_UTF16));
19437 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->in.name_type));
19438 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->in.flags));
19439 : }
19440 0 : if (flags & NDR_OUT) {
19441 : #ifdef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION
19442 : #endif /* FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION */
19443 0 : NDR_CHECK(ndr_pull_WERROR(ndr, NDR_SCALARS, &r->out.result));
19444 : }
19445 0 : return NDR_ERR_SUCCESS;
19446 : }
19447 :
19448 0 : _PUBLIC_ void ndr_print_srvsvc_NetPRNameCompare(struct ndr_print *ndr, const char *name, ndr_flags_type flags, const struct srvsvc_NetPRNameCompare *r)
19449 : {
19450 0 : ndr_print_struct(ndr, name, "srvsvc_NetPRNameCompare");
19451 0 : if (r == NULL) { ndr_print_null(ndr); return; }
19452 0 : ndr->depth++;
19453 0 : if (flags & NDR_SET_VALUES) {
19454 0 : ndr->flags |= LIBNDR_PRINT_SET_VALUES;
19455 : }
19456 0 : if (flags & NDR_IN) {
19457 0 : ndr_print_struct(ndr, "in", "srvsvc_NetPRNameCompare");
19458 0 : ndr->depth++;
19459 0 : ndr_print_ptr(ndr, "server_unc", r->in.server_unc);
19460 0 : ndr->depth++;
19461 0 : if (r->in.server_unc) {
19462 0 : ndr_print_string(ndr, "server_unc", r->in.server_unc);
19463 : }
19464 0 : ndr->depth--;
19465 0 : ndr_print_string(ndr, "name1", r->in.name1);
19466 0 : ndr_print_string(ndr, "name2", r->in.name2);
19467 0 : ndr_print_uint32(ndr, "name_type", r->in.name_type);
19468 0 : ndr_print_uint32(ndr, "flags", r->in.flags);
19469 0 : ndr->depth--;
19470 : }
19471 0 : if (flags & NDR_OUT) {
19472 0 : ndr_print_struct(ndr, "out", "srvsvc_NetPRNameCompare");
19473 0 : ndr->depth++;
19474 0 : ndr_print_WERROR(ndr, "result", r->out.result);
19475 0 : ndr->depth--;
19476 : }
19477 0 : ndr->depth--;
19478 : }
19479 :
19480 238 : static enum ndr_err_code ndr_push_srvsvc_NetShareEnum(struct ndr_push *ndr, ndr_flags_type flags, const struct srvsvc_NetShareEnum *r)
19481 : {
19482 238 : NDR_PUSH_CHECK_FN_FLAGS(ndr, flags);
19483 238 : if (flags & NDR_IN) {
19484 114 : if (r->in.info_ctr == NULL) {
19485 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
19486 : }
19487 114 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->in.server_unc));
19488 114 : if (r->in.server_unc) {
19489 114 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->in.server_unc, CH_UTF16)));
19490 114 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, 0));
19491 114 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->in.server_unc, CH_UTF16)));
19492 114 : NDR_CHECK(ndr_push_charset(ndr, NDR_SCALARS, r->in.server_unc, ndr_charset_length(r->in.server_unc, CH_UTF16), sizeof(uint16_t), CH_UTF16));
19493 : }
19494 114 : NDR_CHECK(ndr_push_srvsvc_NetShareInfoCtr(ndr, NDR_SCALARS|NDR_BUFFERS, r->in.info_ctr));
19495 114 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->in.max_buffer));
19496 114 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->in.resume_handle));
19497 114 : if (r->in.resume_handle) {
19498 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, *r->in.resume_handle));
19499 : }
19500 : }
19501 238 : if (flags & NDR_OUT) {
19502 124 : if (r->out.info_ctr == NULL) {
19503 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
19504 : }
19505 124 : if (r->out.totalentries == NULL) {
19506 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
19507 : }
19508 124 : NDR_CHECK(ndr_push_srvsvc_NetShareInfoCtr(ndr, NDR_SCALARS|NDR_BUFFERS, r->out.info_ctr));
19509 124 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, *r->out.totalentries));
19510 124 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->out.resume_handle));
19511 124 : if (r->out.resume_handle) {
19512 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, *r->out.resume_handle));
19513 : }
19514 124 : NDR_CHECK(ndr_push_WERROR(ndr, NDR_SCALARS, r->out.result));
19515 : }
19516 238 : return NDR_ERR_SUCCESS;
19517 : }
19518 :
19519 228 : static enum ndr_err_code ndr_pull_srvsvc_NetShareEnum(struct ndr_pull *ndr, ndr_flags_type flags, struct srvsvc_NetShareEnum *r)
19520 : {
19521 0 : uint32_t _ptr_server_unc;
19522 228 : uint32_t size_server_unc_1 = 0;
19523 228 : uint32_t length_server_unc_1 = 0;
19524 0 : uint32_t _ptr_resume_handle;
19525 228 : TALLOC_CTX *_mem_save_server_unc_0 = NULL;
19526 228 : TALLOC_CTX *_mem_save_info_ctr_0 = NULL;
19527 228 : TALLOC_CTX *_mem_save_totalentries_0 = NULL;
19528 228 : TALLOC_CTX *_mem_save_resume_handle_0 = NULL;
19529 228 : NDR_PULL_CHECK_FN_FLAGS(ndr, flags);
19530 228 : if (flags & NDR_IN) {
19531 114 : NDR_ZERO_STRUCT(r->out);
19532 :
19533 114 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_server_unc));
19534 114 : if (_ptr_server_unc) {
19535 114 : NDR_PULL_ALLOC(ndr, r->in.server_unc);
19536 : } else {
19537 0 : r->in.server_unc = NULL;
19538 : }
19539 114 : if (r->in.server_unc) {
19540 114 : _mem_save_server_unc_0 = NDR_PULL_GET_MEM_CTX(ndr);
19541 114 : NDR_PULL_SET_MEM_CTX(ndr, r->in.server_unc, 0);
19542 114 : NDR_CHECK(ndr_pull_array_size(ndr, &r->in.server_unc));
19543 114 : NDR_CHECK(ndr_pull_array_length(ndr, &r->in.server_unc));
19544 114 : NDR_CHECK(ndr_steal_array_size(ndr, (void*)&r->in.server_unc, &size_server_unc_1));
19545 114 : NDR_CHECK(ndr_steal_array_length(ndr, (void*)&r->in.server_unc, &length_server_unc_1));
19546 114 : if (length_server_unc_1 > size_server_unc_1) {
19547 0 : return ndr_pull_error(ndr, NDR_ERR_ARRAY_SIZE, "Bad array size %"PRIu32": should exceed array length %"PRIu32"", size_server_unc_1, length_server_unc_1);
19548 : }
19549 114 : NDR_CHECK(ndr_check_string_terminator(ndr, length_server_unc_1, sizeof(uint16_t)));
19550 114 : NDR_CHECK(ndr_pull_charset(ndr, NDR_SCALARS, &r->in.server_unc, length_server_unc_1, sizeof(uint16_t), CH_UTF16));
19551 114 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_server_unc_0, 0);
19552 : }
19553 114 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
19554 114 : NDR_PULL_ALLOC(ndr, r->in.info_ctr);
19555 : }
19556 114 : _mem_save_info_ctr_0 = NDR_PULL_GET_MEM_CTX(ndr);
19557 114 : NDR_PULL_SET_MEM_CTX(ndr, r->in.info_ctr, LIBNDR_FLAG_REF_ALLOC);
19558 114 : NDR_CHECK(ndr_pull_srvsvc_NetShareInfoCtr(ndr, NDR_SCALARS|NDR_BUFFERS, r->in.info_ctr));
19559 114 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_info_ctr_0, LIBNDR_FLAG_REF_ALLOC);
19560 114 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->in.max_buffer));
19561 114 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_resume_handle));
19562 114 : if (_ptr_resume_handle) {
19563 0 : NDR_PULL_ALLOC(ndr, r->in.resume_handle);
19564 : } else {
19565 114 : r->in.resume_handle = NULL;
19566 : }
19567 114 : if (r->in.resume_handle) {
19568 0 : _mem_save_resume_handle_0 = NDR_PULL_GET_MEM_CTX(ndr);
19569 0 : NDR_PULL_SET_MEM_CTX(ndr, r->in.resume_handle, 0);
19570 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, r->in.resume_handle));
19571 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_resume_handle_0, 0);
19572 : }
19573 114 : NDR_PULL_ALLOC(ndr, r->out.info_ctr);
19574 114 : *r->out.info_ctr = *r->in.info_ctr;
19575 114 : NDR_PULL_ALLOC(ndr, r->out.totalentries);
19576 114 : NDR_ZERO_STRUCTP(r->out.totalentries);
19577 : }
19578 228 : if (flags & NDR_OUT) {
19579 : #ifdef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION
19580 : if (r->in.info_ctr == NULL) {
19581 : NDR_PULL_ALLOC(ndr, r->in.info_ctr);
19582 : NDR_ZERO_STRUCTP(r->in.info_ctr);
19583 : }
19584 : #endif /* FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION */
19585 114 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
19586 16 : NDR_PULL_ALLOC(ndr, r->out.info_ctr);
19587 : }
19588 114 : _mem_save_info_ctr_0 = NDR_PULL_GET_MEM_CTX(ndr);
19589 114 : NDR_PULL_SET_MEM_CTX(ndr, r->out.info_ctr, LIBNDR_FLAG_REF_ALLOC);
19590 114 : NDR_CHECK(ndr_pull_srvsvc_NetShareInfoCtr(ndr, NDR_SCALARS|NDR_BUFFERS, r->out.info_ctr));
19591 114 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_info_ctr_0, LIBNDR_FLAG_REF_ALLOC);
19592 114 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
19593 16 : NDR_PULL_ALLOC(ndr, r->out.totalentries);
19594 : }
19595 114 : _mem_save_totalentries_0 = NDR_PULL_GET_MEM_CTX(ndr);
19596 114 : NDR_PULL_SET_MEM_CTX(ndr, r->out.totalentries, LIBNDR_FLAG_REF_ALLOC);
19597 114 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, r->out.totalentries));
19598 114 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_totalentries_0, LIBNDR_FLAG_REF_ALLOC);
19599 114 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_resume_handle));
19600 114 : if (_ptr_resume_handle) {
19601 0 : NDR_PULL_ALLOC(ndr, r->out.resume_handle);
19602 : } else {
19603 114 : r->out.resume_handle = NULL;
19604 : }
19605 114 : if (r->out.resume_handle) {
19606 0 : _mem_save_resume_handle_0 = NDR_PULL_GET_MEM_CTX(ndr);
19607 0 : NDR_PULL_SET_MEM_CTX(ndr, r->out.resume_handle, 0);
19608 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, r->out.resume_handle));
19609 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_resume_handle_0, 0);
19610 : }
19611 114 : NDR_CHECK(ndr_pull_WERROR(ndr, NDR_SCALARS, &r->out.result));
19612 : }
19613 228 : return NDR_ERR_SUCCESS;
19614 : }
19615 :
19616 20 : _PUBLIC_ void ndr_print_srvsvc_NetShareEnum(struct ndr_print *ndr, const char *name, ndr_flags_type flags, const struct srvsvc_NetShareEnum *r)
19617 : {
19618 20 : ndr_print_struct(ndr, name, "srvsvc_NetShareEnum");
19619 20 : if (r == NULL) { ndr_print_null(ndr); return; }
19620 20 : ndr->depth++;
19621 20 : if (flags & NDR_SET_VALUES) {
19622 0 : ndr->flags |= LIBNDR_PRINT_SET_VALUES;
19623 : }
19624 20 : if (flags & NDR_IN) {
19625 0 : ndr_print_struct(ndr, "in", "srvsvc_NetShareEnum");
19626 0 : ndr->depth++;
19627 0 : ndr_print_ptr(ndr, "server_unc", r->in.server_unc);
19628 0 : ndr->depth++;
19629 0 : if (r->in.server_unc) {
19630 0 : ndr_print_string(ndr, "server_unc", r->in.server_unc);
19631 : }
19632 0 : ndr->depth--;
19633 0 : ndr_print_ptr(ndr, "info_ctr", r->in.info_ctr);
19634 0 : ndr->depth++;
19635 0 : ndr_print_srvsvc_NetShareInfoCtr(ndr, "info_ctr", r->in.info_ctr);
19636 0 : ndr->depth--;
19637 0 : ndr_print_uint32(ndr, "max_buffer", r->in.max_buffer);
19638 0 : ndr_print_ptr(ndr, "resume_handle", r->in.resume_handle);
19639 0 : ndr->depth++;
19640 0 : if (r->in.resume_handle) {
19641 0 : ndr_print_uint32(ndr, "resume_handle", *r->in.resume_handle);
19642 : }
19643 0 : ndr->depth--;
19644 0 : ndr->depth--;
19645 : }
19646 20 : if (flags & NDR_OUT) {
19647 20 : ndr_print_struct(ndr, "out", "srvsvc_NetShareEnum");
19648 20 : ndr->depth++;
19649 20 : ndr_print_ptr(ndr, "info_ctr", r->out.info_ctr);
19650 20 : ndr->depth++;
19651 20 : ndr_print_srvsvc_NetShareInfoCtr(ndr, "info_ctr", r->out.info_ctr);
19652 20 : ndr->depth--;
19653 20 : ndr_print_ptr(ndr, "totalentries", r->out.totalentries);
19654 20 : ndr->depth++;
19655 20 : ndr_print_uint32(ndr, "totalentries", *r->out.totalentries);
19656 20 : ndr->depth--;
19657 20 : ndr_print_ptr(ndr, "resume_handle", r->out.resume_handle);
19658 20 : ndr->depth++;
19659 20 : if (r->out.resume_handle) {
19660 0 : ndr_print_uint32(ndr, "resume_handle", *r->out.resume_handle);
19661 : }
19662 20 : ndr->depth--;
19663 20 : ndr_print_WERROR(ndr, "result", r->out.result);
19664 20 : ndr->depth--;
19665 : }
19666 20 : ndr->depth--;
19667 : }
19668 :
19669 0 : static enum ndr_err_code ndr_push_srvsvc_NetShareDelStart(struct ndr_push *ndr, ndr_flags_type flags, const struct srvsvc_NetShareDelStart *r)
19670 : {
19671 0 : NDR_PUSH_CHECK_FN_FLAGS(ndr, flags);
19672 0 : if (flags & NDR_IN) {
19673 0 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->in.server_unc));
19674 0 : if (r->in.server_unc) {
19675 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->in.server_unc, CH_UTF16)));
19676 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, 0));
19677 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->in.server_unc, CH_UTF16)));
19678 0 : NDR_CHECK(ndr_push_charset(ndr, NDR_SCALARS, r->in.server_unc, ndr_charset_length(r->in.server_unc, CH_UTF16), sizeof(uint16_t), CH_UTF16));
19679 : }
19680 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->in.share, CH_UTF16)));
19681 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, 0));
19682 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->in.share, CH_UTF16)));
19683 0 : NDR_CHECK(ndr_push_charset(ndr, NDR_SCALARS, r->in.share, ndr_charset_length(r->in.share, CH_UTF16), sizeof(uint16_t), CH_UTF16));
19684 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->in.reserved));
19685 : }
19686 0 : if (flags & NDR_OUT) {
19687 0 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->out.hnd));
19688 0 : if (r->out.hnd) {
19689 0 : NDR_CHECK(ndr_push_policy_handle(ndr, NDR_SCALARS, r->out.hnd));
19690 : }
19691 0 : NDR_CHECK(ndr_push_WERROR(ndr, NDR_SCALARS, r->out.result));
19692 : }
19693 0 : return NDR_ERR_SUCCESS;
19694 : }
19695 :
19696 0 : static enum ndr_err_code ndr_pull_srvsvc_NetShareDelStart(struct ndr_pull *ndr, ndr_flags_type flags, struct srvsvc_NetShareDelStart *r)
19697 : {
19698 0 : uint32_t _ptr_server_unc;
19699 0 : uint32_t size_server_unc_1 = 0;
19700 0 : uint32_t length_server_unc_1 = 0;
19701 0 : uint32_t size_share_0 = 0;
19702 0 : uint32_t length_share_0 = 0;
19703 0 : uint32_t _ptr_hnd;
19704 0 : TALLOC_CTX *_mem_save_server_unc_0 = NULL;
19705 0 : TALLOC_CTX *_mem_save_hnd_0 = NULL;
19706 0 : NDR_PULL_CHECK_FN_FLAGS(ndr, flags);
19707 0 : if (flags & NDR_IN) {
19708 0 : NDR_ZERO_STRUCT(r->out);
19709 :
19710 0 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_server_unc));
19711 0 : if (_ptr_server_unc) {
19712 0 : NDR_PULL_ALLOC(ndr, r->in.server_unc);
19713 : } else {
19714 0 : r->in.server_unc = NULL;
19715 : }
19716 0 : if (r->in.server_unc) {
19717 0 : _mem_save_server_unc_0 = NDR_PULL_GET_MEM_CTX(ndr);
19718 0 : NDR_PULL_SET_MEM_CTX(ndr, r->in.server_unc, 0);
19719 0 : NDR_CHECK(ndr_pull_array_size(ndr, &r->in.server_unc));
19720 0 : NDR_CHECK(ndr_pull_array_length(ndr, &r->in.server_unc));
19721 0 : NDR_CHECK(ndr_steal_array_size(ndr, (void*)&r->in.server_unc, &size_server_unc_1));
19722 0 : NDR_CHECK(ndr_steal_array_length(ndr, (void*)&r->in.server_unc, &length_server_unc_1));
19723 0 : if (length_server_unc_1 > size_server_unc_1) {
19724 0 : return ndr_pull_error(ndr, NDR_ERR_ARRAY_SIZE, "Bad array size %"PRIu32": should exceed array length %"PRIu32"", size_server_unc_1, length_server_unc_1);
19725 : }
19726 0 : NDR_CHECK(ndr_check_string_terminator(ndr, length_server_unc_1, sizeof(uint16_t)));
19727 0 : NDR_CHECK(ndr_pull_charset(ndr, NDR_SCALARS, &r->in.server_unc, length_server_unc_1, sizeof(uint16_t), CH_UTF16));
19728 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_server_unc_0, 0);
19729 : }
19730 0 : NDR_CHECK(ndr_pull_array_size(ndr, &r->in.share));
19731 0 : NDR_CHECK(ndr_pull_array_length(ndr, &r->in.share));
19732 0 : NDR_CHECK(ndr_steal_array_size(ndr, (void*)&r->in.share, &size_share_0));
19733 0 : NDR_CHECK(ndr_steal_array_length(ndr, (void*)&r->in.share, &length_share_0));
19734 0 : if (length_share_0 > size_share_0) {
19735 0 : return ndr_pull_error(ndr, NDR_ERR_ARRAY_SIZE, "Bad array size %"PRIu32": should exceed array length %"PRIu32"", size_share_0, length_share_0);
19736 : }
19737 0 : NDR_CHECK(ndr_check_string_terminator(ndr, length_share_0, sizeof(uint16_t)));
19738 0 : NDR_CHECK(ndr_pull_charset(ndr, NDR_SCALARS, &r->in.share, length_share_0, sizeof(uint16_t), CH_UTF16));
19739 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->in.reserved));
19740 : }
19741 0 : if (flags & NDR_OUT) {
19742 : #ifdef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION
19743 : #endif /* FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION */
19744 0 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_hnd));
19745 0 : if (_ptr_hnd) {
19746 0 : NDR_PULL_ALLOC(ndr, r->out.hnd);
19747 : } else {
19748 0 : r->out.hnd = NULL;
19749 : }
19750 0 : if (r->out.hnd) {
19751 0 : _mem_save_hnd_0 = NDR_PULL_GET_MEM_CTX(ndr);
19752 0 : NDR_PULL_SET_MEM_CTX(ndr, r->out.hnd, 0);
19753 0 : NDR_CHECK(ndr_pull_policy_handle(ndr, NDR_SCALARS, r->out.hnd));
19754 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_hnd_0, 0);
19755 : }
19756 0 : NDR_CHECK(ndr_pull_WERROR(ndr, NDR_SCALARS, &r->out.result));
19757 : }
19758 0 : return NDR_ERR_SUCCESS;
19759 : }
19760 :
19761 0 : _PUBLIC_ void ndr_print_srvsvc_NetShareDelStart(struct ndr_print *ndr, const char *name, ndr_flags_type flags, const struct srvsvc_NetShareDelStart *r)
19762 : {
19763 0 : ndr_print_struct(ndr, name, "srvsvc_NetShareDelStart");
19764 0 : if (r == NULL) { ndr_print_null(ndr); return; }
19765 0 : ndr->depth++;
19766 0 : if (flags & NDR_SET_VALUES) {
19767 0 : ndr->flags |= LIBNDR_PRINT_SET_VALUES;
19768 : }
19769 0 : if (flags & NDR_IN) {
19770 0 : ndr_print_struct(ndr, "in", "srvsvc_NetShareDelStart");
19771 0 : ndr->depth++;
19772 0 : ndr_print_ptr(ndr, "server_unc", r->in.server_unc);
19773 0 : ndr->depth++;
19774 0 : if (r->in.server_unc) {
19775 0 : ndr_print_string(ndr, "server_unc", r->in.server_unc);
19776 : }
19777 0 : ndr->depth--;
19778 0 : ndr_print_string(ndr, "share", r->in.share);
19779 0 : ndr_print_uint32(ndr, "reserved", r->in.reserved);
19780 0 : ndr->depth--;
19781 : }
19782 0 : if (flags & NDR_OUT) {
19783 0 : ndr_print_struct(ndr, "out", "srvsvc_NetShareDelStart");
19784 0 : ndr->depth++;
19785 0 : ndr_print_ptr(ndr, "hnd", r->out.hnd);
19786 0 : ndr->depth++;
19787 0 : if (r->out.hnd) {
19788 0 : ndr_print_policy_handle(ndr, "hnd", r->out.hnd);
19789 : }
19790 0 : ndr->depth--;
19791 0 : ndr_print_WERROR(ndr, "result", r->out.result);
19792 0 : ndr->depth--;
19793 : }
19794 0 : ndr->depth--;
19795 : }
19796 :
19797 0 : static enum ndr_err_code ndr_push_srvsvc_NetShareDelCommit(struct ndr_push *ndr, ndr_flags_type flags, const struct srvsvc_NetShareDelCommit *r)
19798 : {
19799 0 : NDR_PUSH_CHECK_FN_FLAGS(ndr, flags);
19800 0 : if (flags & NDR_IN) {
19801 0 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->in.hnd));
19802 0 : if (r->in.hnd) {
19803 0 : NDR_CHECK(ndr_push_policy_handle(ndr, NDR_SCALARS, r->in.hnd));
19804 : }
19805 : }
19806 0 : if (flags & NDR_OUT) {
19807 0 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->out.hnd));
19808 0 : if (r->out.hnd) {
19809 0 : NDR_CHECK(ndr_push_policy_handle(ndr, NDR_SCALARS, r->out.hnd));
19810 : }
19811 0 : NDR_CHECK(ndr_push_WERROR(ndr, NDR_SCALARS, r->out.result));
19812 : }
19813 0 : return NDR_ERR_SUCCESS;
19814 : }
19815 :
19816 0 : static enum ndr_err_code ndr_pull_srvsvc_NetShareDelCommit(struct ndr_pull *ndr, ndr_flags_type flags, struct srvsvc_NetShareDelCommit *r)
19817 : {
19818 0 : uint32_t _ptr_hnd;
19819 0 : TALLOC_CTX *_mem_save_hnd_0 = NULL;
19820 0 : NDR_PULL_CHECK_FN_FLAGS(ndr, flags);
19821 0 : if (flags & NDR_IN) {
19822 0 : NDR_ZERO_STRUCT(r->out);
19823 :
19824 0 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_hnd));
19825 0 : if (_ptr_hnd) {
19826 0 : NDR_PULL_ALLOC(ndr, r->in.hnd);
19827 : } else {
19828 0 : r->in.hnd = NULL;
19829 : }
19830 0 : if (r->in.hnd) {
19831 0 : _mem_save_hnd_0 = NDR_PULL_GET_MEM_CTX(ndr);
19832 0 : NDR_PULL_SET_MEM_CTX(ndr, r->in.hnd, 0);
19833 0 : NDR_CHECK(ndr_pull_policy_handle(ndr, NDR_SCALARS, r->in.hnd));
19834 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_hnd_0, 0);
19835 : }
19836 : }
19837 0 : if (flags & NDR_OUT) {
19838 : #ifdef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION
19839 : #endif /* FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION */
19840 0 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_hnd));
19841 0 : if (_ptr_hnd) {
19842 0 : NDR_PULL_ALLOC(ndr, r->out.hnd);
19843 : } else {
19844 0 : r->out.hnd = NULL;
19845 : }
19846 0 : if (r->out.hnd) {
19847 0 : _mem_save_hnd_0 = NDR_PULL_GET_MEM_CTX(ndr);
19848 0 : NDR_PULL_SET_MEM_CTX(ndr, r->out.hnd, 0);
19849 0 : NDR_CHECK(ndr_pull_policy_handle(ndr, NDR_SCALARS, r->out.hnd));
19850 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_hnd_0, 0);
19851 : }
19852 0 : NDR_CHECK(ndr_pull_WERROR(ndr, NDR_SCALARS, &r->out.result));
19853 : }
19854 0 : return NDR_ERR_SUCCESS;
19855 : }
19856 :
19857 0 : _PUBLIC_ void ndr_print_srvsvc_NetShareDelCommit(struct ndr_print *ndr, const char *name, ndr_flags_type flags, const struct srvsvc_NetShareDelCommit *r)
19858 : {
19859 0 : ndr_print_struct(ndr, name, "srvsvc_NetShareDelCommit");
19860 0 : if (r == NULL) { ndr_print_null(ndr); return; }
19861 0 : ndr->depth++;
19862 0 : if (flags & NDR_SET_VALUES) {
19863 0 : ndr->flags |= LIBNDR_PRINT_SET_VALUES;
19864 : }
19865 0 : if (flags & NDR_IN) {
19866 0 : ndr_print_struct(ndr, "in", "srvsvc_NetShareDelCommit");
19867 0 : ndr->depth++;
19868 0 : ndr_print_ptr(ndr, "hnd", r->in.hnd);
19869 0 : ndr->depth++;
19870 0 : if (r->in.hnd) {
19871 0 : ndr_print_policy_handle(ndr, "hnd", r->in.hnd);
19872 : }
19873 0 : ndr->depth--;
19874 0 : ndr->depth--;
19875 : }
19876 0 : if (flags & NDR_OUT) {
19877 0 : ndr_print_struct(ndr, "out", "srvsvc_NetShareDelCommit");
19878 0 : ndr->depth++;
19879 0 : ndr_print_ptr(ndr, "hnd", r->out.hnd);
19880 0 : ndr->depth++;
19881 0 : if (r->out.hnd) {
19882 0 : ndr_print_policy_handle(ndr, "hnd", r->out.hnd);
19883 : }
19884 0 : ndr->depth--;
19885 0 : ndr_print_WERROR(ndr, "result", r->out.result);
19886 0 : ndr->depth--;
19887 : }
19888 0 : ndr->depth--;
19889 : }
19890 :
19891 0 : static enum ndr_err_code ndr_push_srvsvc_NetGetFileSecurity(struct ndr_push *ndr, ndr_flags_type flags, const struct srvsvc_NetGetFileSecurity *r)
19892 : {
19893 0 : NDR_PUSH_CHECK_FN_FLAGS(ndr, flags);
19894 0 : if (flags & NDR_IN) {
19895 0 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->in.server_unc));
19896 0 : if (r->in.server_unc) {
19897 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->in.server_unc, CH_UTF16)));
19898 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, 0));
19899 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->in.server_unc, CH_UTF16)));
19900 0 : NDR_CHECK(ndr_push_charset(ndr, NDR_SCALARS, r->in.server_unc, ndr_charset_length(r->in.server_unc, CH_UTF16), sizeof(uint16_t), CH_UTF16));
19901 : }
19902 0 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->in.share));
19903 0 : if (r->in.share) {
19904 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->in.share, CH_UTF16)));
19905 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, 0));
19906 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->in.share, CH_UTF16)));
19907 0 : NDR_CHECK(ndr_push_charset(ndr, NDR_SCALARS, r->in.share, ndr_charset_length(r->in.share, CH_UTF16), sizeof(uint16_t), CH_UTF16));
19908 : }
19909 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->in.file, CH_UTF16)));
19910 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, 0));
19911 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->in.file, CH_UTF16)));
19912 0 : NDR_CHECK(ndr_push_charset(ndr, NDR_SCALARS, r->in.file, ndr_charset_length(r->in.file, CH_UTF16), sizeof(uint16_t), CH_UTF16));
19913 0 : NDR_CHECK(ndr_push_security_secinfo(ndr, NDR_SCALARS, r->in.securityinformation));
19914 : }
19915 0 : if (flags & NDR_OUT) {
19916 0 : if (r->out.sd_buf == NULL) {
19917 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
19918 : }
19919 0 : NDR_CHECK(ndr_push_unique_ptr(ndr, *r->out.sd_buf));
19920 0 : if (*r->out.sd_buf) {
19921 0 : NDR_CHECK(ndr_push_sec_desc_buf(ndr, NDR_SCALARS|NDR_BUFFERS, *r->out.sd_buf));
19922 : }
19923 0 : NDR_CHECK(ndr_push_WERROR(ndr, NDR_SCALARS, r->out.result));
19924 : }
19925 0 : return NDR_ERR_SUCCESS;
19926 : }
19927 :
19928 0 : static enum ndr_err_code ndr_pull_srvsvc_NetGetFileSecurity(struct ndr_pull *ndr, ndr_flags_type flags, struct srvsvc_NetGetFileSecurity *r)
19929 : {
19930 0 : uint32_t _ptr_server_unc;
19931 0 : uint32_t size_server_unc_1 = 0;
19932 0 : uint32_t length_server_unc_1 = 0;
19933 0 : uint32_t _ptr_share;
19934 0 : uint32_t size_share_1 = 0;
19935 0 : uint32_t length_share_1 = 0;
19936 0 : uint32_t size_file_0 = 0;
19937 0 : uint32_t length_file_0 = 0;
19938 0 : uint32_t _ptr_sd_buf;
19939 0 : TALLOC_CTX *_mem_save_server_unc_0 = NULL;
19940 0 : TALLOC_CTX *_mem_save_share_0 = NULL;
19941 0 : TALLOC_CTX *_mem_save_sd_buf_0 = NULL;
19942 0 : TALLOC_CTX *_mem_save_sd_buf_1 = NULL;
19943 0 : NDR_PULL_CHECK_FN_FLAGS(ndr, flags);
19944 0 : if (flags & NDR_IN) {
19945 0 : NDR_ZERO_STRUCT(r->out);
19946 :
19947 0 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_server_unc));
19948 0 : if (_ptr_server_unc) {
19949 0 : NDR_PULL_ALLOC(ndr, r->in.server_unc);
19950 : } else {
19951 0 : r->in.server_unc = NULL;
19952 : }
19953 0 : if (r->in.server_unc) {
19954 0 : _mem_save_server_unc_0 = NDR_PULL_GET_MEM_CTX(ndr);
19955 0 : NDR_PULL_SET_MEM_CTX(ndr, r->in.server_unc, 0);
19956 0 : NDR_CHECK(ndr_pull_array_size(ndr, &r->in.server_unc));
19957 0 : NDR_CHECK(ndr_pull_array_length(ndr, &r->in.server_unc));
19958 0 : NDR_CHECK(ndr_steal_array_size(ndr, (void*)&r->in.server_unc, &size_server_unc_1));
19959 0 : NDR_CHECK(ndr_steal_array_length(ndr, (void*)&r->in.server_unc, &length_server_unc_1));
19960 0 : if (length_server_unc_1 > size_server_unc_1) {
19961 0 : return ndr_pull_error(ndr, NDR_ERR_ARRAY_SIZE, "Bad array size %"PRIu32": should exceed array length %"PRIu32"", size_server_unc_1, length_server_unc_1);
19962 : }
19963 0 : NDR_CHECK(ndr_check_string_terminator(ndr, length_server_unc_1, sizeof(uint16_t)));
19964 0 : NDR_CHECK(ndr_pull_charset(ndr, NDR_SCALARS, &r->in.server_unc, length_server_unc_1, sizeof(uint16_t), CH_UTF16));
19965 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_server_unc_0, 0);
19966 : }
19967 0 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_share));
19968 0 : if (_ptr_share) {
19969 0 : NDR_PULL_ALLOC(ndr, r->in.share);
19970 : } else {
19971 0 : r->in.share = NULL;
19972 : }
19973 0 : if (r->in.share) {
19974 0 : _mem_save_share_0 = NDR_PULL_GET_MEM_CTX(ndr);
19975 0 : NDR_PULL_SET_MEM_CTX(ndr, r->in.share, 0);
19976 0 : NDR_CHECK(ndr_pull_array_size(ndr, &r->in.share));
19977 0 : NDR_CHECK(ndr_pull_array_length(ndr, &r->in.share));
19978 0 : NDR_CHECK(ndr_steal_array_size(ndr, (void*)&r->in.share, &size_share_1));
19979 0 : NDR_CHECK(ndr_steal_array_length(ndr, (void*)&r->in.share, &length_share_1));
19980 0 : if (length_share_1 > size_share_1) {
19981 0 : return ndr_pull_error(ndr, NDR_ERR_ARRAY_SIZE, "Bad array size %"PRIu32": should exceed array length %"PRIu32"", size_share_1, length_share_1);
19982 : }
19983 0 : NDR_CHECK(ndr_check_string_terminator(ndr, length_share_1, sizeof(uint16_t)));
19984 0 : NDR_CHECK(ndr_pull_charset(ndr, NDR_SCALARS, &r->in.share, length_share_1, sizeof(uint16_t), CH_UTF16));
19985 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_share_0, 0);
19986 : }
19987 0 : NDR_CHECK(ndr_pull_array_size(ndr, &r->in.file));
19988 0 : NDR_CHECK(ndr_pull_array_length(ndr, &r->in.file));
19989 0 : NDR_CHECK(ndr_steal_array_size(ndr, (void*)&r->in.file, &size_file_0));
19990 0 : NDR_CHECK(ndr_steal_array_length(ndr, (void*)&r->in.file, &length_file_0));
19991 0 : if (length_file_0 > size_file_0) {
19992 0 : return ndr_pull_error(ndr, NDR_ERR_ARRAY_SIZE, "Bad array size %"PRIu32": should exceed array length %"PRIu32"", size_file_0, length_file_0);
19993 : }
19994 0 : NDR_CHECK(ndr_check_string_terminator(ndr, length_file_0, sizeof(uint16_t)));
19995 0 : NDR_CHECK(ndr_pull_charset(ndr, NDR_SCALARS, &r->in.file, length_file_0, sizeof(uint16_t), CH_UTF16));
19996 0 : NDR_CHECK(ndr_pull_security_secinfo(ndr, NDR_SCALARS, &r->in.securityinformation));
19997 0 : NDR_PULL_ALLOC(ndr, r->out.sd_buf);
19998 0 : NDR_ZERO_STRUCTP(r->out.sd_buf);
19999 : }
20000 0 : if (flags & NDR_OUT) {
20001 : #ifdef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION
20002 : #endif /* FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION */
20003 0 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
20004 0 : NDR_PULL_ALLOC(ndr, r->out.sd_buf);
20005 : }
20006 0 : _mem_save_sd_buf_0 = NDR_PULL_GET_MEM_CTX(ndr);
20007 0 : NDR_PULL_SET_MEM_CTX(ndr, r->out.sd_buf, LIBNDR_FLAG_REF_ALLOC);
20008 0 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_sd_buf));
20009 0 : if (_ptr_sd_buf) {
20010 0 : NDR_PULL_ALLOC(ndr, *r->out.sd_buf);
20011 : } else {
20012 0 : *r->out.sd_buf = NULL;
20013 : }
20014 0 : if (*r->out.sd_buf) {
20015 0 : _mem_save_sd_buf_1 = NDR_PULL_GET_MEM_CTX(ndr);
20016 0 : NDR_PULL_SET_MEM_CTX(ndr, *r->out.sd_buf, 0);
20017 0 : NDR_CHECK(ndr_pull_sec_desc_buf(ndr, NDR_SCALARS|NDR_BUFFERS, *r->out.sd_buf));
20018 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_sd_buf_1, 0);
20019 : }
20020 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_sd_buf_0, LIBNDR_FLAG_REF_ALLOC);
20021 0 : NDR_CHECK(ndr_pull_WERROR(ndr, NDR_SCALARS, &r->out.result));
20022 : }
20023 0 : return NDR_ERR_SUCCESS;
20024 : }
20025 :
20026 0 : _PUBLIC_ void ndr_print_srvsvc_NetGetFileSecurity(struct ndr_print *ndr, const char *name, ndr_flags_type flags, const struct srvsvc_NetGetFileSecurity *r)
20027 : {
20028 0 : ndr_print_struct(ndr, name, "srvsvc_NetGetFileSecurity");
20029 0 : if (r == NULL) { ndr_print_null(ndr); return; }
20030 0 : ndr->depth++;
20031 0 : if (flags & NDR_SET_VALUES) {
20032 0 : ndr->flags |= LIBNDR_PRINT_SET_VALUES;
20033 : }
20034 0 : if (flags & NDR_IN) {
20035 0 : ndr_print_struct(ndr, "in", "srvsvc_NetGetFileSecurity");
20036 0 : ndr->depth++;
20037 0 : ndr_print_ptr(ndr, "server_unc", r->in.server_unc);
20038 0 : ndr->depth++;
20039 0 : if (r->in.server_unc) {
20040 0 : ndr_print_string(ndr, "server_unc", r->in.server_unc);
20041 : }
20042 0 : ndr->depth--;
20043 0 : ndr_print_ptr(ndr, "share", r->in.share);
20044 0 : ndr->depth++;
20045 0 : if (r->in.share) {
20046 0 : ndr_print_string(ndr, "share", r->in.share);
20047 : }
20048 0 : ndr->depth--;
20049 0 : ndr_print_string(ndr, "file", r->in.file);
20050 0 : ndr_print_security_secinfo(ndr, "securityinformation", r->in.securityinformation);
20051 0 : ndr->depth--;
20052 : }
20053 0 : if (flags & NDR_OUT) {
20054 0 : ndr_print_struct(ndr, "out", "srvsvc_NetGetFileSecurity");
20055 0 : ndr->depth++;
20056 0 : ndr_print_ptr(ndr, "sd_buf", r->out.sd_buf);
20057 0 : ndr->depth++;
20058 0 : ndr_print_ptr(ndr, "sd_buf", *r->out.sd_buf);
20059 0 : ndr->depth++;
20060 0 : if (*r->out.sd_buf) {
20061 0 : ndr_print_sec_desc_buf(ndr, "sd_buf", *r->out.sd_buf);
20062 : }
20063 0 : ndr->depth--;
20064 0 : ndr->depth--;
20065 0 : ndr_print_WERROR(ndr, "result", r->out.result);
20066 0 : ndr->depth--;
20067 : }
20068 0 : ndr->depth--;
20069 : }
20070 :
20071 0 : static enum ndr_err_code ndr_push_srvsvc_NetSetFileSecurity(struct ndr_push *ndr, ndr_flags_type flags, const struct srvsvc_NetSetFileSecurity *r)
20072 : {
20073 0 : NDR_PUSH_CHECK_FN_FLAGS(ndr, flags);
20074 0 : if (flags & NDR_IN) {
20075 0 : if (r->in.sd_buf == NULL) {
20076 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
20077 : }
20078 0 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->in.server_unc));
20079 0 : if (r->in.server_unc) {
20080 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->in.server_unc, CH_UTF16)));
20081 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, 0));
20082 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->in.server_unc, CH_UTF16)));
20083 0 : NDR_CHECK(ndr_push_charset(ndr, NDR_SCALARS, r->in.server_unc, ndr_charset_length(r->in.server_unc, CH_UTF16), sizeof(uint16_t), CH_UTF16));
20084 : }
20085 0 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->in.share));
20086 0 : if (r->in.share) {
20087 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->in.share, CH_UTF16)));
20088 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, 0));
20089 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->in.share, CH_UTF16)));
20090 0 : NDR_CHECK(ndr_push_charset(ndr, NDR_SCALARS, r->in.share, ndr_charset_length(r->in.share, CH_UTF16), sizeof(uint16_t), CH_UTF16));
20091 : }
20092 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->in.file, CH_UTF16)));
20093 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, 0));
20094 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->in.file, CH_UTF16)));
20095 0 : NDR_CHECK(ndr_push_charset(ndr, NDR_SCALARS, r->in.file, ndr_charset_length(r->in.file, CH_UTF16), sizeof(uint16_t), CH_UTF16));
20096 0 : NDR_CHECK(ndr_push_security_secinfo(ndr, NDR_SCALARS, r->in.securityinformation));
20097 0 : NDR_CHECK(ndr_push_sec_desc_buf(ndr, NDR_SCALARS|NDR_BUFFERS, r->in.sd_buf));
20098 : }
20099 0 : if (flags & NDR_OUT) {
20100 0 : NDR_CHECK(ndr_push_WERROR(ndr, NDR_SCALARS, r->out.result));
20101 : }
20102 0 : return NDR_ERR_SUCCESS;
20103 : }
20104 :
20105 0 : static enum ndr_err_code ndr_pull_srvsvc_NetSetFileSecurity(struct ndr_pull *ndr, ndr_flags_type flags, struct srvsvc_NetSetFileSecurity *r)
20106 : {
20107 0 : uint32_t _ptr_server_unc;
20108 0 : uint32_t size_server_unc_1 = 0;
20109 0 : uint32_t length_server_unc_1 = 0;
20110 0 : uint32_t _ptr_share;
20111 0 : uint32_t size_share_1 = 0;
20112 0 : uint32_t length_share_1 = 0;
20113 0 : uint32_t size_file_0 = 0;
20114 0 : uint32_t length_file_0 = 0;
20115 0 : TALLOC_CTX *_mem_save_server_unc_0 = NULL;
20116 0 : TALLOC_CTX *_mem_save_share_0 = NULL;
20117 0 : TALLOC_CTX *_mem_save_sd_buf_0 = NULL;
20118 0 : NDR_PULL_CHECK_FN_FLAGS(ndr, flags);
20119 0 : if (flags & NDR_IN) {
20120 0 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_server_unc));
20121 0 : if (_ptr_server_unc) {
20122 0 : NDR_PULL_ALLOC(ndr, r->in.server_unc);
20123 : } else {
20124 0 : r->in.server_unc = NULL;
20125 : }
20126 0 : if (r->in.server_unc) {
20127 0 : _mem_save_server_unc_0 = NDR_PULL_GET_MEM_CTX(ndr);
20128 0 : NDR_PULL_SET_MEM_CTX(ndr, r->in.server_unc, 0);
20129 0 : NDR_CHECK(ndr_pull_array_size(ndr, &r->in.server_unc));
20130 0 : NDR_CHECK(ndr_pull_array_length(ndr, &r->in.server_unc));
20131 0 : NDR_CHECK(ndr_steal_array_size(ndr, (void*)&r->in.server_unc, &size_server_unc_1));
20132 0 : NDR_CHECK(ndr_steal_array_length(ndr, (void*)&r->in.server_unc, &length_server_unc_1));
20133 0 : if (length_server_unc_1 > size_server_unc_1) {
20134 0 : return ndr_pull_error(ndr, NDR_ERR_ARRAY_SIZE, "Bad array size %"PRIu32": should exceed array length %"PRIu32"", size_server_unc_1, length_server_unc_1);
20135 : }
20136 0 : NDR_CHECK(ndr_check_string_terminator(ndr, length_server_unc_1, sizeof(uint16_t)));
20137 0 : NDR_CHECK(ndr_pull_charset(ndr, NDR_SCALARS, &r->in.server_unc, length_server_unc_1, sizeof(uint16_t), CH_UTF16));
20138 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_server_unc_0, 0);
20139 : }
20140 0 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_share));
20141 0 : if (_ptr_share) {
20142 0 : NDR_PULL_ALLOC(ndr, r->in.share);
20143 : } else {
20144 0 : r->in.share = NULL;
20145 : }
20146 0 : if (r->in.share) {
20147 0 : _mem_save_share_0 = NDR_PULL_GET_MEM_CTX(ndr);
20148 0 : NDR_PULL_SET_MEM_CTX(ndr, r->in.share, 0);
20149 0 : NDR_CHECK(ndr_pull_array_size(ndr, &r->in.share));
20150 0 : NDR_CHECK(ndr_pull_array_length(ndr, &r->in.share));
20151 0 : NDR_CHECK(ndr_steal_array_size(ndr, (void*)&r->in.share, &size_share_1));
20152 0 : NDR_CHECK(ndr_steal_array_length(ndr, (void*)&r->in.share, &length_share_1));
20153 0 : if (length_share_1 > size_share_1) {
20154 0 : return ndr_pull_error(ndr, NDR_ERR_ARRAY_SIZE, "Bad array size %"PRIu32": should exceed array length %"PRIu32"", size_share_1, length_share_1);
20155 : }
20156 0 : NDR_CHECK(ndr_check_string_terminator(ndr, length_share_1, sizeof(uint16_t)));
20157 0 : NDR_CHECK(ndr_pull_charset(ndr, NDR_SCALARS, &r->in.share, length_share_1, sizeof(uint16_t), CH_UTF16));
20158 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_share_0, 0);
20159 : }
20160 0 : NDR_CHECK(ndr_pull_array_size(ndr, &r->in.file));
20161 0 : NDR_CHECK(ndr_pull_array_length(ndr, &r->in.file));
20162 0 : NDR_CHECK(ndr_steal_array_size(ndr, (void*)&r->in.file, &size_file_0));
20163 0 : NDR_CHECK(ndr_steal_array_length(ndr, (void*)&r->in.file, &length_file_0));
20164 0 : if (length_file_0 > size_file_0) {
20165 0 : return ndr_pull_error(ndr, NDR_ERR_ARRAY_SIZE, "Bad array size %"PRIu32": should exceed array length %"PRIu32"", size_file_0, length_file_0);
20166 : }
20167 0 : NDR_CHECK(ndr_check_string_terminator(ndr, length_file_0, sizeof(uint16_t)));
20168 0 : NDR_CHECK(ndr_pull_charset(ndr, NDR_SCALARS, &r->in.file, length_file_0, sizeof(uint16_t), CH_UTF16));
20169 0 : NDR_CHECK(ndr_pull_security_secinfo(ndr, NDR_SCALARS, &r->in.securityinformation));
20170 0 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
20171 0 : NDR_PULL_ALLOC(ndr, r->in.sd_buf);
20172 : }
20173 0 : _mem_save_sd_buf_0 = NDR_PULL_GET_MEM_CTX(ndr);
20174 0 : NDR_PULL_SET_MEM_CTX(ndr, r->in.sd_buf, LIBNDR_FLAG_REF_ALLOC);
20175 0 : NDR_CHECK(ndr_pull_sec_desc_buf(ndr, NDR_SCALARS|NDR_BUFFERS, r->in.sd_buf));
20176 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_sd_buf_0, LIBNDR_FLAG_REF_ALLOC);
20177 : }
20178 0 : if (flags & NDR_OUT) {
20179 : #ifdef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION
20180 : if (r->in.sd_buf == NULL) {
20181 : NDR_PULL_ALLOC(ndr, r->in.sd_buf);
20182 : NDR_ZERO_STRUCTP(r->in.sd_buf);
20183 : }
20184 : #endif /* FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION */
20185 0 : NDR_CHECK(ndr_pull_WERROR(ndr, NDR_SCALARS, &r->out.result));
20186 : }
20187 0 : return NDR_ERR_SUCCESS;
20188 : }
20189 :
20190 0 : _PUBLIC_ void ndr_print_srvsvc_NetSetFileSecurity(struct ndr_print *ndr, const char *name, ndr_flags_type flags, const struct srvsvc_NetSetFileSecurity *r)
20191 : {
20192 0 : ndr_print_struct(ndr, name, "srvsvc_NetSetFileSecurity");
20193 0 : if (r == NULL) { ndr_print_null(ndr); return; }
20194 0 : ndr->depth++;
20195 0 : if (flags & NDR_SET_VALUES) {
20196 0 : ndr->flags |= LIBNDR_PRINT_SET_VALUES;
20197 : }
20198 0 : if (flags & NDR_IN) {
20199 0 : ndr_print_struct(ndr, "in", "srvsvc_NetSetFileSecurity");
20200 0 : ndr->depth++;
20201 0 : ndr_print_ptr(ndr, "server_unc", r->in.server_unc);
20202 0 : ndr->depth++;
20203 0 : if (r->in.server_unc) {
20204 0 : ndr_print_string(ndr, "server_unc", r->in.server_unc);
20205 : }
20206 0 : ndr->depth--;
20207 0 : ndr_print_ptr(ndr, "share", r->in.share);
20208 0 : ndr->depth++;
20209 0 : if (r->in.share) {
20210 0 : ndr_print_string(ndr, "share", r->in.share);
20211 : }
20212 0 : ndr->depth--;
20213 0 : ndr_print_string(ndr, "file", r->in.file);
20214 0 : ndr_print_security_secinfo(ndr, "securityinformation", r->in.securityinformation);
20215 0 : ndr_print_ptr(ndr, "sd_buf", r->in.sd_buf);
20216 0 : ndr->depth++;
20217 0 : ndr_print_sec_desc_buf(ndr, "sd_buf", r->in.sd_buf);
20218 0 : ndr->depth--;
20219 0 : ndr->depth--;
20220 : }
20221 0 : if (flags & NDR_OUT) {
20222 0 : ndr_print_struct(ndr, "out", "srvsvc_NetSetFileSecurity");
20223 0 : ndr->depth++;
20224 0 : ndr_print_WERROR(ndr, "result", r->out.result);
20225 0 : ndr->depth--;
20226 : }
20227 0 : ndr->depth--;
20228 : }
20229 :
20230 0 : static enum ndr_err_code ndr_push_srvsvc_NetServerTransportAddEx(struct ndr_push *ndr, ndr_flags_type flags, const struct srvsvc_NetServerTransportAddEx *r)
20231 : {
20232 0 : NDR_PUSH_CHECK_FN_FLAGS(ndr, flags);
20233 0 : if (flags & NDR_IN) {
20234 0 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->in.server_unc));
20235 0 : if (r->in.server_unc) {
20236 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->in.server_unc, CH_UTF16)));
20237 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, 0));
20238 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->in.server_unc, CH_UTF16)));
20239 0 : NDR_CHECK(ndr_push_charset(ndr, NDR_SCALARS, r->in.server_unc, ndr_charset_length(r->in.server_unc, CH_UTF16), sizeof(uint16_t), CH_UTF16));
20240 : }
20241 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->in.level));
20242 0 : NDR_CHECK(ndr_push_set_switch_value(ndr, &r->in.info, r->in.level));
20243 0 : NDR_CHECK(ndr_push_srvsvc_NetTransportInfo(ndr, NDR_SCALARS|NDR_BUFFERS, &r->in.info));
20244 : }
20245 0 : if (flags & NDR_OUT) {
20246 0 : NDR_CHECK(ndr_push_WERROR(ndr, NDR_SCALARS, r->out.result));
20247 : }
20248 0 : return NDR_ERR_SUCCESS;
20249 : }
20250 :
20251 0 : static enum ndr_err_code ndr_pull_srvsvc_NetServerTransportAddEx(struct ndr_pull *ndr, ndr_flags_type flags, struct srvsvc_NetServerTransportAddEx *r)
20252 : {
20253 0 : uint32_t _ptr_server_unc;
20254 0 : uint32_t size_server_unc_1 = 0;
20255 0 : uint32_t length_server_unc_1 = 0;
20256 0 : TALLOC_CTX *_mem_save_server_unc_0 = NULL;
20257 0 : NDR_PULL_CHECK_FN_FLAGS(ndr, flags);
20258 0 : if (flags & NDR_IN) {
20259 0 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_server_unc));
20260 0 : if (_ptr_server_unc) {
20261 0 : NDR_PULL_ALLOC(ndr, r->in.server_unc);
20262 : } else {
20263 0 : r->in.server_unc = NULL;
20264 : }
20265 0 : if (r->in.server_unc) {
20266 0 : _mem_save_server_unc_0 = NDR_PULL_GET_MEM_CTX(ndr);
20267 0 : NDR_PULL_SET_MEM_CTX(ndr, r->in.server_unc, 0);
20268 0 : NDR_CHECK(ndr_pull_array_size(ndr, &r->in.server_unc));
20269 0 : NDR_CHECK(ndr_pull_array_length(ndr, &r->in.server_unc));
20270 0 : NDR_CHECK(ndr_steal_array_size(ndr, (void*)&r->in.server_unc, &size_server_unc_1));
20271 0 : NDR_CHECK(ndr_steal_array_length(ndr, (void*)&r->in.server_unc, &length_server_unc_1));
20272 0 : if (length_server_unc_1 > size_server_unc_1) {
20273 0 : return ndr_pull_error(ndr, NDR_ERR_ARRAY_SIZE, "Bad array size %"PRIu32": should exceed array length %"PRIu32"", size_server_unc_1, length_server_unc_1);
20274 : }
20275 0 : NDR_CHECK(ndr_check_string_terminator(ndr, length_server_unc_1, sizeof(uint16_t)));
20276 0 : NDR_CHECK(ndr_pull_charset(ndr, NDR_SCALARS, &r->in.server_unc, length_server_unc_1, sizeof(uint16_t), CH_UTF16));
20277 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_server_unc_0, 0);
20278 : }
20279 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->in.level));
20280 0 : NDR_CHECK(ndr_pull_set_switch_value(ndr, &r->in.info, r->in.level));
20281 0 : NDR_CHECK(ndr_pull_srvsvc_NetTransportInfo(ndr, NDR_SCALARS|NDR_BUFFERS, &r->in.info));
20282 : }
20283 0 : if (flags & NDR_OUT) {
20284 : #ifdef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION
20285 : #endif /* FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION */
20286 0 : NDR_CHECK(ndr_pull_WERROR(ndr, NDR_SCALARS, &r->out.result));
20287 : }
20288 0 : return NDR_ERR_SUCCESS;
20289 : }
20290 :
20291 0 : _PUBLIC_ void ndr_print_srvsvc_NetServerTransportAddEx(struct ndr_print *ndr, const char *name, ndr_flags_type flags, const struct srvsvc_NetServerTransportAddEx *r)
20292 : {
20293 0 : ndr_print_struct(ndr, name, "srvsvc_NetServerTransportAddEx");
20294 0 : if (r == NULL) { ndr_print_null(ndr); return; }
20295 0 : ndr->depth++;
20296 0 : if (flags & NDR_SET_VALUES) {
20297 0 : ndr->flags |= LIBNDR_PRINT_SET_VALUES;
20298 : }
20299 0 : if (flags & NDR_IN) {
20300 0 : ndr_print_struct(ndr, "in", "srvsvc_NetServerTransportAddEx");
20301 0 : ndr->depth++;
20302 0 : ndr_print_ptr(ndr, "server_unc", r->in.server_unc);
20303 0 : ndr->depth++;
20304 0 : if (r->in.server_unc) {
20305 0 : ndr_print_string(ndr, "server_unc", r->in.server_unc);
20306 : }
20307 0 : ndr->depth--;
20308 0 : ndr_print_uint32(ndr, "level", r->in.level);
20309 0 : ndr_print_set_switch_value(ndr, &r->in.info, r->in.level);
20310 0 : ndr_print_srvsvc_NetTransportInfo(ndr, "info", &r->in.info);
20311 0 : ndr->depth--;
20312 : }
20313 0 : if (flags & NDR_OUT) {
20314 0 : ndr_print_struct(ndr, "out", "srvsvc_NetServerTransportAddEx");
20315 0 : ndr->depth++;
20316 0 : ndr_print_WERROR(ndr, "result", r->out.result);
20317 0 : ndr->depth--;
20318 : }
20319 0 : ndr->depth--;
20320 : }
20321 :
20322 0 : static enum ndr_err_code ndr_push_srvsvc_NetServerSetServiceBitsEx(struct ndr_push *ndr, ndr_flags_type flags, const struct srvsvc_NetServerSetServiceBitsEx *r)
20323 : {
20324 0 : NDR_PUSH_CHECK_FN_FLAGS(ndr, flags);
20325 0 : if (flags & NDR_IN) {
20326 0 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->in.server_unc));
20327 0 : if (r->in.server_unc) {
20328 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->in.server_unc, CH_UTF16)));
20329 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, 0));
20330 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->in.server_unc, CH_UTF16)));
20331 0 : NDR_CHECK(ndr_push_charset(ndr, NDR_SCALARS, r->in.server_unc, ndr_charset_length(r->in.server_unc, CH_UTF16), sizeof(uint16_t), CH_UTF16));
20332 : }
20333 0 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->in.emulated_server_unc));
20334 0 : if (r->in.emulated_server_unc) {
20335 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->in.emulated_server_unc, CH_UTF16)));
20336 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, 0));
20337 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->in.emulated_server_unc, CH_UTF16)));
20338 0 : NDR_CHECK(ndr_push_charset(ndr, NDR_SCALARS, r->in.emulated_server_unc, ndr_charset_length(r->in.emulated_server_unc, CH_UTF16), sizeof(uint16_t), CH_UTF16));
20339 : }
20340 0 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->in.transport));
20341 0 : if (r->in.transport) {
20342 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->in.transport, CH_UTF16)));
20343 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, 0));
20344 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->in.transport, CH_UTF16)));
20345 0 : NDR_CHECK(ndr_push_charset(ndr, NDR_SCALARS, r->in.transport, ndr_charset_length(r->in.transport, CH_UTF16), sizeof(uint16_t), CH_UTF16));
20346 : }
20347 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->in.servicebitsofinterest));
20348 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->in.servicebits));
20349 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->in.updateimmediately));
20350 : }
20351 0 : if (flags & NDR_OUT) {
20352 0 : NDR_CHECK(ndr_push_WERROR(ndr, NDR_SCALARS, r->out.result));
20353 : }
20354 0 : return NDR_ERR_SUCCESS;
20355 : }
20356 :
20357 0 : static enum ndr_err_code ndr_pull_srvsvc_NetServerSetServiceBitsEx(struct ndr_pull *ndr, ndr_flags_type flags, struct srvsvc_NetServerSetServiceBitsEx *r)
20358 : {
20359 0 : uint32_t _ptr_server_unc;
20360 0 : uint32_t size_server_unc_1 = 0;
20361 0 : uint32_t length_server_unc_1 = 0;
20362 0 : uint32_t _ptr_emulated_server_unc;
20363 0 : uint32_t size_emulated_server_unc_1 = 0;
20364 0 : uint32_t length_emulated_server_unc_1 = 0;
20365 0 : uint32_t _ptr_transport;
20366 0 : uint32_t size_transport_1 = 0;
20367 0 : uint32_t length_transport_1 = 0;
20368 0 : TALLOC_CTX *_mem_save_server_unc_0 = NULL;
20369 0 : TALLOC_CTX *_mem_save_emulated_server_unc_0 = NULL;
20370 0 : TALLOC_CTX *_mem_save_transport_0 = NULL;
20371 0 : NDR_PULL_CHECK_FN_FLAGS(ndr, flags);
20372 0 : if (flags & NDR_IN) {
20373 0 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_server_unc));
20374 0 : if (_ptr_server_unc) {
20375 0 : NDR_PULL_ALLOC(ndr, r->in.server_unc);
20376 : } else {
20377 0 : r->in.server_unc = NULL;
20378 : }
20379 0 : if (r->in.server_unc) {
20380 0 : _mem_save_server_unc_0 = NDR_PULL_GET_MEM_CTX(ndr);
20381 0 : NDR_PULL_SET_MEM_CTX(ndr, r->in.server_unc, 0);
20382 0 : NDR_CHECK(ndr_pull_array_size(ndr, &r->in.server_unc));
20383 0 : NDR_CHECK(ndr_pull_array_length(ndr, &r->in.server_unc));
20384 0 : NDR_CHECK(ndr_steal_array_size(ndr, (void*)&r->in.server_unc, &size_server_unc_1));
20385 0 : NDR_CHECK(ndr_steal_array_length(ndr, (void*)&r->in.server_unc, &length_server_unc_1));
20386 0 : if (length_server_unc_1 > size_server_unc_1) {
20387 0 : return ndr_pull_error(ndr, NDR_ERR_ARRAY_SIZE, "Bad array size %"PRIu32": should exceed array length %"PRIu32"", size_server_unc_1, length_server_unc_1);
20388 : }
20389 0 : NDR_CHECK(ndr_check_string_terminator(ndr, length_server_unc_1, sizeof(uint16_t)));
20390 0 : NDR_CHECK(ndr_pull_charset(ndr, NDR_SCALARS, &r->in.server_unc, length_server_unc_1, sizeof(uint16_t), CH_UTF16));
20391 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_server_unc_0, 0);
20392 : }
20393 0 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_emulated_server_unc));
20394 0 : if (_ptr_emulated_server_unc) {
20395 0 : NDR_PULL_ALLOC(ndr, r->in.emulated_server_unc);
20396 : } else {
20397 0 : r->in.emulated_server_unc = NULL;
20398 : }
20399 0 : if (r->in.emulated_server_unc) {
20400 0 : _mem_save_emulated_server_unc_0 = NDR_PULL_GET_MEM_CTX(ndr);
20401 0 : NDR_PULL_SET_MEM_CTX(ndr, r->in.emulated_server_unc, 0);
20402 0 : NDR_CHECK(ndr_pull_array_size(ndr, &r->in.emulated_server_unc));
20403 0 : NDR_CHECK(ndr_pull_array_length(ndr, &r->in.emulated_server_unc));
20404 0 : NDR_CHECK(ndr_steal_array_size(ndr, (void*)&r->in.emulated_server_unc, &size_emulated_server_unc_1));
20405 0 : NDR_CHECK(ndr_steal_array_length(ndr, (void*)&r->in.emulated_server_unc, &length_emulated_server_unc_1));
20406 0 : if (length_emulated_server_unc_1 > size_emulated_server_unc_1) {
20407 0 : return ndr_pull_error(ndr, NDR_ERR_ARRAY_SIZE, "Bad array size %"PRIu32": should exceed array length %"PRIu32"", size_emulated_server_unc_1, length_emulated_server_unc_1);
20408 : }
20409 0 : NDR_CHECK(ndr_check_string_terminator(ndr, length_emulated_server_unc_1, sizeof(uint16_t)));
20410 0 : NDR_CHECK(ndr_pull_charset(ndr, NDR_SCALARS, &r->in.emulated_server_unc, length_emulated_server_unc_1, sizeof(uint16_t), CH_UTF16));
20411 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_emulated_server_unc_0, 0);
20412 : }
20413 0 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_transport));
20414 0 : if (_ptr_transport) {
20415 0 : NDR_PULL_ALLOC(ndr, r->in.transport);
20416 : } else {
20417 0 : r->in.transport = NULL;
20418 : }
20419 0 : if (r->in.transport) {
20420 0 : _mem_save_transport_0 = NDR_PULL_GET_MEM_CTX(ndr);
20421 0 : NDR_PULL_SET_MEM_CTX(ndr, r->in.transport, 0);
20422 0 : NDR_CHECK(ndr_pull_array_size(ndr, &r->in.transport));
20423 0 : NDR_CHECK(ndr_pull_array_length(ndr, &r->in.transport));
20424 0 : NDR_CHECK(ndr_steal_array_size(ndr, (void*)&r->in.transport, &size_transport_1));
20425 0 : NDR_CHECK(ndr_steal_array_length(ndr, (void*)&r->in.transport, &length_transport_1));
20426 0 : if (length_transport_1 > size_transport_1) {
20427 0 : return ndr_pull_error(ndr, NDR_ERR_ARRAY_SIZE, "Bad array size %"PRIu32": should exceed array length %"PRIu32"", size_transport_1, length_transport_1);
20428 : }
20429 0 : NDR_CHECK(ndr_check_string_terminator(ndr, length_transport_1, sizeof(uint16_t)));
20430 0 : NDR_CHECK(ndr_pull_charset(ndr, NDR_SCALARS, &r->in.transport, length_transport_1, sizeof(uint16_t), CH_UTF16));
20431 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_transport_0, 0);
20432 : }
20433 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->in.servicebitsofinterest));
20434 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->in.servicebits));
20435 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->in.updateimmediately));
20436 : }
20437 0 : if (flags & NDR_OUT) {
20438 : #ifdef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION
20439 : #endif /* FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION */
20440 0 : NDR_CHECK(ndr_pull_WERROR(ndr, NDR_SCALARS, &r->out.result));
20441 : }
20442 0 : return NDR_ERR_SUCCESS;
20443 : }
20444 :
20445 0 : _PUBLIC_ void ndr_print_srvsvc_NetServerSetServiceBitsEx(struct ndr_print *ndr, const char *name, ndr_flags_type flags, const struct srvsvc_NetServerSetServiceBitsEx *r)
20446 : {
20447 0 : ndr_print_struct(ndr, name, "srvsvc_NetServerSetServiceBitsEx");
20448 0 : if (r == NULL) { ndr_print_null(ndr); return; }
20449 0 : ndr->depth++;
20450 0 : if (flags & NDR_SET_VALUES) {
20451 0 : ndr->flags |= LIBNDR_PRINT_SET_VALUES;
20452 : }
20453 0 : if (flags & NDR_IN) {
20454 0 : ndr_print_struct(ndr, "in", "srvsvc_NetServerSetServiceBitsEx");
20455 0 : ndr->depth++;
20456 0 : ndr_print_ptr(ndr, "server_unc", r->in.server_unc);
20457 0 : ndr->depth++;
20458 0 : if (r->in.server_unc) {
20459 0 : ndr_print_string(ndr, "server_unc", r->in.server_unc);
20460 : }
20461 0 : ndr->depth--;
20462 0 : ndr_print_ptr(ndr, "emulated_server_unc", r->in.emulated_server_unc);
20463 0 : ndr->depth++;
20464 0 : if (r->in.emulated_server_unc) {
20465 0 : ndr_print_string(ndr, "emulated_server_unc", r->in.emulated_server_unc);
20466 : }
20467 0 : ndr->depth--;
20468 0 : ndr_print_ptr(ndr, "transport", r->in.transport);
20469 0 : ndr->depth++;
20470 0 : if (r->in.transport) {
20471 0 : ndr_print_string(ndr, "transport", r->in.transport);
20472 : }
20473 0 : ndr->depth--;
20474 0 : ndr_print_uint32(ndr, "servicebitsofinterest", r->in.servicebitsofinterest);
20475 0 : ndr_print_uint32(ndr, "servicebits", r->in.servicebits);
20476 0 : ndr_print_uint32(ndr, "updateimmediately", r->in.updateimmediately);
20477 0 : ndr->depth--;
20478 : }
20479 0 : if (flags & NDR_OUT) {
20480 0 : ndr_print_struct(ndr, "out", "srvsvc_NetServerSetServiceBitsEx");
20481 0 : ndr->depth++;
20482 0 : ndr_print_WERROR(ndr, "result", r->out.result);
20483 0 : ndr->depth--;
20484 : }
20485 0 : ndr->depth--;
20486 : }
20487 :
20488 0 : static enum ndr_err_code ndr_push_srvsvc_NETRDFSGETVERSION(struct ndr_push *ndr, ndr_flags_type flags, const struct srvsvc_NETRDFSGETVERSION *r)
20489 : {
20490 0 : NDR_PUSH_CHECK_FN_FLAGS(ndr, flags);
20491 0 : if (flags & NDR_IN) {
20492 0 : }
20493 0 : if (flags & NDR_OUT) {
20494 0 : NDR_CHECK(ndr_push_WERROR(ndr, NDR_SCALARS, r->out.result));
20495 : }
20496 0 : return NDR_ERR_SUCCESS;
20497 : }
20498 :
20499 0 : static enum ndr_err_code ndr_pull_srvsvc_NETRDFSGETVERSION(struct ndr_pull *ndr, ndr_flags_type flags, struct srvsvc_NETRDFSGETVERSION *r)
20500 : {
20501 0 : NDR_PULL_CHECK_FN_FLAGS(ndr, flags);
20502 0 : if (flags & NDR_IN) {
20503 0 : }
20504 0 : if (flags & NDR_OUT) {
20505 : #ifdef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION
20506 : #endif /* FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION */
20507 0 : NDR_CHECK(ndr_pull_WERROR(ndr, NDR_SCALARS, &r->out.result));
20508 : }
20509 0 : return NDR_ERR_SUCCESS;
20510 : }
20511 :
20512 0 : _PUBLIC_ void ndr_print_srvsvc_NETRDFSGETVERSION(struct ndr_print *ndr, const char *name, ndr_flags_type flags, const struct srvsvc_NETRDFSGETVERSION *r)
20513 : {
20514 0 : ndr_print_struct(ndr, name, "srvsvc_NETRDFSGETVERSION");
20515 0 : if (r == NULL) { ndr_print_null(ndr); return; }
20516 0 : ndr->depth++;
20517 0 : if (flags & NDR_SET_VALUES) {
20518 0 : ndr->flags |= LIBNDR_PRINT_SET_VALUES;
20519 : }
20520 0 : if (flags & NDR_IN) {
20521 0 : ndr_print_struct(ndr, "in", "srvsvc_NETRDFSGETVERSION");
20522 0 : ndr->depth++;
20523 0 : ndr->depth--;
20524 : }
20525 0 : if (flags & NDR_OUT) {
20526 0 : ndr_print_struct(ndr, "out", "srvsvc_NETRDFSGETVERSION");
20527 0 : ndr->depth++;
20528 0 : ndr_print_WERROR(ndr, "result", r->out.result);
20529 0 : ndr->depth--;
20530 : }
20531 0 : ndr->depth--;
20532 : }
20533 :
20534 0 : static enum ndr_err_code ndr_push_srvsvc_NETRDFSCREATELOCALPARTITION(struct ndr_push *ndr, ndr_flags_type flags, const struct srvsvc_NETRDFSCREATELOCALPARTITION *r)
20535 : {
20536 0 : NDR_PUSH_CHECK_FN_FLAGS(ndr, flags);
20537 0 : if (flags & NDR_IN) {
20538 0 : }
20539 0 : if (flags & NDR_OUT) {
20540 0 : NDR_CHECK(ndr_push_WERROR(ndr, NDR_SCALARS, r->out.result));
20541 : }
20542 0 : return NDR_ERR_SUCCESS;
20543 : }
20544 :
20545 0 : static enum ndr_err_code ndr_pull_srvsvc_NETRDFSCREATELOCALPARTITION(struct ndr_pull *ndr, ndr_flags_type flags, struct srvsvc_NETRDFSCREATELOCALPARTITION *r)
20546 : {
20547 0 : NDR_PULL_CHECK_FN_FLAGS(ndr, flags);
20548 0 : if (flags & NDR_IN) {
20549 0 : }
20550 0 : if (flags & NDR_OUT) {
20551 : #ifdef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION
20552 : #endif /* FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION */
20553 0 : NDR_CHECK(ndr_pull_WERROR(ndr, NDR_SCALARS, &r->out.result));
20554 : }
20555 0 : return NDR_ERR_SUCCESS;
20556 : }
20557 :
20558 0 : _PUBLIC_ void ndr_print_srvsvc_NETRDFSCREATELOCALPARTITION(struct ndr_print *ndr, const char *name, ndr_flags_type flags, const struct srvsvc_NETRDFSCREATELOCALPARTITION *r)
20559 : {
20560 0 : ndr_print_struct(ndr, name, "srvsvc_NETRDFSCREATELOCALPARTITION");
20561 0 : if (r == NULL) { ndr_print_null(ndr); return; }
20562 0 : ndr->depth++;
20563 0 : if (flags & NDR_SET_VALUES) {
20564 0 : ndr->flags |= LIBNDR_PRINT_SET_VALUES;
20565 : }
20566 0 : if (flags & NDR_IN) {
20567 0 : ndr_print_struct(ndr, "in", "srvsvc_NETRDFSCREATELOCALPARTITION");
20568 0 : ndr->depth++;
20569 0 : ndr->depth--;
20570 : }
20571 0 : if (flags & NDR_OUT) {
20572 0 : ndr_print_struct(ndr, "out", "srvsvc_NETRDFSCREATELOCALPARTITION");
20573 0 : ndr->depth++;
20574 0 : ndr_print_WERROR(ndr, "result", r->out.result);
20575 0 : ndr->depth--;
20576 : }
20577 0 : ndr->depth--;
20578 : }
20579 :
20580 0 : static enum ndr_err_code ndr_push_srvsvc_NETRDFSDELETELOCALPARTITION(struct ndr_push *ndr, ndr_flags_type flags, const struct srvsvc_NETRDFSDELETELOCALPARTITION *r)
20581 : {
20582 0 : NDR_PUSH_CHECK_FN_FLAGS(ndr, flags);
20583 0 : if (flags & NDR_IN) {
20584 0 : }
20585 0 : if (flags & NDR_OUT) {
20586 0 : NDR_CHECK(ndr_push_WERROR(ndr, NDR_SCALARS, r->out.result));
20587 : }
20588 0 : return NDR_ERR_SUCCESS;
20589 : }
20590 :
20591 0 : static enum ndr_err_code ndr_pull_srvsvc_NETRDFSDELETELOCALPARTITION(struct ndr_pull *ndr, ndr_flags_type flags, struct srvsvc_NETRDFSDELETELOCALPARTITION *r)
20592 : {
20593 0 : NDR_PULL_CHECK_FN_FLAGS(ndr, flags);
20594 0 : if (flags & NDR_IN) {
20595 0 : }
20596 0 : if (flags & NDR_OUT) {
20597 : #ifdef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION
20598 : #endif /* FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION */
20599 0 : NDR_CHECK(ndr_pull_WERROR(ndr, NDR_SCALARS, &r->out.result));
20600 : }
20601 0 : return NDR_ERR_SUCCESS;
20602 : }
20603 :
20604 0 : _PUBLIC_ void ndr_print_srvsvc_NETRDFSDELETELOCALPARTITION(struct ndr_print *ndr, const char *name, ndr_flags_type flags, const struct srvsvc_NETRDFSDELETELOCALPARTITION *r)
20605 : {
20606 0 : ndr_print_struct(ndr, name, "srvsvc_NETRDFSDELETELOCALPARTITION");
20607 0 : if (r == NULL) { ndr_print_null(ndr); return; }
20608 0 : ndr->depth++;
20609 0 : if (flags & NDR_SET_VALUES) {
20610 0 : ndr->flags |= LIBNDR_PRINT_SET_VALUES;
20611 : }
20612 0 : if (flags & NDR_IN) {
20613 0 : ndr_print_struct(ndr, "in", "srvsvc_NETRDFSDELETELOCALPARTITION");
20614 0 : ndr->depth++;
20615 0 : ndr->depth--;
20616 : }
20617 0 : if (flags & NDR_OUT) {
20618 0 : ndr_print_struct(ndr, "out", "srvsvc_NETRDFSDELETELOCALPARTITION");
20619 0 : ndr->depth++;
20620 0 : ndr_print_WERROR(ndr, "result", r->out.result);
20621 0 : ndr->depth--;
20622 : }
20623 0 : ndr->depth--;
20624 : }
20625 :
20626 0 : static enum ndr_err_code ndr_push_srvsvc_NETRDFSSETLOCALVOLUMESTATE(struct ndr_push *ndr, ndr_flags_type flags, const struct srvsvc_NETRDFSSETLOCALVOLUMESTATE *r)
20627 : {
20628 0 : NDR_PUSH_CHECK_FN_FLAGS(ndr, flags);
20629 0 : if (flags & NDR_IN) {
20630 0 : }
20631 0 : if (flags & NDR_OUT) {
20632 0 : NDR_CHECK(ndr_push_WERROR(ndr, NDR_SCALARS, r->out.result));
20633 : }
20634 0 : return NDR_ERR_SUCCESS;
20635 : }
20636 :
20637 0 : static enum ndr_err_code ndr_pull_srvsvc_NETRDFSSETLOCALVOLUMESTATE(struct ndr_pull *ndr, ndr_flags_type flags, struct srvsvc_NETRDFSSETLOCALVOLUMESTATE *r)
20638 : {
20639 0 : NDR_PULL_CHECK_FN_FLAGS(ndr, flags);
20640 0 : if (flags & NDR_IN) {
20641 0 : }
20642 0 : if (flags & NDR_OUT) {
20643 : #ifdef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION
20644 : #endif /* FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION */
20645 0 : NDR_CHECK(ndr_pull_WERROR(ndr, NDR_SCALARS, &r->out.result));
20646 : }
20647 0 : return NDR_ERR_SUCCESS;
20648 : }
20649 :
20650 0 : _PUBLIC_ void ndr_print_srvsvc_NETRDFSSETLOCALVOLUMESTATE(struct ndr_print *ndr, const char *name, ndr_flags_type flags, const struct srvsvc_NETRDFSSETLOCALVOLUMESTATE *r)
20651 : {
20652 0 : ndr_print_struct(ndr, name, "srvsvc_NETRDFSSETLOCALVOLUMESTATE");
20653 0 : if (r == NULL) { ndr_print_null(ndr); return; }
20654 0 : ndr->depth++;
20655 0 : if (flags & NDR_SET_VALUES) {
20656 0 : ndr->flags |= LIBNDR_PRINT_SET_VALUES;
20657 : }
20658 0 : if (flags & NDR_IN) {
20659 0 : ndr_print_struct(ndr, "in", "srvsvc_NETRDFSSETLOCALVOLUMESTATE");
20660 0 : ndr->depth++;
20661 0 : ndr->depth--;
20662 : }
20663 0 : if (flags & NDR_OUT) {
20664 0 : ndr_print_struct(ndr, "out", "srvsvc_NETRDFSSETLOCALVOLUMESTATE");
20665 0 : ndr->depth++;
20666 0 : ndr_print_WERROR(ndr, "result", r->out.result);
20667 0 : ndr->depth--;
20668 : }
20669 0 : ndr->depth--;
20670 : }
20671 :
20672 0 : static enum ndr_err_code ndr_push_srvsvc_NETRDFSSETSERVERINFO(struct ndr_push *ndr, ndr_flags_type flags, const struct srvsvc_NETRDFSSETSERVERINFO *r)
20673 : {
20674 0 : NDR_PUSH_CHECK_FN_FLAGS(ndr, flags);
20675 0 : if (flags & NDR_IN) {
20676 0 : }
20677 0 : if (flags & NDR_OUT) {
20678 0 : NDR_CHECK(ndr_push_WERROR(ndr, NDR_SCALARS, r->out.result));
20679 : }
20680 0 : return NDR_ERR_SUCCESS;
20681 : }
20682 :
20683 0 : static enum ndr_err_code ndr_pull_srvsvc_NETRDFSSETSERVERINFO(struct ndr_pull *ndr, ndr_flags_type flags, struct srvsvc_NETRDFSSETSERVERINFO *r)
20684 : {
20685 0 : NDR_PULL_CHECK_FN_FLAGS(ndr, flags);
20686 0 : if (flags & NDR_IN) {
20687 0 : }
20688 0 : if (flags & NDR_OUT) {
20689 : #ifdef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION
20690 : #endif /* FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION */
20691 0 : NDR_CHECK(ndr_pull_WERROR(ndr, NDR_SCALARS, &r->out.result));
20692 : }
20693 0 : return NDR_ERR_SUCCESS;
20694 : }
20695 :
20696 0 : _PUBLIC_ void ndr_print_srvsvc_NETRDFSSETSERVERINFO(struct ndr_print *ndr, const char *name, ndr_flags_type flags, const struct srvsvc_NETRDFSSETSERVERINFO *r)
20697 : {
20698 0 : ndr_print_struct(ndr, name, "srvsvc_NETRDFSSETSERVERINFO");
20699 0 : if (r == NULL) { ndr_print_null(ndr); return; }
20700 0 : ndr->depth++;
20701 0 : if (flags & NDR_SET_VALUES) {
20702 0 : ndr->flags |= LIBNDR_PRINT_SET_VALUES;
20703 : }
20704 0 : if (flags & NDR_IN) {
20705 0 : ndr_print_struct(ndr, "in", "srvsvc_NETRDFSSETSERVERINFO");
20706 0 : ndr->depth++;
20707 0 : ndr->depth--;
20708 : }
20709 0 : if (flags & NDR_OUT) {
20710 0 : ndr_print_struct(ndr, "out", "srvsvc_NETRDFSSETSERVERINFO");
20711 0 : ndr->depth++;
20712 0 : ndr_print_WERROR(ndr, "result", r->out.result);
20713 0 : ndr->depth--;
20714 : }
20715 0 : ndr->depth--;
20716 : }
20717 :
20718 0 : static enum ndr_err_code ndr_push_srvsvc_NETRDFSCREATEEXITPOINT(struct ndr_push *ndr, ndr_flags_type flags, const struct srvsvc_NETRDFSCREATEEXITPOINT *r)
20719 : {
20720 0 : NDR_PUSH_CHECK_FN_FLAGS(ndr, flags);
20721 0 : if (flags & NDR_IN) {
20722 0 : }
20723 0 : if (flags & NDR_OUT) {
20724 0 : NDR_CHECK(ndr_push_WERROR(ndr, NDR_SCALARS, r->out.result));
20725 : }
20726 0 : return NDR_ERR_SUCCESS;
20727 : }
20728 :
20729 0 : static enum ndr_err_code ndr_pull_srvsvc_NETRDFSCREATEEXITPOINT(struct ndr_pull *ndr, ndr_flags_type flags, struct srvsvc_NETRDFSCREATEEXITPOINT *r)
20730 : {
20731 0 : NDR_PULL_CHECK_FN_FLAGS(ndr, flags);
20732 0 : if (flags & NDR_IN) {
20733 0 : }
20734 0 : if (flags & NDR_OUT) {
20735 : #ifdef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION
20736 : #endif /* FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION */
20737 0 : NDR_CHECK(ndr_pull_WERROR(ndr, NDR_SCALARS, &r->out.result));
20738 : }
20739 0 : return NDR_ERR_SUCCESS;
20740 : }
20741 :
20742 0 : _PUBLIC_ void ndr_print_srvsvc_NETRDFSCREATEEXITPOINT(struct ndr_print *ndr, const char *name, ndr_flags_type flags, const struct srvsvc_NETRDFSCREATEEXITPOINT *r)
20743 : {
20744 0 : ndr_print_struct(ndr, name, "srvsvc_NETRDFSCREATEEXITPOINT");
20745 0 : if (r == NULL) { ndr_print_null(ndr); return; }
20746 0 : ndr->depth++;
20747 0 : if (flags & NDR_SET_VALUES) {
20748 0 : ndr->flags |= LIBNDR_PRINT_SET_VALUES;
20749 : }
20750 0 : if (flags & NDR_IN) {
20751 0 : ndr_print_struct(ndr, "in", "srvsvc_NETRDFSCREATEEXITPOINT");
20752 0 : ndr->depth++;
20753 0 : ndr->depth--;
20754 : }
20755 0 : if (flags & NDR_OUT) {
20756 0 : ndr_print_struct(ndr, "out", "srvsvc_NETRDFSCREATEEXITPOINT");
20757 0 : ndr->depth++;
20758 0 : ndr_print_WERROR(ndr, "result", r->out.result);
20759 0 : ndr->depth--;
20760 : }
20761 0 : ndr->depth--;
20762 : }
20763 :
20764 0 : static enum ndr_err_code ndr_push_srvsvc_NETRDFSDELETEEXITPOINT(struct ndr_push *ndr, ndr_flags_type flags, const struct srvsvc_NETRDFSDELETEEXITPOINT *r)
20765 : {
20766 0 : NDR_PUSH_CHECK_FN_FLAGS(ndr, flags);
20767 0 : if (flags & NDR_IN) {
20768 0 : }
20769 0 : if (flags & NDR_OUT) {
20770 0 : NDR_CHECK(ndr_push_WERROR(ndr, NDR_SCALARS, r->out.result));
20771 : }
20772 0 : return NDR_ERR_SUCCESS;
20773 : }
20774 :
20775 0 : static enum ndr_err_code ndr_pull_srvsvc_NETRDFSDELETEEXITPOINT(struct ndr_pull *ndr, ndr_flags_type flags, struct srvsvc_NETRDFSDELETEEXITPOINT *r)
20776 : {
20777 0 : NDR_PULL_CHECK_FN_FLAGS(ndr, flags);
20778 0 : if (flags & NDR_IN) {
20779 0 : }
20780 0 : if (flags & NDR_OUT) {
20781 : #ifdef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION
20782 : #endif /* FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION */
20783 0 : NDR_CHECK(ndr_pull_WERROR(ndr, NDR_SCALARS, &r->out.result));
20784 : }
20785 0 : return NDR_ERR_SUCCESS;
20786 : }
20787 :
20788 0 : _PUBLIC_ void ndr_print_srvsvc_NETRDFSDELETEEXITPOINT(struct ndr_print *ndr, const char *name, ndr_flags_type flags, const struct srvsvc_NETRDFSDELETEEXITPOINT *r)
20789 : {
20790 0 : ndr_print_struct(ndr, name, "srvsvc_NETRDFSDELETEEXITPOINT");
20791 0 : if (r == NULL) { ndr_print_null(ndr); return; }
20792 0 : ndr->depth++;
20793 0 : if (flags & NDR_SET_VALUES) {
20794 0 : ndr->flags |= LIBNDR_PRINT_SET_VALUES;
20795 : }
20796 0 : if (flags & NDR_IN) {
20797 0 : ndr_print_struct(ndr, "in", "srvsvc_NETRDFSDELETEEXITPOINT");
20798 0 : ndr->depth++;
20799 0 : ndr->depth--;
20800 : }
20801 0 : if (flags & NDR_OUT) {
20802 0 : ndr_print_struct(ndr, "out", "srvsvc_NETRDFSDELETEEXITPOINT");
20803 0 : ndr->depth++;
20804 0 : ndr_print_WERROR(ndr, "result", r->out.result);
20805 0 : ndr->depth--;
20806 : }
20807 0 : ndr->depth--;
20808 : }
20809 :
20810 0 : static enum ndr_err_code ndr_push_srvsvc_NETRDFSMODIFYPREFIX(struct ndr_push *ndr, ndr_flags_type flags, const struct srvsvc_NETRDFSMODIFYPREFIX *r)
20811 : {
20812 0 : NDR_PUSH_CHECK_FN_FLAGS(ndr, flags);
20813 0 : if (flags & NDR_IN) {
20814 0 : }
20815 0 : if (flags & NDR_OUT) {
20816 0 : NDR_CHECK(ndr_push_WERROR(ndr, NDR_SCALARS, r->out.result));
20817 : }
20818 0 : return NDR_ERR_SUCCESS;
20819 : }
20820 :
20821 0 : static enum ndr_err_code ndr_pull_srvsvc_NETRDFSMODIFYPREFIX(struct ndr_pull *ndr, ndr_flags_type flags, struct srvsvc_NETRDFSMODIFYPREFIX *r)
20822 : {
20823 0 : NDR_PULL_CHECK_FN_FLAGS(ndr, flags);
20824 0 : if (flags & NDR_IN) {
20825 0 : }
20826 0 : if (flags & NDR_OUT) {
20827 : #ifdef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION
20828 : #endif /* FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION */
20829 0 : NDR_CHECK(ndr_pull_WERROR(ndr, NDR_SCALARS, &r->out.result));
20830 : }
20831 0 : return NDR_ERR_SUCCESS;
20832 : }
20833 :
20834 0 : _PUBLIC_ void ndr_print_srvsvc_NETRDFSMODIFYPREFIX(struct ndr_print *ndr, const char *name, ndr_flags_type flags, const struct srvsvc_NETRDFSMODIFYPREFIX *r)
20835 : {
20836 0 : ndr_print_struct(ndr, name, "srvsvc_NETRDFSMODIFYPREFIX");
20837 0 : if (r == NULL) { ndr_print_null(ndr); return; }
20838 0 : ndr->depth++;
20839 0 : if (flags & NDR_SET_VALUES) {
20840 0 : ndr->flags |= LIBNDR_PRINT_SET_VALUES;
20841 : }
20842 0 : if (flags & NDR_IN) {
20843 0 : ndr_print_struct(ndr, "in", "srvsvc_NETRDFSMODIFYPREFIX");
20844 0 : ndr->depth++;
20845 0 : ndr->depth--;
20846 : }
20847 0 : if (flags & NDR_OUT) {
20848 0 : ndr_print_struct(ndr, "out", "srvsvc_NETRDFSMODIFYPREFIX");
20849 0 : ndr->depth++;
20850 0 : ndr_print_WERROR(ndr, "result", r->out.result);
20851 0 : ndr->depth--;
20852 : }
20853 0 : ndr->depth--;
20854 : }
20855 :
20856 0 : static enum ndr_err_code ndr_push_srvsvc_NETRDFSFIXLOCALVOLUME(struct ndr_push *ndr, ndr_flags_type flags, const struct srvsvc_NETRDFSFIXLOCALVOLUME *r)
20857 : {
20858 0 : NDR_PUSH_CHECK_FN_FLAGS(ndr, flags);
20859 0 : if (flags & NDR_IN) {
20860 0 : }
20861 0 : if (flags & NDR_OUT) {
20862 0 : NDR_CHECK(ndr_push_WERROR(ndr, NDR_SCALARS, r->out.result));
20863 : }
20864 0 : return NDR_ERR_SUCCESS;
20865 : }
20866 :
20867 0 : static enum ndr_err_code ndr_pull_srvsvc_NETRDFSFIXLOCALVOLUME(struct ndr_pull *ndr, ndr_flags_type flags, struct srvsvc_NETRDFSFIXLOCALVOLUME *r)
20868 : {
20869 0 : NDR_PULL_CHECK_FN_FLAGS(ndr, flags);
20870 0 : if (flags & NDR_IN) {
20871 0 : }
20872 0 : if (flags & NDR_OUT) {
20873 : #ifdef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION
20874 : #endif /* FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION */
20875 0 : NDR_CHECK(ndr_pull_WERROR(ndr, NDR_SCALARS, &r->out.result));
20876 : }
20877 0 : return NDR_ERR_SUCCESS;
20878 : }
20879 :
20880 0 : _PUBLIC_ void ndr_print_srvsvc_NETRDFSFIXLOCALVOLUME(struct ndr_print *ndr, const char *name, ndr_flags_type flags, const struct srvsvc_NETRDFSFIXLOCALVOLUME *r)
20881 : {
20882 0 : ndr_print_struct(ndr, name, "srvsvc_NETRDFSFIXLOCALVOLUME");
20883 0 : if (r == NULL) { ndr_print_null(ndr); return; }
20884 0 : ndr->depth++;
20885 0 : if (flags & NDR_SET_VALUES) {
20886 0 : ndr->flags |= LIBNDR_PRINT_SET_VALUES;
20887 : }
20888 0 : if (flags & NDR_IN) {
20889 0 : ndr_print_struct(ndr, "in", "srvsvc_NETRDFSFIXLOCALVOLUME");
20890 0 : ndr->depth++;
20891 0 : ndr->depth--;
20892 : }
20893 0 : if (flags & NDR_OUT) {
20894 0 : ndr_print_struct(ndr, "out", "srvsvc_NETRDFSFIXLOCALVOLUME");
20895 0 : ndr->depth++;
20896 0 : ndr_print_WERROR(ndr, "result", r->out.result);
20897 0 : ndr->depth--;
20898 : }
20899 0 : ndr->depth--;
20900 : }
20901 :
20902 0 : static enum ndr_err_code ndr_push_srvsvc_NETRDFSMANAGERREPORTSITEINFO(struct ndr_push *ndr, ndr_flags_type flags, const struct srvsvc_NETRDFSMANAGERREPORTSITEINFO *r)
20903 : {
20904 0 : NDR_PUSH_CHECK_FN_FLAGS(ndr, flags);
20905 0 : if (flags & NDR_IN) {
20906 0 : }
20907 0 : if (flags & NDR_OUT) {
20908 0 : NDR_CHECK(ndr_push_WERROR(ndr, NDR_SCALARS, r->out.result));
20909 : }
20910 0 : return NDR_ERR_SUCCESS;
20911 : }
20912 :
20913 0 : static enum ndr_err_code ndr_pull_srvsvc_NETRDFSMANAGERREPORTSITEINFO(struct ndr_pull *ndr, ndr_flags_type flags, struct srvsvc_NETRDFSMANAGERREPORTSITEINFO *r)
20914 : {
20915 0 : NDR_PULL_CHECK_FN_FLAGS(ndr, flags);
20916 0 : if (flags & NDR_IN) {
20917 0 : }
20918 0 : if (flags & NDR_OUT) {
20919 : #ifdef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION
20920 : #endif /* FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION */
20921 0 : NDR_CHECK(ndr_pull_WERROR(ndr, NDR_SCALARS, &r->out.result));
20922 : }
20923 0 : return NDR_ERR_SUCCESS;
20924 : }
20925 :
20926 0 : _PUBLIC_ void ndr_print_srvsvc_NETRDFSMANAGERREPORTSITEINFO(struct ndr_print *ndr, const char *name, ndr_flags_type flags, const struct srvsvc_NETRDFSMANAGERREPORTSITEINFO *r)
20927 : {
20928 0 : ndr_print_struct(ndr, name, "srvsvc_NETRDFSMANAGERREPORTSITEINFO");
20929 0 : if (r == NULL) { ndr_print_null(ndr); return; }
20930 0 : ndr->depth++;
20931 0 : if (flags & NDR_SET_VALUES) {
20932 0 : ndr->flags |= LIBNDR_PRINT_SET_VALUES;
20933 : }
20934 0 : if (flags & NDR_IN) {
20935 0 : ndr_print_struct(ndr, "in", "srvsvc_NETRDFSMANAGERREPORTSITEINFO");
20936 0 : ndr->depth++;
20937 0 : ndr->depth--;
20938 : }
20939 0 : if (flags & NDR_OUT) {
20940 0 : ndr_print_struct(ndr, "out", "srvsvc_NETRDFSMANAGERREPORTSITEINFO");
20941 0 : ndr->depth++;
20942 0 : ndr_print_WERROR(ndr, "result", r->out.result);
20943 0 : ndr->depth--;
20944 : }
20945 0 : ndr->depth--;
20946 : }
20947 :
20948 0 : static enum ndr_err_code ndr_push_srvsvc_NETRSERVERTRANSPORTDELEX(struct ndr_push *ndr, ndr_flags_type flags, const struct srvsvc_NETRSERVERTRANSPORTDELEX *r)
20949 : {
20950 0 : NDR_PUSH_CHECK_FN_FLAGS(ndr, flags);
20951 0 : if (flags & NDR_IN) {
20952 0 : }
20953 0 : if (flags & NDR_OUT) {
20954 0 : NDR_CHECK(ndr_push_WERROR(ndr, NDR_SCALARS, r->out.result));
20955 : }
20956 0 : return NDR_ERR_SUCCESS;
20957 : }
20958 :
20959 0 : static enum ndr_err_code ndr_pull_srvsvc_NETRSERVERTRANSPORTDELEX(struct ndr_pull *ndr, ndr_flags_type flags, struct srvsvc_NETRSERVERTRANSPORTDELEX *r)
20960 : {
20961 0 : NDR_PULL_CHECK_FN_FLAGS(ndr, flags);
20962 0 : if (flags & NDR_IN) {
20963 0 : }
20964 0 : if (flags & NDR_OUT) {
20965 : #ifdef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION
20966 : #endif /* FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION */
20967 0 : NDR_CHECK(ndr_pull_WERROR(ndr, NDR_SCALARS, &r->out.result));
20968 : }
20969 0 : return NDR_ERR_SUCCESS;
20970 : }
20971 :
20972 0 : _PUBLIC_ void ndr_print_srvsvc_NETRSERVERTRANSPORTDELEX(struct ndr_print *ndr, const char *name, ndr_flags_type flags, const struct srvsvc_NETRSERVERTRANSPORTDELEX *r)
20973 : {
20974 0 : ndr_print_struct(ndr, name, "srvsvc_NETRSERVERTRANSPORTDELEX");
20975 0 : if (r == NULL) { ndr_print_null(ndr); return; }
20976 0 : ndr->depth++;
20977 0 : if (flags & NDR_SET_VALUES) {
20978 0 : ndr->flags |= LIBNDR_PRINT_SET_VALUES;
20979 : }
20980 0 : if (flags & NDR_IN) {
20981 0 : ndr_print_struct(ndr, "in", "srvsvc_NETRSERVERTRANSPORTDELEX");
20982 0 : ndr->depth++;
20983 0 : ndr->depth--;
20984 : }
20985 0 : if (flags & NDR_OUT) {
20986 0 : ndr_print_struct(ndr, "out", "srvsvc_NETRSERVERTRANSPORTDELEX");
20987 0 : ndr->depth++;
20988 0 : ndr_print_WERROR(ndr, "result", r->out.result);
20989 0 : ndr->depth--;
20990 : }
20991 0 : ndr->depth--;
20992 : }
20993 :
20994 : #ifndef SKIP_NDR_TABLE_srvsvc
20995 : static const struct ndr_interface_public_struct srvsvc_public_structs[] = {
20996 : {
20997 : .name = "srvsvc_NetSrvInfo100",
20998 : .struct_size = sizeof(struct srvsvc_NetSrvInfo100 ),
20999 : .ndr_push = (ndr_push_flags_fn_t) ndr_push_srvsvc_NetSrvInfo100,
21000 : .ndr_pull = (ndr_pull_flags_fn_t) ndr_pull_srvsvc_NetSrvInfo100,
21001 : .ndr_print = (ndr_print_function_t) ndr_print_flags_srvsvc_NetSrvInfo100,
21002 : },
21003 : {
21004 : .name = "srvsvc_NetSrvInfo101",
21005 : .struct_size = sizeof(struct srvsvc_NetSrvInfo101 ),
21006 : .ndr_push = (ndr_push_flags_fn_t) ndr_push_srvsvc_NetSrvInfo101,
21007 : .ndr_pull = (ndr_pull_flags_fn_t) ndr_pull_srvsvc_NetSrvInfo101,
21008 : .ndr_print = (ndr_print_function_t) ndr_print_flags_srvsvc_NetSrvInfo101,
21009 : },
21010 : { .name = NULL }
21011 : };
21012 :
21013 : static const struct ndr_interface_call srvsvc_calls[] = {
21014 : {
21015 : "srvsvc_NetCharDevEnum",
21016 : sizeof(struct srvsvc_NetCharDevEnum),
21017 : (ndr_push_flags_fn_t) ndr_push_srvsvc_NetCharDevEnum,
21018 : (ndr_pull_flags_fn_t) ndr_pull_srvsvc_NetCharDevEnum,
21019 : (ndr_print_function_t) ndr_print_srvsvc_NetCharDevEnum,
21020 : { 0, NULL },
21021 : { 0, NULL },
21022 : },
21023 : {
21024 : "srvsvc_NetCharDevGetInfo",
21025 : sizeof(struct srvsvc_NetCharDevGetInfo),
21026 : (ndr_push_flags_fn_t) ndr_push_srvsvc_NetCharDevGetInfo,
21027 : (ndr_pull_flags_fn_t) ndr_pull_srvsvc_NetCharDevGetInfo,
21028 : (ndr_print_function_t) ndr_print_srvsvc_NetCharDevGetInfo,
21029 : { 0, NULL },
21030 : { 0, NULL },
21031 : },
21032 : {
21033 : "srvsvc_NetCharDevControl",
21034 : sizeof(struct srvsvc_NetCharDevControl),
21035 : (ndr_push_flags_fn_t) ndr_push_srvsvc_NetCharDevControl,
21036 : (ndr_pull_flags_fn_t) ndr_pull_srvsvc_NetCharDevControl,
21037 : (ndr_print_function_t) ndr_print_srvsvc_NetCharDevControl,
21038 : { 0, NULL },
21039 : { 0, NULL },
21040 : },
21041 : {
21042 : "srvsvc_NetCharDevQEnum",
21043 : sizeof(struct srvsvc_NetCharDevQEnum),
21044 : (ndr_push_flags_fn_t) ndr_push_srvsvc_NetCharDevQEnum,
21045 : (ndr_pull_flags_fn_t) ndr_pull_srvsvc_NetCharDevQEnum,
21046 : (ndr_print_function_t) ndr_print_srvsvc_NetCharDevQEnum,
21047 : { 0, NULL },
21048 : { 0, NULL },
21049 : },
21050 : {
21051 : "srvsvc_NetCharDevQGetInfo",
21052 : sizeof(struct srvsvc_NetCharDevQGetInfo),
21053 : (ndr_push_flags_fn_t) ndr_push_srvsvc_NetCharDevQGetInfo,
21054 : (ndr_pull_flags_fn_t) ndr_pull_srvsvc_NetCharDevQGetInfo,
21055 : (ndr_print_function_t) ndr_print_srvsvc_NetCharDevQGetInfo,
21056 : { 0, NULL },
21057 : { 0, NULL },
21058 : },
21059 : {
21060 : "srvsvc_NetCharDevQSetInfo",
21061 : sizeof(struct srvsvc_NetCharDevQSetInfo),
21062 : (ndr_push_flags_fn_t) ndr_push_srvsvc_NetCharDevQSetInfo,
21063 : (ndr_pull_flags_fn_t) ndr_pull_srvsvc_NetCharDevQSetInfo,
21064 : (ndr_print_function_t) ndr_print_srvsvc_NetCharDevQSetInfo,
21065 : { 0, NULL },
21066 : { 0, NULL },
21067 : },
21068 : {
21069 : "srvsvc_NetCharDevQPurge",
21070 : sizeof(struct srvsvc_NetCharDevQPurge),
21071 : (ndr_push_flags_fn_t) ndr_push_srvsvc_NetCharDevQPurge,
21072 : (ndr_pull_flags_fn_t) ndr_pull_srvsvc_NetCharDevQPurge,
21073 : (ndr_print_function_t) ndr_print_srvsvc_NetCharDevQPurge,
21074 : { 0, NULL },
21075 : { 0, NULL },
21076 : },
21077 : {
21078 : "srvsvc_NetCharDevQPurgeSelf",
21079 : sizeof(struct srvsvc_NetCharDevQPurgeSelf),
21080 : (ndr_push_flags_fn_t) ndr_push_srvsvc_NetCharDevQPurgeSelf,
21081 : (ndr_pull_flags_fn_t) ndr_pull_srvsvc_NetCharDevQPurgeSelf,
21082 : (ndr_print_function_t) ndr_print_srvsvc_NetCharDevQPurgeSelf,
21083 : { 0, NULL },
21084 : { 0, NULL },
21085 : },
21086 : {
21087 : "srvsvc_NetConnEnum",
21088 : sizeof(struct srvsvc_NetConnEnum),
21089 : (ndr_push_flags_fn_t) ndr_push_srvsvc_NetConnEnum,
21090 : (ndr_pull_flags_fn_t) ndr_pull_srvsvc_NetConnEnum,
21091 : (ndr_print_function_t) ndr_print_srvsvc_NetConnEnum,
21092 : { 0, NULL },
21093 : { 0, NULL },
21094 : },
21095 : {
21096 : "srvsvc_NetFileEnum",
21097 : sizeof(struct srvsvc_NetFileEnum),
21098 : (ndr_push_flags_fn_t) ndr_push_srvsvc_NetFileEnum,
21099 : (ndr_pull_flags_fn_t) ndr_pull_srvsvc_NetFileEnum,
21100 : (ndr_print_function_t) ndr_print_srvsvc_NetFileEnum,
21101 : { 0, NULL },
21102 : { 0, NULL },
21103 : },
21104 : {
21105 : "srvsvc_NetFileGetInfo",
21106 : sizeof(struct srvsvc_NetFileGetInfo),
21107 : (ndr_push_flags_fn_t) ndr_push_srvsvc_NetFileGetInfo,
21108 : (ndr_pull_flags_fn_t) ndr_pull_srvsvc_NetFileGetInfo,
21109 : (ndr_print_function_t) ndr_print_srvsvc_NetFileGetInfo,
21110 : { 0, NULL },
21111 : { 0, NULL },
21112 : },
21113 : {
21114 : "srvsvc_NetFileClose",
21115 : sizeof(struct srvsvc_NetFileClose),
21116 : (ndr_push_flags_fn_t) ndr_push_srvsvc_NetFileClose,
21117 : (ndr_pull_flags_fn_t) ndr_pull_srvsvc_NetFileClose,
21118 : (ndr_print_function_t) ndr_print_srvsvc_NetFileClose,
21119 : { 0, NULL },
21120 : { 0, NULL },
21121 : },
21122 : {
21123 : "srvsvc_NetSessEnum",
21124 : sizeof(struct srvsvc_NetSessEnum),
21125 : (ndr_push_flags_fn_t) ndr_push_srvsvc_NetSessEnum,
21126 : (ndr_pull_flags_fn_t) ndr_pull_srvsvc_NetSessEnum,
21127 : (ndr_print_function_t) ndr_print_srvsvc_NetSessEnum,
21128 : { 0, NULL },
21129 : { 0, NULL },
21130 : },
21131 : {
21132 : "srvsvc_NetSessDel",
21133 : sizeof(struct srvsvc_NetSessDel),
21134 : (ndr_push_flags_fn_t) ndr_push_srvsvc_NetSessDel,
21135 : (ndr_pull_flags_fn_t) ndr_pull_srvsvc_NetSessDel,
21136 : (ndr_print_function_t) ndr_print_srvsvc_NetSessDel,
21137 : { 0, NULL },
21138 : { 0, NULL },
21139 : },
21140 : {
21141 : "srvsvc_NetShareAdd",
21142 : sizeof(struct srvsvc_NetShareAdd),
21143 : (ndr_push_flags_fn_t) ndr_push_srvsvc_NetShareAdd,
21144 : (ndr_pull_flags_fn_t) ndr_pull_srvsvc_NetShareAdd,
21145 : (ndr_print_function_t) ndr_print_srvsvc_NetShareAdd,
21146 : { 0, NULL },
21147 : { 0, NULL },
21148 : },
21149 : {
21150 : "srvsvc_NetShareEnumAll",
21151 : sizeof(struct srvsvc_NetShareEnumAll),
21152 : (ndr_push_flags_fn_t) ndr_push_srvsvc_NetShareEnumAll,
21153 : (ndr_pull_flags_fn_t) ndr_pull_srvsvc_NetShareEnumAll,
21154 : (ndr_print_function_t) ndr_print_srvsvc_NetShareEnumAll,
21155 : { 0, NULL },
21156 : { 0, NULL },
21157 : },
21158 : {
21159 : "srvsvc_NetShareGetInfo",
21160 : sizeof(struct srvsvc_NetShareGetInfo),
21161 : (ndr_push_flags_fn_t) ndr_push_srvsvc_NetShareGetInfo,
21162 : (ndr_pull_flags_fn_t) ndr_pull_srvsvc_NetShareGetInfo,
21163 : (ndr_print_function_t) ndr_print_srvsvc_NetShareGetInfo,
21164 : { 0, NULL },
21165 : { 0, NULL },
21166 : },
21167 : {
21168 : "srvsvc_NetShareSetInfo",
21169 : sizeof(struct srvsvc_NetShareSetInfo),
21170 : (ndr_push_flags_fn_t) ndr_push_srvsvc_NetShareSetInfo,
21171 : (ndr_pull_flags_fn_t) ndr_pull_srvsvc_NetShareSetInfo,
21172 : (ndr_print_function_t) ndr_print_srvsvc_NetShareSetInfo,
21173 : { 0, NULL },
21174 : { 0, NULL },
21175 : },
21176 : {
21177 : "srvsvc_NetShareDel",
21178 : sizeof(struct srvsvc_NetShareDel),
21179 : (ndr_push_flags_fn_t) ndr_push_srvsvc_NetShareDel,
21180 : (ndr_pull_flags_fn_t) ndr_pull_srvsvc_NetShareDel,
21181 : (ndr_print_function_t) ndr_print_srvsvc_NetShareDel,
21182 : { 0, NULL },
21183 : { 0, NULL },
21184 : },
21185 : {
21186 : "srvsvc_NetShareDelSticky",
21187 : sizeof(struct srvsvc_NetShareDelSticky),
21188 : (ndr_push_flags_fn_t) ndr_push_srvsvc_NetShareDelSticky,
21189 : (ndr_pull_flags_fn_t) ndr_pull_srvsvc_NetShareDelSticky,
21190 : (ndr_print_function_t) ndr_print_srvsvc_NetShareDelSticky,
21191 : { 0, NULL },
21192 : { 0, NULL },
21193 : },
21194 : {
21195 : "srvsvc_NetShareCheck",
21196 : sizeof(struct srvsvc_NetShareCheck),
21197 : (ndr_push_flags_fn_t) ndr_push_srvsvc_NetShareCheck,
21198 : (ndr_pull_flags_fn_t) ndr_pull_srvsvc_NetShareCheck,
21199 : (ndr_print_function_t) ndr_print_srvsvc_NetShareCheck,
21200 : { 0, NULL },
21201 : { 0, NULL },
21202 : },
21203 : {
21204 : "srvsvc_NetSrvGetInfo",
21205 : sizeof(struct srvsvc_NetSrvGetInfo),
21206 : (ndr_push_flags_fn_t) ndr_push_srvsvc_NetSrvGetInfo,
21207 : (ndr_pull_flags_fn_t) ndr_pull_srvsvc_NetSrvGetInfo,
21208 : (ndr_print_function_t) ndr_print_srvsvc_NetSrvGetInfo,
21209 : { 0, NULL },
21210 : { 0, NULL },
21211 : },
21212 : {
21213 : "srvsvc_NetSrvSetInfo",
21214 : sizeof(struct srvsvc_NetSrvSetInfo),
21215 : (ndr_push_flags_fn_t) ndr_push_srvsvc_NetSrvSetInfo,
21216 : (ndr_pull_flags_fn_t) ndr_pull_srvsvc_NetSrvSetInfo,
21217 : (ndr_print_function_t) ndr_print_srvsvc_NetSrvSetInfo,
21218 : { 0, NULL },
21219 : { 0, NULL },
21220 : },
21221 : {
21222 : "srvsvc_NetDiskEnum",
21223 : sizeof(struct srvsvc_NetDiskEnum),
21224 : (ndr_push_flags_fn_t) ndr_push_srvsvc_NetDiskEnum,
21225 : (ndr_pull_flags_fn_t) ndr_pull_srvsvc_NetDiskEnum,
21226 : (ndr_print_function_t) ndr_print_srvsvc_NetDiskEnum,
21227 : { 0, NULL },
21228 : { 0, NULL },
21229 : },
21230 : {
21231 : "srvsvc_NetServerStatisticsGet",
21232 : sizeof(struct srvsvc_NetServerStatisticsGet),
21233 : (ndr_push_flags_fn_t) ndr_push_srvsvc_NetServerStatisticsGet,
21234 : (ndr_pull_flags_fn_t) ndr_pull_srvsvc_NetServerStatisticsGet,
21235 : (ndr_print_function_t) ndr_print_srvsvc_NetServerStatisticsGet,
21236 : { 0, NULL },
21237 : { 0, NULL },
21238 : },
21239 : {
21240 : "srvsvc_NetTransportAdd",
21241 : sizeof(struct srvsvc_NetTransportAdd),
21242 : (ndr_push_flags_fn_t) ndr_push_srvsvc_NetTransportAdd,
21243 : (ndr_pull_flags_fn_t) ndr_pull_srvsvc_NetTransportAdd,
21244 : (ndr_print_function_t) ndr_print_srvsvc_NetTransportAdd,
21245 : { 0, NULL },
21246 : { 0, NULL },
21247 : },
21248 : {
21249 : "srvsvc_NetTransportEnum",
21250 : sizeof(struct srvsvc_NetTransportEnum),
21251 : (ndr_push_flags_fn_t) ndr_push_srvsvc_NetTransportEnum,
21252 : (ndr_pull_flags_fn_t) ndr_pull_srvsvc_NetTransportEnum,
21253 : (ndr_print_function_t) ndr_print_srvsvc_NetTransportEnum,
21254 : { 0, NULL },
21255 : { 0, NULL },
21256 : },
21257 : {
21258 : "srvsvc_NetTransportDel",
21259 : sizeof(struct srvsvc_NetTransportDel),
21260 : (ndr_push_flags_fn_t) ndr_push_srvsvc_NetTransportDel,
21261 : (ndr_pull_flags_fn_t) ndr_pull_srvsvc_NetTransportDel,
21262 : (ndr_print_function_t) ndr_print_srvsvc_NetTransportDel,
21263 : { 0, NULL },
21264 : { 0, NULL },
21265 : },
21266 : {
21267 : "srvsvc_NetRemoteTOD",
21268 : sizeof(struct srvsvc_NetRemoteTOD),
21269 : (ndr_push_flags_fn_t) ndr_push_srvsvc_NetRemoteTOD,
21270 : (ndr_pull_flags_fn_t) ndr_pull_srvsvc_NetRemoteTOD,
21271 : (ndr_print_function_t) ndr_print_srvsvc_NetRemoteTOD,
21272 : { 0, NULL },
21273 : { 0, NULL },
21274 : },
21275 : {
21276 : "srvsvc_NetSetServiceBits",
21277 : sizeof(struct srvsvc_NetSetServiceBits),
21278 : (ndr_push_flags_fn_t) ndr_push_srvsvc_NetSetServiceBits,
21279 : (ndr_pull_flags_fn_t) ndr_pull_srvsvc_NetSetServiceBits,
21280 : (ndr_print_function_t) ndr_print_srvsvc_NetSetServiceBits,
21281 : { 0, NULL },
21282 : { 0, NULL },
21283 : },
21284 : {
21285 : "srvsvc_NetPathType",
21286 : sizeof(struct srvsvc_NetPathType),
21287 : (ndr_push_flags_fn_t) ndr_push_srvsvc_NetPathType,
21288 : (ndr_pull_flags_fn_t) ndr_pull_srvsvc_NetPathType,
21289 : (ndr_print_function_t) ndr_print_srvsvc_NetPathType,
21290 : { 0, NULL },
21291 : { 0, NULL },
21292 : },
21293 : {
21294 : "srvsvc_NetPathCanonicalize",
21295 : sizeof(struct srvsvc_NetPathCanonicalize),
21296 : (ndr_push_flags_fn_t) ndr_push_srvsvc_NetPathCanonicalize,
21297 : (ndr_pull_flags_fn_t) ndr_pull_srvsvc_NetPathCanonicalize,
21298 : (ndr_print_function_t) ndr_print_srvsvc_NetPathCanonicalize,
21299 : { 0, NULL },
21300 : { 0, NULL },
21301 : },
21302 : {
21303 : "srvsvc_NetPathCompare",
21304 : sizeof(struct srvsvc_NetPathCompare),
21305 : (ndr_push_flags_fn_t) ndr_push_srvsvc_NetPathCompare,
21306 : (ndr_pull_flags_fn_t) ndr_pull_srvsvc_NetPathCompare,
21307 : (ndr_print_function_t) ndr_print_srvsvc_NetPathCompare,
21308 : { 0, NULL },
21309 : { 0, NULL },
21310 : },
21311 : {
21312 : "srvsvc_NetNameValidate",
21313 : sizeof(struct srvsvc_NetNameValidate),
21314 : (ndr_push_flags_fn_t) ndr_push_srvsvc_NetNameValidate,
21315 : (ndr_pull_flags_fn_t) ndr_pull_srvsvc_NetNameValidate,
21316 : (ndr_print_function_t) ndr_print_srvsvc_NetNameValidate,
21317 : { 0, NULL },
21318 : { 0, NULL },
21319 : },
21320 : {
21321 : "srvsvc_NETRPRNAMECANONICALIZE",
21322 : sizeof(struct srvsvc_NETRPRNAMECANONICALIZE),
21323 : (ndr_push_flags_fn_t) ndr_push_srvsvc_NETRPRNAMECANONICALIZE,
21324 : (ndr_pull_flags_fn_t) ndr_pull_srvsvc_NETRPRNAMECANONICALIZE,
21325 : (ndr_print_function_t) ndr_print_srvsvc_NETRPRNAMECANONICALIZE,
21326 : { 0, NULL },
21327 : { 0, NULL },
21328 : },
21329 : {
21330 : "srvsvc_NetPRNameCompare",
21331 : sizeof(struct srvsvc_NetPRNameCompare),
21332 : (ndr_push_flags_fn_t) ndr_push_srvsvc_NetPRNameCompare,
21333 : (ndr_pull_flags_fn_t) ndr_pull_srvsvc_NetPRNameCompare,
21334 : (ndr_print_function_t) ndr_print_srvsvc_NetPRNameCompare,
21335 : { 0, NULL },
21336 : { 0, NULL },
21337 : },
21338 : {
21339 : "srvsvc_NetShareEnum",
21340 : sizeof(struct srvsvc_NetShareEnum),
21341 : (ndr_push_flags_fn_t) ndr_push_srvsvc_NetShareEnum,
21342 : (ndr_pull_flags_fn_t) ndr_pull_srvsvc_NetShareEnum,
21343 : (ndr_print_function_t) ndr_print_srvsvc_NetShareEnum,
21344 : { 0, NULL },
21345 : { 0, NULL },
21346 : },
21347 : {
21348 : "srvsvc_NetShareDelStart",
21349 : sizeof(struct srvsvc_NetShareDelStart),
21350 : (ndr_push_flags_fn_t) ndr_push_srvsvc_NetShareDelStart,
21351 : (ndr_pull_flags_fn_t) ndr_pull_srvsvc_NetShareDelStart,
21352 : (ndr_print_function_t) ndr_print_srvsvc_NetShareDelStart,
21353 : { 0, NULL },
21354 : { 0, NULL },
21355 : },
21356 : {
21357 : "srvsvc_NetShareDelCommit",
21358 : sizeof(struct srvsvc_NetShareDelCommit),
21359 : (ndr_push_flags_fn_t) ndr_push_srvsvc_NetShareDelCommit,
21360 : (ndr_pull_flags_fn_t) ndr_pull_srvsvc_NetShareDelCommit,
21361 : (ndr_print_function_t) ndr_print_srvsvc_NetShareDelCommit,
21362 : { 0, NULL },
21363 : { 0, NULL },
21364 : },
21365 : {
21366 : "srvsvc_NetGetFileSecurity",
21367 : sizeof(struct srvsvc_NetGetFileSecurity),
21368 : (ndr_push_flags_fn_t) ndr_push_srvsvc_NetGetFileSecurity,
21369 : (ndr_pull_flags_fn_t) ndr_pull_srvsvc_NetGetFileSecurity,
21370 : (ndr_print_function_t) ndr_print_srvsvc_NetGetFileSecurity,
21371 : { 0, NULL },
21372 : { 0, NULL },
21373 : },
21374 : {
21375 : "srvsvc_NetSetFileSecurity",
21376 : sizeof(struct srvsvc_NetSetFileSecurity),
21377 : (ndr_push_flags_fn_t) ndr_push_srvsvc_NetSetFileSecurity,
21378 : (ndr_pull_flags_fn_t) ndr_pull_srvsvc_NetSetFileSecurity,
21379 : (ndr_print_function_t) ndr_print_srvsvc_NetSetFileSecurity,
21380 : { 0, NULL },
21381 : { 0, NULL },
21382 : },
21383 : {
21384 : "srvsvc_NetServerTransportAddEx",
21385 : sizeof(struct srvsvc_NetServerTransportAddEx),
21386 : (ndr_push_flags_fn_t) ndr_push_srvsvc_NetServerTransportAddEx,
21387 : (ndr_pull_flags_fn_t) ndr_pull_srvsvc_NetServerTransportAddEx,
21388 : (ndr_print_function_t) ndr_print_srvsvc_NetServerTransportAddEx,
21389 : { 0, NULL },
21390 : { 0, NULL },
21391 : },
21392 : {
21393 : "srvsvc_NetServerSetServiceBitsEx",
21394 : sizeof(struct srvsvc_NetServerSetServiceBitsEx),
21395 : (ndr_push_flags_fn_t) ndr_push_srvsvc_NetServerSetServiceBitsEx,
21396 : (ndr_pull_flags_fn_t) ndr_pull_srvsvc_NetServerSetServiceBitsEx,
21397 : (ndr_print_function_t) ndr_print_srvsvc_NetServerSetServiceBitsEx,
21398 : { 0, NULL },
21399 : { 0, NULL },
21400 : },
21401 : {
21402 : "srvsvc_NETRDFSGETVERSION",
21403 : sizeof(struct srvsvc_NETRDFSGETVERSION),
21404 : (ndr_push_flags_fn_t) ndr_push_srvsvc_NETRDFSGETVERSION,
21405 : (ndr_pull_flags_fn_t) ndr_pull_srvsvc_NETRDFSGETVERSION,
21406 : (ndr_print_function_t) ndr_print_srvsvc_NETRDFSGETVERSION,
21407 : { 0, NULL },
21408 : { 0, NULL },
21409 : },
21410 : {
21411 : "srvsvc_NETRDFSCREATELOCALPARTITION",
21412 : sizeof(struct srvsvc_NETRDFSCREATELOCALPARTITION),
21413 : (ndr_push_flags_fn_t) ndr_push_srvsvc_NETRDFSCREATELOCALPARTITION,
21414 : (ndr_pull_flags_fn_t) ndr_pull_srvsvc_NETRDFSCREATELOCALPARTITION,
21415 : (ndr_print_function_t) ndr_print_srvsvc_NETRDFSCREATELOCALPARTITION,
21416 : { 0, NULL },
21417 : { 0, NULL },
21418 : },
21419 : {
21420 : "srvsvc_NETRDFSDELETELOCALPARTITION",
21421 : sizeof(struct srvsvc_NETRDFSDELETELOCALPARTITION),
21422 : (ndr_push_flags_fn_t) ndr_push_srvsvc_NETRDFSDELETELOCALPARTITION,
21423 : (ndr_pull_flags_fn_t) ndr_pull_srvsvc_NETRDFSDELETELOCALPARTITION,
21424 : (ndr_print_function_t) ndr_print_srvsvc_NETRDFSDELETELOCALPARTITION,
21425 : { 0, NULL },
21426 : { 0, NULL },
21427 : },
21428 : {
21429 : "srvsvc_NETRDFSSETLOCALVOLUMESTATE",
21430 : sizeof(struct srvsvc_NETRDFSSETLOCALVOLUMESTATE),
21431 : (ndr_push_flags_fn_t) ndr_push_srvsvc_NETRDFSSETLOCALVOLUMESTATE,
21432 : (ndr_pull_flags_fn_t) ndr_pull_srvsvc_NETRDFSSETLOCALVOLUMESTATE,
21433 : (ndr_print_function_t) ndr_print_srvsvc_NETRDFSSETLOCALVOLUMESTATE,
21434 : { 0, NULL },
21435 : { 0, NULL },
21436 : },
21437 : {
21438 : "srvsvc_NETRDFSSETSERVERINFO",
21439 : sizeof(struct srvsvc_NETRDFSSETSERVERINFO),
21440 : (ndr_push_flags_fn_t) ndr_push_srvsvc_NETRDFSSETSERVERINFO,
21441 : (ndr_pull_flags_fn_t) ndr_pull_srvsvc_NETRDFSSETSERVERINFO,
21442 : (ndr_print_function_t) ndr_print_srvsvc_NETRDFSSETSERVERINFO,
21443 : { 0, NULL },
21444 : { 0, NULL },
21445 : },
21446 : {
21447 : "srvsvc_NETRDFSCREATEEXITPOINT",
21448 : sizeof(struct srvsvc_NETRDFSCREATEEXITPOINT),
21449 : (ndr_push_flags_fn_t) ndr_push_srvsvc_NETRDFSCREATEEXITPOINT,
21450 : (ndr_pull_flags_fn_t) ndr_pull_srvsvc_NETRDFSCREATEEXITPOINT,
21451 : (ndr_print_function_t) ndr_print_srvsvc_NETRDFSCREATEEXITPOINT,
21452 : { 0, NULL },
21453 : { 0, NULL },
21454 : },
21455 : {
21456 : "srvsvc_NETRDFSDELETEEXITPOINT",
21457 : sizeof(struct srvsvc_NETRDFSDELETEEXITPOINT),
21458 : (ndr_push_flags_fn_t) ndr_push_srvsvc_NETRDFSDELETEEXITPOINT,
21459 : (ndr_pull_flags_fn_t) ndr_pull_srvsvc_NETRDFSDELETEEXITPOINT,
21460 : (ndr_print_function_t) ndr_print_srvsvc_NETRDFSDELETEEXITPOINT,
21461 : { 0, NULL },
21462 : { 0, NULL },
21463 : },
21464 : {
21465 : "srvsvc_NETRDFSMODIFYPREFIX",
21466 : sizeof(struct srvsvc_NETRDFSMODIFYPREFIX),
21467 : (ndr_push_flags_fn_t) ndr_push_srvsvc_NETRDFSMODIFYPREFIX,
21468 : (ndr_pull_flags_fn_t) ndr_pull_srvsvc_NETRDFSMODIFYPREFIX,
21469 : (ndr_print_function_t) ndr_print_srvsvc_NETRDFSMODIFYPREFIX,
21470 : { 0, NULL },
21471 : { 0, NULL },
21472 : },
21473 : {
21474 : "srvsvc_NETRDFSFIXLOCALVOLUME",
21475 : sizeof(struct srvsvc_NETRDFSFIXLOCALVOLUME),
21476 : (ndr_push_flags_fn_t) ndr_push_srvsvc_NETRDFSFIXLOCALVOLUME,
21477 : (ndr_pull_flags_fn_t) ndr_pull_srvsvc_NETRDFSFIXLOCALVOLUME,
21478 : (ndr_print_function_t) ndr_print_srvsvc_NETRDFSFIXLOCALVOLUME,
21479 : { 0, NULL },
21480 : { 0, NULL },
21481 : },
21482 : {
21483 : "srvsvc_NETRDFSMANAGERREPORTSITEINFO",
21484 : sizeof(struct srvsvc_NETRDFSMANAGERREPORTSITEINFO),
21485 : (ndr_push_flags_fn_t) ndr_push_srvsvc_NETRDFSMANAGERREPORTSITEINFO,
21486 : (ndr_pull_flags_fn_t) ndr_pull_srvsvc_NETRDFSMANAGERREPORTSITEINFO,
21487 : (ndr_print_function_t) ndr_print_srvsvc_NETRDFSMANAGERREPORTSITEINFO,
21488 : { 0, NULL },
21489 : { 0, NULL },
21490 : },
21491 : {
21492 : "srvsvc_NETRSERVERTRANSPORTDELEX",
21493 : sizeof(struct srvsvc_NETRSERVERTRANSPORTDELEX),
21494 : (ndr_push_flags_fn_t) ndr_push_srvsvc_NETRSERVERTRANSPORTDELEX,
21495 : (ndr_pull_flags_fn_t) ndr_pull_srvsvc_NETRSERVERTRANSPORTDELEX,
21496 : (ndr_print_function_t) ndr_print_srvsvc_NETRSERVERTRANSPORTDELEX,
21497 : { 0, NULL },
21498 : { 0, NULL },
21499 : },
21500 : { .name = NULL }
21501 : };
21502 :
21503 : static const char * const srvsvc_endpoint_strings[] = {
21504 : "ncacn_np:[\\pipe\\srvsvc]",
21505 : "ncacn_ip_tcp:",
21506 : "ncalrpc:",
21507 : };
21508 :
21509 : static const struct ndr_interface_string_array srvsvc_endpoints = {
21510 : .count = 3,
21511 : .names = srvsvc_endpoint_strings
21512 : };
21513 :
21514 : static const char * const srvsvc_authservice_strings[] = {
21515 : "host",
21516 : };
21517 :
21518 : static const struct ndr_interface_string_array srvsvc_authservices = {
21519 : .count = 1,
21520 : .names = srvsvc_authservice_strings
21521 : };
21522 :
21523 :
21524 : const struct ndr_interface_table ndr_table_srvsvc = {
21525 : .name = "srvsvc",
21526 : .syntax_id = {
21527 : {0x4b324fc8,0x1670,0x01d3,{0x12,0x78},{0x5a,0x47,0xbf,0x6e,0xe1,0x88}},
21528 : NDR_SRVSVC_VERSION
21529 : },
21530 : .helpstring = NDR_SRVSVC_HELPSTRING,
21531 : .num_calls = 54,
21532 : .calls = srvsvc_calls,
21533 : .num_public_structs = 2,
21534 : .public_structs = srvsvc_public_structs,
21535 : .endpoints = &srvsvc_endpoints,
21536 : .authservices = &srvsvc_authservices
21537 : };
21538 :
21539 : #endif /* SKIP_NDR_TABLE_srvsvc */
|