1 /* parser auto-generated by pidl */
4 #include "../librpc/gen_ndr/ndr_srvsvc.h"
6 #include "librpc/gen_ndr/ndr_security.h"
7 #include "librpc/gen_ndr/ndr_svcctl.h"
8 static enum ndr_err_code
ndr_push_srvsvc_NetCharDevInfo0(struct ndr_push
*ndr
, int ndr_flags
, const struct srvsvc_NetCharDevInfo0
*r
)
10 if (ndr_flags
& NDR_SCALARS
) {
11 NDR_CHECK(ndr_push_align(ndr
, 4));
12 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->device
));
14 if (ndr_flags
& NDR_BUFFERS
) {
16 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->device
, CH_UTF16
)));
17 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
18 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->device
, CH_UTF16
)));
19 NDR_CHECK(ndr_push_charset(ndr
, NDR_SCALARS
, r
->device
, ndr_charset_length(r
->device
, CH_UTF16
), sizeof(uint16_t), CH_UTF16
));
22 return NDR_ERR_SUCCESS
;
25 static enum ndr_err_code
ndr_pull_srvsvc_NetCharDevInfo0(struct ndr_pull
*ndr
, int ndr_flags
, struct srvsvc_NetCharDevInfo0
*r
)
28 uint32_t size_device_1
= 0;
29 uint32_t length_device_1
= 0;
30 TALLOC_CTX
*_mem_save_device_0
;
31 if (ndr_flags
& NDR_SCALARS
) {
32 NDR_CHECK(ndr_pull_align(ndr
, 4));
33 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_device
));
35 NDR_PULL_ALLOC(ndr
, r
->device
);
40 if (ndr_flags
& NDR_BUFFERS
) {
42 _mem_save_device_0
= NDR_PULL_GET_MEM_CTX(ndr
);
43 NDR_PULL_SET_MEM_CTX(ndr
, r
->device
, 0);
44 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->device
));
45 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->device
));
46 size_device_1
= ndr_get_array_size(ndr
, &r
->device
);
47 length_device_1
= ndr_get_array_length(ndr
, &r
->device
);
48 if (length_device_1
> size_device_1
) {
49 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", size_device_1
, length_device_1
);
51 NDR_CHECK(ndr_check_string_terminator(ndr
, length_device_1
, sizeof(uint16_t)));
52 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->device
, length_device_1
, sizeof(uint16_t), CH_UTF16
));
53 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_device_0
, 0);
56 return NDR_ERR_SUCCESS
;
59 _PUBLIC_
void ndr_print_srvsvc_NetCharDevInfo0(struct ndr_print
*ndr
, const char *name
, const struct srvsvc_NetCharDevInfo0
*r
)
61 ndr_print_struct(ndr
, name
, "srvsvc_NetCharDevInfo0");
63 ndr_print_ptr(ndr
, "device", r
->device
);
66 ndr_print_string(ndr
, "device", r
->device
);
72 static enum ndr_err_code
ndr_push_srvsvc_NetCharDevCtr0(struct ndr_push
*ndr
, int ndr_flags
, const struct srvsvc_NetCharDevCtr0
*r
)
74 uint32_t cntr_array_1
;
75 if (ndr_flags
& NDR_SCALARS
) {
76 NDR_CHECK(ndr_push_align(ndr
, 4));
77 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->count
));
78 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->array
));
80 if (ndr_flags
& NDR_BUFFERS
) {
82 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->count
));
83 for (cntr_array_1
= 0; cntr_array_1
< r
->count
; cntr_array_1
++) {
84 NDR_CHECK(ndr_push_srvsvc_NetCharDevInfo0(ndr
, NDR_SCALARS
, &r
->array
[cntr_array_1
]));
86 for (cntr_array_1
= 0; cntr_array_1
< r
->count
; cntr_array_1
++) {
87 NDR_CHECK(ndr_push_srvsvc_NetCharDevInfo0(ndr
, NDR_BUFFERS
, &r
->array
[cntr_array_1
]));
91 return NDR_ERR_SUCCESS
;
94 static enum ndr_err_code
ndr_pull_srvsvc_NetCharDevCtr0(struct ndr_pull
*ndr
, int ndr_flags
, struct srvsvc_NetCharDevCtr0
*r
)
97 uint32_t size_array_1
= 0;
98 uint32_t cntr_array_1
;
99 TALLOC_CTX
*_mem_save_array_0
;
100 TALLOC_CTX
*_mem_save_array_1
;
101 if (ndr_flags
& NDR_SCALARS
) {
102 NDR_CHECK(ndr_pull_align(ndr
, 4));
103 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->count
));
104 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_array
));
106 NDR_PULL_ALLOC(ndr
, r
->array
);
111 if (ndr_flags
& NDR_BUFFERS
) {
113 _mem_save_array_0
= NDR_PULL_GET_MEM_CTX(ndr
);
114 NDR_PULL_SET_MEM_CTX(ndr
, r
->array
, 0);
115 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->array
));
116 size_array_1
= ndr_get_array_size(ndr
, &r
->array
);
117 NDR_PULL_ALLOC_N(ndr
, r
->array
, size_array_1
);
118 _mem_save_array_1
= NDR_PULL_GET_MEM_CTX(ndr
);
119 NDR_PULL_SET_MEM_CTX(ndr
, r
->array
, 0);
120 for (cntr_array_1
= 0; cntr_array_1
< size_array_1
; cntr_array_1
++) {
121 NDR_CHECK(ndr_pull_srvsvc_NetCharDevInfo0(ndr
, NDR_SCALARS
, &r
->array
[cntr_array_1
]));
123 for (cntr_array_1
= 0; cntr_array_1
< size_array_1
; cntr_array_1
++) {
124 NDR_CHECK(ndr_pull_srvsvc_NetCharDevInfo0(ndr
, NDR_BUFFERS
, &r
->array
[cntr_array_1
]));
126 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_array_1
, 0);
127 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_array_0
, 0);
130 NDR_CHECK(ndr_check_array_size(ndr
, (void*)&r
->array
, r
->count
));
133 return NDR_ERR_SUCCESS
;
136 _PUBLIC_
void ndr_print_srvsvc_NetCharDevCtr0(struct ndr_print
*ndr
, const char *name
, const struct srvsvc_NetCharDevCtr0
*r
)
138 uint32_t cntr_array_1
;
139 ndr_print_struct(ndr
, name
, "srvsvc_NetCharDevCtr0");
141 ndr_print_uint32(ndr
, "count", r
->count
);
142 ndr_print_ptr(ndr
, "array", r
->array
);
145 ndr
->print(ndr
, "%s: ARRAY(%d)", "array", (int)r
->count
);
147 for (cntr_array_1
=0;cntr_array_1
<r
->count
;cntr_array_1
++) {
149 if (asprintf(&idx_1
, "[%d]", cntr_array_1
) != -1) {
150 ndr_print_srvsvc_NetCharDevInfo0(ndr
, "array", &r
->array
[cntr_array_1
]);
160 static enum ndr_err_code
ndr_push_srvsvc_NetCharDevInfo1(struct ndr_push
*ndr
, int ndr_flags
, const struct srvsvc_NetCharDevInfo1
*r
)
162 if (ndr_flags
& NDR_SCALARS
) {
163 NDR_CHECK(ndr_push_align(ndr
, 4));
164 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->device
));
165 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->status
));
166 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->user
));
167 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->time
));
169 if (ndr_flags
& NDR_BUFFERS
) {
171 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->device
, CH_UTF16
)));
172 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
173 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->device
, CH_UTF16
)));
174 NDR_CHECK(ndr_push_charset(ndr
, NDR_SCALARS
, r
->device
, ndr_charset_length(r
->device
, CH_UTF16
), sizeof(uint16_t), CH_UTF16
));
177 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->user
, CH_UTF16
)));
178 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
179 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->user
, CH_UTF16
)));
180 NDR_CHECK(ndr_push_charset(ndr
, NDR_SCALARS
, r
->user
, ndr_charset_length(r
->user
, CH_UTF16
), sizeof(uint16_t), CH_UTF16
));
183 return NDR_ERR_SUCCESS
;
186 static enum ndr_err_code
ndr_pull_srvsvc_NetCharDevInfo1(struct ndr_pull
*ndr
, int ndr_flags
, struct srvsvc_NetCharDevInfo1
*r
)
188 uint32_t _ptr_device
;
189 uint32_t size_device_1
= 0;
190 uint32_t length_device_1
= 0;
191 TALLOC_CTX
*_mem_save_device_0
;
193 uint32_t size_user_1
= 0;
194 uint32_t length_user_1
= 0;
195 TALLOC_CTX
*_mem_save_user_0
;
196 if (ndr_flags
& NDR_SCALARS
) {
197 NDR_CHECK(ndr_pull_align(ndr
, 4));
198 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_device
));
200 NDR_PULL_ALLOC(ndr
, r
->device
);
204 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->status
));
205 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_user
));
207 NDR_PULL_ALLOC(ndr
, r
->user
);
211 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->time
));
213 if (ndr_flags
& NDR_BUFFERS
) {
215 _mem_save_device_0
= NDR_PULL_GET_MEM_CTX(ndr
);
216 NDR_PULL_SET_MEM_CTX(ndr
, r
->device
, 0);
217 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->device
));
218 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->device
));
219 size_device_1
= ndr_get_array_size(ndr
, &r
->device
);
220 length_device_1
= ndr_get_array_length(ndr
, &r
->device
);
221 if (length_device_1
> size_device_1
) {
222 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", size_device_1
, length_device_1
);
224 NDR_CHECK(ndr_check_string_terminator(ndr
, length_device_1
, sizeof(uint16_t)));
225 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->device
, length_device_1
, sizeof(uint16_t), CH_UTF16
));
226 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_device_0
, 0);
229 _mem_save_user_0
= NDR_PULL_GET_MEM_CTX(ndr
);
230 NDR_PULL_SET_MEM_CTX(ndr
, r
->user
, 0);
231 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->user
));
232 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->user
));
233 size_user_1
= ndr_get_array_size(ndr
, &r
->user
);
234 length_user_1
= ndr_get_array_length(ndr
, &r
->user
);
235 if (length_user_1
> size_user_1
) {
236 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", size_user_1
, length_user_1
);
238 NDR_CHECK(ndr_check_string_terminator(ndr
, length_user_1
, sizeof(uint16_t)));
239 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->user
, length_user_1
, sizeof(uint16_t), CH_UTF16
));
240 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_user_0
, 0);
243 return NDR_ERR_SUCCESS
;
246 _PUBLIC_
void ndr_print_srvsvc_NetCharDevInfo1(struct ndr_print
*ndr
, const char *name
, const struct srvsvc_NetCharDevInfo1
*r
)
248 ndr_print_struct(ndr
, name
, "srvsvc_NetCharDevInfo1");
250 ndr_print_ptr(ndr
, "device", r
->device
);
253 ndr_print_string(ndr
, "device", r
->device
);
256 ndr_print_uint32(ndr
, "status", r
->status
);
257 ndr_print_ptr(ndr
, "user", r
->user
);
260 ndr_print_string(ndr
, "user", r
->user
);
263 ndr_print_uint32(ndr
, "time", r
->time
);
267 static enum ndr_err_code
ndr_push_srvsvc_NetCharDevCtr1(struct ndr_push
*ndr
, int ndr_flags
, const struct srvsvc_NetCharDevCtr1
*r
)
269 uint32_t cntr_array_1
;
270 if (ndr_flags
& NDR_SCALARS
) {
271 NDR_CHECK(ndr_push_align(ndr
, 4));
272 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->count
));
273 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->array
));
275 if (ndr_flags
& NDR_BUFFERS
) {
277 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->count
));
278 for (cntr_array_1
= 0; cntr_array_1
< r
->count
; cntr_array_1
++) {
279 NDR_CHECK(ndr_push_srvsvc_NetCharDevInfo1(ndr
, NDR_SCALARS
, &r
->array
[cntr_array_1
]));
281 for (cntr_array_1
= 0; cntr_array_1
< r
->count
; cntr_array_1
++) {
282 NDR_CHECK(ndr_push_srvsvc_NetCharDevInfo1(ndr
, NDR_BUFFERS
, &r
->array
[cntr_array_1
]));
286 return NDR_ERR_SUCCESS
;
289 static enum ndr_err_code
ndr_pull_srvsvc_NetCharDevCtr1(struct ndr_pull
*ndr
, int ndr_flags
, struct srvsvc_NetCharDevCtr1
*r
)
292 uint32_t size_array_1
= 0;
293 uint32_t cntr_array_1
;
294 TALLOC_CTX
*_mem_save_array_0
;
295 TALLOC_CTX
*_mem_save_array_1
;
296 if (ndr_flags
& NDR_SCALARS
) {
297 NDR_CHECK(ndr_pull_align(ndr
, 4));
298 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->count
));
299 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_array
));
301 NDR_PULL_ALLOC(ndr
, r
->array
);
306 if (ndr_flags
& NDR_BUFFERS
) {
308 _mem_save_array_0
= NDR_PULL_GET_MEM_CTX(ndr
);
309 NDR_PULL_SET_MEM_CTX(ndr
, r
->array
, 0);
310 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->array
));
311 size_array_1
= ndr_get_array_size(ndr
, &r
->array
);
312 NDR_PULL_ALLOC_N(ndr
, r
->array
, size_array_1
);
313 _mem_save_array_1
= NDR_PULL_GET_MEM_CTX(ndr
);
314 NDR_PULL_SET_MEM_CTX(ndr
, r
->array
, 0);
315 for (cntr_array_1
= 0; cntr_array_1
< size_array_1
; cntr_array_1
++) {
316 NDR_CHECK(ndr_pull_srvsvc_NetCharDevInfo1(ndr
, NDR_SCALARS
, &r
->array
[cntr_array_1
]));
318 for (cntr_array_1
= 0; cntr_array_1
< size_array_1
; cntr_array_1
++) {
319 NDR_CHECK(ndr_pull_srvsvc_NetCharDevInfo1(ndr
, NDR_BUFFERS
, &r
->array
[cntr_array_1
]));
321 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_array_1
, 0);
322 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_array_0
, 0);
325 NDR_CHECK(ndr_check_array_size(ndr
, (void*)&r
->array
, r
->count
));
328 return NDR_ERR_SUCCESS
;
331 _PUBLIC_
void ndr_print_srvsvc_NetCharDevCtr1(struct ndr_print
*ndr
, const char *name
, const struct srvsvc_NetCharDevCtr1
*r
)
333 uint32_t cntr_array_1
;
334 ndr_print_struct(ndr
, name
, "srvsvc_NetCharDevCtr1");
336 ndr_print_uint32(ndr
, "count", r
->count
);
337 ndr_print_ptr(ndr
, "array", r
->array
);
340 ndr
->print(ndr
, "%s: ARRAY(%d)", "array", (int)r
->count
);
342 for (cntr_array_1
=0;cntr_array_1
<r
->count
;cntr_array_1
++) {
344 if (asprintf(&idx_1
, "[%d]", cntr_array_1
) != -1) {
345 ndr_print_srvsvc_NetCharDevInfo1(ndr
, "array", &r
->array
[cntr_array_1
]);
355 static enum ndr_err_code
ndr_push_srvsvc_NetCharDevInfo(struct ndr_push
*ndr
, int ndr_flags
, const union srvsvc_NetCharDevInfo
*r
)
357 if (ndr_flags
& NDR_SCALARS
) {
358 int level
= ndr_push_get_switch_value(ndr
, r
);
359 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, level
));
362 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->info0
));
366 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->info1
));
374 if (ndr_flags
& NDR_BUFFERS
) {
375 int level
= ndr_push_get_switch_value(ndr
, r
);
379 NDR_CHECK(ndr_push_srvsvc_NetCharDevInfo0(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->info0
));
385 NDR_CHECK(ndr_push_srvsvc_NetCharDevInfo1(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->info1
));
394 return NDR_ERR_SUCCESS
;
397 static enum ndr_err_code
ndr_pull_srvsvc_NetCharDevInfo(struct ndr_pull
*ndr
, int ndr_flags
, union srvsvc_NetCharDevInfo
*r
)
401 TALLOC_CTX
*_mem_save_info0_0
;
403 TALLOC_CTX
*_mem_save_info1_0
;
405 level
= ndr_pull_get_switch_value(ndr
, r
);
406 if (ndr_flags
& NDR_SCALARS
) {
407 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &_level
));
408 if (_level
!= level
) {
409 return ndr_pull_error(ndr
, NDR_ERR_BAD_SWITCH
, "Bad switch value %u for r", _level
);
413 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_info0
));
415 NDR_PULL_ALLOC(ndr
, r
->info0
);
422 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_info1
));
424 NDR_PULL_ALLOC(ndr
, r
->info1
);
435 if (ndr_flags
& NDR_BUFFERS
) {
439 _mem_save_info0_0
= NDR_PULL_GET_MEM_CTX(ndr
);
440 NDR_PULL_SET_MEM_CTX(ndr
, r
->info0
, 0);
441 NDR_CHECK(ndr_pull_srvsvc_NetCharDevInfo0(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->info0
));
442 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_info0_0
, 0);
448 _mem_save_info1_0
= NDR_PULL_GET_MEM_CTX(ndr
);
449 NDR_PULL_SET_MEM_CTX(ndr
, r
->info1
, 0);
450 NDR_CHECK(ndr_pull_srvsvc_NetCharDevInfo1(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->info1
));
451 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_info1_0
, 0);
460 return NDR_ERR_SUCCESS
;
463 _PUBLIC_
void ndr_print_srvsvc_NetCharDevInfo(struct ndr_print
*ndr
, const char *name
, const union srvsvc_NetCharDevInfo
*r
)
466 level
= ndr_print_get_switch_value(ndr
, r
);
467 ndr_print_union(ndr
, name
, level
, "srvsvc_NetCharDevInfo");
470 ndr_print_ptr(ndr
, "info0", r
->info0
);
473 ndr_print_srvsvc_NetCharDevInfo0(ndr
, "info0", r
->info0
);
479 ndr_print_ptr(ndr
, "info1", r
->info1
);
482 ndr_print_srvsvc_NetCharDevInfo1(ndr
, "info1", r
->info1
);
493 static enum ndr_err_code
ndr_push_srvsvc_NetCharDevCtr(struct ndr_push
*ndr
, int ndr_flags
, const union srvsvc_NetCharDevCtr
*r
)
495 if (ndr_flags
& NDR_SCALARS
) {
496 int level
= ndr_push_get_switch_value(ndr
, r
);
497 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, level
));
500 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->ctr0
));
504 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->ctr1
));
512 if (ndr_flags
& NDR_BUFFERS
) {
513 int level
= ndr_push_get_switch_value(ndr
, r
);
517 NDR_CHECK(ndr_push_srvsvc_NetCharDevCtr0(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->ctr0
));
523 NDR_CHECK(ndr_push_srvsvc_NetCharDevCtr1(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->ctr1
));
532 return NDR_ERR_SUCCESS
;
535 static enum ndr_err_code
ndr_pull_srvsvc_NetCharDevCtr(struct ndr_pull
*ndr
, int ndr_flags
, union srvsvc_NetCharDevCtr
*r
)
539 TALLOC_CTX
*_mem_save_ctr0_0
;
541 TALLOC_CTX
*_mem_save_ctr1_0
;
543 level
= ndr_pull_get_switch_value(ndr
, r
);
544 if (ndr_flags
& NDR_SCALARS
) {
545 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &_level
));
546 if (_level
!= level
) {
547 return ndr_pull_error(ndr
, NDR_ERR_BAD_SWITCH
, "Bad switch value %u for r", _level
);
551 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_ctr0
));
553 NDR_PULL_ALLOC(ndr
, r
->ctr0
);
560 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_ctr1
));
562 NDR_PULL_ALLOC(ndr
, r
->ctr1
);
573 if (ndr_flags
& NDR_BUFFERS
) {
577 _mem_save_ctr0_0
= NDR_PULL_GET_MEM_CTX(ndr
);
578 NDR_PULL_SET_MEM_CTX(ndr
, r
->ctr0
, 0);
579 NDR_CHECK(ndr_pull_srvsvc_NetCharDevCtr0(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->ctr0
));
580 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_ctr0_0
, 0);
586 _mem_save_ctr1_0
= NDR_PULL_GET_MEM_CTX(ndr
);
587 NDR_PULL_SET_MEM_CTX(ndr
, r
->ctr1
, 0);
588 NDR_CHECK(ndr_pull_srvsvc_NetCharDevCtr1(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->ctr1
));
589 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_ctr1_0
, 0);
598 return NDR_ERR_SUCCESS
;
601 _PUBLIC_
void ndr_print_srvsvc_NetCharDevCtr(struct ndr_print
*ndr
, const char *name
, const union srvsvc_NetCharDevCtr
*r
)
604 level
= ndr_print_get_switch_value(ndr
, r
);
605 ndr_print_union(ndr
, name
, level
, "srvsvc_NetCharDevCtr");
608 ndr_print_ptr(ndr
, "ctr0", r
->ctr0
);
611 ndr_print_srvsvc_NetCharDevCtr0(ndr
, "ctr0", r
->ctr0
);
617 ndr_print_ptr(ndr
, "ctr1", r
->ctr1
);
620 ndr_print_srvsvc_NetCharDevCtr1(ndr
, "ctr1", r
->ctr1
);
631 static enum ndr_err_code
ndr_push_srvsvc_NetCharDevInfoCtr(struct ndr_push
*ndr
, int ndr_flags
, const struct srvsvc_NetCharDevInfoCtr
*r
)
633 if (ndr_flags
& NDR_SCALARS
) {
634 NDR_CHECK(ndr_push_align(ndr
, 4));
635 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->level
));
636 NDR_CHECK(ndr_push_set_switch_value(ndr
, &r
->ctr
, r
->level
));
637 NDR_CHECK(ndr_push_srvsvc_NetCharDevCtr(ndr
, NDR_SCALARS
, &r
->ctr
));
639 if (ndr_flags
& NDR_BUFFERS
) {
640 NDR_CHECK(ndr_push_srvsvc_NetCharDevCtr(ndr
, NDR_BUFFERS
, &r
->ctr
));
642 return NDR_ERR_SUCCESS
;
645 static enum ndr_err_code
ndr_pull_srvsvc_NetCharDevInfoCtr(struct ndr_pull
*ndr
, int ndr_flags
, struct srvsvc_NetCharDevInfoCtr
*r
)
647 if (ndr_flags
& NDR_SCALARS
) {
648 NDR_CHECK(ndr_pull_align(ndr
, 4));
649 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->level
));
650 NDR_CHECK(ndr_pull_set_switch_value(ndr
, &r
->ctr
, r
->level
));
651 NDR_CHECK(ndr_pull_srvsvc_NetCharDevCtr(ndr
, NDR_SCALARS
, &r
->ctr
));
653 if (ndr_flags
& NDR_BUFFERS
) {
654 NDR_CHECK(ndr_pull_srvsvc_NetCharDevCtr(ndr
, NDR_BUFFERS
, &r
->ctr
));
656 return NDR_ERR_SUCCESS
;
659 _PUBLIC_
void ndr_print_srvsvc_NetCharDevInfoCtr(struct ndr_print
*ndr
, const char *name
, const struct srvsvc_NetCharDevInfoCtr
*r
)
661 ndr_print_struct(ndr
, name
, "srvsvc_NetCharDevInfoCtr");
663 ndr_print_uint32(ndr
, "level", r
->level
);
664 ndr_print_set_switch_value(ndr
, &r
->ctr
, r
->level
);
665 ndr_print_srvsvc_NetCharDevCtr(ndr
, "ctr", &r
->ctr
);
669 static enum ndr_err_code
ndr_push_srvsvc_NetCharDevQInfo0(struct ndr_push
*ndr
, int ndr_flags
, const struct srvsvc_NetCharDevQInfo0
*r
)
671 if (ndr_flags
& NDR_SCALARS
) {
672 NDR_CHECK(ndr_push_align(ndr
, 4));
673 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->device
));
675 if (ndr_flags
& NDR_BUFFERS
) {
677 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->device
, CH_UTF16
)));
678 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
679 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->device
, CH_UTF16
)));
680 NDR_CHECK(ndr_push_charset(ndr
, NDR_SCALARS
, r
->device
, ndr_charset_length(r
->device
, CH_UTF16
), sizeof(uint16_t), CH_UTF16
));
683 return NDR_ERR_SUCCESS
;
686 static enum ndr_err_code
ndr_pull_srvsvc_NetCharDevQInfo0(struct ndr_pull
*ndr
, int ndr_flags
, struct srvsvc_NetCharDevQInfo0
*r
)
688 uint32_t _ptr_device
;
689 uint32_t size_device_1
= 0;
690 uint32_t length_device_1
= 0;
691 TALLOC_CTX
*_mem_save_device_0
;
692 if (ndr_flags
& NDR_SCALARS
) {
693 NDR_CHECK(ndr_pull_align(ndr
, 4));
694 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_device
));
696 NDR_PULL_ALLOC(ndr
, r
->device
);
701 if (ndr_flags
& NDR_BUFFERS
) {
703 _mem_save_device_0
= NDR_PULL_GET_MEM_CTX(ndr
);
704 NDR_PULL_SET_MEM_CTX(ndr
, r
->device
, 0);
705 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->device
));
706 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->device
));
707 size_device_1
= ndr_get_array_size(ndr
, &r
->device
);
708 length_device_1
= ndr_get_array_length(ndr
, &r
->device
);
709 if (length_device_1
> size_device_1
) {
710 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", size_device_1
, length_device_1
);
712 NDR_CHECK(ndr_check_string_terminator(ndr
, length_device_1
, sizeof(uint16_t)));
713 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->device
, length_device_1
, sizeof(uint16_t), CH_UTF16
));
714 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_device_0
, 0);
717 return NDR_ERR_SUCCESS
;
720 _PUBLIC_
void ndr_print_srvsvc_NetCharDevQInfo0(struct ndr_print
*ndr
, const char *name
, const struct srvsvc_NetCharDevQInfo0
*r
)
722 ndr_print_struct(ndr
, name
, "srvsvc_NetCharDevQInfo0");
724 ndr_print_ptr(ndr
, "device", r
->device
);
727 ndr_print_string(ndr
, "device", r
->device
);
733 static enum ndr_err_code
ndr_push_srvsvc_NetCharDevQCtr0(struct ndr_push
*ndr
, int ndr_flags
, const struct srvsvc_NetCharDevQCtr0
*r
)
735 uint32_t cntr_array_1
;
736 if (ndr_flags
& NDR_SCALARS
) {
737 NDR_CHECK(ndr_push_align(ndr
, 4));
738 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->count
));
739 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->array
));
741 if (ndr_flags
& NDR_BUFFERS
) {
743 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->count
));
744 for (cntr_array_1
= 0; cntr_array_1
< r
->count
; cntr_array_1
++) {
745 NDR_CHECK(ndr_push_srvsvc_NetCharDevQInfo0(ndr
, NDR_SCALARS
, &r
->array
[cntr_array_1
]));
747 for (cntr_array_1
= 0; cntr_array_1
< r
->count
; cntr_array_1
++) {
748 NDR_CHECK(ndr_push_srvsvc_NetCharDevQInfo0(ndr
, NDR_BUFFERS
, &r
->array
[cntr_array_1
]));
752 return NDR_ERR_SUCCESS
;
755 static enum ndr_err_code
ndr_pull_srvsvc_NetCharDevQCtr0(struct ndr_pull
*ndr
, int ndr_flags
, struct srvsvc_NetCharDevQCtr0
*r
)
758 uint32_t size_array_1
= 0;
759 uint32_t cntr_array_1
;
760 TALLOC_CTX
*_mem_save_array_0
;
761 TALLOC_CTX
*_mem_save_array_1
;
762 if (ndr_flags
& NDR_SCALARS
) {
763 NDR_CHECK(ndr_pull_align(ndr
, 4));
764 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->count
));
765 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_array
));
767 NDR_PULL_ALLOC(ndr
, r
->array
);
772 if (ndr_flags
& NDR_BUFFERS
) {
774 _mem_save_array_0
= NDR_PULL_GET_MEM_CTX(ndr
);
775 NDR_PULL_SET_MEM_CTX(ndr
, r
->array
, 0);
776 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->array
));
777 size_array_1
= ndr_get_array_size(ndr
, &r
->array
);
778 NDR_PULL_ALLOC_N(ndr
, r
->array
, size_array_1
);
779 _mem_save_array_1
= NDR_PULL_GET_MEM_CTX(ndr
);
780 NDR_PULL_SET_MEM_CTX(ndr
, r
->array
, 0);
781 for (cntr_array_1
= 0; cntr_array_1
< size_array_1
; cntr_array_1
++) {
782 NDR_CHECK(ndr_pull_srvsvc_NetCharDevQInfo0(ndr
, NDR_SCALARS
, &r
->array
[cntr_array_1
]));
784 for (cntr_array_1
= 0; cntr_array_1
< size_array_1
; cntr_array_1
++) {
785 NDR_CHECK(ndr_pull_srvsvc_NetCharDevQInfo0(ndr
, NDR_BUFFERS
, &r
->array
[cntr_array_1
]));
787 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_array_1
, 0);
788 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_array_0
, 0);
791 NDR_CHECK(ndr_check_array_size(ndr
, (void*)&r
->array
, r
->count
));
794 return NDR_ERR_SUCCESS
;
797 _PUBLIC_
void ndr_print_srvsvc_NetCharDevQCtr0(struct ndr_print
*ndr
, const char *name
, const struct srvsvc_NetCharDevQCtr0
*r
)
799 uint32_t cntr_array_1
;
800 ndr_print_struct(ndr
, name
, "srvsvc_NetCharDevQCtr0");
802 ndr_print_uint32(ndr
, "count", r
->count
);
803 ndr_print_ptr(ndr
, "array", r
->array
);
806 ndr
->print(ndr
, "%s: ARRAY(%d)", "array", (int)r
->count
);
808 for (cntr_array_1
=0;cntr_array_1
<r
->count
;cntr_array_1
++) {
810 if (asprintf(&idx_1
, "[%d]", cntr_array_1
) != -1) {
811 ndr_print_srvsvc_NetCharDevQInfo0(ndr
, "array", &r
->array
[cntr_array_1
]);
821 static enum ndr_err_code
ndr_push_srvsvc_NetCharDevQInfo1(struct ndr_push
*ndr
, int ndr_flags
, const struct srvsvc_NetCharDevQInfo1
*r
)
823 if (ndr_flags
& NDR_SCALARS
) {
824 NDR_CHECK(ndr_push_align(ndr
, 4));
825 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->device
));
826 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->priority
));
827 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->devices
));
828 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->users
));
829 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->num_ahead
));
831 if (ndr_flags
& NDR_BUFFERS
) {
833 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->device
, CH_UTF16
)));
834 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
835 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->device
, CH_UTF16
)));
836 NDR_CHECK(ndr_push_charset(ndr
, NDR_SCALARS
, r
->device
, ndr_charset_length(r
->device
, CH_UTF16
), sizeof(uint16_t), CH_UTF16
));
839 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->devices
, CH_UTF16
)));
840 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
841 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->devices
, CH_UTF16
)));
842 NDR_CHECK(ndr_push_charset(ndr
, NDR_SCALARS
, r
->devices
, ndr_charset_length(r
->devices
, CH_UTF16
), sizeof(uint16_t), CH_UTF16
));
845 return NDR_ERR_SUCCESS
;
848 static enum ndr_err_code
ndr_pull_srvsvc_NetCharDevQInfo1(struct ndr_pull
*ndr
, int ndr_flags
, struct srvsvc_NetCharDevQInfo1
*r
)
850 uint32_t _ptr_device
;
851 uint32_t size_device_1
= 0;
852 uint32_t length_device_1
= 0;
853 TALLOC_CTX
*_mem_save_device_0
;
854 uint32_t _ptr_devices
;
855 uint32_t size_devices_1
= 0;
856 uint32_t length_devices_1
= 0;
857 TALLOC_CTX
*_mem_save_devices_0
;
858 if (ndr_flags
& NDR_SCALARS
) {
859 NDR_CHECK(ndr_pull_align(ndr
, 4));
860 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_device
));
862 NDR_PULL_ALLOC(ndr
, r
->device
);
866 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->priority
));
867 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_devices
));
869 NDR_PULL_ALLOC(ndr
, r
->devices
);
873 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->users
));
874 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->num_ahead
));
876 if (ndr_flags
& NDR_BUFFERS
) {
878 _mem_save_device_0
= NDR_PULL_GET_MEM_CTX(ndr
);
879 NDR_PULL_SET_MEM_CTX(ndr
, r
->device
, 0);
880 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->device
));
881 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->device
));
882 size_device_1
= ndr_get_array_size(ndr
, &r
->device
);
883 length_device_1
= ndr_get_array_length(ndr
, &r
->device
);
884 if (length_device_1
> size_device_1
) {
885 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", size_device_1
, length_device_1
);
887 NDR_CHECK(ndr_check_string_terminator(ndr
, length_device_1
, sizeof(uint16_t)));
888 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->device
, length_device_1
, sizeof(uint16_t), CH_UTF16
));
889 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_device_0
, 0);
892 _mem_save_devices_0
= NDR_PULL_GET_MEM_CTX(ndr
);
893 NDR_PULL_SET_MEM_CTX(ndr
, r
->devices
, 0);
894 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->devices
));
895 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->devices
));
896 size_devices_1
= ndr_get_array_size(ndr
, &r
->devices
);
897 length_devices_1
= ndr_get_array_length(ndr
, &r
->devices
);
898 if (length_devices_1
> size_devices_1
) {
899 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", size_devices_1
, length_devices_1
);
901 NDR_CHECK(ndr_check_string_terminator(ndr
, length_devices_1
, sizeof(uint16_t)));
902 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->devices
, length_devices_1
, sizeof(uint16_t), CH_UTF16
));
903 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_devices_0
, 0);
906 return NDR_ERR_SUCCESS
;
909 _PUBLIC_
void ndr_print_srvsvc_NetCharDevQInfo1(struct ndr_print
*ndr
, const char *name
, const struct srvsvc_NetCharDevQInfo1
*r
)
911 ndr_print_struct(ndr
, name
, "srvsvc_NetCharDevQInfo1");
913 ndr_print_ptr(ndr
, "device", r
->device
);
916 ndr_print_string(ndr
, "device", r
->device
);
919 ndr_print_uint32(ndr
, "priority", r
->priority
);
920 ndr_print_ptr(ndr
, "devices", r
->devices
);
923 ndr_print_string(ndr
, "devices", r
->devices
);
926 ndr_print_uint32(ndr
, "users", r
->users
);
927 ndr_print_uint32(ndr
, "num_ahead", r
->num_ahead
);
931 static enum ndr_err_code
ndr_push_srvsvc_NetCharDevQCtr1(struct ndr_push
*ndr
, int ndr_flags
, const struct srvsvc_NetCharDevQCtr1
*r
)
933 uint32_t cntr_array_1
;
934 if (ndr_flags
& NDR_SCALARS
) {
935 NDR_CHECK(ndr_push_align(ndr
, 4));
936 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->count
));
937 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->array
));
939 if (ndr_flags
& NDR_BUFFERS
) {
941 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->count
));
942 for (cntr_array_1
= 0; cntr_array_1
< r
->count
; cntr_array_1
++) {
943 NDR_CHECK(ndr_push_srvsvc_NetCharDevQInfo1(ndr
, NDR_SCALARS
, &r
->array
[cntr_array_1
]));
945 for (cntr_array_1
= 0; cntr_array_1
< r
->count
; cntr_array_1
++) {
946 NDR_CHECK(ndr_push_srvsvc_NetCharDevQInfo1(ndr
, NDR_BUFFERS
, &r
->array
[cntr_array_1
]));
950 return NDR_ERR_SUCCESS
;
953 static enum ndr_err_code
ndr_pull_srvsvc_NetCharDevQCtr1(struct ndr_pull
*ndr
, int ndr_flags
, struct srvsvc_NetCharDevQCtr1
*r
)
956 uint32_t size_array_1
= 0;
957 uint32_t cntr_array_1
;
958 TALLOC_CTX
*_mem_save_array_0
;
959 TALLOC_CTX
*_mem_save_array_1
;
960 if (ndr_flags
& NDR_SCALARS
) {
961 NDR_CHECK(ndr_pull_align(ndr
, 4));
962 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->count
));
963 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_array
));
965 NDR_PULL_ALLOC(ndr
, r
->array
);
970 if (ndr_flags
& NDR_BUFFERS
) {
972 _mem_save_array_0
= NDR_PULL_GET_MEM_CTX(ndr
);
973 NDR_PULL_SET_MEM_CTX(ndr
, r
->array
, 0);
974 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->array
));
975 size_array_1
= ndr_get_array_size(ndr
, &r
->array
);
976 NDR_PULL_ALLOC_N(ndr
, r
->array
, size_array_1
);
977 _mem_save_array_1
= NDR_PULL_GET_MEM_CTX(ndr
);
978 NDR_PULL_SET_MEM_CTX(ndr
, r
->array
, 0);
979 for (cntr_array_1
= 0; cntr_array_1
< size_array_1
; cntr_array_1
++) {
980 NDR_CHECK(ndr_pull_srvsvc_NetCharDevQInfo1(ndr
, NDR_SCALARS
, &r
->array
[cntr_array_1
]));
982 for (cntr_array_1
= 0; cntr_array_1
< size_array_1
; cntr_array_1
++) {
983 NDR_CHECK(ndr_pull_srvsvc_NetCharDevQInfo1(ndr
, NDR_BUFFERS
, &r
->array
[cntr_array_1
]));
985 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_array_1
, 0);
986 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_array_0
, 0);
989 NDR_CHECK(ndr_check_array_size(ndr
, (void*)&r
->array
, r
->count
));
992 return NDR_ERR_SUCCESS
;
995 _PUBLIC_
void ndr_print_srvsvc_NetCharDevQCtr1(struct ndr_print
*ndr
, const char *name
, const struct srvsvc_NetCharDevQCtr1
*r
)
997 uint32_t cntr_array_1
;
998 ndr_print_struct(ndr
, name
, "srvsvc_NetCharDevQCtr1");
1000 ndr_print_uint32(ndr
, "count", r
->count
);
1001 ndr_print_ptr(ndr
, "array", r
->array
);
1004 ndr
->print(ndr
, "%s: ARRAY(%d)", "array", (int)r
->count
);
1006 for (cntr_array_1
=0;cntr_array_1
<r
->count
;cntr_array_1
++) {
1008 if (asprintf(&idx_1
, "[%d]", cntr_array_1
) != -1) {
1009 ndr_print_srvsvc_NetCharDevQInfo1(ndr
, "array", &r
->array
[cntr_array_1
]);
1019 static enum ndr_err_code
ndr_push_srvsvc_NetCharDevQInfo(struct ndr_push
*ndr
, int ndr_flags
, const union srvsvc_NetCharDevQInfo
*r
)
1021 if (ndr_flags
& NDR_SCALARS
) {
1022 int level
= ndr_push_get_switch_value(ndr
, r
);
1023 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, level
));
1026 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->info0
));
1030 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->info1
));
1038 if (ndr_flags
& NDR_BUFFERS
) {
1039 int level
= ndr_push_get_switch_value(ndr
, r
);
1043 NDR_CHECK(ndr_push_srvsvc_NetCharDevQInfo0(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->info0
));
1049 NDR_CHECK(ndr_push_srvsvc_NetCharDevQInfo1(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->info1
));
1058 return NDR_ERR_SUCCESS
;
1061 static enum ndr_err_code
ndr_pull_srvsvc_NetCharDevQInfo(struct ndr_pull
*ndr
, int ndr_flags
, union srvsvc_NetCharDevQInfo
*r
)
1065 TALLOC_CTX
*_mem_save_info0_0
;
1066 uint32_t _ptr_info0
;
1067 TALLOC_CTX
*_mem_save_info1_0
;
1068 uint32_t _ptr_info1
;
1069 level
= ndr_pull_get_switch_value(ndr
, r
);
1070 if (ndr_flags
& NDR_SCALARS
) {
1071 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &_level
));
1072 if (_level
!= level
) {
1073 return ndr_pull_error(ndr
, NDR_ERR_BAD_SWITCH
, "Bad switch value %u for r", _level
);
1077 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_info0
));
1079 NDR_PULL_ALLOC(ndr
, r
->info0
);
1086 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_info1
));
1088 NDR_PULL_ALLOC(ndr
, r
->info1
);
1099 if (ndr_flags
& NDR_BUFFERS
) {
1103 _mem_save_info0_0
= NDR_PULL_GET_MEM_CTX(ndr
);
1104 NDR_PULL_SET_MEM_CTX(ndr
, r
->info0
, 0);
1105 NDR_CHECK(ndr_pull_srvsvc_NetCharDevQInfo0(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->info0
));
1106 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_info0_0
, 0);
1112 _mem_save_info1_0
= NDR_PULL_GET_MEM_CTX(ndr
);
1113 NDR_PULL_SET_MEM_CTX(ndr
, r
->info1
, 0);
1114 NDR_CHECK(ndr_pull_srvsvc_NetCharDevQInfo1(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->info1
));
1115 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_info1_0
, 0);
1124 return NDR_ERR_SUCCESS
;
1127 _PUBLIC_
void ndr_print_srvsvc_NetCharDevQInfo(struct ndr_print
*ndr
, const char *name
, const union srvsvc_NetCharDevQInfo
*r
)
1130 level
= ndr_print_get_switch_value(ndr
, r
);
1131 ndr_print_union(ndr
, name
, level
, "srvsvc_NetCharDevQInfo");
1134 ndr_print_ptr(ndr
, "info0", r
->info0
);
1137 ndr_print_srvsvc_NetCharDevQInfo0(ndr
, "info0", r
->info0
);
1143 ndr_print_ptr(ndr
, "info1", r
->info1
);
1146 ndr_print_srvsvc_NetCharDevQInfo1(ndr
, "info1", r
->info1
);
1157 static enum ndr_err_code
ndr_push_srvsvc_NetCharDevQCtr(struct ndr_push
*ndr
, int ndr_flags
, const union srvsvc_NetCharDevQCtr
*r
)
1159 if (ndr_flags
& NDR_SCALARS
) {
1160 int level
= ndr_push_get_switch_value(ndr
, r
);
1161 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, level
));
1164 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->ctr0
));
1168 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->ctr1
));
1176 if (ndr_flags
& NDR_BUFFERS
) {
1177 int level
= ndr_push_get_switch_value(ndr
, r
);
1181 NDR_CHECK(ndr_push_srvsvc_NetCharDevQCtr0(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->ctr0
));
1187 NDR_CHECK(ndr_push_srvsvc_NetCharDevQCtr1(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->ctr1
));
1196 return NDR_ERR_SUCCESS
;
1199 static enum ndr_err_code
ndr_pull_srvsvc_NetCharDevQCtr(struct ndr_pull
*ndr
, int ndr_flags
, union srvsvc_NetCharDevQCtr
*r
)
1203 TALLOC_CTX
*_mem_save_ctr0_0
;
1205 TALLOC_CTX
*_mem_save_ctr1_0
;
1207 level
= ndr_pull_get_switch_value(ndr
, r
);
1208 if (ndr_flags
& NDR_SCALARS
) {
1209 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &_level
));
1210 if (_level
!= level
) {
1211 return ndr_pull_error(ndr
, NDR_ERR_BAD_SWITCH
, "Bad switch value %u for r", _level
);
1215 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_ctr0
));
1217 NDR_PULL_ALLOC(ndr
, r
->ctr0
);
1224 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_ctr1
));
1226 NDR_PULL_ALLOC(ndr
, r
->ctr1
);
1237 if (ndr_flags
& NDR_BUFFERS
) {
1241 _mem_save_ctr0_0
= NDR_PULL_GET_MEM_CTX(ndr
);
1242 NDR_PULL_SET_MEM_CTX(ndr
, r
->ctr0
, 0);
1243 NDR_CHECK(ndr_pull_srvsvc_NetCharDevQCtr0(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->ctr0
));
1244 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_ctr0_0
, 0);
1250 _mem_save_ctr1_0
= NDR_PULL_GET_MEM_CTX(ndr
);
1251 NDR_PULL_SET_MEM_CTX(ndr
, r
->ctr1
, 0);
1252 NDR_CHECK(ndr_pull_srvsvc_NetCharDevQCtr1(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->ctr1
));
1253 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_ctr1_0
, 0);
1262 return NDR_ERR_SUCCESS
;
1265 _PUBLIC_
void ndr_print_srvsvc_NetCharDevQCtr(struct ndr_print
*ndr
, const char *name
, const union srvsvc_NetCharDevQCtr
*r
)
1268 level
= ndr_print_get_switch_value(ndr
, r
);
1269 ndr_print_union(ndr
, name
, level
, "srvsvc_NetCharDevQCtr");
1272 ndr_print_ptr(ndr
, "ctr0", r
->ctr0
);
1275 ndr_print_srvsvc_NetCharDevQCtr0(ndr
, "ctr0", r
->ctr0
);
1281 ndr_print_ptr(ndr
, "ctr1", r
->ctr1
);
1284 ndr_print_srvsvc_NetCharDevQCtr1(ndr
, "ctr1", r
->ctr1
);
1295 static enum ndr_err_code
ndr_push_srvsvc_NetCharDevQInfoCtr(struct ndr_push
*ndr
, int ndr_flags
, const struct srvsvc_NetCharDevQInfoCtr
*r
)
1297 if (ndr_flags
& NDR_SCALARS
) {
1298 NDR_CHECK(ndr_push_align(ndr
, 4));
1299 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->level
));
1300 NDR_CHECK(ndr_push_set_switch_value(ndr
, &r
->ctr
, r
->level
));
1301 NDR_CHECK(ndr_push_srvsvc_NetCharDevQCtr(ndr
, NDR_SCALARS
, &r
->ctr
));
1303 if (ndr_flags
& NDR_BUFFERS
) {
1304 NDR_CHECK(ndr_push_srvsvc_NetCharDevQCtr(ndr
, NDR_BUFFERS
, &r
->ctr
));
1306 return NDR_ERR_SUCCESS
;
1309 static enum ndr_err_code
ndr_pull_srvsvc_NetCharDevQInfoCtr(struct ndr_pull
*ndr
, int ndr_flags
, struct srvsvc_NetCharDevQInfoCtr
*r
)
1311 if (ndr_flags
& NDR_SCALARS
) {
1312 NDR_CHECK(ndr_pull_align(ndr
, 4));
1313 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->level
));
1314 NDR_CHECK(ndr_pull_set_switch_value(ndr
, &r
->ctr
, r
->level
));
1315 NDR_CHECK(ndr_pull_srvsvc_NetCharDevQCtr(ndr
, NDR_SCALARS
, &r
->ctr
));
1317 if (ndr_flags
& NDR_BUFFERS
) {
1318 NDR_CHECK(ndr_pull_srvsvc_NetCharDevQCtr(ndr
, NDR_BUFFERS
, &r
->ctr
));
1320 return NDR_ERR_SUCCESS
;
1323 _PUBLIC_
void ndr_print_srvsvc_NetCharDevQInfoCtr(struct ndr_print
*ndr
, const char *name
, const struct srvsvc_NetCharDevQInfoCtr
*r
)
1325 ndr_print_struct(ndr
, name
, "srvsvc_NetCharDevQInfoCtr");
1327 ndr_print_uint32(ndr
, "level", r
->level
);
1328 ndr_print_set_switch_value(ndr
, &r
->ctr
, r
->level
);
1329 ndr_print_srvsvc_NetCharDevQCtr(ndr
, "ctr", &r
->ctr
);
1333 static enum ndr_err_code
ndr_push_srvsvc_NetConnInfo0(struct ndr_push
*ndr
, int ndr_flags
, const struct srvsvc_NetConnInfo0
*r
)
1335 if (ndr_flags
& NDR_SCALARS
) {
1336 NDR_CHECK(ndr_push_align(ndr
, 4));
1337 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->conn_id
));
1339 if (ndr_flags
& NDR_BUFFERS
) {
1341 return NDR_ERR_SUCCESS
;
1344 static enum ndr_err_code
ndr_pull_srvsvc_NetConnInfo0(struct ndr_pull
*ndr
, int ndr_flags
, struct srvsvc_NetConnInfo0
*r
)
1346 if (ndr_flags
& NDR_SCALARS
) {
1347 NDR_CHECK(ndr_pull_align(ndr
, 4));
1348 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->conn_id
));
1350 if (ndr_flags
& NDR_BUFFERS
) {
1352 return NDR_ERR_SUCCESS
;
1355 _PUBLIC_
void ndr_print_srvsvc_NetConnInfo0(struct ndr_print
*ndr
, const char *name
, const struct srvsvc_NetConnInfo0
*r
)
1357 ndr_print_struct(ndr
, name
, "srvsvc_NetConnInfo0");
1359 ndr_print_uint32(ndr
, "conn_id", r
->conn_id
);
1363 static enum ndr_err_code
ndr_push_srvsvc_NetConnCtr0(struct ndr_push
*ndr
, int ndr_flags
, const struct srvsvc_NetConnCtr0
*r
)
1365 uint32_t cntr_array_1
;
1366 if (ndr_flags
& NDR_SCALARS
) {
1367 NDR_CHECK(ndr_push_align(ndr
, 4));
1368 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->count
));
1369 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->array
));
1371 if (ndr_flags
& NDR_BUFFERS
) {
1373 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->count
));
1374 for (cntr_array_1
= 0; cntr_array_1
< r
->count
; cntr_array_1
++) {
1375 NDR_CHECK(ndr_push_srvsvc_NetConnInfo0(ndr
, NDR_SCALARS
, &r
->array
[cntr_array_1
]));
1379 return NDR_ERR_SUCCESS
;
1382 static enum ndr_err_code
ndr_pull_srvsvc_NetConnCtr0(struct ndr_pull
*ndr
, int ndr_flags
, struct srvsvc_NetConnCtr0
*r
)
1384 uint32_t _ptr_array
;
1385 uint32_t size_array_1
= 0;
1386 uint32_t cntr_array_1
;
1387 TALLOC_CTX
*_mem_save_array_0
;
1388 TALLOC_CTX
*_mem_save_array_1
;
1389 if (ndr_flags
& NDR_SCALARS
) {
1390 NDR_CHECK(ndr_pull_align(ndr
, 4));
1391 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->count
));
1392 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_array
));
1394 NDR_PULL_ALLOC(ndr
, r
->array
);
1399 if (ndr_flags
& NDR_BUFFERS
) {
1401 _mem_save_array_0
= NDR_PULL_GET_MEM_CTX(ndr
);
1402 NDR_PULL_SET_MEM_CTX(ndr
, r
->array
, 0);
1403 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->array
));
1404 size_array_1
= ndr_get_array_size(ndr
, &r
->array
);
1405 NDR_PULL_ALLOC_N(ndr
, r
->array
, size_array_1
);
1406 _mem_save_array_1
= NDR_PULL_GET_MEM_CTX(ndr
);
1407 NDR_PULL_SET_MEM_CTX(ndr
, r
->array
, 0);
1408 for (cntr_array_1
= 0; cntr_array_1
< size_array_1
; cntr_array_1
++) {
1409 NDR_CHECK(ndr_pull_srvsvc_NetConnInfo0(ndr
, NDR_SCALARS
, &r
->array
[cntr_array_1
]));
1411 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_array_1
, 0);
1412 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_array_0
, 0);
1415 NDR_CHECK(ndr_check_array_size(ndr
, (void*)&r
->array
, r
->count
));
1418 return NDR_ERR_SUCCESS
;
1421 _PUBLIC_
void ndr_print_srvsvc_NetConnCtr0(struct ndr_print
*ndr
, const char *name
, const struct srvsvc_NetConnCtr0
*r
)
1423 uint32_t cntr_array_1
;
1424 ndr_print_struct(ndr
, name
, "srvsvc_NetConnCtr0");
1426 ndr_print_uint32(ndr
, "count", r
->count
);
1427 ndr_print_ptr(ndr
, "array", r
->array
);
1430 ndr
->print(ndr
, "%s: ARRAY(%d)", "array", (int)r
->count
);
1432 for (cntr_array_1
=0;cntr_array_1
<r
->count
;cntr_array_1
++) {
1434 if (asprintf(&idx_1
, "[%d]", cntr_array_1
) != -1) {
1435 ndr_print_srvsvc_NetConnInfo0(ndr
, "array", &r
->array
[cntr_array_1
]);
1445 static enum ndr_err_code
ndr_push_srvsvc_NetConnInfo1(struct ndr_push
*ndr
, int ndr_flags
, const struct srvsvc_NetConnInfo1
*r
)
1447 if (ndr_flags
& NDR_SCALARS
) {
1448 NDR_CHECK(ndr_push_align(ndr
, 4));
1449 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->conn_id
));
1450 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->conn_type
));
1451 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->num_open
));
1452 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->num_users
));
1453 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->conn_time
));
1454 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->user
));
1455 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->share
));
1457 if (ndr_flags
& NDR_BUFFERS
) {
1459 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->user
, CH_UTF16
)));
1460 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
1461 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->user
, CH_UTF16
)));
1462 NDR_CHECK(ndr_push_charset(ndr
, NDR_SCALARS
, r
->user
, ndr_charset_length(r
->user
, CH_UTF16
), sizeof(uint16_t), CH_UTF16
));
1465 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->share
, CH_UTF16
)));
1466 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
1467 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->share
, CH_UTF16
)));
1468 NDR_CHECK(ndr_push_charset(ndr
, NDR_SCALARS
, r
->share
, ndr_charset_length(r
->share
, CH_UTF16
), sizeof(uint16_t), CH_UTF16
));
1471 return NDR_ERR_SUCCESS
;
1474 static enum ndr_err_code
ndr_pull_srvsvc_NetConnInfo1(struct ndr_pull
*ndr
, int ndr_flags
, struct srvsvc_NetConnInfo1
*r
)
1477 uint32_t size_user_1
= 0;
1478 uint32_t length_user_1
= 0;
1479 TALLOC_CTX
*_mem_save_user_0
;
1480 uint32_t _ptr_share
;
1481 uint32_t size_share_1
= 0;
1482 uint32_t length_share_1
= 0;
1483 TALLOC_CTX
*_mem_save_share_0
;
1484 if (ndr_flags
& NDR_SCALARS
) {
1485 NDR_CHECK(ndr_pull_align(ndr
, 4));
1486 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->conn_id
));
1487 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->conn_type
));
1488 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->num_open
));
1489 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->num_users
));
1490 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->conn_time
));
1491 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_user
));
1493 NDR_PULL_ALLOC(ndr
, r
->user
);
1497 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_share
));
1499 NDR_PULL_ALLOC(ndr
, r
->share
);
1504 if (ndr_flags
& NDR_BUFFERS
) {
1506 _mem_save_user_0
= NDR_PULL_GET_MEM_CTX(ndr
);
1507 NDR_PULL_SET_MEM_CTX(ndr
, r
->user
, 0);
1508 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->user
));
1509 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->user
));
1510 size_user_1
= ndr_get_array_size(ndr
, &r
->user
);
1511 length_user_1
= ndr_get_array_length(ndr
, &r
->user
);
1512 if (length_user_1
> size_user_1
) {
1513 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", size_user_1
, length_user_1
);
1515 NDR_CHECK(ndr_check_string_terminator(ndr
, length_user_1
, sizeof(uint16_t)));
1516 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->user
, length_user_1
, sizeof(uint16_t), CH_UTF16
));
1517 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_user_0
, 0);
1520 _mem_save_share_0
= NDR_PULL_GET_MEM_CTX(ndr
);
1521 NDR_PULL_SET_MEM_CTX(ndr
, r
->share
, 0);
1522 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->share
));
1523 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->share
));
1524 size_share_1
= ndr_get_array_size(ndr
, &r
->share
);
1525 length_share_1
= ndr_get_array_length(ndr
, &r
->share
);
1526 if (length_share_1
> size_share_1
) {
1527 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", size_share_1
, length_share_1
);
1529 NDR_CHECK(ndr_check_string_terminator(ndr
, length_share_1
, sizeof(uint16_t)));
1530 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->share
, length_share_1
, sizeof(uint16_t), CH_UTF16
));
1531 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_share_0
, 0);
1534 return NDR_ERR_SUCCESS
;
1537 _PUBLIC_
void ndr_print_srvsvc_NetConnInfo1(struct ndr_print
*ndr
, const char *name
, const struct srvsvc_NetConnInfo1
*r
)
1539 ndr_print_struct(ndr
, name
, "srvsvc_NetConnInfo1");
1541 ndr_print_uint32(ndr
, "conn_id", r
->conn_id
);
1542 ndr_print_uint32(ndr
, "conn_type", r
->conn_type
);
1543 ndr_print_uint32(ndr
, "num_open", r
->num_open
);
1544 ndr_print_uint32(ndr
, "num_users", r
->num_users
);
1545 ndr_print_uint32(ndr
, "conn_time", r
->conn_time
);
1546 ndr_print_ptr(ndr
, "user", r
->user
);
1549 ndr_print_string(ndr
, "user", r
->user
);
1552 ndr_print_ptr(ndr
, "share", r
->share
);
1555 ndr_print_string(ndr
, "share", r
->share
);
1561 static enum ndr_err_code
ndr_push_srvsvc_NetConnCtr1(struct ndr_push
*ndr
, int ndr_flags
, const struct srvsvc_NetConnCtr1
*r
)
1563 uint32_t cntr_array_1
;
1564 if (ndr_flags
& NDR_SCALARS
) {
1565 NDR_CHECK(ndr_push_align(ndr
, 4));
1566 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->count
));
1567 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->array
));
1569 if (ndr_flags
& NDR_BUFFERS
) {
1571 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->count
));
1572 for (cntr_array_1
= 0; cntr_array_1
< r
->count
; cntr_array_1
++) {
1573 NDR_CHECK(ndr_push_srvsvc_NetConnInfo1(ndr
, NDR_SCALARS
, &r
->array
[cntr_array_1
]));
1575 for (cntr_array_1
= 0; cntr_array_1
< r
->count
; cntr_array_1
++) {
1576 NDR_CHECK(ndr_push_srvsvc_NetConnInfo1(ndr
, NDR_BUFFERS
, &r
->array
[cntr_array_1
]));
1580 return NDR_ERR_SUCCESS
;
1583 static enum ndr_err_code
ndr_pull_srvsvc_NetConnCtr1(struct ndr_pull
*ndr
, int ndr_flags
, struct srvsvc_NetConnCtr1
*r
)
1585 uint32_t _ptr_array
;
1586 uint32_t size_array_1
= 0;
1587 uint32_t cntr_array_1
;
1588 TALLOC_CTX
*_mem_save_array_0
;
1589 TALLOC_CTX
*_mem_save_array_1
;
1590 if (ndr_flags
& NDR_SCALARS
) {
1591 NDR_CHECK(ndr_pull_align(ndr
, 4));
1592 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->count
));
1593 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_array
));
1595 NDR_PULL_ALLOC(ndr
, r
->array
);
1600 if (ndr_flags
& NDR_BUFFERS
) {
1602 _mem_save_array_0
= NDR_PULL_GET_MEM_CTX(ndr
);
1603 NDR_PULL_SET_MEM_CTX(ndr
, r
->array
, 0);
1604 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->array
));
1605 size_array_1
= ndr_get_array_size(ndr
, &r
->array
);
1606 NDR_PULL_ALLOC_N(ndr
, r
->array
, size_array_1
);
1607 _mem_save_array_1
= NDR_PULL_GET_MEM_CTX(ndr
);
1608 NDR_PULL_SET_MEM_CTX(ndr
, r
->array
, 0);
1609 for (cntr_array_1
= 0; cntr_array_1
< size_array_1
; cntr_array_1
++) {
1610 NDR_CHECK(ndr_pull_srvsvc_NetConnInfo1(ndr
, NDR_SCALARS
, &r
->array
[cntr_array_1
]));
1612 for (cntr_array_1
= 0; cntr_array_1
< size_array_1
; cntr_array_1
++) {
1613 NDR_CHECK(ndr_pull_srvsvc_NetConnInfo1(ndr
, NDR_BUFFERS
, &r
->array
[cntr_array_1
]));
1615 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_array_1
, 0);
1616 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_array_0
, 0);
1619 NDR_CHECK(ndr_check_array_size(ndr
, (void*)&r
->array
, r
->count
));
1622 return NDR_ERR_SUCCESS
;
1625 _PUBLIC_
void ndr_print_srvsvc_NetConnCtr1(struct ndr_print
*ndr
, const char *name
, const struct srvsvc_NetConnCtr1
*r
)
1627 uint32_t cntr_array_1
;
1628 ndr_print_struct(ndr
, name
, "srvsvc_NetConnCtr1");
1630 ndr_print_uint32(ndr
, "count", r
->count
);
1631 ndr_print_ptr(ndr
, "array", r
->array
);
1634 ndr
->print(ndr
, "%s: ARRAY(%d)", "array", (int)r
->count
);
1636 for (cntr_array_1
=0;cntr_array_1
<r
->count
;cntr_array_1
++) {
1638 if (asprintf(&idx_1
, "[%d]", cntr_array_1
) != -1) {
1639 ndr_print_srvsvc_NetConnInfo1(ndr
, "array", &r
->array
[cntr_array_1
]);
1649 static enum ndr_err_code
ndr_push_srvsvc_NetConnCtr(struct ndr_push
*ndr
, int ndr_flags
, const union srvsvc_NetConnCtr
*r
)
1651 if (ndr_flags
& NDR_SCALARS
) {
1652 int level
= ndr_push_get_switch_value(ndr
, r
);
1653 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, level
));
1656 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->ctr0
));
1660 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->ctr1
));
1668 if (ndr_flags
& NDR_BUFFERS
) {
1669 int level
= ndr_push_get_switch_value(ndr
, r
);
1673 NDR_CHECK(ndr_push_srvsvc_NetConnCtr0(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->ctr0
));
1679 NDR_CHECK(ndr_push_srvsvc_NetConnCtr1(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->ctr1
));
1688 return NDR_ERR_SUCCESS
;
1691 static enum ndr_err_code
ndr_pull_srvsvc_NetConnCtr(struct ndr_pull
*ndr
, int ndr_flags
, union srvsvc_NetConnCtr
*r
)
1695 TALLOC_CTX
*_mem_save_ctr0_0
;
1697 TALLOC_CTX
*_mem_save_ctr1_0
;
1699 level
= ndr_pull_get_switch_value(ndr
, r
);
1700 if (ndr_flags
& NDR_SCALARS
) {
1701 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &_level
));
1702 if (_level
!= level
) {
1703 return ndr_pull_error(ndr
, NDR_ERR_BAD_SWITCH
, "Bad switch value %u for r", _level
);
1707 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_ctr0
));
1709 NDR_PULL_ALLOC(ndr
, r
->ctr0
);
1716 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_ctr1
));
1718 NDR_PULL_ALLOC(ndr
, r
->ctr1
);
1729 if (ndr_flags
& NDR_BUFFERS
) {
1733 _mem_save_ctr0_0
= NDR_PULL_GET_MEM_CTX(ndr
);
1734 NDR_PULL_SET_MEM_CTX(ndr
, r
->ctr0
, 0);
1735 NDR_CHECK(ndr_pull_srvsvc_NetConnCtr0(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->ctr0
));
1736 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_ctr0_0
, 0);
1742 _mem_save_ctr1_0
= NDR_PULL_GET_MEM_CTX(ndr
);
1743 NDR_PULL_SET_MEM_CTX(ndr
, r
->ctr1
, 0);
1744 NDR_CHECK(ndr_pull_srvsvc_NetConnCtr1(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->ctr1
));
1745 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_ctr1_0
, 0);
1754 return NDR_ERR_SUCCESS
;
1757 _PUBLIC_
void ndr_print_srvsvc_NetConnCtr(struct ndr_print
*ndr
, const char *name
, const union srvsvc_NetConnCtr
*r
)
1760 level
= ndr_print_get_switch_value(ndr
, r
);
1761 ndr_print_union(ndr
, name
, level
, "srvsvc_NetConnCtr");
1764 ndr_print_ptr(ndr
, "ctr0", r
->ctr0
);
1767 ndr_print_srvsvc_NetConnCtr0(ndr
, "ctr0", r
->ctr0
);
1773 ndr_print_ptr(ndr
, "ctr1", r
->ctr1
);
1776 ndr_print_srvsvc_NetConnCtr1(ndr
, "ctr1", r
->ctr1
);
1787 static enum ndr_err_code
ndr_push_srvsvc_NetConnInfoCtr(struct ndr_push
*ndr
, int ndr_flags
, const struct srvsvc_NetConnInfoCtr
*r
)
1789 if (ndr_flags
& NDR_SCALARS
) {
1790 NDR_CHECK(ndr_push_align(ndr
, 4));
1791 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->level
));
1792 NDR_CHECK(ndr_push_set_switch_value(ndr
, &r
->ctr
, r
->level
));
1793 NDR_CHECK(ndr_push_srvsvc_NetConnCtr(ndr
, NDR_SCALARS
, &r
->ctr
));
1795 if (ndr_flags
& NDR_BUFFERS
) {
1796 NDR_CHECK(ndr_push_srvsvc_NetConnCtr(ndr
, NDR_BUFFERS
, &r
->ctr
));
1798 return NDR_ERR_SUCCESS
;
1801 static enum ndr_err_code
ndr_pull_srvsvc_NetConnInfoCtr(struct ndr_pull
*ndr
, int ndr_flags
, struct srvsvc_NetConnInfoCtr
*r
)
1803 if (ndr_flags
& NDR_SCALARS
) {
1804 NDR_CHECK(ndr_pull_align(ndr
, 4));
1805 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->level
));
1806 NDR_CHECK(ndr_pull_set_switch_value(ndr
, &r
->ctr
, r
->level
));
1807 NDR_CHECK(ndr_pull_srvsvc_NetConnCtr(ndr
, NDR_SCALARS
, &r
->ctr
));
1809 if (ndr_flags
& NDR_BUFFERS
) {
1810 NDR_CHECK(ndr_pull_srvsvc_NetConnCtr(ndr
, NDR_BUFFERS
, &r
->ctr
));
1812 return NDR_ERR_SUCCESS
;
1815 _PUBLIC_
void ndr_print_srvsvc_NetConnInfoCtr(struct ndr_print
*ndr
, const char *name
, const struct srvsvc_NetConnInfoCtr
*r
)
1817 ndr_print_struct(ndr
, name
, "srvsvc_NetConnInfoCtr");
1819 ndr_print_uint32(ndr
, "level", r
->level
);
1820 ndr_print_set_switch_value(ndr
, &r
->ctr
, r
->level
);
1821 ndr_print_srvsvc_NetConnCtr(ndr
, "ctr", &r
->ctr
);
1825 static enum ndr_err_code
ndr_push_srvsvc_NetFileInfo2(struct ndr_push
*ndr
, int ndr_flags
, const struct srvsvc_NetFileInfo2
*r
)
1827 if (ndr_flags
& NDR_SCALARS
) {
1828 NDR_CHECK(ndr_push_align(ndr
, 4));
1829 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->fid
));
1831 if (ndr_flags
& NDR_BUFFERS
) {
1833 return NDR_ERR_SUCCESS
;
1836 static enum ndr_err_code
ndr_pull_srvsvc_NetFileInfo2(struct ndr_pull
*ndr
, int ndr_flags
, struct srvsvc_NetFileInfo2
*r
)
1838 if (ndr_flags
& NDR_SCALARS
) {
1839 NDR_CHECK(ndr_pull_align(ndr
, 4));
1840 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->fid
));
1842 if (ndr_flags
& NDR_BUFFERS
) {
1844 return NDR_ERR_SUCCESS
;
1847 _PUBLIC_
void ndr_print_srvsvc_NetFileInfo2(struct ndr_print
*ndr
, const char *name
, const struct srvsvc_NetFileInfo2
*r
)
1849 ndr_print_struct(ndr
, name
, "srvsvc_NetFileInfo2");
1851 ndr_print_uint32(ndr
, "fid", r
->fid
);
1855 static enum ndr_err_code
ndr_push_srvsvc_NetFileCtr2(struct ndr_push
*ndr
, int ndr_flags
, const struct srvsvc_NetFileCtr2
*r
)
1857 uint32_t cntr_array_1
;
1858 if (ndr_flags
& NDR_SCALARS
) {
1859 NDR_CHECK(ndr_push_align(ndr
, 4));
1860 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->count
));
1861 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->array
));
1863 if (ndr_flags
& NDR_BUFFERS
) {
1865 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->count
));
1866 for (cntr_array_1
= 0; cntr_array_1
< r
->count
; cntr_array_1
++) {
1867 NDR_CHECK(ndr_push_srvsvc_NetFileInfo2(ndr
, NDR_SCALARS
, &r
->array
[cntr_array_1
]));
1871 return NDR_ERR_SUCCESS
;
1874 static enum ndr_err_code
ndr_pull_srvsvc_NetFileCtr2(struct ndr_pull
*ndr
, int ndr_flags
, struct srvsvc_NetFileCtr2
*r
)
1876 uint32_t _ptr_array
;
1877 uint32_t size_array_1
= 0;
1878 uint32_t cntr_array_1
;
1879 TALLOC_CTX
*_mem_save_array_0
;
1880 TALLOC_CTX
*_mem_save_array_1
;
1881 if (ndr_flags
& NDR_SCALARS
) {
1882 NDR_CHECK(ndr_pull_align(ndr
, 4));
1883 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->count
));
1884 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_array
));
1886 NDR_PULL_ALLOC(ndr
, r
->array
);
1891 if (ndr_flags
& NDR_BUFFERS
) {
1893 _mem_save_array_0
= NDR_PULL_GET_MEM_CTX(ndr
);
1894 NDR_PULL_SET_MEM_CTX(ndr
, r
->array
, 0);
1895 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->array
));
1896 size_array_1
= ndr_get_array_size(ndr
, &r
->array
);
1897 NDR_PULL_ALLOC_N(ndr
, r
->array
, size_array_1
);
1898 _mem_save_array_1
= NDR_PULL_GET_MEM_CTX(ndr
);
1899 NDR_PULL_SET_MEM_CTX(ndr
, r
->array
, 0);
1900 for (cntr_array_1
= 0; cntr_array_1
< size_array_1
; cntr_array_1
++) {
1901 NDR_CHECK(ndr_pull_srvsvc_NetFileInfo2(ndr
, NDR_SCALARS
, &r
->array
[cntr_array_1
]));
1903 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_array_1
, 0);
1904 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_array_0
, 0);
1907 NDR_CHECK(ndr_check_array_size(ndr
, (void*)&r
->array
, r
->count
));
1910 return NDR_ERR_SUCCESS
;
1913 _PUBLIC_
void ndr_print_srvsvc_NetFileCtr2(struct ndr_print
*ndr
, const char *name
, const struct srvsvc_NetFileCtr2
*r
)
1915 uint32_t cntr_array_1
;
1916 ndr_print_struct(ndr
, name
, "srvsvc_NetFileCtr2");
1918 ndr_print_uint32(ndr
, "count", r
->count
);
1919 ndr_print_ptr(ndr
, "array", r
->array
);
1922 ndr
->print(ndr
, "%s: ARRAY(%d)", "array", (int)r
->count
);
1924 for (cntr_array_1
=0;cntr_array_1
<r
->count
;cntr_array_1
++) {
1926 if (asprintf(&idx_1
, "[%d]", cntr_array_1
) != -1) {
1927 ndr_print_srvsvc_NetFileInfo2(ndr
, "array", &r
->array
[cntr_array_1
]);
1937 static enum ndr_err_code
ndr_push_srvsvc_NetFileInfo3(struct ndr_push
*ndr
, int ndr_flags
, const struct srvsvc_NetFileInfo3
*r
)
1939 if (ndr_flags
& NDR_SCALARS
) {
1940 NDR_CHECK(ndr_push_align(ndr
, 4));
1941 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->fid
));
1942 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->permissions
));
1943 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->num_locks
));
1944 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->path
));
1945 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->user
));
1947 if (ndr_flags
& NDR_BUFFERS
) {
1949 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->path
, CH_UTF16
)));
1950 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
1951 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->path
, CH_UTF16
)));
1952 NDR_CHECK(ndr_push_charset(ndr
, NDR_SCALARS
, r
->path
, ndr_charset_length(r
->path
, CH_UTF16
), sizeof(uint16_t), CH_UTF16
));
1955 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->user
, CH_UTF16
)));
1956 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
1957 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->user
, CH_UTF16
)));
1958 NDR_CHECK(ndr_push_charset(ndr
, NDR_SCALARS
, r
->user
, ndr_charset_length(r
->user
, CH_UTF16
), sizeof(uint16_t), CH_UTF16
));
1961 return NDR_ERR_SUCCESS
;
1964 static enum ndr_err_code
ndr_pull_srvsvc_NetFileInfo3(struct ndr_pull
*ndr
, int ndr_flags
, struct srvsvc_NetFileInfo3
*r
)
1967 uint32_t size_path_1
= 0;
1968 uint32_t length_path_1
= 0;
1969 TALLOC_CTX
*_mem_save_path_0
;
1971 uint32_t size_user_1
= 0;
1972 uint32_t length_user_1
= 0;
1973 TALLOC_CTX
*_mem_save_user_0
;
1974 if (ndr_flags
& NDR_SCALARS
) {
1975 NDR_CHECK(ndr_pull_align(ndr
, 4));
1976 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->fid
));
1977 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->permissions
));
1978 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->num_locks
));
1979 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_path
));
1981 NDR_PULL_ALLOC(ndr
, r
->path
);
1985 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_user
));
1987 NDR_PULL_ALLOC(ndr
, r
->user
);
1992 if (ndr_flags
& NDR_BUFFERS
) {
1994 _mem_save_path_0
= NDR_PULL_GET_MEM_CTX(ndr
);
1995 NDR_PULL_SET_MEM_CTX(ndr
, r
->path
, 0);
1996 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->path
));
1997 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->path
));
1998 size_path_1
= ndr_get_array_size(ndr
, &r
->path
);
1999 length_path_1
= ndr_get_array_length(ndr
, &r
->path
);
2000 if (length_path_1
> size_path_1
) {
2001 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", size_path_1
, length_path_1
);
2003 NDR_CHECK(ndr_check_string_terminator(ndr
, length_path_1
, sizeof(uint16_t)));
2004 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->path
, length_path_1
, sizeof(uint16_t), CH_UTF16
));
2005 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_path_0
, 0);
2008 _mem_save_user_0
= NDR_PULL_GET_MEM_CTX(ndr
);
2009 NDR_PULL_SET_MEM_CTX(ndr
, r
->user
, 0);
2010 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->user
));
2011 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->user
));
2012 size_user_1
= ndr_get_array_size(ndr
, &r
->user
);
2013 length_user_1
= ndr_get_array_length(ndr
, &r
->user
);
2014 if (length_user_1
> size_user_1
) {
2015 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", size_user_1
, length_user_1
);
2017 NDR_CHECK(ndr_check_string_terminator(ndr
, length_user_1
, sizeof(uint16_t)));
2018 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->user
, length_user_1
, sizeof(uint16_t), CH_UTF16
));
2019 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_user_0
, 0);
2022 return NDR_ERR_SUCCESS
;
2025 _PUBLIC_
void ndr_print_srvsvc_NetFileInfo3(struct ndr_print
*ndr
, const char *name
, const struct srvsvc_NetFileInfo3
*r
)
2027 ndr_print_struct(ndr
, name
, "srvsvc_NetFileInfo3");
2029 ndr_print_uint32(ndr
, "fid", r
->fid
);
2030 ndr_print_uint32(ndr
, "permissions", r
->permissions
);
2031 ndr_print_uint32(ndr
, "num_locks", r
->num_locks
);
2032 ndr_print_ptr(ndr
, "path", r
->path
);
2035 ndr_print_string(ndr
, "path", r
->path
);
2038 ndr_print_ptr(ndr
, "user", r
->user
);
2041 ndr_print_string(ndr
, "user", r
->user
);
2047 static enum ndr_err_code
ndr_push_srvsvc_NetFileCtr3(struct ndr_push
*ndr
, int ndr_flags
, const struct srvsvc_NetFileCtr3
*r
)
2049 uint32_t cntr_array_1
;
2050 if (ndr_flags
& NDR_SCALARS
) {
2051 NDR_CHECK(ndr_push_align(ndr
, 4));
2052 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->count
));
2053 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->array
));
2055 if (ndr_flags
& NDR_BUFFERS
) {
2057 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->count
));
2058 for (cntr_array_1
= 0; cntr_array_1
< r
->count
; cntr_array_1
++) {
2059 NDR_CHECK(ndr_push_srvsvc_NetFileInfo3(ndr
, NDR_SCALARS
, &r
->array
[cntr_array_1
]));
2061 for (cntr_array_1
= 0; cntr_array_1
< r
->count
; cntr_array_1
++) {
2062 NDR_CHECK(ndr_push_srvsvc_NetFileInfo3(ndr
, NDR_BUFFERS
, &r
->array
[cntr_array_1
]));
2066 return NDR_ERR_SUCCESS
;
2069 static enum ndr_err_code
ndr_pull_srvsvc_NetFileCtr3(struct ndr_pull
*ndr
, int ndr_flags
, struct srvsvc_NetFileCtr3
*r
)
2071 uint32_t _ptr_array
;
2072 uint32_t size_array_1
= 0;
2073 uint32_t cntr_array_1
;
2074 TALLOC_CTX
*_mem_save_array_0
;
2075 TALLOC_CTX
*_mem_save_array_1
;
2076 if (ndr_flags
& NDR_SCALARS
) {
2077 NDR_CHECK(ndr_pull_align(ndr
, 4));
2078 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->count
));
2079 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_array
));
2081 NDR_PULL_ALLOC(ndr
, r
->array
);
2086 if (ndr_flags
& NDR_BUFFERS
) {
2088 _mem_save_array_0
= NDR_PULL_GET_MEM_CTX(ndr
);
2089 NDR_PULL_SET_MEM_CTX(ndr
, r
->array
, 0);
2090 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->array
));
2091 size_array_1
= ndr_get_array_size(ndr
, &r
->array
);
2092 NDR_PULL_ALLOC_N(ndr
, r
->array
, size_array_1
);
2093 _mem_save_array_1
= NDR_PULL_GET_MEM_CTX(ndr
);
2094 NDR_PULL_SET_MEM_CTX(ndr
, r
->array
, 0);
2095 for (cntr_array_1
= 0; cntr_array_1
< size_array_1
; cntr_array_1
++) {
2096 NDR_CHECK(ndr_pull_srvsvc_NetFileInfo3(ndr
, NDR_SCALARS
, &r
->array
[cntr_array_1
]));
2098 for (cntr_array_1
= 0; cntr_array_1
< size_array_1
; cntr_array_1
++) {
2099 NDR_CHECK(ndr_pull_srvsvc_NetFileInfo3(ndr
, NDR_BUFFERS
, &r
->array
[cntr_array_1
]));
2101 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_array_1
, 0);
2102 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_array_0
, 0);
2105 NDR_CHECK(ndr_check_array_size(ndr
, (void*)&r
->array
, r
->count
));
2108 return NDR_ERR_SUCCESS
;
2111 _PUBLIC_
void ndr_print_srvsvc_NetFileCtr3(struct ndr_print
*ndr
, const char *name
, const struct srvsvc_NetFileCtr3
*r
)
2113 uint32_t cntr_array_1
;
2114 ndr_print_struct(ndr
, name
, "srvsvc_NetFileCtr3");
2116 ndr_print_uint32(ndr
, "count", r
->count
);
2117 ndr_print_ptr(ndr
, "array", r
->array
);
2120 ndr
->print(ndr
, "%s: ARRAY(%d)", "array", (int)r
->count
);
2122 for (cntr_array_1
=0;cntr_array_1
<r
->count
;cntr_array_1
++) {
2124 if (asprintf(&idx_1
, "[%d]", cntr_array_1
) != -1) {
2125 ndr_print_srvsvc_NetFileInfo3(ndr
, "array", &r
->array
[cntr_array_1
]);
2135 static enum ndr_err_code
ndr_push_srvsvc_NetFileInfo(struct ndr_push
*ndr
, int ndr_flags
, const union srvsvc_NetFileInfo
*r
)
2137 if (ndr_flags
& NDR_SCALARS
) {
2138 int level
= ndr_push_get_switch_value(ndr
, r
);
2139 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, level
));
2142 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->info2
));
2146 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->info3
));
2154 if (ndr_flags
& NDR_BUFFERS
) {
2155 int level
= ndr_push_get_switch_value(ndr
, r
);
2159 NDR_CHECK(ndr_push_srvsvc_NetFileInfo2(ndr
, NDR_SCALARS
, r
->info2
));
2165 NDR_CHECK(ndr_push_srvsvc_NetFileInfo3(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->info3
));
2174 return NDR_ERR_SUCCESS
;
2177 static enum ndr_err_code
ndr_pull_srvsvc_NetFileInfo(struct ndr_pull
*ndr
, int ndr_flags
, union srvsvc_NetFileInfo
*r
)
2181 TALLOC_CTX
*_mem_save_info2_0
;
2182 uint32_t _ptr_info2
;
2183 TALLOC_CTX
*_mem_save_info3_0
;
2184 uint32_t _ptr_info3
;
2185 level
= ndr_pull_get_switch_value(ndr
, r
);
2186 if (ndr_flags
& NDR_SCALARS
) {
2187 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &_level
));
2188 if (_level
!= level
) {
2189 return ndr_pull_error(ndr
, NDR_ERR_BAD_SWITCH
, "Bad switch value %u for r", _level
);
2193 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_info2
));
2195 NDR_PULL_ALLOC(ndr
, r
->info2
);
2202 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_info3
));
2204 NDR_PULL_ALLOC(ndr
, r
->info3
);
2215 if (ndr_flags
& NDR_BUFFERS
) {
2219 _mem_save_info2_0
= NDR_PULL_GET_MEM_CTX(ndr
);
2220 NDR_PULL_SET_MEM_CTX(ndr
, r
->info2
, 0);
2221 NDR_CHECK(ndr_pull_srvsvc_NetFileInfo2(ndr
, NDR_SCALARS
, r
->info2
));
2222 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_info2_0
, 0);
2228 _mem_save_info3_0
= NDR_PULL_GET_MEM_CTX(ndr
);
2229 NDR_PULL_SET_MEM_CTX(ndr
, r
->info3
, 0);
2230 NDR_CHECK(ndr_pull_srvsvc_NetFileInfo3(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->info3
));
2231 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_info3_0
, 0);
2240 return NDR_ERR_SUCCESS
;
2243 _PUBLIC_
void ndr_print_srvsvc_NetFileInfo(struct ndr_print
*ndr
, const char *name
, const union srvsvc_NetFileInfo
*r
)
2246 level
= ndr_print_get_switch_value(ndr
, r
);
2247 ndr_print_union(ndr
, name
, level
, "srvsvc_NetFileInfo");
2250 ndr_print_ptr(ndr
, "info2", r
->info2
);
2253 ndr_print_srvsvc_NetFileInfo2(ndr
, "info2", r
->info2
);
2259 ndr_print_ptr(ndr
, "info3", r
->info3
);
2262 ndr_print_srvsvc_NetFileInfo3(ndr
, "info3", r
->info3
);
2273 static enum ndr_err_code
ndr_push_srvsvc_NetFileCtr(struct ndr_push
*ndr
, int ndr_flags
, const union srvsvc_NetFileCtr
*r
)
2275 if (ndr_flags
& NDR_SCALARS
) {
2276 int level
= ndr_push_get_switch_value(ndr
, r
);
2277 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, level
));
2280 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->ctr2
));
2284 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->ctr3
));
2292 if (ndr_flags
& NDR_BUFFERS
) {
2293 int level
= ndr_push_get_switch_value(ndr
, r
);
2297 NDR_CHECK(ndr_push_srvsvc_NetFileCtr2(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->ctr2
));
2303 NDR_CHECK(ndr_push_srvsvc_NetFileCtr3(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->ctr3
));
2312 return NDR_ERR_SUCCESS
;
2315 static enum ndr_err_code
ndr_pull_srvsvc_NetFileCtr(struct ndr_pull
*ndr
, int ndr_flags
, union srvsvc_NetFileCtr
*r
)
2319 TALLOC_CTX
*_mem_save_ctr2_0
;
2321 TALLOC_CTX
*_mem_save_ctr3_0
;
2323 level
= ndr_pull_get_switch_value(ndr
, r
);
2324 if (ndr_flags
& NDR_SCALARS
) {
2325 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &_level
));
2326 if (_level
!= level
) {
2327 return ndr_pull_error(ndr
, NDR_ERR_BAD_SWITCH
, "Bad switch value %u for r", _level
);
2331 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_ctr2
));
2333 NDR_PULL_ALLOC(ndr
, r
->ctr2
);
2340 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_ctr3
));
2342 NDR_PULL_ALLOC(ndr
, r
->ctr3
);
2353 if (ndr_flags
& NDR_BUFFERS
) {
2357 _mem_save_ctr2_0
= NDR_PULL_GET_MEM_CTX(ndr
);
2358 NDR_PULL_SET_MEM_CTX(ndr
, r
->ctr2
, 0);
2359 NDR_CHECK(ndr_pull_srvsvc_NetFileCtr2(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->ctr2
));
2360 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_ctr2_0
, 0);
2366 _mem_save_ctr3_0
= NDR_PULL_GET_MEM_CTX(ndr
);
2367 NDR_PULL_SET_MEM_CTX(ndr
, r
->ctr3
, 0);
2368 NDR_CHECK(ndr_pull_srvsvc_NetFileCtr3(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->ctr3
));
2369 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_ctr3_0
, 0);
2378 return NDR_ERR_SUCCESS
;
2381 _PUBLIC_
void ndr_print_srvsvc_NetFileCtr(struct ndr_print
*ndr
, const char *name
, const union srvsvc_NetFileCtr
*r
)
2384 level
= ndr_print_get_switch_value(ndr
, r
);
2385 ndr_print_union(ndr
, name
, level
, "srvsvc_NetFileCtr");
2388 ndr_print_ptr(ndr
, "ctr2", r
->ctr2
);
2391 ndr_print_srvsvc_NetFileCtr2(ndr
, "ctr2", r
->ctr2
);
2397 ndr_print_ptr(ndr
, "ctr3", r
->ctr3
);
2400 ndr_print_srvsvc_NetFileCtr3(ndr
, "ctr3", r
->ctr3
);
2411 static enum ndr_err_code
ndr_push_srvsvc_NetFileInfoCtr(struct ndr_push
*ndr
, int ndr_flags
, const struct srvsvc_NetFileInfoCtr
*r
)
2413 if (ndr_flags
& NDR_SCALARS
) {
2414 NDR_CHECK(ndr_push_align(ndr
, 4));
2415 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->level
));
2416 NDR_CHECK(ndr_push_set_switch_value(ndr
, &r
->ctr
, r
->level
));
2417 NDR_CHECK(ndr_push_srvsvc_NetFileCtr(ndr
, NDR_SCALARS
, &r
->ctr
));
2419 if (ndr_flags
& NDR_BUFFERS
) {
2420 NDR_CHECK(ndr_push_srvsvc_NetFileCtr(ndr
, NDR_BUFFERS
, &r
->ctr
));
2422 return NDR_ERR_SUCCESS
;
2425 static enum ndr_err_code
ndr_pull_srvsvc_NetFileInfoCtr(struct ndr_pull
*ndr
, int ndr_flags
, struct srvsvc_NetFileInfoCtr
*r
)
2427 if (ndr_flags
& NDR_SCALARS
) {
2428 NDR_CHECK(ndr_pull_align(ndr
, 4));
2429 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->level
));
2430 NDR_CHECK(ndr_pull_set_switch_value(ndr
, &r
->ctr
, r
->level
));
2431 NDR_CHECK(ndr_pull_srvsvc_NetFileCtr(ndr
, NDR_SCALARS
, &r
->ctr
));
2433 if (ndr_flags
& NDR_BUFFERS
) {
2434 NDR_CHECK(ndr_pull_srvsvc_NetFileCtr(ndr
, NDR_BUFFERS
, &r
->ctr
));
2436 return NDR_ERR_SUCCESS
;
2439 _PUBLIC_
void ndr_print_srvsvc_NetFileInfoCtr(struct ndr_print
*ndr
, const char *name
, const struct srvsvc_NetFileInfoCtr
*r
)
2441 ndr_print_struct(ndr
, name
, "srvsvc_NetFileInfoCtr");
2443 ndr_print_uint32(ndr
, "level", r
->level
);
2444 ndr_print_set_switch_value(ndr
, &r
->ctr
, r
->level
);
2445 ndr_print_srvsvc_NetFileCtr(ndr
, "ctr", &r
->ctr
);
2449 static enum ndr_err_code
ndr_push_srvsvc_NetSessInfo0(struct ndr_push
*ndr
, int ndr_flags
, const struct srvsvc_NetSessInfo0
*r
)
2451 if (ndr_flags
& NDR_SCALARS
) {
2452 NDR_CHECK(ndr_push_align(ndr
, 4));
2453 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->client
));
2455 if (ndr_flags
& NDR_BUFFERS
) {
2457 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->client
, CH_UTF16
)));
2458 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
2459 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->client
, CH_UTF16
)));
2460 NDR_CHECK(ndr_push_charset(ndr
, NDR_SCALARS
, r
->client
, ndr_charset_length(r
->client
, CH_UTF16
), sizeof(uint16_t), CH_UTF16
));
2463 return NDR_ERR_SUCCESS
;
2466 static enum ndr_err_code
ndr_pull_srvsvc_NetSessInfo0(struct ndr_pull
*ndr
, int ndr_flags
, struct srvsvc_NetSessInfo0
*r
)
2468 uint32_t _ptr_client
;
2469 uint32_t size_client_1
= 0;
2470 uint32_t length_client_1
= 0;
2471 TALLOC_CTX
*_mem_save_client_0
;
2472 if (ndr_flags
& NDR_SCALARS
) {
2473 NDR_CHECK(ndr_pull_align(ndr
, 4));
2474 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_client
));
2476 NDR_PULL_ALLOC(ndr
, r
->client
);
2481 if (ndr_flags
& NDR_BUFFERS
) {
2483 _mem_save_client_0
= NDR_PULL_GET_MEM_CTX(ndr
);
2484 NDR_PULL_SET_MEM_CTX(ndr
, r
->client
, 0);
2485 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->client
));
2486 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->client
));
2487 size_client_1
= ndr_get_array_size(ndr
, &r
->client
);
2488 length_client_1
= ndr_get_array_length(ndr
, &r
->client
);
2489 if (length_client_1
> size_client_1
) {
2490 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", size_client_1
, length_client_1
);
2492 NDR_CHECK(ndr_check_string_terminator(ndr
, length_client_1
, sizeof(uint16_t)));
2493 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->client
, length_client_1
, sizeof(uint16_t), CH_UTF16
));
2494 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_client_0
, 0);
2497 return NDR_ERR_SUCCESS
;
2500 _PUBLIC_
void ndr_print_srvsvc_NetSessInfo0(struct ndr_print
*ndr
, const char *name
, const struct srvsvc_NetSessInfo0
*r
)
2502 ndr_print_struct(ndr
, name
, "srvsvc_NetSessInfo0");
2504 ndr_print_ptr(ndr
, "client", r
->client
);
2507 ndr_print_string(ndr
, "client", r
->client
);
2513 static enum ndr_err_code
ndr_push_srvsvc_NetSessCtr0(struct ndr_push
*ndr
, int ndr_flags
, const struct srvsvc_NetSessCtr0
*r
)
2515 uint32_t cntr_array_1
;
2516 if (ndr_flags
& NDR_SCALARS
) {
2517 NDR_CHECK(ndr_push_align(ndr
, 4));
2518 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->count
));
2519 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->array
));
2521 if (ndr_flags
& NDR_BUFFERS
) {
2523 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->count
));
2524 for (cntr_array_1
= 0; cntr_array_1
< r
->count
; cntr_array_1
++) {
2525 NDR_CHECK(ndr_push_srvsvc_NetSessInfo0(ndr
, NDR_SCALARS
, &r
->array
[cntr_array_1
]));
2527 for (cntr_array_1
= 0; cntr_array_1
< r
->count
; cntr_array_1
++) {
2528 NDR_CHECK(ndr_push_srvsvc_NetSessInfo0(ndr
, NDR_BUFFERS
, &r
->array
[cntr_array_1
]));
2532 return NDR_ERR_SUCCESS
;
2535 static enum ndr_err_code
ndr_pull_srvsvc_NetSessCtr0(struct ndr_pull
*ndr
, int ndr_flags
, struct srvsvc_NetSessCtr0
*r
)
2537 uint32_t _ptr_array
;
2538 uint32_t size_array_1
= 0;
2539 uint32_t cntr_array_1
;
2540 TALLOC_CTX
*_mem_save_array_0
;
2541 TALLOC_CTX
*_mem_save_array_1
;
2542 if (ndr_flags
& NDR_SCALARS
) {
2543 NDR_CHECK(ndr_pull_align(ndr
, 4));
2544 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->count
));
2545 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_array
));
2547 NDR_PULL_ALLOC(ndr
, r
->array
);
2552 if (ndr_flags
& NDR_BUFFERS
) {
2554 _mem_save_array_0
= NDR_PULL_GET_MEM_CTX(ndr
);
2555 NDR_PULL_SET_MEM_CTX(ndr
, r
->array
, 0);
2556 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->array
));
2557 size_array_1
= ndr_get_array_size(ndr
, &r
->array
);
2558 NDR_PULL_ALLOC_N(ndr
, r
->array
, size_array_1
);
2559 _mem_save_array_1
= NDR_PULL_GET_MEM_CTX(ndr
);
2560 NDR_PULL_SET_MEM_CTX(ndr
, r
->array
, 0);
2561 for (cntr_array_1
= 0; cntr_array_1
< size_array_1
; cntr_array_1
++) {
2562 NDR_CHECK(ndr_pull_srvsvc_NetSessInfo0(ndr
, NDR_SCALARS
, &r
->array
[cntr_array_1
]));
2564 for (cntr_array_1
= 0; cntr_array_1
< size_array_1
; cntr_array_1
++) {
2565 NDR_CHECK(ndr_pull_srvsvc_NetSessInfo0(ndr
, NDR_BUFFERS
, &r
->array
[cntr_array_1
]));
2567 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_array_1
, 0);
2568 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_array_0
, 0);
2571 NDR_CHECK(ndr_check_array_size(ndr
, (void*)&r
->array
, r
->count
));
2574 return NDR_ERR_SUCCESS
;
2577 _PUBLIC_
void ndr_print_srvsvc_NetSessCtr0(struct ndr_print
*ndr
, const char *name
, const struct srvsvc_NetSessCtr0
*r
)
2579 uint32_t cntr_array_1
;
2580 ndr_print_struct(ndr
, name
, "srvsvc_NetSessCtr0");
2582 ndr_print_uint32(ndr
, "count", r
->count
);
2583 ndr_print_ptr(ndr
, "array", r
->array
);
2586 ndr
->print(ndr
, "%s: ARRAY(%d)", "array", (int)r
->count
);
2588 for (cntr_array_1
=0;cntr_array_1
<r
->count
;cntr_array_1
++) {
2590 if (asprintf(&idx_1
, "[%d]", cntr_array_1
) != -1) {
2591 ndr_print_srvsvc_NetSessInfo0(ndr
, "array", &r
->array
[cntr_array_1
]);
2601 static enum ndr_err_code
ndr_push_srvsvc_NetSessInfo1(struct ndr_push
*ndr
, int ndr_flags
, const struct srvsvc_NetSessInfo1
*r
)
2603 if (ndr_flags
& NDR_SCALARS
) {
2604 NDR_CHECK(ndr_push_align(ndr
, 4));
2605 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->client
));
2606 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->user
));
2607 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->num_open
));
2608 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->time
));
2609 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->idle_time
));
2610 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->user_flags
));
2612 if (ndr_flags
& NDR_BUFFERS
) {
2614 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->client
, CH_UTF16
)));
2615 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
2616 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->client
, CH_UTF16
)));
2617 NDR_CHECK(ndr_push_charset(ndr
, NDR_SCALARS
, r
->client
, ndr_charset_length(r
->client
, CH_UTF16
), sizeof(uint16_t), CH_UTF16
));
2620 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->user
, CH_UTF16
)));
2621 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
2622 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->user
, CH_UTF16
)));
2623 NDR_CHECK(ndr_push_charset(ndr
, NDR_SCALARS
, r
->user
, ndr_charset_length(r
->user
, CH_UTF16
), sizeof(uint16_t), CH_UTF16
));
2626 return NDR_ERR_SUCCESS
;
2629 static enum ndr_err_code
ndr_pull_srvsvc_NetSessInfo1(struct ndr_pull
*ndr
, int ndr_flags
, struct srvsvc_NetSessInfo1
*r
)
2631 uint32_t _ptr_client
;
2632 uint32_t size_client_1
= 0;
2633 uint32_t length_client_1
= 0;
2634 TALLOC_CTX
*_mem_save_client_0
;
2636 uint32_t size_user_1
= 0;
2637 uint32_t length_user_1
= 0;
2638 TALLOC_CTX
*_mem_save_user_0
;
2639 if (ndr_flags
& NDR_SCALARS
) {
2640 NDR_CHECK(ndr_pull_align(ndr
, 4));
2641 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_client
));
2643 NDR_PULL_ALLOC(ndr
, r
->client
);
2647 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_user
));
2649 NDR_PULL_ALLOC(ndr
, r
->user
);
2653 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->num_open
));
2654 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->time
));
2655 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->idle_time
));
2656 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->user_flags
));
2658 if (ndr_flags
& NDR_BUFFERS
) {
2660 _mem_save_client_0
= NDR_PULL_GET_MEM_CTX(ndr
);
2661 NDR_PULL_SET_MEM_CTX(ndr
, r
->client
, 0);
2662 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->client
));
2663 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->client
));
2664 size_client_1
= ndr_get_array_size(ndr
, &r
->client
);
2665 length_client_1
= ndr_get_array_length(ndr
, &r
->client
);
2666 if (length_client_1
> size_client_1
) {
2667 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", size_client_1
, length_client_1
);
2669 NDR_CHECK(ndr_check_string_terminator(ndr
, length_client_1
, sizeof(uint16_t)));
2670 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->client
, length_client_1
, sizeof(uint16_t), CH_UTF16
));
2671 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_client_0
, 0);
2674 _mem_save_user_0
= NDR_PULL_GET_MEM_CTX(ndr
);
2675 NDR_PULL_SET_MEM_CTX(ndr
, r
->user
, 0);
2676 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->user
));
2677 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->user
));
2678 size_user_1
= ndr_get_array_size(ndr
, &r
->user
);
2679 length_user_1
= ndr_get_array_length(ndr
, &r
->user
);
2680 if (length_user_1
> size_user_1
) {
2681 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", size_user_1
, length_user_1
);
2683 NDR_CHECK(ndr_check_string_terminator(ndr
, length_user_1
, sizeof(uint16_t)));
2684 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->user
, length_user_1
, sizeof(uint16_t), CH_UTF16
));
2685 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_user_0
, 0);
2688 return NDR_ERR_SUCCESS
;
2691 _PUBLIC_
void ndr_print_srvsvc_NetSessInfo1(struct ndr_print
*ndr
, const char *name
, const struct srvsvc_NetSessInfo1
*r
)
2693 ndr_print_struct(ndr
, name
, "srvsvc_NetSessInfo1");
2695 ndr_print_ptr(ndr
, "client", r
->client
);
2698 ndr_print_string(ndr
, "client", r
->client
);
2701 ndr_print_ptr(ndr
, "user", r
->user
);
2704 ndr_print_string(ndr
, "user", r
->user
);
2707 ndr_print_uint32(ndr
, "num_open", r
->num_open
);
2708 ndr_print_uint32(ndr
, "time", r
->time
);
2709 ndr_print_uint32(ndr
, "idle_time", r
->idle_time
);
2710 ndr_print_uint32(ndr
, "user_flags", r
->user_flags
);
2714 static enum ndr_err_code
ndr_push_srvsvc_NetSessCtr1(struct ndr_push
*ndr
, int ndr_flags
, const struct srvsvc_NetSessCtr1
*r
)
2716 uint32_t cntr_array_1
;
2717 if (ndr_flags
& NDR_SCALARS
) {
2718 NDR_CHECK(ndr_push_align(ndr
, 4));
2719 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->count
));
2720 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->array
));
2722 if (ndr_flags
& NDR_BUFFERS
) {
2724 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->count
));
2725 for (cntr_array_1
= 0; cntr_array_1
< r
->count
; cntr_array_1
++) {
2726 NDR_CHECK(ndr_push_srvsvc_NetSessInfo1(ndr
, NDR_SCALARS
, &r
->array
[cntr_array_1
]));
2728 for (cntr_array_1
= 0; cntr_array_1
< r
->count
; cntr_array_1
++) {
2729 NDR_CHECK(ndr_push_srvsvc_NetSessInfo1(ndr
, NDR_BUFFERS
, &r
->array
[cntr_array_1
]));
2733 return NDR_ERR_SUCCESS
;
2736 static enum ndr_err_code
ndr_pull_srvsvc_NetSessCtr1(struct ndr_pull
*ndr
, int ndr_flags
, struct srvsvc_NetSessCtr1
*r
)
2738 uint32_t _ptr_array
;
2739 uint32_t size_array_1
= 0;
2740 uint32_t cntr_array_1
;
2741 TALLOC_CTX
*_mem_save_array_0
;
2742 TALLOC_CTX
*_mem_save_array_1
;
2743 if (ndr_flags
& NDR_SCALARS
) {
2744 NDR_CHECK(ndr_pull_align(ndr
, 4));
2745 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->count
));
2746 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_array
));
2748 NDR_PULL_ALLOC(ndr
, r
->array
);
2753 if (ndr_flags
& NDR_BUFFERS
) {
2755 _mem_save_array_0
= NDR_PULL_GET_MEM_CTX(ndr
);
2756 NDR_PULL_SET_MEM_CTX(ndr
, r
->array
, 0);
2757 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->array
));
2758 size_array_1
= ndr_get_array_size(ndr
, &r
->array
);
2759 NDR_PULL_ALLOC_N(ndr
, r
->array
, size_array_1
);
2760 _mem_save_array_1
= NDR_PULL_GET_MEM_CTX(ndr
);
2761 NDR_PULL_SET_MEM_CTX(ndr
, r
->array
, 0);
2762 for (cntr_array_1
= 0; cntr_array_1
< size_array_1
; cntr_array_1
++) {
2763 NDR_CHECK(ndr_pull_srvsvc_NetSessInfo1(ndr
, NDR_SCALARS
, &r
->array
[cntr_array_1
]));
2765 for (cntr_array_1
= 0; cntr_array_1
< size_array_1
; cntr_array_1
++) {
2766 NDR_CHECK(ndr_pull_srvsvc_NetSessInfo1(ndr
, NDR_BUFFERS
, &r
->array
[cntr_array_1
]));
2768 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_array_1
, 0);
2769 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_array_0
, 0);
2772 NDR_CHECK(ndr_check_array_size(ndr
, (void*)&r
->array
, r
->count
));
2775 return NDR_ERR_SUCCESS
;
2778 _PUBLIC_
void ndr_print_srvsvc_NetSessCtr1(struct ndr_print
*ndr
, const char *name
, const struct srvsvc_NetSessCtr1
*r
)
2780 uint32_t cntr_array_1
;
2781 ndr_print_struct(ndr
, name
, "srvsvc_NetSessCtr1");
2783 ndr_print_uint32(ndr
, "count", r
->count
);
2784 ndr_print_ptr(ndr
, "array", r
->array
);
2787 ndr
->print(ndr
, "%s: ARRAY(%d)", "array", (int)r
->count
);
2789 for (cntr_array_1
=0;cntr_array_1
<r
->count
;cntr_array_1
++) {
2791 if (asprintf(&idx_1
, "[%d]", cntr_array_1
) != -1) {
2792 ndr_print_srvsvc_NetSessInfo1(ndr
, "array", &r
->array
[cntr_array_1
]);
2802 static enum ndr_err_code
ndr_push_srvsvc_NetSessInfo2(struct ndr_push
*ndr
, int ndr_flags
, const struct srvsvc_NetSessInfo2
*r
)
2804 if (ndr_flags
& NDR_SCALARS
) {
2805 NDR_CHECK(ndr_push_align(ndr
, 4));
2806 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->client
));
2807 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->user
));
2808 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->num_open
));
2809 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->time
));
2810 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->idle_time
));
2811 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->user_flags
));
2812 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->client_type
));
2814 if (ndr_flags
& NDR_BUFFERS
) {
2816 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->client
, CH_UTF16
)));
2817 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
2818 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->client
, CH_UTF16
)));
2819 NDR_CHECK(ndr_push_charset(ndr
, NDR_SCALARS
, r
->client
, ndr_charset_length(r
->client
, CH_UTF16
), sizeof(uint16_t), CH_UTF16
));
2822 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->user
, CH_UTF16
)));
2823 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
2824 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->user
, CH_UTF16
)));
2825 NDR_CHECK(ndr_push_charset(ndr
, NDR_SCALARS
, r
->user
, ndr_charset_length(r
->user
, CH_UTF16
), sizeof(uint16_t), CH_UTF16
));
2827 if (r
->client_type
) {
2828 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->client_type
, CH_UTF16
)));
2829 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
2830 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->client_type
, CH_UTF16
)));
2831 NDR_CHECK(ndr_push_charset(ndr
, NDR_SCALARS
, r
->client_type
, ndr_charset_length(r
->client_type
, CH_UTF16
), sizeof(uint16_t), CH_UTF16
));
2834 return NDR_ERR_SUCCESS
;
2837 static enum ndr_err_code
ndr_pull_srvsvc_NetSessInfo2(struct ndr_pull
*ndr
, int ndr_flags
, struct srvsvc_NetSessInfo2
*r
)
2839 uint32_t _ptr_client
;
2840 uint32_t size_client_1
= 0;
2841 uint32_t length_client_1
= 0;
2842 TALLOC_CTX
*_mem_save_client_0
;
2844 uint32_t size_user_1
= 0;
2845 uint32_t length_user_1
= 0;
2846 TALLOC_CTX
*_mem_save_user_0
;
2847 uint32_t _ptr_client_type
;
2848 uint32_t size_client_type_1
= 0;
2849 uint32_t length_client_type_1
= 0;
2850 TALLOC_CTX
*_mem_save_client_type_0
;
2851 if (ndr_flags
& NDR_SCALARS
) {
2852 NDR_CHECK(ndr_pull_align(ndr
, 4));
2853 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_client
));
2855 NDR_PULL_ALLOC(ndr
, r
->client
);
2859 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_user
));
2861 NDR_PULL_ALLOC(ndr
, r
->user
);
2865 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->num_open
));
2866 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->time
));
2867 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->idle_time
));
2868 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->user_flags
));
2869 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_client_type
));
2870 if (_ptr_client_type
) {
2871 NDR_PULL_ALLOC(ndr
, r
->client_type
);
2873 r
->client_type
= NULL
;
2876 if (ndr_flags
& NDR_BUFFERS
) {
2878 _mem_save_client_0
= NDR_PULL_GET_MEM_CTX(ndr
);
2879 NDR_PULL_SET_MEM_CTX(ndr
, r
->client
, 0);
2880 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->client
));
2881 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->client
));
2882 size_client_1
= ndr_get_array_size(ndr
, &r
->client
);
2883 length_client_1
= ndr_get_array_length(ndr
, &r
->client
);
2884 if (length_client_1
> size_client_1
) {
2885 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", size_client_1
, length_client_1
);
2887 NDR_CHECK(ndr_check_string_terminator(ndr
, length_client_1
, sizeof(uint16_t)));
2888 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->client
, length_client_1
, sizeof(uint16_t), CH_UTF16
));
2889 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_client_0
, 0);
2892 _mem_save_user_0
= NDR_PULL_GET_MEM_CTX(ndr
);
2893 NDR_PULL_SET_MEM_CTX(ndr
, r
->user
, 0);
2894 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->user
));
2895 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->user
));
2896 size_user_1
= ndr_get_array_size(ndr
, &r
->user
);
2897 length_user_1
= ndr_get_array_length(ndr
, &r
->user
);
2898 if (length_user_1
> size_user_1
) {
2899 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", size_user_1
, length_user_1
);
2901 NDR_CHECK(ndr_check_string_terminator(ndr
, length_user_1
, sizeof(uint16_t)));
2902 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->user
, length_user_1
, sizeof(uint16_t), CH_UTF16
));
2903 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_user_0
, 0);
2905 if (r
->client_type
) {
2906 _mem_save_client_type_0
= NDR_PULL_GET_MEM_CTX(ndr
);
2907 NDR_PULL_SET_MEM_CTX(ndr
, r
->client_type
, 0);
2908 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->client_type
));
2909 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->client_type
));
2910 size_client_type_1
= ndr_get_array_size(ndr
, &r
->client_type
);
2911 length_client_type_1
= ndr_get_array_length(ndr
, &r
->client_type
);
2912 if (length_client_type_1
> size_client_type_1
) {
2913 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", size_client_type_1
, length_client_type_1
);
2915 NDR_CHECK(ndr_check_string_terminator(ndr
, length_client_type_1
, sizeof(uint16_t)));
2916 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->client_type
, length_client_type_1
, sizeof(uint16_t), CH_UTF16
));
2917 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_client_type_0
, 0);
2920 return NDR_ERR_SUCCESS
;
2923 _PUBLIC_
void ndr_print_srvsvc_NetSessInfo2(struct ndr_print
*ndr
, const char *name
, const struct srvsvc_NetSessInfo2
*r
)
2925 ndr_print_struct(ndr
, name
, "srvsvc_NetSessInfo2");
2927 ndr_print_ptr(ndr
, "client", r
->client
);
2930 ndr_print_string(ndr
, "client", r
->client
);
2933 ndr_print_ptr(ndr
, "user", r
->user
);
2936 ndr_print_string(ndr
, "user", r
->user
);
2939 ndr_print_uint32(ndr
, "num_open", r
->num_open
);
2940 ndr_print_uint32(ndr
, "time", r
->time
);
2941 ndr_print_uint32(ndr
, "idle_time", r
->idle_time
);
2942 ndr_print_uint32(ndr
, "user_flags", r
->user_flags
);
2943 ndr_print_ptr(ndr
, "client_type", r
->client_type
);
2945 if (r
->client_type
) {
2946 ndr_print_string(ndr
, "client_type", r
->client_type
);
2952 static enum ndr_err_code
ndr_push_srvsvc_NetSessCtr2(struct ndr_push
*ndr
, int ndr_flags
, const struct srvsvc_NetSessCtr2
*r
)
2954 uint32_t cntr_array_1
;
2955 if (ndr_flags
& NDR_SCALARS
) {
2956 NDR_CHECK(ndr_push_align(ndr
, 4));
2957 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->count
));
2958 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->array
));
2960 if (ndr_flags
& NDR_BUFFERS
) {
2962 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->count
));
2963 for (cntr_array_1
= 0; cntr_array_1
< r
->count
; cntr_array_1
++) {
2964 NDR_CHECK(ndr_push_srvsvc_NetSessInfo2(ndr
, NDR_SCALARS
, &r
->array
[cntr_array_1
]));
2966 for (cntr_array_1
= 0; cntr_array_1
< r
->count
; cntr_array_1
++) {
2967 NDR_CHECK(ndr_push_srvsvc_NetSessInfo2(ndr
, NDR_BUFFERS
, &r
->array
[cntr_array_1
]));
2971 return NDR_ERR_SUCCESS
;
2974 static enum ndr_err_code
ndr_pull_srvsvc_NetSessCtr2(struct ndr_pull
*ndr
, int ndr_flags
, struct srvsvc_NetSessCtr2
*r
)
2976 uint32_t _ptr_array
;
2977 uint32_t size_array_1
= 0;
2978 uint32_t cntr_array_1
;
2979 TALLOC_CTX
*_mem_save_array_0
;
2980 TALLOC_CTX
*_mem_save_array_1
;
2981 if (ndr_flags
& NDR_SCALARS
) {
2982 NDR_CHECK(ndr_pull_align(ndr
, 4));
2983 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->count
));
2984 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_array
));
2986 NDR_PULL_ALLOC(ndr
, r
->array
);
2991 if (ndr_flags
& NDR_BUFFERS
) {
2993 _mem_save_array_0
= NDR_PULL_GET_MEM_CTX(ndr
);
2994 NDR_PULL_SET_MEM_CTX(ndr
, r
->array
, 0);
2995 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->array
));
2996 size_array_1
= ndr_get_array_size(ndr
, &r
->array
);
2997 NDR_PULL_ALLOC_N(ndr
, r
->array
, size_array_1
);
2998 _mem_save_array_1
= NDR_PULL_GET_MEM_CTX(ndr
);
2999 NDR_PULL_SET_MEM_CTX(ndr
, r
->array
, 0);
3000 for (cntr_array_1
= 0; cntr_array_1
< size_array_1
; cntr_array_1
++) {
3001 NDR_CHECK(ndr_pull_srvsvc_NetSessInfo2(ndr
, NDR_SCALARS
, &r
->array
[cntr_array_1
]));
3003 for (cntr_array_1
= 0; cntr_array_1
< size_array_1
; cntr_array_1
++) {
3004 NDR_CHECK(ndr_pull_srvsvc_NetSessInfo2(ndr
, NDR_BUFFERS
, &r
->array
[cntr_array_1
]));
3006 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_array_1
, 0);
3007 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_array_0
, 0);
3010 NDR_CHECK(ndr_check_array_size(ndr
, (void*)&r
->array
, r
->count
));
3013 return NDR_ERR_SUCCESS
;
3016 _PUBLIC_
void ndr_print_srvsvc_NetSessCtr2(struct ndr_print
*ndr
, const char *name
, const struct srvsvc_NetSessCtr2
*r
)
3018 uint32_t cntr_array_1
;
3019 ndr_print_struct(ndr
, name
, "srvsvc_NetSessCtr2");
3021 ndr_print_uint32(ndr
, "count", r
->count
);
3022 ndr_print_ptr(ndr
, "array", r
->array
);
3025 ndr
->print(ndr
, "%s: ARRAY(%d)", "array", (int)r
->count
);
3027 for (cntr_array_1
=0;cntr_array_1
<r
->count
;cntr_array_1
++) {
3029 if (asprintf(&idx_1
, "[%d]", cntr_array_1
) != -1) {
3030 ndr_print_srvsvc_NetSessInfo2(ndr
, "array", &r
->array
[cntr_array_1
]);
3040 static enum ndr_err_code
ndr_push_srvsvc_NetSessInfo10(struct ndr_push
*ndr
, int ndr_flags
, const struct srvsvc_NetSessInfo10
*r
)
3042 if (ndr_flags
& NDR_SCALARS
) {
3043 NDR_CHECK(ndr_push_align(ndr
, 4));
3044 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->client
));
3045 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->user
));
3046 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->time
));
3047 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->idle_time
));
3049 if (ndr_flags
& NDR_BUFFERS
) {
3051 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->client
, CH_UTF16
)));
3052 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
3053 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->client
, CH_UTF16
)));
3054 NDR_CHECK(ndr_push_charset(ndr
, NDR_SCALARS
, r
->client
, ndr_charset_length(r
->client
, CH_UTF16
), sizeof(uint16_t), CH_UTF16
));
3057 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->user
, CH_UTF16
)));
3058 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
3059 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->user
, CH_UTF16
)));
3060 NDR_CHECK(ndr_push_charset(ndr
, NDR_SCALARS
, r
->user
, ndr_charset_length(r
->user
, CH_UTF16
), sizeof(uint16_t), CH_UTF16
));
3063 return NDR_ERR_SUCCESS
;
3066 static enum ndr_err_code
ndr_pull_srvsvc_NetSessInfo10(struct ndr_pull
*ndr
, int ndr_flags
, struct srvsvc_NetSessInfo10
*r
)
3068 uint32_t _ptr_client
;
3069 uint32_t size_client_1
= 0;
3070 uint32_t length_client_1
= 0;
3071 TALLOC_CTX
*_mem_save_client_0
;
3073 uint32_t size_user_1
= 0;
3074 uint32_t length_user_1
= 0;
3075 TALLOC_CTX
*_mem_save_user_0
;
3076 if (ndr_flags
& NDR_SCALARS
) {
3077 NDR_CHECK(ndr_pull_align(ndr
, 4));
3078 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_client
));
3080 NDR_PULL_ALLOC(ndr
, r
->client
);
3084 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_user
));
3086 NDR_PULL_ALLOC(ndr
, r
->user
);
3090 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->time
));
3091 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->idle_time
));
3093 if (ndr_flags
& NDR_BUFFERS
) {
3095 _mem_save_client_0
= NDR_PULL_GET_MEM_CTX(ndr
);
3096 NDR_PULL_SET_MEM_CTX(ndr
, r
->client
, 0);
3097 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->client
));
3098 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->client
));
3099 size_client_1
= ndr_get_array_size(ndr
, &r
->client
);
3100 length_client_1
= ndr_get_array_length(ndr
, &r
->client
);
3101 if (length_client_1
> size_client_1
) {
3102 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", size_client_1
, length_client_1
);
3104 NDR_CHECK(ndr_check_string_terminator(ndr
, length_client_1
, sizeof(uint16_t)));
3105 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->client
, length_client_1
, sizeof(uint16_t), CH_UTF16
));
3106 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_client_0
, 0);
3109 _mem_save_user_0
= NDR_PULL_GET_MEM_CTX(ndr
);
3110 NDR_PULL_SET_MEM_CTX(ndr
, r
->user
, 0);
3111 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->user
));
3112 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->user
));
3113 size_user_1
= ndr_get_array_size(ndr
, &r
->user
);
3114 length_user_1
= ndr_get_array_length(ndr
, &r
->user
);
3115 if (length_user_1
> size_user_1
) {
3116 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", size_user_1
, length_user_1
);
3118 NDR_CHECK(ndr_check_string_terminator(ndr
, length_user_1
, sizeof(uint16_t)));
3119 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->user
, length_user_1
, sizeof(uint16_t), CH_UTF16
));
3120 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_user_0
, 0);
3123 return NDR_ERR_SUCCESS
;
3126 _PUBLIC_
void ndr_print_srvsvc_NetSessInfo10(struct ndr_print
*ndr
, const char *name
, const struct srvsvc_NetSessInfo10
*r
)
3128 ndr_print_struct(ndr
, name
, "srvsvc_NetSessInfo10");
3130 ndr_print_ptr(ndr
, "client", r
->client
);
3133 ndr_print_string(ndr
, "client", r
->client
);
3136 ndr_print_ptr(ndr
, "user", r
->user
);
3139 ndr_print_string(ndr
, "user", r
->user
);
3142 ndr_print_uint32(ndr
, "time", r
->time
);
3143 ndr_print_uint32(ndr
, "idle_time", r
->idle_time
);
3147 static enum ndr_err_code
ndr_push_srvsvc_NetSessCtr10(struct ndr_push
*ndr
, int ndr_flags
, const struct srvsvc_NetSessCtr10
*r
)
3149 uint32_t cntr_array_1
;
3150 if (ndr_flags
& NDR_SCALARS
) {
3151 NDR_CHECK(ndr_push_align(ndr
, 4));
3152 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->count
));
3153 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->array
));
3155 if (ndr_flags
& NDR_BUFFERS
) {
3157 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->count
));
3158 for (cntr_array_1
= 0; cntr_array_1
< r
->count
; cntr_array_1
++) {
3159 NDR_CHECK(ndr_push_srvsvc_NetSessInfo10(ndr
, NDR_SCALARS
, &r
->array
[cntr_array_1
]));
3161 for (cntr_array_1
= 0; cntr_array_1
< r
->count
; cntr_array_1
++) {
3162 NDR_CHECK(ndr_push_srvsvc_NetSessInfo10(ndr
, NDR_BUFFERS
, &r
->array
[cntr_array_1
]));
3166 return NDR_ERR_SUCCESS
;
3169 static enum ndr_err_code
ndr_pull_srvsvc_NetSessCtr10(struct ndr_pull
*ndr
, int ndr_flags
, struct srvsvc_NetSessCtr10
*r
)
3171 uint32_t _ptr_array
;
3172 uint32_t size_array_1
= 0;
3173 uint32_t cntr_array_1
;
3174 TALLOC_CTX
*_mem_save_array_0
;
3175 TALLOC_CTX
*_mem_save_array_1
;
3176 if (ndr_flags
& NDR_SCALARS
) {
3177 NDR_CHECK(ndr_pull_align(ndr
, 4));
3178 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->count
));
3179 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_array
));
3181 NDR_PULL_ALLOC(ndr
, r
->array
);
3186 if (ndr_flags
& NDR_BUFFERS
) {
3188 _mem_save_array_0
= NDR_PULL_GET_MEM_CTX(ndr
);
3189 NDR_PULL_SET_MEM_CTX(ndr
, r
->array
, 0);
3190 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->array
));
3191 size_array_1
= ndr_get_array_size(ndr
, &r
->array
);
3192 NDR_PULL_ALLOC_N(ndr
, r
->array
, size_array_1
);
3193 _mem_save_array_1
= NDR_PULL_GET_MEM_CTX(ndr
);
3194 NDR_PULL_SET_MEM_CTX(ndr
, r
->array
, 0);
3195 for (cntr_array_1
= 0; cntr_array_1
< size_array_1
; cntr_array_1
++) {
3196 NDR_CHECK(ndr_pull_srvsvc_NetSessInfo10(ndr
, NDR_SCALARS
, &r
->array
[cntr_array_1
]));
3198 for (cntr_array_1
= 0; cntr_array_1
< size_array_1
; cntr_array_1
++) {
3199 NDR_CHECK(ndr_pull_srvsvc_NetSessInfo10(ndr
, NDR_BUFFERS
, &r
->array
[cntr_array_1
]));
3201 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_array_1
, 0);
3202 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_array_0
, 0);
3205 NDR_CHECK(ndr_check_array_size(ndr
, (void*)&r
->array
, r
->count
));
3208 return NDR_ERR_SUCCESS
;
3211 _PUBLIC_
void ndr_print_srvsvc_NetSessCtr10(struct ndr_print
*ndr
, const char *name
, const struct srvsvc_NetSessCtr10
*r
)
3213 uint32_t cntr_array_1
;
3214 ndr_print_struct(ndr
, name
, "srvsvc_NetSessCtr10");
3216 ndr_print_uint32(ndr
, "count", r
->count
);
3217 ndr_print_ptr(ndr
, "array", r
->array
);
3220 ndr
->print(ndr
, "%s: ARRAY(%d)", "array", (int)r
->count
);
3222 for (cntr_array_1
=0;cntr_array_1
<r
->count
;cntr_array_1
++) {
3224 if (asprintf(&idx_1
, "[%d]", cntr_array_1
) != -1) {
3225 ndr_print_srvsvc_NetSessInfo10(ndr
, "array", &r
->array
[cntr_array_1
]);
3235 static enum ndr_err_code
ndr_push_srvsvc_NetSessInfo502(struct ndr_push
*ndr
, int ndr_flags
, const struct srvsvc_NetSessInfo502
*r
)
3237 if (ndr_flags
& NDR_SCALARS
) {
3238 NDR_CHECK(ndr_push_align(ndr
, 4));
3239 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->client
));
3240 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->user
));
3241 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->num_open
));
3242 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->time
));
3243 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->idle_time
));
3244 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->user_flags
));
3245 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->client_type
));
3246 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->transport
));
3248 if (ndr_flags
& NDR_BUFFERS
) {
3250 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->client
, CH_UTF16
)));
3251 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
3252 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->client
, CH_UTF16
)));
3253 NDR_CHECK(ndr_push_charset(ndr
, NDR_SCALARS
, r
->client
, ndr_charset_length(r
->client
, CH_UTF16
), sizeof(uint16_t), CH_UTF16
));
3256 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->user
, CH_UTF16
)));
3257 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
3258 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->user
, CH_UTF16
)));
3259 NDR_CHECK(ndr_push_charset(ndr
, NDR_SCALARS
, r
->user
, ndr_charset_length(r
->user
, CH_UTF16
), sizeof(uint16_t), CH_UTF16
));
3261 if (r
->client_type
) {
3262 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->client_type
, CH_UTF16
)));
3263 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
3264 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->client_type
, CH_UTF16
)));
3265 NDR_CHECK(ndr_push_charset(ndr
, NDR_SCALARS
, r
->client_type
, ndr_charset_length(r
->client_type
, CH_UTF16
), sizeof(uint16_t), CH_UTF16
));
3268 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->transport
, CH_UTF16
)));
3269 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
3270 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->transport
, CH_UTF16
)));
3271 NDR_CHECK(ndr_push_charset(ndr
, NDR_SCALARS
, r
->transport
, ndr_charset_length(r
->transport
, CH_UTF16
), sizeof(uint16_t), CH_UTF16
));
3274 return NDR_ERR_SUCCESS
;
3277 static enum ndr_err_code
ndr_pull_srvsvc_NetSessInfo502(struct ndr_pull
*ndr
, int ndr_flags
, struct srvsvc_NetSessInfo502
*r
)
3279 uint32_t _ptr_client
;
3280 uint32_t size_client_1
= 0;
3281 uint32_t length_client_1
= 0;
3282 TALLOC_CTX
*_mem_save_client_0
;
3284 uint32_t size_user_1
= 0;
3285 uint32_t length_user_1
= 0;
3286 TALLOC_CTX
*_mem_save_user_0
;
3287 uint32_t _ptr_client_type
;
3288 uint32_t size_client_type_1
= 0;
3289 uint32_t length_client_type_1
= 0;
3290 TALLOC_CTX
*_mem_save_client_type_0
;
3291 uint32_t _ptr_transport
;
3292 uint32_t size_transport_1
= 0;
3293 uint32_t length_transport_1
= 0;
3294 TALLOC_CTX
*_mem_save_transport_0
;
3295 if (ndr_flags
& NDR_SCALARS
) {
3296 NDR_CHECK(ndr_pull_align(ndr
, 4));
3297 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_client
));
3299 NDR_PULL_ALLOC(ndr
, r
->client
);
3303 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_user
));
3305 NDR_PULL_ALLOC(ndr
, r
->user
);
3309 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->num_open
));
3310 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->time
));
3311 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->idle_time
));
3312 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->user_flags
));
3313 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_client_type
));
3314 if (_ptr_client_type
) {
3315 NDR_PULL_ALLOC(ndr
, r
->client_type
);
3317 r
->client_type
= NULL
;
3319 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_transport
));
3320 if (_ptr_transport
) {
3321 NDR_PULL_ALLOC(ndr
, r
->transport
);
3323 r
->transport
= NULL
;
3326 if (ndr_flags
& NDR_BUFFERS
) {
3328 _mem_save_client_0
= NDR_PULL_GET_MEM_CTX(ndr
);
3329 NDR_PULL_SET_MEM_CTX(ndr
, r
->client
, 0);
3330 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->client
));
3331 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->client
));
3332 size_client_1
= ndr_get_array_size(ndr
, &r
->client
);
3333 length_client_1
= ndr_get_array_length(ndr
, &r
->client
);
3334 if (length_client_1
> size_client_1
) {
3335 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", size_client_1
, length_client_1
);
3337 NDR_CHECK(ndr_check_string_terminator(ndr
, length_client_1
, sizeof(uint16_t)));
3338 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->client
, length_client_1
, sizeof(uint16_t), CH_UTF16
));
3339 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_client_0
, 0);
3342 _mem_save_user_0
= NDR_PULL_GET_MEM_CTX(ndr
);
3343 NDR_PULL_SET_MEM_CTX(ndr
, r
->user
, 0);
3344 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->user
));
3345 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->user
));
3346 size_user_1
= ndr_get_array_size(ndr
, &r
->user
);
3347 length_user_1
= ndr_get_array_length(ndr
, &r
->user
);
3348 if (length_user_1
> size_user_1
) {
3349 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", size_user_1
, length_user_1
);
3351 NDR_CHECK(ndr_check_string_terminator(ndr
, length_user_1
, sizeof(uint16_t)));
3352 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->user
, length_user_1
, sizeof(uint16_t), CH_UTF16
));
3353 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_user_0
, 0);
3355 if (r
->client_type
) {
3356 _mem_save_client_type_0
= NDR_PULL_GET_MEM_CTX(ndr
);
3357 NDR_PULL_SET_MEM_CTX(ndr
, r
->client_type
, 0);
3358 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->client_type
));
3359 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->client_type
));
3360 size_client_type_1
= ndr_get_array_size(ndr
, &r
->client_type
);
3361 length_client_type_1
= ndr_get_array_length(ndr
, &r
->client_type
);
3362 if (length_client_type_1
> size_client_type_1
) {
3363 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", size_client_type_1
, length_client_type_1
);
3365 NDR_CHECK(ndr_check_string_terminator(ndr
, length_client_type_1
, sizeof(uint16_t)));
3366 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->client_type
, length_client_type_1
, sizeof(uint16_t), CH_UTF16
));
3367 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_client_type_0
, 0);
3370 _mem_save_transport_0
= NDR_PULL_GET_MEM_CTX(ndr
);
3371 NDR_PULL_SET_MEM_CTX(ndr
, r
->transport
, 0);
3372 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->transport
));
3373 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->transport
));
3374 size_transport_1
= ndr_get_array_size(ndr
, &r
->transport
);
3375 length_transport_1
= ndr_get_array_length(ndr
, &r
->transport
);
3376 if (length_transport_1
> size_transport_1
) {
3377 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", size_transport_1
, length_transport_1
);
3379 NDR_CHECK(ndr_check_string_terminator(ndr
, length_transport_1
, sizeof(uint16_t)));
3380 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->transport
, length_transport_1
, sizeof(uint16_t), CH_UTF16
));
3381 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_transport_0
, 0);
3384 return NDR_ERR_SUCCESS
;
3387 _PUBLIC_
void ndr_print_srvsvc_NetSessInfo502(struct ndr_print
*ndr
, const char *name
, const struct srvsvc_NetSessInfo502
*r
)
3389 ndr_print_struct(ndr
, name
, "srvsvc_NetSessInfo502");
3391 ndr_print_ptr(ndr
, "client", r
->client
);
3394 ndr_print_string(ndr
, "client", r
->client
);
3397 ndr_print_ptr(ndr
, "user", r
->user
);
3400 ndr_print_string(ndr
, "user", r
->user
);
3403 ndr_print_uint32(ndr
, "num_open", r
->num_open
);
3404 ndr_print_uint32(ndr
, "time", r
->time
);
3405 ndr_print_uint32(ndr
, "idle_time", r
->idle_time
);
3406 ndr_print_uint32(ndr
, "user_flags", r
->user_flags
);
3407 ndr_print_ptr(ndr
, "client_type", r
->client_type
);
3409 if (r
->client_type
) {
3410 ndr_print_string(ndr
, "client_type", r
->client_type
);
3413 ndr_print_ptr(ndr
, "transport", r
->transport
);
3416 ndr_print_string(ndr
, "transport", r
->transport
);
3422 static enum ndr_err_code
ndr_push_srvsvc_NetSessCtr502(struct ndr_push
*ndr
, int ndr_flags
, const struct srvsvc_NetSessCtr502
*r
)
3424 uint32_t cntr_array_1
;
3425 if (ndr_flags
& NDR_SCALARS
) {
3426 NDR_CHECK(ndr_push_align(ndr
, 4));
3427 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->count
));
3428 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->array
));
3430 if (ndr_flags
& NDR_BUFFERS
) {
3432 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->count
));
3433 for (cntr_array_1
= 0; cntr_array_1
< r
->count
; cntr_array_1
++) {
3434 NDR_CHECK(ndr_push_srvsvc_NetSessInfo502(ndr
, NDR_SCALARS
, &r
->array
[cntr_array_1
]));
3436 for (cntr_array_1
= 0; cntr_array_1
< r
->count
; cntr_array_1
++) {
3437 NDR_CHECK(ndr_push_srvsvc_NetSessInfo502(ndr
, NDR_BUFFERS
, &r
->array
[cntr_array_1
]));
3441 return NDR_ERR_SUCCESS
;
3444 static enum ndr_err_code
ndr_pull_srvsvc_NetSessCtr502(struct ndr_pull
*ndr
, int ndr_flags
, struct srvsvc_NetSessCtr502
*r
)
3446 uint32_t _ptr_array
;
3447 uint32_t size_array_1
= 0;
3448 uint32_t cntr_array_1
;
3449 TALLOC_CTX
*_mem_save_array_0
;
3450 TALLOC_CTX
*_mem_save_array_1
;
3451 if (ndr_flags
& NDR_SCALARS
) {
3452 NDR_CHECK(ndr_pull_align(ndr
, 4));
3453 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->count
));
3454 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_array
));
3456 NDR_PULL_ALLOC(ndr
, r
->array
);
3461 if (ndr_flags
& NDR_BUFFERS
) {
3463 _mem_save_array_0
= NDR_PULL_GET_MEM_CTX(ndr
);
3464 NDR_PULL_SET_MEM_CTX(ndr
, r
->array
, 0);
3465 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->array
));
3466 size_array_1
= ndr_get_array_size(ndr
, &r
->array
);
3467 NDR_PULL_ALLOC_N(ndr
, r
->array
, size_array_1
);
3468 _mem_save_array_1
= NDR_PULL_GET_MEM_CTX(ndr
);
3469 NDR_PULL_SET_MEM_CTX(ndr
, r
->array
, 0);
3470 for (cntr_array_1
= 0; cntr_array_1
< size_array_1
; cntr_array_1
++) {
3471 NDR_CHECK(ndr_pull_srvsvc_NetSessInfo502(ndr
, NDR_SCALARS
, &r
->array
[cntr_array_1
]));
3473 for (cntr_array_1
= 0; cntr_array_1
< size_array_1
; cntr_array_1
++) {
3474 NDR_CHECK(ndr_pull_srvsvc_NetSessInfo502(ndr
, NDR_BUFFERS
, &r
->array
[cntr_array_1
]));
3476 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_array_1
, 0);
3477 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_array_0
, 0);
3480 NDR_CHECK(ndr_check_array_size(ndr
, (void*)&r
->array
, r
->count
));
3483 return NDR_ERR_SUCCESS
;
3486 _PUBLIC_
void ndr_print_srvsvc_NetSessCtr502(struct ndr_print
*ndr
, const char *name
, const struct srvsvc_NetSessCtr502
*r
)
3488 uint32_t cntr_array_1
;
3489 ndr_print_struct(ndr
, name
, "srvsvc_NetSessCtr502");
3491 ndr_print_uint32(ndr
, "count", r
->count
);
3492 ndr_print_ptr(ndr
, "array", r
->array
);
3495 ndr
->print(ndr
, "%s: ARRAY(%d)", "array", (int)r
->count
);
3497 for (cntr_array_1
=0;cntr_array_1
<r
->count
;cntr_array_1
++) {
3499 if (asprintf(&idx_1
, "[%d]", cntr_array_1
) != -1) {
3500 ndr_print_srvsvc_NetSessInfo502(ndr
, "array", &r
->array
[cntr_array_1
]);
3510 static enum ndr_err_code
ndr_push_srvsvc_NetSessCtr(struct ndr_push
*ndr
, int ndr_flags
, const union srvsvc_NetSessCtr
*r
)
3512 if (ndr_flags
& NDR_SCALARS
) {
3513 int level
= ndr_push_get_switch_value(ndr
, r
);
3514 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, level
));
3517 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->ctr0
));
3521 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->ctr1
));
3525 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->ctr2
));
3529 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->ctr10
));
3533 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->ctr502
));
3541 if (ndr_flags
& NDR_BUFFERS
) {
3542 int level
= ndr_push_get_switch_value(ndr
, r
);
3546 NDR_CHECK(ndr_push_srvsvc_NetSessCtr0(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->ctr0
));
3552 NDR_CHECK(ndr_push_srvsvc_NetSessCtr1(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->ctr1
));
3558 NDR_CHECK(ndr_push_srvsvc_NetSessCtr2(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->ctr2
));
3564 NDR_CHECK(ndr_push_srvsvc_NetSessCtr10(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->ctr10
));
3570 NDR_CHECK(ndr_push_srvsvc_NetSessCtr502(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->ctr502
));
3579 return NDR_ERR_SUCCESS
;
3582 static enum ndr_err_code
ndr_pull_srvsvc_NetSessCtr(struct ndr_pull
*ndr
, int ndr_flags
, union srvsvc_NetSessCtr
*r
)
3586 TALLOC_CTX
*_mem_save_ctr0_0
;
3588 TALLOC_CTX
*_mem_save_ctr1_0
;
3590 TALLOC_CTX
*_mem_save_ctr2_0
;
3592 TALLOC_CTX
*_mem_save_ctr10_0
;
3593 uint32_t _ptr_ctr10
;
3594 TALLOC_CTX
*_mem_save_ctr502_0
;
3595 uint32_t _ptr_ctr502
;
3596 level
= ndr_pull_get_switch_value(ndr
, r
);
3597 if (ndr_flags
& NDR_SCALARS
) {
3598 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &_level
));
3599 if (_level
!= level
) {
3600 return ndr_pull_error(ndr
, NDR_ERR_BAD_SWITCH
, "Bad switch value %u for r", _level
);
3604 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_ctr0
));
3606 NDR_PULL_ALLOC(ndr
, r
->ctr0
);
3613 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_ctr1
));
3615 NDR_PULL_ALLOC(ndr
, r
->ctr1
);
3622 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_ctr2
));
3624 NDR_PULL_ALLOC(ndr
, r
->ctr2
);
3631 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_ctr10
));
3633 NDR_PULL_ALLOC(ndr
, r
->ctr10
);
3640 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_ctr502
));
3642 NDR_PULL_ALLOC(ndr
, r
->ctr502
);
3653 if (ndr_flags
& NDR_BUFFERS
) {
3657 _mem_save_ctr0_0
= NDR_PULL_GET_MEM_CTX(ndr
);
3658 NDR_PULL_SET_MEM_CTX(ndr
, r
->ctr0
, 0);
3659 NDR_CHECK(ndr_pull_srvsvc_NetSessCtr0(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->ctr0
));
3660 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_ctr0_0
, 0);
3666 _mem_save_ctr1_0
= NDR_PULL_GET_MEM_CTX(ndr
);
3667 NDR_PULL_SET_MEM_CTX(ndr
, r
->ctr1
, 0);
3668 NDR_CHECK(ndr_pull_srvsvc_NetSessCtr1(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->ctr1
));
3669 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_ctr1_0
, 0);
3675 _mem_save_ctr2_0
= NDR_PULL_GET_MEM_CTX(ndr
);
3676 NDR_PULL_SET_MEM_CTX(ndr
, r
->ctr2
, 0);
3677 NDR_CHECK(ndr_pull_srvsvc_NetSessCtr2(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->ctr2
));
3678 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_ctr2_0
, 0);
3684 _mem_save_ctr10_0
= NDR_PULL_GET_MEM_CTX(ndr
);
3685 NDR_PULL_SET_MEM_CTX(ndr
, r
->ctr10
, 0);
3686 NDR_CHECK(ndr_pull_srvsvc_NetSessCtr10(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->ctr10
));
3687 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_ctr10_0
, 0);
3693 _mem_save_ctr502_0
= NDR_PULL_GET_MEM_CTX(ndr
);
3694 NDR_PULL_SET_MEM_CTX(ndr
, r
->ctr502
, 0);
3695 NDR_CHECK(ndr_pull_srvsvc_NetSessCtr502(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->ctr502
));
3696 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_ctr502_0
, 0);
3705 return NDR_ERR_SUCCESS
;
3708 _PUBLIC_
void ndr_print_srvsvc_NetSessCtr(struct ndr_print
*ndr
, const char *name
, const union srvsvc_NetSessCtr
*r
)
3711 level
= ndr_print_get_switch_value(ndr
, r
);
3712 ndr_print_union(ndr
, name
, level
, "srvsvc_NetSessCtr");
3715 ndr_print_ptr(ndr
, "ctr0", r
->ctr0
);
3718 ndr_print_srvsvc_NetSessCtr0(ndr
, "ctr0", r
->ctr0
);
3724 ndr_print_ptr(ndr
, "ctr1", r
->ctr1
);
3727 ndr_print_srvsvc_NetSessCtr1(ndr
, "ctr1", r
->ctr1
);
3733 ndr_print_ptr(ndr
, "ctr2", r
->ctr2
);
3736 ndr_print_srvsvc_NetSessCtr2(ndr
, "ctr2", r
->ctr2
);
3742 ndr_print_ptr(ndr
, "ctr10", r
->ctr10
);
3745 ndr_print_srvsvc_NetSessCtr10(ndr
, "ctr10", r
->ctr10
);
3751 ndr_print_ptr(ndr
, "ctr502", r
->ctr502
);
3754 ndr_print_srvsvc_NetSessCtr502(ndr
, "ctr502", r
->ctr502
);
3765 static enum ndr_err_code
ndr_push_srvsvc_NetSessInfoCtr(struct ndr_push
*ndr
, int ndr_flags
, const struct srvsvc_NetSessInfoCtr
*r
)
3767 if (ndr_flags
& NDR_SCALARS
) {
3768 NDR_CHECK(ndr_push_align(ndr
, 4));
3769 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->level
));
3770 NDR_CHECK(ndr_push_set_switch_value(ndr
, &r
->ctr
, r
->level
));
3771 NDR_CHECK(ndr_push_srvsvc_NetSessCtr(ndr
, NDR_SCALARS
, &r
->ctr
));
3773 if (ndr_flags
& NDR_BUFFERS
) {
3774 NDR_CHECK(ndr_push_srvsvc_NetSessCtr(ndr
, NDR_BUFFERS
, &r
->ctr
));
3776 return NDR_ERR_SUCCESS
;
3779 static enum ndr_err_code
ndr_pull_srvsvc_NetSessInfoCtr(struct ndr_pull
*ndr
, int ndr_flags
, struct srvsvc_NetSessInfoCtr
*r
)
3781 if (ndr_flags
& NDR_SCALARS
) {
3782 NDR_CHECK(ndr_pull_align(ndr
, 4));
3783 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->level
));
3784 NDR_CHECK(ndr_pull_set_switch_value(ndr
, &r
->ctr
, r
->level
));
3785 NDR_CHECK(ndr_pull_srvsvc_NetSessCtr(ndr
, NDR_SCALARS
, &r
->ctr
));
3787 if (ndr_flags
& NDR_BUFFERS
) {
3788 NDR_CHECK(ndr_pull_srvsvc_NetSessCtr(ndr
, NDR_BUFFERS
, &r
->ctr
));
3790 return NDR_ERR_SUCCESS
;
3793 _PUBLIC_
void ndr_print_srvsvc_NetSessInfoCtr(struct ndr_print
*ndr
, const char *name
, const struct srvsvc_NetSessInfoCtr
*r
)
3795 ndr_print_struct(ndr
, name
, "srvsvc_NetSessInfoCtr");
3797 ndr_print_uint32(ndr
, "level", r
->level
);
3798 ndr_print_set_switch_value(ndr
, &r
->ctr
, r
->level
);
3799 ndr_print_srvsvc_NetSessCtr(ndr
, "ctr", &r
->ctr
);
3803 static enum ndr_err_code
ndr_push_srvsvc_ShareType(struct ndr_push
*ndr
, int ndr_flags
, enum srvsvc_ShareType r
)
3806 uint32_t _flags_save_ENUM
= ndr
->flags
;
3807 ndr_set_flags(&ndr
->flags
, LIBNDR_PRINT_ARRAY_HEX
);
3808 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
));
3809 ndr
->flags
= _flags_save_ENUM
;
3811 return NDR_ERR_SUCCESS
;
3814 static enum ndr_err_code
ndr_pull_srvsvc_ShareType(struct ndr_pull
*ndr
, int ndr_flags
, enum srvsvc_ShareType
*r
)
3818 uint32_t _flags_save_ENUM
= ndr
->flags
;
3819 ndr_set_flags(&ndr
->flags
, LIBNDR_PRINT_ARRAY_HEX
);
3820 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &v
));
3822 ndr
->flags
= _flags_save_ENUM
;
3824 return NDR_ERR_SUCCESS
;
3827 _PUBLIC_
void ndr_print_srvsvc_ShareType(struct ndr_print
*ndr
, const char *name
, enum srvsvc_ShareType r
)
3829 const char *val
= NULL
;
3832 uint32_t _flags_save_ENUM
= ndr
->flags
;
3833 ndr_set_flags(&ndr
->flags
, LIBNDR_PRINT_ARRAY_HEX
);
3835 case STYPE_DISKTREE
: val
= "STYPE_DISKTREE"; break;
3836 case STYPE_DISKTREE_TEMPORARY
: val
= "STYPE_DISKTREE_TEMPORARY"; break;
3837 case STYPE_DISKTREE_HIDDEN
: val
= "STYPE_DISKTREE_HIDDEN"; break;
3838 case STYPE_PRINTQ
: val
= "STYPE_PRINTQ"; break;
3839 case STYPE_PRINTQ_TEMPORARY
: val
= "STYPE_PRINTQ_TEMPORARY"; break;
3840 case STYPE_PRINTQ_HIDDEN
: val
= "STYPE_PRINTQ_HIDDEN"; break;
3841 case STYPE_DEVICE
: val
= "STYPE_DEVICE"; break;
3842 case STYPE_DEVICE_TEMPORARY
: val
= "STYPE_DEVICE_TEMPORARY"; break;
3843 case STYPE_DEVICE_HIDDEN
: val
= "STYPE_DEVICE_HIDDEN"; break;
3844 case STYPE_IPC
: val
= "STYPE_IPC"; break;
3845 case STYPE_IPC_TEMPORARY
: val
= "STYPE_IPC_TEMPORARY"; break;
3846 case STYPE_IPC_HIDDEN
: val
= "STYPE_IPC_HIDDEN"; break;
3848 ndr_print_enum(ndr
, name
, "ENUM", val
, r
);
3849 ndr
->flags
= _flags_save_ENUM
;
3853 static enum ndr_err_code
ndr_push_srvsvc_NetShareInfo0(struct ndr_push
*ndr
, int ndr_flags
, const struct srvsvc_NetShareInfo0
*r
)
3855 if (ndr_flags
& NDR_SCALARS
) {
3856 NDR_CHECK(ndr_push_align(ndr
, 4));
3857 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->name
));
3859 if (ndr_flags
& NDR_BUFFERS
) {
3861 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->name
, CH_UTF16
)));
3862 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
3863 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->name
, CH_UTF16
)));
3864 NDR_CHECK(ndr_push_charset(ndr
, NDR_SCALARS
, r
->name
, ndr_charset_length(r
->name
, CH_UTF16
), sizeof(uint16_t), CH_UTF16
));
3867 return NDR_ERR_SUCCESS
;
3870 static enum ndr_err_code
ndr_pull_srvsvc_NetShareInfo0(struct ndr_pull
*ndr
, int ndr_flags
, struct srvsvc_NetShareInfo0
*r
)
3873 uint32_t size_name_1
= 0;
3874 uint32_t length_name_1
= 0;
3875 TALLOC_CTX
*_mem_save_name_0
;
3876 if (ndr_flags
& NDR_SCALARS
) {
3877 NDR_CHECK(ndr_pull_align(ndr
, 4));
3878 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_name
));
3880 NDR_PULL_ALLOC(ndr
, r
->name
);
3885 if (ndr_flags
& NDR_BUFFERS
) {
3887 _mem_save_name_0
= NDR_PULL_GET_MEM_CTX(ndr
);
3888 NDR_PULL_SET_MEM_CTX(ndr
, r
->name
, 0);
3889 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->name
));
3890 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->name
));
3891 size_name_1
= ndr_get_array_size(ndr
, &r
->name
);
3892 length_name_1
= ndr_get_array_length(ndr
, &r
->name
);
3893 if (length_name_1
> size_name_1
) {
3894 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", size_name_1
, length_name_1
);
3896 NDR_CHECK(ndr_check_string_terminator(ndr
, length_name_1
, sizeof(uint16_t)));
3897 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->name
, length_name_1
, sizeof(uint16_t), CH_UTF16
));
3898 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_name_0
, 0);
3901 return NDR_ERR_SUCCESS
;
3904 _PUBLIC_
void ndr_print_srvsvc_NetShareInfo0(struct ndr_print
*ndr
, const char *name
, const struct srvsvc_NetShareInfo0
*r
)
3906 ndr_print_struct(ndr
, name
, "srvsvc_NetShareInfo0");
3908 ndr_print_ptr(ndr
, "name", r
->name
);
3911 ndr_print_string(ndr
, "name", r
->name
);
3917 static enum ndr_err_code
ndr_push_srvsvc_NetShareCtr0(struct ndr_push
*ndr
, int ndr_flags
, const struct srvsvc_NetShareCtr0
*r
)
3919 uint32_t cntr_array_1
;
3920 if (ndr_flags
& NDR_SCALARS
) {
3921 NDR_CHECK(ndr_push_align(ndr
, 4));
3922 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->count
));
3923 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->array
));
3925 if (ndr_flags
& NDR_BUFFERS
) {
3927 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->count
));
3928 for (cntr_array_1
= 0; cntr_array_1
< r
->count
; cntr_array_1
++) {
3929 NDR_CHECK(ndr_push_srvsvc_NetShareInfo0(ndr
, NDR_SCALARS
, &r
->array
[cntr_array_1
]));
3931 for (cntr_array_1
= 0; cntr_array_1
< r
->count
; cntr_array_1
++) {
3932 NDR_CHECK(ndr_push_srvsvc_NetShareInfo0(ndr
, NDR_BUFFERS
, &r
->array
[cntr_array_1
]));
3936 return NDR_ERR_SUCCESS
;
3939 static enum ndr_err_code
ndr_pull_srvsvc_NetShareCtr0(struct ndr_pull
*ndr
, int ndr_flags
, struct srvsvc_NetShareCtr0
*r
)
3941 uint32_t _ptr_array
;
3942 uint32_t size_array_1
= 0;
3943 uint32_t cntr_array_1
;
3944 TALLOC_CTX
*_mem_save_array_0
;
3945 TALLOC_CTX
*_mem_save_array_1
;
3946 if (ndr_flags
& NDR_SCALARS
) {
3947 NDR_CHECK(ndr_pull_align(ndr
, 4));
3948 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->count
));
3949 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_array
));
3951 NDR_PULL_ALLOC(ndr
, r
->array
);
3956 if (ndr_flags
& NDR_BUFFERS
) {
3958 _mem_save_array_0
= NDR_PULL_GET_MEM_CTX(ndr
);
3959 NDR_PULL_SET_MEM_CTX(ndr
, r
->array
, 0);
3960 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->array
));
3961 size_array_1
= ndr_get_array_size(ndr
, &r
->array
);
3962 NDR_PULL_ALLOC_N(ndr
, r
->array
, size_array_1
);
3963 _mem_save_array_1
= NDR_PULL_GET_MEM_CTX(ndr
);
3964 NDR_PULL_SET_MEM_CTX(ndr
, r
->array
, 0);
3965 for (cntr_array_1
= 0; cntr_array_1
< size_array_1
; cntr_array_1
++) {
3966 NDR_CHECK(ndr_pull_srvsvc_NetShareInfo0(ndr
, NDR_SCALARS
, &r
->array
[cntr_array_1
]));
3968 for (cntr_array_1
= 0; cntr_array_1
< size_array_1
; cntr_array_1
++) {
3969 NDR_CHECK(ndr_pull_srvsvc_NetShareInfo0(ndr
, NDR_BUFFERS
, &r
->array
[cntr_array_1
]));
3971 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_array_1
, 0);
3972 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_array_0
, 0);
3975 NDR_CHECK(ndr_check_array_size(ndr
, (void*)&r
->array
, r
->count
));
3978 return NDR_ERR_SUCCESS
;
3981 _PUBLIC_
void ndr_print_srvsvc_NetShareCtr0(struct ndr_print
*ndr
, const char *name
, const struct srvsvc_NetShareCtr0
*r
)
3983 uint32_t cntr_array_1
;
3984 ndr_print_struct(ndr
, name
, "srvsvc_NetShareCtr0");
3986 ndr_print_uint32(ndr
, "count", r
->count
);
3987 ndr_print_ptr(ndr
, "array", r
->array
);
3990 ndr
->print(ndr
, "%s: ARRAY(%d)", "array", (int)r
->count
);
3992 for (cntr_array_1
=0;cntr_array_1
<r
->count
;cntr_array_1
++) {
3994 if (asprintf(&idx_1
, "[%d]", cntr_array_1
) != -1) {
3995 ndr_print_srvsvc_NetShareInfo0(ndr
, "array", &r
->array
[cntr_array_1
]);
4005 static enum ndr_err_code
ndr_push_srvsvc_NetShareInfo1(struct ndr_push
*ndr
, int ndr_flags
, const struct srvsvc_NetShareInfo1
*r
)
4007 if (ndr_flags
& NDR_SCALARS
) {
4008 NDR_CHECK(ndr_push_align(ndr
, 4));
4009 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->name
));
4010 NDR_CHECK(ndr_push_srvsvc_ShareType(ndr
, NDR_SCALARS
, r
->type
));
4011 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->comment
));
4013 if (ndr_flags
& NDR_BUFFERS
) {
4015 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->name
, CH_UTF16
)));
4016 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
4017 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->name
, CH_UTF16
)));
4018 NDR_CHECK(ndr_push_charset(ndr
, NDR_SCALARS
, r
->name
, ndr_charset_length(r
->name
, CH_UTF16
), sizeof(uint16_t), CH_UTF16
));
4021 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->comment
, CH_UTF16
)));
4022 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
4023 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->comment
, CH_UTF16
)));
4024 NDR_CHECK(ndr_push_charset(ndr
, NDR_SCALARS
, r
->comment
, ndr_charset_length(r
->comment
, CH_UTF16
), sizeof(uint16_t), CH_UTF16
));
4027 return NDR_ERR_SUCCESS
;
4030 static enum ndr_err_code
ndr_pull_srvsvc_NetShareInfo1(struct ndr_pull
*ndr
, int ndr_flags
, struct srvsvc_NetShareInfo1
*r
)
4033 uint32_t size_name_1
= 0;
4034 uint32_t length_name_1
= 0;
4035 TALLOC_CTX
*_mem_save_name_0
;
4036 uint32_t _ptr_comment
;
4037 uint32_t size_comment_1
= 0;
4038 uint32_t length_comment_1
= 0;
4039 TALLOC_CTX
*_mem_save_comment_0
;
4040 if (ndr_flags
& NDR_SCALARS
) {
4041 NDR_CHECK(ndr_pull_align(ndr
, 4));
4042 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_name
));
4044 NDR_PULL_ALLOC(ndr
, r
->name
);
4048 NDR_CHECK(ndr_pull_srvsvc_ShareType(ndr
, NDR_SCALARS
, &r
->type
));
4049 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_comment
));
4051 NDR_PULL_ALLOC(ndr
, r
->comment
);
4056 if (ndr_flags
& NDR_BUFFERS
) {
4058 _mem_save_name_0
= NDR_PULL_GET_MEM_CTX(ndr
);
4059 NDR_PULL_SET_MEM_CTX(ndr
, r
->name
, 0);
4060 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->name
));
4061 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->name
));
4062 size_name_1
= ndr_get_array_size(ndr
, &r
->name
);
4063 length_name_1
= ndr_get_array_length(ndr
, &r
->name
);
4064 if (length_name_1
> size_name_1
) {
4065 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", size_name_1
, length_name_1
);
4067 NDR_CHECK(ndr_check_string_terminator(ndr
, length_name_1
, sizeof(uint16_t)));
4068 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->name
, length_name_1
, sizeof(uint16_t), CH_UTF16
));
4069 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_name_0
, 0);
4072 _mem_save_comment_0
= NDR_PULL_GET_MEM_CTX(ndr
);
4073 NDR_PULL_SET_MEM_CTX(ndr
, r
->comment
, 0);
4074 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->comment
));
4075 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->comment
));
4076 size_comment_1
= ndr_get_array_size(ndr
, &r
->comment
);
4077 length_comment_1
= ndr_get_array_length(ndr
, &r
->comment
);
4078 if (length_comment_1
> size_comment_1
) {
4079 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", size_comment_1
, length_comment_1
);
4081 NDR_CHECK(ndr_check_string_terminator(ndr
, length_comment_1
, sizeof(uint16_t)));
4082 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->comment
, length_comment_1
, sizeof(uint16_t), CH_UTF16
));
4083 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_comment_0
, 0);
4086 return NDR_ERR_SUCCESS
;
4089 _PUBLIC_
void ndr_print_srvsvc_NetShareInfo1(struct ndr_print
*ndr
, const char *name
, const struct srvsvc_NetShareInfo1
*r
)
4091 ndr_print_struct(ndr
, name
, "srvsvc_NetShareInfo1");
4093 ndr_print_ptr(ndr
, "name", r
->name
);
4096 ndr_print_string(ndr
, "name", r
->name
);
4099 ndr_print_srvsvc_ShareType(ndr
, "type", r
->type
);
4100 ndr_print_ptr(ndr
, "comment", r
->comment
);
4103 ndr_print_string(ndr
, "comment", r
->comment
);
4109 static enum ndr_err_code
ndr_push_srvsvc_NetShareCtr1(struct ndr_push
*ndr
, int ndr_flags
, const struct srvsvc_NetShareCtr1
*r
)
4111 uint32_t cntr_array_1
;
4112 if (ndr_flags
& NDR_SCALARS
) {
4113 NDR_CHECK(ndr_push_align(ndr
, 4));
4114 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->count
));
4115 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->array
));
4117 if (ndr_flags
& NDR_BUFFERS
) {
4119 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->count
));
4120 for (cntr_array_1
= 0; cntr_array_1
< r
->count
; cntr_array_1
++) {
4121 NDR_CHECK(ndr_push_srvsvc_NetShareInfo1(ndr
, NDR_SCALARS
, &r
->array
[cntr_array_1
]));
4123 for (cntr_array_1
= 0; cntr_array_1
< r
->count
; cntr_array_1
++) {
4124 NDR_CHECK(ndr_push_srvsvc_NetShareInfo1(ndr
, NDR_BUFFERS
, &r
->array
[cntr_array_1
]));
4128 return NDR_ERR_SUCCESS
;
4131 static enum ndr_err_code
ndr_pull_srvsvc_NetShareCtr1(struct ndr_pull
*ndr
, int ndr_flags
, struct srvsvc_NetShareCtr1
*r
)
4133 uint32_t _ptr_array
;
4134 uint32_t size_array_1
= 0;
4135 uint32_t cntr_array_1
;
4136 TALLOC_CTX
*_mem_save_array_0
;
4137 TALLOC_CTX
*_mem_save_array_1
;
4138 if (ndr_flags
& NDR_SCALARS
) {
4139 NDR_CHECK(ndr_pull_align(ndr
, 4));
4140 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->count
));
4141 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_array
));
4143 NDR_PULL_ALLOC(ndr
, r
->array
);
4148 if (ndr_flags
& NDR_BUFFERS
) {
4150 _mem_save_array_0
= NDR_PULL_GET_MEM_CTX(ndr
);
4151 NDR_PULL_SET_MEM_CTX(ndr
, r
->array
, 0);
4152 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->array
));
4153 size_array_1
= ndr_get_array_size(ndr
, &r
->array
);
4154 NDR_PULL_ALLOC_N(ndr
, r
->array
, size_array_1
);
4155 _mem_save_array_1
= NDR_PULL_GET_MEM_CTX(ndr
);
4156 NDR_PULL_SET_MEM_CTX(ndr
, r
->array
, 0);
4157 for (cntr_array_1
= 0; cntr_array_1
< size_array_1
; cntr_array_1
++) {
4158 NDR_CHECK(ndr_pull_srvsvc_NetShareInfo1(ndr
, NDR_SCALARS
, &r
->array
[cntr_array_1
]));
4160 for (cntr_array_1
= 0; cntr_array_1
< size_array_1
; cntr_array_1
++) {
4161 NDR_CHECK(ndr_pull_srvsvc_NetShareInfo1(ndr
, NDR_BUFFERS
, &r
->array
[cntr_array_1
]));
4163 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_array_1
, 0);
4164 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_array_0
, 0);
4167 NDR_CHECK(ndr_check_array_size(ndr
, (void*)&r
->array
, r
->count
));
4170 return NDR_ERR_SUCCESS
;
4173 _PUBLIC_
void ndr_print_srvsvc_NetShareCtr1(struct ndr_print
*ndr
, const char *name
, const struct srvsvc_NetShareCtr1
*r
)
4175 uint32_t cntr_array_1
;
4176 ndr_print_struct(ndr
, name
, "srvsvc_NetShareCtr1");
4178 ndr_print_uint32(ndr
, "count", r
->count
);
4179 ndr_print_ptr(ndr
, "array", r
->array
);
4182 ndr
->print(ndr
, "%s: ARRAY(%d)", "array", (int)r
->count
);
4184 for (cntr_array_1
=0;cntr_array_1
<r
->count
;cntr_array_1
++) {
4186 if (asprintf(&idx_1
, "[%d]", cntr_array_1
) != -1) {
4187 ndr_print_srvsvc_NetShareInfo1(ndr
, "array", &r
->array
[cntr_array_1
]);
4197 static enum ndr_err_code
ndr_push_srvsvc_NetShareInfo2(struct ndr_push
*ndr
, int ndr_flags
, const struct srvsvc_NetShareInfo2
*r
)
4199 if (ndr_flags
& NDR_SCALARS
) {
4200 NDR_CHECK(ndr_push_align(ndr
, 4));
4201 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->name
));
4202 NDR_CHECK(ndr_push_srvsvc_ShareType(ndr
, NDR_SCALARS
, r
->type
));
4203 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->comment
));
4204 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->permissions
));
4205 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->max_users
));
4206 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->current_users
));
4207 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->path
));
4208 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->password
));
4210 if (ndr_flags
& NDR_BUFFERS
) {
4212 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->name
, CH_UTF16
)));
4213 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
4214 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->name
, CH_UTF16
)));
4215 NDR_CHECK(ndr_push_charset(ndr
, NDR_SCALARS
, r
->name
, ndr_charset_length(r
->name
, CH_UTF16
), sizeof(uint16_t), CH_UTF16
));
4218 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->comment
, CH_UTF16
)));
4219 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
4220 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->comment
, CH_UTF16
)));
4221 NDR_CHECK(ndr_push_charset(ndr
, NDR_SCALARS
, r
->comment
, ndr_charset_length(r
->comment
, CH_UTF16
), sizeof(uint16_t), CH_UTF16
));
4224 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->path
, CH_UTF16
)));
4225 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
4226 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->path
, CH_UTF16
)));
4227 NDR_CHECK(ndr_push_charset(ndr
, NDR_SCALARS
, r
->path
, ndr_charset_length(r
->path
, CH_UTF16
), sizeof(uint16_t), CH_UTF16
));
4230 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->password
, CH_UTF16
)));
4231 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
4232 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->password
, CH_UTF16
)));
4233 NDR_CHECK(ndr_push_charset(ndr
, NDR_SCALARS
, r
->password
, ndr_charset_length(r
->password
, CH_UTF16
), sizeof(uint16_t), CH_UTF16
));
4236 return NDR_ERR_SUCCESS
;
4239 static enum ndr_err_code
ndr_pull_srvsvc_NetShareInfo2(struct ndr_pull
*ndr
, int ndr_flags
, struct srvsvc_NetShareInfo2
*r
)
4242 uint32_t size_name_1
= 0;
4243 uint32_t length_name_1
= 0;
4244 TALLOC_CTX
*_mem_save_name_0
;
4245 uint32_t _ptr_comment
;
4246 uint32_t size_comment_1
= 0;
4247 uint32_t length_comment_1
= 0;
4248 TALLOC_CTX
*_mem_save_comment_0
;
4250 uint32_t size_path_1
= 0;
4251 uint32_t length_path_1
= 0;
4252 TALLOC_CTX
*_mem_save_path_0
;
4253 uint32_t _ptr_password
;
4254 uint32_t size_password_1
= 0;
4255 uint32_t length_password_1
= 0;
4256 TALLOC_CTX
*_mem_save_password_0
;
4257 if (ndr_flags
& NDR_SCALARS
) {
4258 NDR_CHECK(ndr_pull_align(ndr
, 4));
4259 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_name
));
4261 NDR_PULL_ALLOC(ndr
, r
->name
);
4265 NDR_CHECK(ndr_pull_srvsvc_ShareType(ndr
, NDR_SCALARS
, &r
->type
));
4266 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_comment
));
4268 NDR_PULL_ALLOC(ndr
, r
->comment
);
4272 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->permissions
));
4273 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->max_users
));
4274 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->current_users
));
4275 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_path
));
4277 NDR_PULL_ALLOC(ndr
, r
->path
);
4281 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_password
));
4282 if (_ptr_password
) {
4283 NDR_PULL_ALLOC(ndr
, r
->password
);
4288 if (ndr_flags
& NDR_BUFFERS
) {
4290 _mem_save_name_0
= NDR_PULL_GET_MEM_CTX(ndr
);
4291 NDR_PULL_SET_MEM_CTX(ndr
, r
->name
, 0);
4292 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->name
));
4293 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->name
));
4294 size_name_1
= ndr_get_array_size(ndr
, &r
->name
);
4295 length_name_1
= ndr_get_array_length(ndr
, &r
->name
);
4296 if (length_name_1
> size_name_1
) {
4297 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", size_name_1
, length_name_1
);
4299 NDR_CHECK(ndr_check_string_terminator(ndr
, length_name_1
, sizeof(uint16_t)));
4300 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->name
, length_name_1
, sizeof(uint16_t), CH_UTF16
));
4301 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_name_0
, 0);
4304 _mem_save_comment_0
= NDR_PULL_GET_MEM_CTX(ndr
);
4305 NDR_PULL_SET_MEM_CTX(ndr
, r
->comment
, 0);
4306 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->comment
));
4307 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->comment
));
4308 size_comment_1
= ndr_get_array_size(ndr
, &r
->comment
);
4309 length_comment_1
= ndr_get_array_length(ndr
, &r
->comment
);
4310 if (length_comment_1
> size_comment_1
) {
4311 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", size_comment_1
, length_comment_1
);
4313 NDR_CHECK(ndr_check_string_terminator(ndr
, length_comment_1
, sizeof(uint16_t)));
4314 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->comment
, length_comment_1
, sizeof(uint16_t), CH_UTF16
));
4315 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_comment_0
, 0);
4318 _mem_save_path_0
= NDR_PULL_GET_MEM_CTX(ndr
);
4319 NDR_PULL_SET_MEM_CTX(ndr
, r
->path
, 0);
4320 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->path
));
4321 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->path
));
4322 size_path_1
= ndr_get_array_size(ndr
, &r
->path
);
4323 length_path_1
= ndr_get_array_length(ndr
, &r
->path
);
4324 if (length_path_1
> size_path_1
) {
4325 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", size_path_1
, length_path_1
);
4327 NDR_CHECK(ndr_check_string_terminator(ndr
, length_path_1
, sizeof(uint16_t)));
4328 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->path
, length_path_1
, sizeof(uint16_t), CH_UTF16
));
4329 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_path_0
, 0);
4332 _mem_save_password_0
= NDR_PULL_GET_MEM_CTX(ndr
);
4333 NDR_PULL_SET_MEM_CTX(ndr
, r
->password
, 0);
4334 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->password
));
4335 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->password
));
4336 size_password_1
= ndr_get_array_size(ndr
, &r
->password
);
4337 length_password_1
= ndr_get_array_length(ndr
, &r
->password
);
4338 if (length_password_1
> size_password_1
) {
4339 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", size_password_1
, length_password_1
);
4341 NDR_CHECK(ndr_check_string_terminator(ndr
, length_password_1
, sizeof(uint16_t)));
4342 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->password
, length_password_1
, sizeof(uint16_t), CH_UTF16
));
4343 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_password_0
, 0);
4346 return NDR_ERR_SUCCESS
;
4349 _PUBLIC_
void ndr_print_srvsvc_NetShareInfo2(struct ndr_print
*ndr
, const char *name
, const struct srvsvc_NetShareInfo2
*r
)
4351 ndr_print_struct(ndr
, name
, "srvsvc_NetShareInfo2");
4353 ndr_print_ptr(ndr
, "name", r
->name
);
4356 ndr_print_string(ndr
, "name", r
->name
);
4359 ndr_print_srvsvc_ShareType(ndr
, "type", r
->type
);
4360 ndr_print_ptr(ndr
, "comment", r
->comment
);
4363 ndr_print_string(ndr
, "comment", r
->comment
);
4366 ndr_print_uint32(ndr
, "permissions", r
->permissions
);
4367 ndr_print_uint32(ndr
, "max_users", r
->max_users
);
4368 ndr_print_uint32(ndr
, "current_users", r
->current_users
);
4369 ndr_print_ptr(ndr
, "path", r
->path
);
4372 ndr_print_string(ndr
, "path", r
->path
);
4375 ndr_print_ptr(ndr
, "password", r
->password
);
4378 ndr_print_string(ndr
, "password", r
->password
);
4384 static enum ndr_err_code
ndr_push_srvsvc_NetShareCtr2(struct ndr_push
*ndr
, int ndr_flags
, const struct srvsvc_NetShareCtr2
*r
)
4386 uint32_t cntr_array_1
;
4387 if (ndr_flags
& NDR_SCALARS
) {
4388 NDR_CHECK(ndr_push_align(ndr
, 4));
4389 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->count
));
4390 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->array
));
4392 if (ndr_flags
& NDR_BUFFERS
) {
4394 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->count
));
4395 for (cntr_array_1
= 0; cntr_array_1
< r
->count
; cntr_array_1
++) {
4396 NDR_CHECK(ndr_push_srvsvc_NetShareInfo2(ndr
, NDR_SCALARS
, &r
->array
[cntr_array_1
]));
4398 for (cntr_array_1
= 0; cntr_array_1
< r
->count
; cntr_array_1
++) {
4399 NDR_CHECK(ndr_push_srvsvc_NetShareInfo2(ndr
, NDR_BUFFERS
, &r
->array
[cntr_array_1
]));
4403 return NDR_ERR_SUCCESS
;
4406 static enum ndr_err_code
ndr_pull_srvsvc_NetShareCtr2(struct ndr_pull
*ndr
, int ndr_flags
, struct srvsvc_NetShareCtr2
*r
)
4408 uint32_t _ptr_array
;
4409 uint32_t size_array_1
= 0;
4410 uint32_t cntr_array_1
;
4411 TALLOC_CTX
*_mem_save_array_0
;
4412 TALLOC_CTX
*_mem_save_array_1
;
4413 if (ndr_flags
& NDR_SCALARS
) {
4414 NDR_CHECK(ndr_pull_align(ndr
, 4));
4415 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->count
));
4416 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_array
));
4418 NDR_PULL_ALLOC(ndr
, r
->array
);
4423 if (ndr_flags
& NDR_BUFFERS
) {
4425 _mem_save_array_0
= NDR_PULL_GET_MEM_CTX(ndr
);
4426 NDR_PULL_SET_MEM_CTX(ndr
, r
->array
, 0);
4427 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->array
));
4428 size_array_1
= ndr_get_array_size(ndr
, &r
->array
);
4429 NDR_PULL_ALLOC_N(ndr
, r
->array
, size_array_1
);
4430 _mem_save_array_1
= NDR_PULL_GET_MEM_CTX(ndr
);
4431 NDR_PULL_SET_MEM_CTX(ndr
, r
->array
, 0);
4432 for (cntr_array_1
= 0; cntr_array_1
< size_array_1
; cntr_array_1
++) {
4433 NDR_CHECK(ndr_pull_srvsvc_NetShareInfo2(ndr
, NDR_SCALARS
, &r
->array
[cntr_array_1
]));
4435 for (cntr_array_1
= 0; cntr_array_1
< size_array_1
; cntr_array_1
++) {
4436 NDR_CHECK(ndr_pull_srvsvc_NetShareInfo2(ndr
, NDR_BUFFERS
, &r
->array
[cntr_array_1
]));
4438 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_array_1
, 0);
4439 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_array_0
, 0);
4442 NDR_CHECK(ndr_check_array_size(ndr
, (void*)&r
->array
, r
->count
));
4445 return NDR_ERR_SUCCESS
;
4448 _PUBLIC_
void ndr_print_srvsvc_NetShareCtr2(struct ndr_print
*ndr
, const char *name
, const struct srvsvc_NetShareCtr2
*r
)
4450 uint32_t cntr_array_1
;
4451 ndr_print_struct(ndr
, name
, "srvsvc_NetShareCtr2");
4453 ndr_print_uint32(ndr
, "count", r
->count
);
4454 ndr_print_ptr(ndr
, "array", r
->array
);
4457 ndr
->print(ndr
, "%s: ARRAY(%d)", "array", (int)r
->count
);
4459 for (cntr_array_1
=0;cntr_array_1
<r
->count
;cntr_array_1
++) {
4461 if (asprintf(&idx_1
, "[%d]", cntr_array_1
) != -1) {
4462 ndr_print_srvsvc_NetShareInfo2(ndr
, "array", &r
->array
[cntr_array_1
]);
4472 static enum ndr_err_code
ndr_push_srvsvc_NetShareInfo501(struct ndr_push
*ndr
, int ndr_flags
, const struct srvsvc_NetShareInfo501
*r
)
4474 if (ndr_flags
& NDR_SCALARS
) {
4475 NDR_CHECK(ndr_push_align(ndr
, 4));
4476 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->name
));
4477 NDR_CHECK(ndr_push_srvsvc_ShareType(ndr
, NDR_SCALARS
, r
->type
));
4478 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->comment
));
4479 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->csc_policy
));
4481 if (ndr_flags
& NDR_BUFFERS
) {
4483 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->name
, CH_UTF16
)));
4484 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
4485 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->name
, CH_UTF16
)));
4486 NDR_CHECK(ndr_push_charset(ndr
, NDR_SCALARS
, r
->name
, ndr_charset_length(r
->name
, CH_UTF16
), sizeof(uint16_t), CH_UTF16
));
4489 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->comment
, CH_UTF16
)));
4490 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
4491 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->comment
, CH_UTF16
)));
4492 NDR_CHECK(ndr_push_charset(ndr
, NDR_SCALARS
, r
->comment
, ndr_charset_length(r
->comment
, CH_UTF16
), sizeof(uint16_t), CH_UTF16
));
4495 return NDR_ERR_SUCCESS
;
4498 static enum ndr_err_code
ndr_pull_srvsvc_NetShareInfo501(struct ndr_pull
*ndr
, int ndr_flags
, struct srvsvc_NetShareInfo501
*r
)
4501 uint32_t size_name_1
= 0;
4502 uint32_t length_name_1
= 0;
4503 TALLOC_CTX
*_mem_save_name_0
;
4504 uint32_t _ptr_comment
;
4505 uint32_t size_comment_1
= 0;
4506 uint32_t length_comment_1
= 0;
4507 TALLOC_CTX
*_mem_save_comment_0
;
4508 if (ndr_flags
& NDR_SCALARS
) {
4509 NDR_CHECK(ndr_pull_align(ndr
, 4));
4510 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_name
));
4512 NDR_PULL_ALLOC(ndr
, r
->name
);
4516 NDR_CHECK(ndr_pull_srvsvc_ShareType(ndr
, NDR_SCALARS
, &r
->type
));
4517 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_comment
));
4519 NDR_PULL_ALLOC(ndr
, r
->comment
);
4523 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->csc_policy
));
4525 if (ndr_flags
& NDR_BUFFERS
) {
4527 _mem_save_name_0
= NDR_PULL_GET_MEM_CTX(ndr
);
4528 NDR_PULL_SET_MEM_CTX(ndr
, r
->name
, 0);
4529 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->name
));
4530 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->name
));
4531 size_name_1
= ndr_get_array_size(ndr
, &r
->name
);
4532 length_name_1
= ndr_get_array_length(ndr
, &r
->name
);
4533 if (length_name_1
> size_name_1
) {
4534 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", size_name_1
, length_name_1
);
4536 NDR_CHECK(ndr_check_string_terminator(ndr
, length_name_1
, sizeof(uint16_t)));
4537 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->name
, length_name_1
, sizeof(uint16_t), CH_UTF16
));
4538 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_name_0
, 0);
4541 _mem_save_comment_0
= NDR_PULL_GET_MEM_CTX(ndr
);
4542 NDR_PULL_SET_MEM_CTX(ndr
, r
->comment
, 0);
4543 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->comment
));
4544 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->comment
));
4545 size_comment_1
= ndr_get_array_size(ndr
, &r
->comment
);
4546 length_comment_1
= ndr_get_array_length(ndr
, &r
->comment
);
4547 if (length_comment_1
> size_comment_1
) {
4548 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", size_comment_1
, length_comment_1
);
4550 NDR_CHECK(ndr_check_string_terminator(ndr
, length_comment_1
, sizeof(uint16_t)));
4551 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->comment
, length_comment_1
, sizeof(uint16_t), CH_UTF16
));
4552 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_comment_0
, 0);
4555 return NDR_ERR_SUCCESS
;
4558 _PUBLIC_
void ndr_print_srvsvc_NetShareInfo501(struct ndr_print
*ndr
, const char *name
, const struct srvsvc_NetShareInfo501
*r
)
4560 ndr_print_struct(ndr
, name
, "srvsvc_NetShareInfo501");
4562 ndr_print_ptr(ndr
, "name", r
->name
);
4565 ndr_print_string(ndr
, "name", r
->name
);
4568 ndr_print_srvsvc_ShareType(ndr
, "type", r
->type
);
4569 ndr_print_ptr(ndr
, "comment", r
->comment
);
4572 ndr_print_string(ndr
, "comment", r
->comment
);
4575 ndr_print_uint32(ndr
, "csc_policy", r
->csc_policy
);
4579 static enum ndr_err_code
ndr_push_srvsvc_NetShareCtr501(struct ndr_push
*ndr
, int ndr_flags
, const struct srvsvc_NetShareCtr501
*r
)
4581 uint32_t cntr_array_1
;
4582 if (ndr_flags
& NDR_SCALARS
) {
4583 NDR_CHECK(ndr_push_align(ndr
, 4));
4584 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->count
));
4585 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->array
));
4587 if (ndr_flags
& NDR_BUFFERS
) {
4589 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->count
));
4590 for (cntr_array_1
= 0; cntr_array_1
< r
->count
; cntr_array_1
++) {
4591 NDR_CHECK(ndr_push_srvsvc_NetShareInfo501(ndr
, NDR_SCALARS
, &r
->array
[cntr_array_1
]));
4593 for (cntr_array_1
= 0; cntr_array_1
< r
->count
; cntr_array_1
++) {
4594 NDR_CHECK(ndr_push_srvsvc_NetShareInfo501(ndr
, NDR_BUFFERS
, &r
->array
[cntr_array_1
]));
4598 return NDR_ERR_SUCCESS
;
4601 static enum ndr_err_code
ndr_pull_srvsvc_NetShareCtr501(struct ndr_pull
*ndr
, int ndr_flags
, struct srvsvc_NetShareCtr501
*r
)
4603 uint32_t _ptr_array
;
4604 uint32_t size_array_1
= 0;
4605 uint32_t cntr_array_1
;
4606 TALLOC_CTX
*_mem_save_array_0
;
4607 TALLOC_CTX
*_mem_save_array_1
;
4608 if (ndr_flags
& NDR_SCALARS
) {
4609 NDR_CHECK(ndr_pull_align(ndr
, 4));
4610 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->count
));
4611 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_array
));
4613 NDR_PULL_ALLOC(ndr
, r
->array
);
4618 if (ndr_flags
& NDR_BUFFERS
) {
4620 _mem_save_array_0
= NDR_PULL_GET_MEM_CTX(ndr
);
4621 NDR_PULL_SET_MEM_CTX(ndr
, r
->array
, 0);
4622 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->array
));
4623 size_array_1
= ndr_get_array_size(ndr
, &r
->array
);
4624 NDR_PULL_ALLOC_N(ndr
, r
->array
, size_array_1
);
4625 _mem_save_array_1
= NDR_PULL_GET_MEM_CTX(ndr
);
4626 NDR_PULL_SET_MEM_CTX(ndr
, r
->array
, 0);
4627 for (cntr_array_1
= 0; cntr_array_1
< size_array_1
; cntr_array_1
++) {
4628 NDR_CHECK(ndr_pull_srvsvc_NetShareInfo501(ndr
, NDR_SCALARS
, &r
->array
[cntr_array_1
]));
4630 for (cntr_array_1
= 0; cntr_array_1
< size_array_1
; cntr_array_1
++) {
4631 NDR_CHECK(ndr_pull_srvsvc_NetShareInfo501(ndr
, NDR_BUFFERS
, &r
->array
[cntr_array_1
]));
4633 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_array_1
, 0);
4634 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_array_0
, 0);
4637 NDR_CHECK(ndr_check_array_size(ndr
, (void*)&r
->array
, r
->count
));
4640 return NDR_ERR_SUCCESS
;
4643 _PUBLIC_
void ndr_print_srvsvc_NetShareCtr501(struct ndr_print
*ndr
, const char *name
, const struct srvsvc_NetShareCtr501
*r
)
4645 uint32_t cntr_array_1
;
4646 ndr_print_struct(ndr
, name
, "srvsvc_NetShareCtr501");
4648 ndr_print_uint32(ndr
, "count", r
->count
);
4649 ndr_print_ptr(ndr
, "array", r
->array
);
4652 ndr
->print(ndr
, "%s: ARRAY(%d)", "array", (int)r
->count
);
4654 for (cntr_array_1
=0;cntr_array_1
<r
->count
;cntr_array_1
++) {
4656 if (asprintf(&idx_1
, "[%d]", cntr_array_1
) != -1) {
4657 ndr_print_srvsvc_NetShareInfo501(ndr
, "array", &r
->array
[cntr_array_1
]);
4667 static enum ndr_err_code
ndr_push_srvsvc_NetShareInfo502(struct ndr_push
*ndr
, int ndr_flags
, const struct srvsvc_NetShareInfo502
*r
)
4669 if (ndr_flags
& NDR_SCALARS
) {
4670 NDR_CHECK(ndr_push_align(ndr
, 4));
4671 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->name
));
4672 NDR_CHECK(ndr_push_srvsvc_ShareType(ndr
, NDR_SCALARS
, r
->type
));
4673 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->comment
));
4674 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->permissions
));
4675 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->max_users
));
4676 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->current_users
));
4677 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->path
));
4678 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->password
));
4679 NDR_CHECK(ndr_push_sec_desc_buf(ndr
, NDR_SCALARS
, &r
->sd_buf
));
4681 if (ndr_flags
& NDR_BUFFERS
) {
4683 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->name
, CH_UTF16
)));
4684 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
4685 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->name
, CH_UTF16
)));
4686 NDR_CHECK(ndr_push_charset(ndr
, NDR_SCALARS
, r
->name
, ndr_charset_length(r
->name
, CH_UTF16
), sizeof(uint16_t), CH_UTF16
));
4689 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->comment
, CH_UTF16
)));
4690 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
4691 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->comment
, CH_UTF16
)));
4692 NDR_CHECK(ndr_push_charset(ndr
, NDR_SCALARS
, r
->comment
, ndr_charset_length(r
->comment
, CH_UTF16
), sizeof(uint16_t), CH_UTF16
));
4695 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->path
, CH_UTF16
)));
4696 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
4697 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->path
, CH_UTF16
)));
4698 NDR_CHECK(ndr_push_charset(ndr
, NDR_SCALARS
, r
->path
, ndr_charset_length(r
->path
, CH_UTF16
), sizeof(uint16_t), CH_UTF16
));
4701 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->password
, CH_UTF16
)));
4702 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
4703 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->password
, CH_UTF16
)));
4704 NDR_CHECK(ndr_push_charset(ndr
, NDR_SCALARS
, r
->password
, ndr_charset_length(r
->password
, CH_UTF16
), sizeof(uint16_t), CH_UTF16
));
4706 NDR_CHECK(ndr_push_sec_desc_buf(ndr
, NDR_BUFFERS
, &r
->sd_buf
));
4708 return NDR_ERR_SUCCESS
;
4711 static enum ndr_err_code
ndr_pull_srvsvc_NetShareInfo502(struct ndr_pull
*ndr
, int ndr_flags
, struct srvsvc_NetShareInfo502
*r
)
4714 uint32_t size_name_1
= 0;
4715 uint32_t length_name_1
= 0;
4716 TALLOC_CTX
*_mem_save_name_0
;
4717 uint32_t _ptr_comment
;
4718 uint32_t size_comment_1
= 0;
4719 uint32_t length_comment_1
= 0;
4720 TALLOC_CTX
*_mem_save_comment_0
;
4722 uint32_t size_path_1
= 0;
4723 uint32_t length_path_1
= 0;
4724 TALLOC_CTX
*_mem_save_path_0
;
4725 uint32_t _ptr_password
;
4726 uint32_t size_password_1
= 0;
4727 uint32_t length_password_1
= 0;
4728 TALLOC_CTX
*_mem_save_password_0
;
4729 if (ndr_flags
& NDR_SCALARS
) {
4730 NDR_CHECK(ndr_pull_align(ndr
, 4));
4731 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_name
));
4733 NDR_PULL_ALLOC(ndr
, r
->name
);
4737 NDR_CHECK(ndr_pull_srvsvc_ShareType(ndr
, NDR_SCALARS
, &r
->type
));
4738 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_comment
));
4740 NDR_PULL_ALLOC(ndr
, r
->comment
);
4744 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->permissions
));
4745 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->max_users
));
4746 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->current_users
));
4747 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_path
));
4749 NDR_PULL_ALLOC(ndr
, r
->path
);
4753 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_password
));
4754 if (_ptr_password
) {
4755 NDR_PULL_ALLOC(ndr
, r
->password
);
4759 NDR_CHECK(ndr_pull_sec_desc_buf(ndr
, NDR_SCALARS
, &r
->sd_buf
));
4761 if (ndr_flags
& NDR_BUFFERS
) {
4763 _mem_save_name_0
= NDR_PULL_GET_MEM_CTX(ndr
);
4764 NDR_PULL_SET_MEM_CTX(ndr
, r
->name
, 0);
4765 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->name
));
4766 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->name
));
4767 size_name_1
= ndr_get_array_size(ndr
, &r
->name
);
4768 length_name_1
= ndr_get_array_length(ndr
, &r
->name
);
4769 if (length_name_1
> size_name_1
) {
4770 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", size_name_1
, length_name_1
);
4772 NDR_CHECK(ndr_check_string_terminator(ndr
, length_name_1
, sizeof(uint16_t)));
4773 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->name
, length_name_1
, sizeof(uint16_t), CH_UTF16
));
4774 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_name_0
, 0);
4777 _mem_save_comment_0
= NDR_PULL_GET_MEM_CTX(ndr
);
4778 NDR_PULL_SET_MEM_CTX(ndr
, r
->comment
, 0);
4779 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->comment
));
4780 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->comment
));
4781 size_comment_1
= ndr_get_array_size(ndr
, &r
->comment
);
4782 length_comment_1
= ndr_get_array_length(ndr
, &r
->comment
);
4783 if (length_comment_1
> size_comment_1
) {
4784 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", size_comment_1
, length_comment_1
);
4786 NDR_CHECK(ndr_check_string_terminator(ndr
, length_comment_1
, sizeof(uint16_t)));
4787 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->comment
, length_comment_1
, sizeof(uint16_t), CH_UTF16
));
4788 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_comment_0
, 0);
4791 _mem_save_path_0
= NDR_PULL_GET_MEM_CTX(ndr
);
4792 NDR_PULL_SET_MEM_CTX(ndr
, r
->path
, 0);
4793 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->path
));
4794 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->path
));
4795 size_path_1
= ndr_get_array_size(ndr
, &r
->path
);
4796 length_path_1
= ndr_get_array_length(ndr
, &r
->path
);
4797 if (length_path_1
> size_path_1
) {
4798 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", size_path_1
, length_path_1
);
4800 NDR_CHECK(ndr_check_string_terminator(ndr
, length_path_1
, sizeof(uint16_t)));
4801 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->path
, length_path_1
, sizeof(uint16_t), CH_UTF16
));
4802 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_path_0
, 0);
4805 _mem_save_password_0
= NDR_PULL_GET_MEM_CTX(ndr
);
4806 NDR_PULL_SET_MEM_CTX(ndr
, r
->password
, 0);
4807 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->password
));
4808 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->password
));
4809 size_password_1
= ndr_get_array_size(ndr
, &r
->password
);
4810 length_password_1
= ndr_get_array_length(ndr
, &r
->password
);
4811 if (length_password_1
> size_password_1
) {
4812 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", size_password_1
, length_password_1
);
4814 NDR_CHECK(ndr_check_string_terminator(ndr
, length_password_1
, sizeof(uint16_t)));
4815 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->password
, length_password_1
, sizeof(uint16_t), CH_UTF16
));
4816 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_password_0
, 0);
4818 NDR_CHECK(ndr_pull_sec_desc_buf(ndr
, NDR_BUFFERS
, &r
->sd_buf
));
4820 return NDR_ERR_SUCCESS
;
4823 _PUBLIC_
void ndr_print_srvsvc_NetShareInfo502(struct ndr_print
*ndr
, const char *name
, const struct srvsvc_NetShareInfo502
*r
)
4825 ndr_print_struct(ndr
, name
, "srvsvc_NetShareInfo502");
4827 ndr_print_ptr(ndr
, "name", r
->name
);
4830 ndr_print_string(ndr
, "name", r
->name
);
4833 ndr_print_srvsvc_ShareType(ndr
, "type", r
->type
);
4834 ndr_print_ptr(ndr
, "comment", r
->comment
);
4837 ndr_print_string(ndr
, "comment", r
->comment
);
4840 ndr_print_uint32(ndr
, "permissions", r
->permissions
);
4841 ndr_print_uint32(ndr
, "max_users", r
->max_users
);
4842 ndr_print_uint32(ndr
, "current_users", r
->current_users
);
4843 ndr_print_ptr(ndr
, "path", r
->path
);
4846 ndr_print_string(ndr
, "path", r
->path
);
4849 ndr_print_ptr(ndr
, "password", r
->password
);
4852 ndr_print_string(ndr
, "password", r
->password
);
4855 ndr_print_sec_desc_buf(ndr
, "sd_buf", &r
->sd_buf
);
4859 static enum ndr_err_code
ndr_push_srvsvc_NetShareCtr502(struct ndr_push
*ndr
, int ndr_flags
, const struct srvsvc_NetShareCtr502
*r
)
4861 uint32_t cntr_array_1
;
4862 if (ndr_flags
& NDR_SCALARS
) {
4863 NDR_CHECK(ndr_push_align(ndr
, 4));
4864 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->count
));
4865 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->array
));
4867 if (ndr_flags
& NDR_BUFFERS
) {
4869 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->count
));
4870 for (cntr_array_1
= 0; cntr_array_1
< r
->count
; cntr_array_1
++) {
4871 NDR_CHECK(ndr_push_srvsvc_NetShareInfo502(ndr
, NDR_SCALARS
, &r
->array
[cntr_array_1
]));
4873 for (cntr_array_1
= 0; cntr_array_1
< r
->count
; cntr_array_1
++) {
4874 NDR_CHECK(ndr_push_srvsvc_NetShareInfo502(ndr
, NDR_BUFFERS
, &r
->array
[cntr_array_1
]));
4878 return NDR_ERR_SUCCESS
;
4881 static enum ndr_err_code
ndr_pull_srvsvc_NetShareCtr502(struct ndr_pull
*ndr
, int ndr_flags
, struct srvsvc_NetShareCtr502
*r
)
4883 uint32_t _ptr_array
;
4884 uint32_t size_array_1
= 0;
4885 uint32_t cntr_array_1
;
4886 TALLOC_CTX
*_mem_save_array_0
;
4887 TALLOC_CTX
*_mem_save_array_1
;
4888 if (ndr_flags
& NDR_SCALARS
) {
4889 NDR_CHECK(ndr_pull_align(ndr
, 4));
4890 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->count
));
4891 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_array
));
4893 NDR_PULL_ALLOC(ndr
, r
->array
);
4898 if (ndr_flags
& NDR_BUFFERS
) {
4900 _mem_save_array_0
= NDR_PULL_GET_MEM_CTX(ndr
);
4901 NDR_PULL_SET_MEM_CTX(ndr
, r
->array
, 0);
4902 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->array
));
4903 size_array_1
= ndr_get_array_size(ndr
, &r
->array
);
4904 NDR_PULL_ALLOC_N(ndr
, r
->array
, size_array_1
);
4905 _mem_save_array_1
= NDR_PULL_GET_MEM_CTX(ndr
);
4906 NDR_PULL_SET_MEM_CTX(ndr
, r
->array
, 0);
4907 for (cntr_array_1
= 0; cntr_array_1
< size_array_1
; cntr_array_1
++) {
4908 NDR_CHECK(ndr_pull_srvsvc_NetShareInfo502(ndr
, NDR_SCALARS
, &r
->array
[cntr_array_1
]));
4910 for (cntr_array_1
= 0; cntr_array_1
< size_array_1
; cntr_array_1
++) {
4911 NDR_CHECK(ndr_pull_srvsvc_NetShareInfo502(ndr
, NDR_BUFFERS
, &r
->array
[cntr_array_1
]));
4913 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_array_1
, 0);
4914 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_array_0
, 0);
4917 NDR_CHECK(ndr_check_array_size(ndr
, (void*)&r
->array
, r
->count
));
4920 return NDR_ERR_SUCCESS
;
4923 _PUBLIC_
void ndr_print_srvsvc_NetShareCtr502(struct ndr_print
*ndr
, const char *name
, const struct srvsvc_NetShareCtr502
*r
)
4925 uint32_t cntr_array_1
;
4926 ndr_print_struct(ndr
, name
, "srvsvc_NetShareCtr502");
4928 ndr_print_uint32(ndr
, "count", r
->count
);
4929 ndr_print_ptr(ndr
, "array", r
->array
);
4932 ndr
->print(ndr
, "%s: ARRAY(%d)", "array", (int)r
->count
);
4934 for (cntr_array_1
=0;cntr_array_1
<r
->count
;cntr_array_1
++) {
4936 if (asprintf(&idx_1
, "[%d]", cntr_array_1
) != -1) {
4937 ndr_print_srvsvc_NetShareInfo502(ndr
, "array", &r
->array
[cntr_array_1
]);
4947 static enum ndr_err_code
ndr_push_srvsvc_NetShareInfo1004(struct ndr_push
*ndr
, int ndr_flags
, const struct srvsvc_NetShareInfo1004
*r
)
4949 if (ndr_flags
& NDR_SCALARS
) {
4950 NDR_CHECK(ndr_push_align(ndr
, 4));
4951 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->comment
));
4953 if (ndr_flags
& NDR_BUFFERS
) {
4955 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->comment
, CH_UTF16
)));
4956 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
4957 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->comment
, CH_UTF16
)));
4958 NDR_CHECK(ndr_push_charset(ndr
, NDR_SCALARS
, r
->comment
, ndr_charset_length(r
->comment
, CH_UTF16
), sizeof(uint16_t), CH_UTF16
));
4961 return NDR_ERR_SUCCESS
;
4964 static enum ndr_err_code
ndr_pull_srvsvc_NetShareInfo1004(struct ndr_pull
*ndr
, int ndr_flags
, struct srvsvc_NetShareInfo1004
*r
)
4966 uint32_t _ptr_comment
;
4967 uint32_t size_comment_1
= 0;
4968 uint32_t length_comment_1
= 0;
4969 TALLOC_CTX
*_mem_save_comment_0
;
4970 if (ndr_flags
& NDR_SCALARS
) {
4971 NDR_CHECK(ndr_pull_align(ndr
, 4));
4972 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_comment
));
4974 NDR_PULL_ALLOC(ndr
, r
->comment
);
4979 if (ndr_flags
& NDR_BUFFERS
) {
4981 _mem_save_comment_0
= NDR_PULL_GET_MEM_CTX(ndr
);
4982 NDR_PULL_SET_MEM_CTX(ndr
, r
->comment
, 0);
4983 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->comment
));
4984 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->comment
));
4985 size_comment_1
= ndr_get_array_size(ndr
, &r
->comment
);
4986 length_comment_1
= ndr_get_array_length(ndr
, &r
->comment
);
4987 if (length_comment_1
> size_comment_1
) {
4988 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", size_comment_1
, length_comment_1
);
4990 NDR_CHECK(ndr_check_string_terminator(ndr
, length_comment_1
, sizeof(uint16_t)));
4991 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->comment
, length_comment_1
, sizeof(uint16_t), CH_UTF16
));
4992 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_comment_0
, 0);
4995 return NDR_ERR_SUCCESS
;
4998 _PUBLIC_
void ndr_print_srvsvc_NetShareInfo1004(struct ndr_print
*ndr
, const char *name
, const struct srvsvc_NetShareInfo1004
*r
)
5000 ndr_print_struct(ndr
, name
, "srvsvc_NetShareInfo1004");
5002 ndr_print_ptr(ndr
, "comment", r
->comment
);
5005 ndr_print_string(ndr
, "comment", r
->comment
);
5011 static enum ndr_err_code
ndr_push_srvsvc_NetShareCtr1004(struct ndr_push
*ndr
, int ndr_flags
, const struct srvsvc_NetShareCtr1004
*r
)
5013 uint32_t cntr_array_1
;
5014 if (ndr_flags
& NDR_SCALARS
) {
5015 NDR_CHECK(ndr_push_align(ndr
, 4));
5016 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->count
));
5017 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->array
));
5019 if (ndr_flags
& NDR_BUFFERS
) {
5021 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->count
));
5022 for (cntr_array_1
= 0; cntr_array_1
< r
->count
; cntr_array_1
++) {
5023 NDR_CHECK(ndr_push_srvsvc_NetShareInfo1004(ndr
, NDR_SCALARS
, &r
->array
[cntr_array_1
]));
5025 for (cntr_array_1
= 0; cntr_array_1
< r
->count
; cntr_array_1
++) {
5026 NDR_CHECK(ndr_push_srvsvc_NetShareInfo1004(ndr
, NDR_BUFFERS
, &r
->array
[cntr_array_1
]));
5030 return NDR_ERR_SUCCESS
;
5033 static enum ndr_err_code
ndr_pull_srvsvc_NetShareCtr1004(struct ndr_pull
*ndr
, int ndr_flags
, struct srvsvc_NetShareCtr1004
*r
)
5035 uint32_t _ptr_array
;
5036 uint32_t size_array_1
= 0;
5037 uint32_t cntr_array_1
;
5038 TALLOC_CTX
*_mem_save_array_0
;
5039 TALLOC_CTX
*_mem_save_array_1
;
5040 if (ndr_flags
& NDR_SCALARS
) {
5041 NDR_CHECK(ndr_pull_align(ndr
, 4));
5042 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->count
));
5043 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_array
));
5045 NDR_PULL_ALLOC(ndr
, r
->array
);
5050 if (ndr_flags
& NDR_BUFFERS
) {
5052 _mem_save_array_0
= NDR_PULL_GET_MEM_CTX(ndr
);
5053 NDR_PULL_SET_MEM_CTX(ndr
, r
->array
, 0);
5054 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->array
));
5055 size_array_1
= ndr_get_array_size(ndr
, &r
->array
);
5056 NDR_PULL_ALLOC_N(ndr
, r
->array
, size_array_1
);
5057 _mem_save_array_1
= NDR_PULL_GET_MEM_CTX(ndr
);
5058 NDR_PULL_SET_MEM_CTX(ndr
, r
->array
, 0);
5059 for (cntr_array_1
= 0; cntr_array_1
< size_array_1
; cntr_array_1
++) {
5060 NDR_CHECK(ndr_pull_srvsvc_NetShareInfo1004(ndr
, NDR_SCALARS
, &r
->array
[cntr_array_1
]));
5062 for (cntr_array_1
= 0; cntr_array_1
< size_array_1
; cntr_array_1
++) {
5063 NDR_CHECK(ndr_pull_srvsvc_NetShareInfo1004(ndr
, NDR_BUFFERS
, &r
->array
[cntr_array_1
]));
5065 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_array_1
, 0);
5066 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_array_0
, 0);
5069 NDR_CHECK(ndr_check_array_size(ndr
, (void*)&r
->array
, r
->count
));
5072 return NDR_ERR_SUCCESS
;
5075 _PUBLIC_
void ndr_print_srvsvc_NetShareCtr1004(struct ndr_print
*ndr
, const char *name
, const struct srvsvc_NetShareCtr1004
*r
)
5077 uint32_t cntr_array_1
;
5078 ndr_print_struct(ndr
, name
, "srvsvc_NetShareCtr1004");
5080 ndr_print_uint32(ndr
, "count", r
->count
);
5081 ndr_print_ptr(ndr
, "array", r
->array
);
5084 ndr
->print(ndr
, "%s: ARRAY(%d)", "array", (int)r
->count
);
5086 for (cntr_array_1
=0;cntr_array_1
<r
->count
;cntr_array_1
++) {
5088 if (asprintf(&idx_1
, "[%d]", cntr_array_1
) != -1) {
5089 ndr_print_srvsvc_NetShareInfo1004(ndr
, "array", &r
->array
[cntr_array_1
]);
5099 static enum ndr_err_code
ndr_push_NetShareInfo1005Flags(struct ndr_push
*ndr
, int ndr_flags
, uint32_t r
)
5101 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
));
5102 return NDR_ERR_SUCCESS
;
5105 static enum ndr_err_code
ndr_pull_NetShareInfo1005Flags(struct ndr_pull
*ndr
, int ndr_flags
, uint32_t *r
)
5108 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &v
));
5110 return NDR_ERR_SUCCESS
;
5113 _PUBLIC_
void ndr_print_NetShareInfo1005Flags(struct ndr_print
*ndr
, const char *name
, uint32_t r
)
5115 ndr_print_uint32(ndr
, name
, r
);
5117 ndr_print_bitmap_flag(ndr
, sizeof(uint32_t), "SHARE_1005_IN_DFS", SHARE_1005_IN_DFS
, r
);
5118 ndr_print_bitmap_flag(ndr
, sizeof(uint32_t), "SHARE_1005_DFS_ROOT", SHARE_1005_DFS_ROOT
, r
);
5122 static enum ndr_err_code
ndr_push_srvsvc_NetShareInfo1005(struct ndr_push
*ndr
, int ndr_flags
, const struct srvsvc_NetShareInfo1005
*r
)
5124 if (ndr_flags
& NDR_SCALARS
) {
5125 NDR_CHECK(ndr_push_align(ndr
, 4));
5126 NDR_CHECK(ndr_push_NetShareInfo1005Flags(ndr
, NDR_SCALARS
, r
->dfs_flags
));
5128 if (ndr_flags
& NDR_BUFFERS
) {
5130 return NDR_ERR_SUCCESS
;
5133 static enum ndr_err_code
ndr_pull_srvsvc_NetShareInfo1005(struct ndr_pull
*ndr
, int ndr_flags
, struct srvsvc_NetShareInfo1005
*r
)
5135 if (ndr_flags
& NDR_SCALARS
) {
5136 NDR_CHECK(ndr_pull_align(ndr
, 4));
5137 NDR_CHECK(ndr_pull_NetShareInfo1005Flags(ndr
, NDR_SCALARS
, &r
->dfs_flags
));
5139 if (ndr_flags
& NDR_BUFFERS
) {
5141 return NDR_ERR_SUCCESS
;
5144 _PUBLIC_
void ndr_print_srvsvc_NetShareInfo1005(struct ndr_print
*ndr
, const char *name
, const struct srvsvc_NetShareInfo1005
*r
)
5146 ndr_print_struct(ndr
, name
, "srvsvc_NetShareInfo1005");
5148 ndr_print_NetShareInfo1005Flags(ndr
, "dfs_flags", r
->dfs_flags
);
5152 static enum ndr_err_code
ndr_push_srvsvc_NetShareCtr1005(struct ndr_push
*ndr
, int ndr_flags
, const struct srvsvc_NetShareCtr1005
*r
)
5154 uint32_t cntr_array_1
;
5155 if (ndr_flags
& NDR_SCALARS
) {
5156 NDR_CHECK(ndr_push_align(ndr
, 4));
5157 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->count
));
5158 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->array
));
5160 if (ndr_flags
& NDR_BUFFERS
) {
5162 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->count
));
5163 for (cntr_array_1
= 0; cntr_array_1
< r
->count
; cntr_array_1
++) {
5164 NDR_CHECK(ndr_push_srvsvc_NetShareInfo1005(ndr
, NDR_SCALARS
, &r
->array
[cntr_array_1
]));
5168 return NDR_ERR_SUCCESS
;
5171 static enum ndr_err_code
ndr_pull_srvsvc_NetShareCtr1005(struct ndr_pull
*ndr
, int ndr_flags
, struct srvsvc_NetShareCtr1005
*r
)
5173 uint32_t _ptr_array
;
5174 uint32_t size_array_1
= 0;
5175 uint32_t cntr_array_1
;
5176 TALLOC_CTX
*_mem_save_array_0
;
5177 TALLOC_CTX
*_mem_save_array_1
;
5178 if (ndr_flags
& NDR_SCALARS
) {
5179 NDR_CHECK(ndr_pull_align(ndr
, 4));
5180 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->count
));
5181 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_array
));
5183 NDR_PULL_ALLOC(ndr
, r
->array
);
5188 if (ndr_flags
& NDR_BUFFERS
) {
5190 _mem_save_array_0
= NDR_PULL_GET_MEM_CTX(ndr
);
5191 NDR_PULL_SET_MEM_CTX(ndr
, r
->array
, 0);
5192 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->array
));
5193 size_array_1
= ndr_get_array_size(ndr
, &r
->array
);
5194 NDR_PULL_ALLOC_N(ndr
, r
->array
, size_array_1
);
5195 _mem_save_array_1
= NDR_PULL_GET_MEM_CTX(ndr
);
5196 NDR_PULL_SET_MEM_CTX(ndr
, r
->array
, 0);
5197 for (cntr_array_1
= 0; cntr_array_1
< size_array_1
; cntr_array_1
++) {
5198 NDR_CHECK(ndr_pull_srvsvc_NetShareInfo1005(ndr
, NDR_SCALARS
, &r
->array
[cntr_array_1
]));
5200 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_array_1
, 0);
5201 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_array_0
, 0);
5204 NDR_CHECK(ndr_check_array_size(ndr
, (void*)&r
->array
, r
->count
));
5207 return NDR_ERR_SUCCESS
;
5210 _PUBLIC_
void ndr_print_srvsvc_NetShareCtr1005(struct ndr_print
*ndr
, const char *name
, const struct srvsvc_NetShareCtr1005
*r
)
5212 uint32_t cntr_array_1
;
5213 ndr_print_struct(ndr
, name
, "srvsvc_NetShareCtr1005");
5215 ndr_print_uint32(ndr
, "count", r
->count
);
5216 ndr_print_ptr(ndr
, "array", r
->array
);
5219 ndr
->print(ndr
, "%s: ARRAY(%d)", "array", (int)r
->count
);
5221 for (cntr_array_1
=0;cntr_array_1
<r
->count
;cntr_array_1
++) {
5223 if (asprintf(&idx_1
, "[%d]", cntr_array_1
) != -1) {
5224 ndr_print_srvsvc_NetShareInfo1005(ndr
, "array", &r
->array
[cntr_array_1
]);
5234 static enum ndr_err_code
ndr_push_srvsvc_NetShareInfo1006(struct ndr_push
*ndr
, int ndr_flags
, const struct srvsvc_NetShareInfo1006
*r
)
5236 if (ndr_flags
& NDR_SCALARS
) {
5237 NDR_CHECK(ndr_push_align(ndr
, 4));
5238 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->max_users
));
5240 if (ndr_flags
& NDR_BUFFERS
) {
5242 return NDR_ERR_SUCCESS
;
5245 static enum ndr_err_code
ndr_pull_srvsvc_NetShareInfo1006(struct ndr_pull
*ndr
, int ndr_flags
, struct srvsvc_NetShareInfo1006
*r
)
5247 if (ndr_flags
& NDR_SCALARS
) {
5248 NDR_CHECK(ndr_pull_align(ndr
, 4));
5249 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->max_users
));
5251 if (ndr_flags
& NDR_BUFFERS
) {
5253 return NDR_ERR_SUCCESS
;
5256 _PUBLIC_
void ndr_print_srvsvc_NetShareInfo1006(struct ndr_print
*ndr
, const char *name
, const struct srvsvc_NetShareInfo1006
*r
)
5258 ndr_print_struct(ndr
, name
, "srvsvc_NetShareInfo1006");
5260 ndr_print_uint32(ndr
, "max_users", r
->max_users
);
5264 static enum ndr_err_code
ndr_push_srvsvc_NetShareCtr1006(struct ndr_push
*ndr
, int ndr_flags
, const struct srvsvc_NetShareCtr1006
*r
)
5266 uint32_t cntr_array_1
;
5267 if (ndr_flags
& NDR_SCALARS
) {
5268 NDR_CHECK(ndr_push_align(ndr
, 4));
5269 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->count
));
5270 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->array
));
5272 if (ndr_flags
& NDR_BUFFERS
) {
5274 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->count
));
5275 for (cntr_array_1
= 0; cntr_array_1
< r
->count
; cntr_array_1
++) {
5276 NDR_CHECK(ndr_push_srvsvc_NetShareInfo1006(ndr
, NDR_SCALARS
, &r
->array
[cntr_array_1
]));
5280 return NDR_ERR_SUCCESS
;
5283 static enum ndr_err_code
ndr_pull_srvsvc_NetShareCtr1006(struct ndr_pull
*ndr
, int ndr_flags
, struct srvsvc_NetShareCtr1006
*r
)
5285 uint32_t _ptr_array
;
5286 uint32_t size_array_1
= 0;
5287 uint32_t cntr_array_1
;
5288 TALLOC_CTX
*_mem_save_array_0
;
5289 TALLOC_CTX
*_mem_save_array_1
;
5290 if (ndr_flags
& NDR_SCALARS
) {
5291 NDR_CHECK(ndr_pull_align(ndr
, 4));
5292 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->count
));
5293 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_array
));
5295 NDR_PULL_ALLOC(ndr
, r
->array
);
5300 if (ndr_flags
& NDR_BUFFERS
) {
5302 _mem_save_array_0
= NDR_PULL_GET_MEM_CTX(ndr
);
5303 NDR_PULL_SET_MEM_CTX(ndr
, r
->array
, 0);
5304 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->array
));
5305 size_array_1
= ndr_get_array_size(ndr
, &r
->array
);
5306 NDR_PULL_ALLOC_N(ndr
, r
->array
, size_array_1
);
5307 _mem_save_array_1
= NDR_PULL_GET_MEM_CTX(ndr
);
5308 NDR_PULL_SET_MEM_CTX(ndr
, r
->array
, 0);
5309 for (cntr_array_1
= 0; cntr_array_1
< size_array_1
; cntr_array_1
++) {
5310 NDR_CHECK(ndr_pull_srvsvc_NetShareInfo1006(ndr
, NDR_SCALARS
, &r
->array
[cntr_array_1
]));
5312 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_array_1
, 0);
5313 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_array_0
, 0);
5316 NDR_CHECK(ndr_check_array_size(ndr
, (void*)&r
->array
, r
->count
));
5319 return NDR_ERR_SUCCESS
;
5322 _PUBLIC_
void ndr_print_srvsvc_NetShareCtr1006(struct ndr_print
*ndr
, const char *name
, const struct srvsvc_NetShareCtr1006
*r
)
5324 uint32_t cntr_array_1
;
5325 ndr_print_struct(ndr
, name
, "srvsvc_NetShareCtr1006");
5327 ndr_print_uint32(ndr
, "count", r
->count
);
5328 ndr_print_ptr(ndr
, "array", r
->array
);
5331 ndr
->print(ndr
, "%s: ARRAY(%d)", "array", (int)r
->count
);
5333 for (cntr_array_1
=0;cntr_array_1
<r
->count
;cntr_array_1
++) {
5335 if (asprintf(&idx_1
, "[%d]", cntr_array_1
) != -1) {
5336 ndr_print_srvsvc_NetShareInfo1006(ndr
, "array", &r
->array
[cntr_array_1
]);
5346 static enum ndr_err_code
ndr_push_srvsvc_NetShareInfo1007(struct ndr_push
*ndr
, int ndr_flags
, const struct srvsvc_NetShareInfo1007
*r
)
5348 if (ndr_flags
& NDR_SCALARS
) {
5349 NDR_CHECK(ndr_push_align(ndr
, 4));
5350 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->flags
));
5351 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->alternate_directory_name
));
5353 if (ndr_flags
& NDR_BUFFERS
) {
5354 if (r
->alternate_directory_name
) {
5355 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->alternate_directory_name
, CH_UTF16
)));
5356 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
5357 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->alternate_directory_name
, CH_UTF16
)));
5358 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
));
5361 return NDR_ERR_SUCCESS
;
5364 static enum ndr_err_code
ndr_pull_srvsvc_NetShareInfo1007(struct ndr_pull
*ndr
, int ndr_flags
, struct srvsvc_NetShareInfo1007
*r
)
5366 uint32_t _ptr_alternate_directory_name
;
5367 uint32_t size_alternate_directory_name_1
= 0;
5368 uint32_t length_alternate_directory_name_1
= 0;
5369 TALLOC_CTX
*_mem_save_alternate_directory_name_0
;
5370 if (ndr_flags
& NDR_SCALARS
) {
5371 NDR_CHECK(ndr_pull_align(ndr
, 4));
5372 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->flags
));
5373 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_alternate_directory_name
));
5374 if (_ptr_alternate_directory_name
) {
5375 NDR_PULL_ALLOC(ndr
, r
->alternate_directory_name
);
5377 r
->alternate_directory_name
= NULL
;
5380 if (ndr_flags
& NDR_BUFFERS
) {
5381 if (r
->alternate_directory_name
) {
5382 _mem_save_alternate_directory_name_0
= NDR_PULL_GET_MEM_CTX(ndr
);
5383 NDR_PULL_SET_MEM_CTX(ndr
, r
->alternate_directory_name
, 0);
5384 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->alternate_directory_name
));
5385 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->alternate_directory_name
));
5386 size_alternate_directory_name_1
= ndr_get_array_size(ndr
, &r
->alternate_directory_name
);
5387 length_alternate_directory_name_1
= ndr_get_array_length(ndr
, &r
->alternate_directory_name
);
5388 if (length_alternate_directory_name_1
> size_alternate_directory_name_1
) {
5389 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", size_alternate_directory_name_1
, length_alternate_directory_name_1
);
5391 NDR_CHECK(ndr_check_string_terminator(ndr
, length_alternate_directory_name_1
, sizeof(uint16_t)));
5392 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->alternate_directory_name
, length_alternate_directory_name_1
, sizeof(uint16_t), CH_UTF16
));
5393 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_alternate_directory_name_0
, 0);
5396 return NDR_ERR_SUCCESS
;
5399 _PUBLIC_
void ndr_print_srvsvc_NetShareInfo1007(struct ndr_print
*ndr
, const char *name
, const struct srvsvc_NetShareInfo1007
*r
)
5401 ndr_print_struct(ndr
, name
, "srvsvc_NetShareInfo1007");
5403 ndr_print_uint32(ndr
, "flags", r
->flags
);
5404 ndr_print_ptr(ndr
, "alternate_directory_name", r
->alternate_directory_name
);
5406 if (r
->alternate_directory_name
) {
5407 ndr_print_string(ndr
, "alternate_directory_name", r
->alternate_directory_name
);
5413 static enum ndr_err_code
ndr_push_srvsvc_NetShareCtr1007(struct ndr_push
*ndr
, int ndr_flags
, const struct srvsvc_NetShareCtr1007
*r
)
5415 uint32_t cntr_array_1
;
5416 if (ndr_flags
& NDR_SCALARS
) {
5417 NDR_CHECK(ndr_push_align(ndr
, 4));
5418 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->count
));
5419 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->array
));
5421 if (ndr_flags
& NDR_BUFFERS
) {
5423 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->count
));
5424 for (cntr_array_1
= 0; cntr_array_1
< r
->count
; cntr_array_1
++) {
5425 NDR_CHECK(ndr_push_srvsvc_NetShareInfo1007(ndr
, NDR_SCALARS
, &r
->array
[cntr_array_1
]));
5427 for (cntr_array_1
= 0; cntr_array_1
< r
->count
; cntr_array_1
++) {
5428 NDR_CHECK(ndr_push_srvsvc_NetShareInfo1007(ndr
, NDR_BUFFERS
, &r
->array
[cntr_array_1
]));
5432 return NDR_ERR_SUCCESS
;
5435 static enum ndr_err_code
ndr_pull_srvsvc_NetShareCtr1007(struct ndr_pull
*ndr
, int ndr_flags
, struct srvsvc_NetShareCtr1007
*r
)
5437 uint32_t _ptr_array
;
5438 uint32_t size_array_1
= 0;
5439 uint32_t cntr_array_1
;
5440 TALLOC_CTX
*_mem_save_array_0
;
5441 TALLOC_CTX
*_mem_save_array_1
;
5442 if (ndr_flags
& NDR_SCALARS
) {
5443 NDR_CHECK(ndr_pull_align(ndr
, 4));
5444 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->count
));
5445 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_array
));
5447 NDR_PULL_ALLOC(ndr
, r
->array
);
5452 if (ndr_flags
& NDR_BUFFERS
) {
5454 _mem_save_array_0
= NDR_PULL_GET_MEM_CTX(ndr
);
5455 NDR_PULL_SET_MEM_CTX(ndr
, r
->array
, 0);
5456 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->array
));
5457 size_array_1
= ndr_get_array_size(ndr
, &r
->array
);
5458 NDR_PULL_ALLOC_N(ndr
, r
->array
, size_array_1
);
5459 _mem_save_array_1
= NDR_PULL_GET_MEM_CTX(ndr
);
5460 NDR_PULL_SET_MEM_CTX(ndr
, r
->array
, 0);
5461 for (cntr_array_1
= 0; cntr_array_1
< size_array_1
; cntr_array_1
++) {
5462 NDR_CHECK(ndr_pull_srvsvc_NetShareInfo1007(ndr
, NDR_SCALARS
, &r
->array
[cntr_array_1
]));
5464 for (cntr_array_1
= 0; cntr_array_1
< size_array_1
; cntr_array_1
++) {
5465 NDR_CHECK(ndr_pull_srvsvc_NetShareInfo1007(ndr
, NDR_BUFFERS
, &r
->array
[cntr_array_1
]));
5467 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_array_1
, 0);
5468 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_array_0
, 0);
5471 NDR_CHECK(ndr_check_array_size(ndr
, (void*)&r
->array
, r
->count
));
5474 return NDR_ERR_SUCCESS
;
5477 _PUBLIC_
void ndr_print_srvsvc_NetShareCtr1007(struct ndr_print
*ndr
, const char *name
, const struct srvsvc_NetShareCtr1007
*r
)
5479 uint32_t cntr_array_1
;
5480 ndr_print_struct(ndr
, name
, "srvsvc_NetShareCtr1007");
5482 ndr_print_uint32(ndr
, "count", r
->count
);
5483 ndr_print_ptr(ndr
, "array", r
->array
);
5486 ndr
->print(ndr
, "%s: ARRAY(%d)", "array", (int)r
->count
);
5488 for (cntr_array_1
=0;cntr_array_1
<r
->count
;cntr_array_1
++) {
5490 if (asprintf(&idx_1
, "[%d]", cntr_array_1
) != -1) {
5491 ndr_print_srvsvc_NetShareInfo1007(ndr
, "array", &r
->array
[cntr_array_1
]);
5501 static enum ndr_err_code
ndr_push_srvsvc_NetShareCtr1501(struct ndr_push
*ndr
, int ndr_flags
, const struct srvsvc_NetShareCtr1501
*r
)
5503 uint32_t cntr_array_1
;
5504 if (ndr_flags
& NDR_SCALARS
) {
5505 NDR_CHECK(ndr_push_align(ndr
, 4));
5506 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->count
));
5507 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->array
));
5509 if (ndr_flags
& NDR_BUFFERS
) {
5511 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->count
));
5512 for (cntr_array_1
= 0; cntr_array_1
< r
->count
; cntr_array_1
++) {
5513 NDR_CHECK(ndr_push_sec_desc_buf(ndr
, NDR_SCALARS
, &r
->array
[cntr_array_1
]));
5515 for (cntr_array_1
= 0; cntr_array_1
< r
->count
; cntr_array_1
++) {
5516 NDR_CHECK(ndr_push_sec_desc_buf(ndr
, NDR_BUFFERS
, &r
->array
[cntr_array_1
]));
5520 return NDR_ERR_SUCCESS
;
5523 static enum ndr_err_code
ndr_pull_srvsvc_NetShareCtr1501(struct ndr_pull
*ndr
, int ndr_flags
, struct srvsvc_NetShareCtr1501
*r
)
5525 uint32_t _ptr_array
;
5526 uint32_t size_array_1
= 0;
5527 uint32_t cntr_array_1
;
5528 TALLOC_CTX
*_mem_save_array_0
;
5529 TALLOC_CTX
*_mem_save_array_1
;
5530 if (ndr_flags
& NDR_SCALARS
) {
5531 NDR_CHECK(ndr_pull_align(ndr
, 4));
5532 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->count
));
5533 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_array
));
5535 NDR_PULL_ALLOC(ndr
, r
->array
);
5540 if (ndr_flags
& NDR_BUFFERS
) {
5542 _mem_save_array_0
= NDR_PULL_GET_MEM_CTX(ndr
);
5543 NDR_PULL_SET_MEM_CTX(ndr
, r
->array
, 0);
5544 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->array
));
5545 size_array_1
= ndr_get_array_size(ndr
, &r
->array
);
5546 NDR_PULL_ALLOC_N(ndr
, r
->array
, size_array_1
);
5547 _mem_save_array_1
= NDR_PULL_GET_MEM_CTX(ndr
);
5548 NDR_PULL_SET_MEM_CTX(ndr
, r
->array
, 0);
5549 for (cntr_array_1
= 0; cntr_array_1
< size_array_1
; cntr_array_1
++) {
5550 NDR_CHECK(ndr_pull_sec_desc_buf(ndr
, NDR_SCALARS
, &r
->array
[cntr_array_1
]));
5552 for (cntr_array_1
= 0; cntr_array_1
< size_array_1
; cntr_array_1
++) {
5553 NDR_CHECK(ndr_pull_sec_desc_buf(ndr
, NDR_BUFFERS
, &r
->array
[cntr_array_1
]));
5555 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_array_1
, 0);
5556 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_array_0
, 0);
5559 NDR_CHECK(ndr_check_array_size(ndr
, (void*)&r
->array
, r
->count
));
5562 return NDR_ERR_SUCCESS
;
5565 _PUBLIC_
void ndr_print_srvsvc_NetShareCtr1501(struct ndr_print
*ndr
, const char *name
, const struct srvsvc_NetShareCtr1501
*r
)
5567 uint32_t cntr_array_1
;
5568 ndr_print_struct(ndr
, name
, "srvsvc_NetShareCtr1501");
5570 ndr_print_uint32(ndr
, "count", r
->count
);
5571 ndr_print_ptr(ndr
, "array", r
->array
);
5574 ndr
->print(ndr
, "%s: ARRAY(%d)", "array", (int)r
->count
);
5576 for (cntr_array_1
=0;cntr_array_1
<r
->count
;cntr_array_1
++) {
5578 if (asprintf(&idx_1
, "[%d]", cntr_array_1
) != -1) {
5579 ndr_print_sec_desc_buf(ndr
, "array", &r
->array
[cntr_array_1
]);
5589 static enum ndr_err_code
ndr_push_srvsvc_NetShareInfo(struct ndr_push
*ndr
, int ndr_flags
, const union srvsvc_NetShareInfo
*r
)
5591 if (ndr_flags
& NDR_SCALARS
) {
5592 int level
= ndr_push_get_switch_value(ndr
, r
);
5593 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, level
));
5596 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->info0
));
5600 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->info1
));
5604 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->info2
));
5608 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->info501
));
5612 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->info502
));
5616 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->info1004
));
5620 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->info1005
));
5624 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->info1006
));
5628 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->info1007
));
5632 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->info1501
));
5640 if (ndr_flags
& NDR_BUFFERS
) {
5641 int level
= ndr_push_get_switch_value(ndr
, r
);
5645 NDR_CHECK(ndr_push_srvsvc_NetShareInfo0(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->info0
));
5651 NDR_CHECK(ndr_push_srvsvc_NetShareInfo1(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->info1
));
5657 NDR_CHECK(ndr_push_srvsvc_NetShareInfo2(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->info2
));
5663 NDR_CHECK(ndr_push_srvsvc_NetShareInfo501(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->info501
));
5669 NDR_CHECK(ndr_push_srvsvc_NetShareInfo502(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->info502
));
5675 NDR_CHECK(ndr_push_srvsvc_NetShareInfo1004(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->info1004
));
5681 NDR_CHECK(ndr_push_srvsvc_NetShareInfo1005(ndr
, NDR_SCALARS
, r
->info1005
));
5687 NDR_CHECK(ndr_push_srvsvc_NetShareInfo1006(ndr
, NDR_SCALARS
, r
->info1006
));
5693 NDR_CHECK(ndr_push_srvsvc_NetShareInfo1007(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->info1007
));
5699 NDR_CHECK(ndr_push_sec_desc_buf(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->info1501
));
5708 return NDR_ERR_SUCCESS
;
5711 static enum ndr_err_code
ndr_pull_srvsvc_NetShareInfo(struct ndr_pull
*ndr
, int ndr_flags
, union srvsvc_NetShareInfo
*r
)
5715 TALLOC_CTX
*_mem_save_info0_0
;
5716 uint32_t _ptr_info0
;
5717 TALLOC_CTX
*_mem_save_info1_0
;
5718 uint32_t _ptr_info1
;
5719 TALLOC_CTX
*_mem_save_info2_0
;
5720 uint32_t _ptr_info2
;
5721 TALLOC_CTX
*_mem_save_info501_0
;
5722 uint32_t _ptr_info501
;
5723 TALLOC_CTX
*_mem_save_info502_0
;
5724 uint32_t _ptr_info502
;
5725 TALLOC_CTX
*_mem_save_info1004_0
;
5726 uint32_t _ptr_info1004
;
5727 TALLOC_CTX
*_mem_save_info1005_0
;
5728 uint32_t _ptr_info1005
;
5729 TALLOC_CTX
*_mem_save_info1006_0
;
5730 uint32_t _ptr_info1006
;
5731 TALLOC_CTX
*_mem_save_info1007_0
;
5732 uint32_t _ptr_info1007
;
5733 TALLOC_CTX
*_mem_save_info1501_0
;
5734 uint32_t _ptr_info1501
;
5735 level
= ndr_pull_get_switch_value(ndr
, r
);
5736 if (ndr_flags
& NDR_SCALARS
) {
5737 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &_level
));
5738 if (_level
!= level
) {
5739 return ndr_pull_error(ndr
, NDR_ERR_BAD_SWITCH
, "Bad switch value %u for r", _level
);
5743 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_info0
));
5745 NDR_PULL_ALLOC(ndr
, r
->info0
);
5752 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_info1
));
5754 NDR_PULL_ALLOC(ndr
, r
->info1
);
5761 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_info2
));
5763 NDR_PULL_ALLOC(ndr
, r
->info2
);
5770 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_info501
));
5772 NDR_PULL_ALLOC(ndr
, r
->info501
);
5779 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_info502
));
5781 NDR_PULL_ALLOC(ndr
, r
->info502
);
5788 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_info1004
));
5789 if (_ptr_info1004
) {
5790 NDR_PULL_ALLOC(ndr
, r
->info1004
);
5797 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_info1005
));
5798 if (_ptr_info1005
) {
5799 NDR_PULL_ALLOC(ndr
, r
->info1005
);
5806 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_info1006
));
5807 if (_ptr_info1006
) {
5808 NDR_PULL_ALLOC(ndr
, r
->info1006
);
5815 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_info1007
));
5816 if (_ptr_info1007
) {
5817 NDR_PULL_ALLOC(ndr
, r
->info1007
);
5824 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_info1501
));
5825 if (_ptr_info1501
) {
5826 NDR_PULL_ALLOC(ndr
, r
->info1501
);
5837 if (ndr_flags
& NDR_BUFFERS
) {
5841 _mem_save_info0_0
= NDR_PULL_GET_MEM_CTX(ndr
);
5842 NDR_PULL_SET_MEM_CTX(ndr
, r
->info0
, 0);
5843 NDR_CHECK(ndr_pull_srvsvc_NetShareInfo0(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->info0
));
5844 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_info0_0
, 0);
5850 _mem_save_info1_0
= NDR_PULL_GET_MEM_CTX(ndr
);
5851 NDR_PULL_SET_MEM_CTX(ndr
, r
->info1
, 0);
5852 NDR_CHECK(ndr_pull_srvsvc_NetShareInfo1(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->info1
));
5853 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_info1_0
, 0);
5859 _mem_save_info2_0
= NDR_PULL_GET_MEM_CTX(ndr
);
5860 NDR_PULL_SET_MEM_CTX(ndr
, r
->info2
, 0);
5861 NDR_CHECK(ndr_pull_srvsvc_NetShareInfo2(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->info2
));
5862 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_info2_0
, 0);
5868 _mem_save_info501_0
= NDR_PULL_GET_MEM_CTX(ndr
);
5869 NDR_PULL_SET_MEM_CTX(ndr
, r
->info501
, 0);
5870 NDR_CHECK(ndr_pull_srvsvc_NetShareInfo501(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->info501
));
5871 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_info501_0
, 0);
5877 _mem_save_info502_0
= NDR_PULL_GET_MEM_CTX(ndr
);
5878 NDR_PULL_SET_MEM_CTX(ndr
, r
->info502
, 0);
5879 NDR_CHECK(ndr_pull_srvsvc_NetShareInfo502(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->info502
));
5880 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_info502_0
, 0);
5886 _mem_save_info1004_0
= NDR_PULL_GET_MEM_CTX(ndr
);
5887 NDR_PULL_SET_MEM_CTX(ndr
, r
->info1004
, 0);
5888 NDR_CHECK(ndr_pull_srvsvc_NetShareInfo1004(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->info1004
));
5889 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_info1004_0
, 0);
5895 _mem_save_info1005_0
= NDR_PULL_GET_MEM_CTX(ndr
);
5896 NDR_PULL_SET_MEM_CTX(ndr
, r
->info1005
, 0);
5897 NDR_CHECK(ndr_pull_srvsvc_NetShareInfo1005(ndr
, NDR_SCALARS
, r
->info1005
));
5898 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_info1005_0
, 0);
5904 _mem_save_info1006_0
= NDR_PULL_GET_MEM_CTX(ndr
);
5905 NDR_PULL_SET_MEM_CTX(ndr
, r
->info1006
, 0);
5906 NDR_CHECK(ndr_pull_srvsvc_NetShareInfo1006(ndr
, NDR_SCALARS
, r
->info1006
));
5907 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_info1006_0
, 0);
5913 _mem_save_info1007_0
= NDR_PULL_GET_MEM_CTX(ndr
);
5914 NDR_PULL_SET_MEM_CTX(ndr
, r
->info1007
, 0);
5915 NDR_CHECK(ndr_pull_srvsvc_NetShareInfo1007(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->info1007
));
5916 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_info1007_0
, 0);
5922 _mem_save_info1501_0
= NDR_PULL_GET_MEM_CTX(ndr
);
5923 NDR_PULL_SET_MEM_CTX(ndr
, r
->info1501
, 0);
5924 NDR_CHECK(ndr_pull_sec_desc_buf(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->info1501
));
5925 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_info1501_0
, 0);
5934 return NDR_ERR_SUCCESS
;
5937 _PUBLIC_
void ndr_print_srvsvc_NetShareInfo(struct ndr_print
*ndr
, const char *name
, const union srvsvc_NetShareInfo
*r
)
5940 level
= ndr_print_get_switch_value(ndr
, r
);
5941 ndr_print_union(ndr
, name
, level
, "srvsvc_NetShareInfo");
5944 ndr_print_ptr(ndr
, "info0", r
->info0
);
5947 ndr_print_srvsvc_NetShareInfo0(ndr
, "info0", r
->info0
);
5953 ndr_print_ptr(ndr
, "info1", r
->info1
);
5956 ndr_print_srvsvc_NetShareInfo1(ndr
, "info1", r
->info1
);
5962 ndr_print_ptr(ndr
, "info2", r
->info2
);
5965 ndr_print_srvsvc_NetShareInfo2(ndr
, "info2", r
->info2
);
5971 ndr_print_ptr(ndr
, "info501", r
->info501
);
5974 ndr_print_srvsvc_NetShareInfo501(ndr
, "info501", r
->info501
);
5980 ndr_print_ptr(ndr
, "info502", r
->info502
);
5983 ndr_print_srvsvc_NetShareInfo502(ndr
, "info502", r
->info502
);
5989 ndr_print_ptr(ndr
, "info1004", r
->info1004
);
5992 ndr_print_srvsvc_NetShareInfo1004(ndr
, "info1004", r
->info1004
);
5998 ndr_print_ptr(ndr
, "info1005", r
->info1005
);
6001 ndr_print_srvsvc_NetShareInfo1005(ndr
, "info1005", r
->info1005
);
6007 ndr_print_ptr(ndr
, "info1006", r
->info1006
);
6010 ndr_print_srvsvc_NetShareInfo1006(ndr
, "info1006", r
->info1006
);
6016 ndr_print_ptr(ndr
, "info1007", r
->info1007
);
6019 ndr_print_srvsvc_NetShareInfo1007(ndr
, "info1007", r
->info1007
);
6025 ndr_print_ptr(ndr
, "info1501", r
->info1501
);
6028 ndr_print_sec_desc_buf(ndr
, "info1501", r
->info1501
);
6039 static enum ndr_err_code
ndr_push_srvsvc_NetShareCtr(struct ndr_push
*ndr
, int ndr_flags
, const union srvsvc_NetShareCtr
*r
)
6041 if (ndr_flags
& NDR_SCALARS
) {
6042 int level
= ndr_push_get_switch_value(ndr
, r
);
6043 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, level
));
6046 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->ctr0
));
6050 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->ctr1
));
6054 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->ctr2
));
6058 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->ctr501
));
6062 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->ctr502
));
6066 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->ctr1004
));
6070 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->ctr1005
));
6074 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->ctr1006
));
6078 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->ctr1007
));
6082 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->ctr1501
));
6090 if (ndr_flags
& NDR_BUFFERS
) {
6091 int level
= ndr_push_get_switch_value(ndr
, r
);
6095 NDR_CHECK(ndr_push_srvsvc_NetShareCtr0(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->ctr0
));
6101 NDR_CHECK(ndr_push_srvsvc_NetShareCtr1(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->ctr1
));
6107 NDR_CHECK(ndr_push_srvsvc_NetShareCtr2(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->ctr2
));
6113 NDR_CHECK(ndr_push_srvsvc_NetShareCtr501(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->ctr501
));
6119 NDR_CHECK(ndr_push_srvsvc_NetShareCtr502(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->ctr502
));
6125 NDR_CHECK(ndr_push_srvsvc_NetShareCtr1004(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->ctr1004
));
6131 NDR_CHECK(ndr_push_srvsvc_NetShareCtr1005(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->ctr1005
));
6137 NDR_CHECK(ndr_push_srvsvc_NetShareCtr1006(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->ctr1006
));
6143 NDR_CHECK(ndr_push_srvsvc_NetShareCtr1007(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->ctr1007
));
6149 NDR_CHECK(ndr_push_srvsvc_NetShareCtr1501(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->ctr1501
));
6158 return NDR_ERR_SUCCESS
;
6161 static enum ndr_err_code
ndr_pull_srvsvc_NetShareCtr(struct ndr_pull
*ndr
, int ndr_flags
, union srvsvc_NetShareCtr
*r
)
6165 TALLOC_CTX
*_mem_save_ctr0_0
;
6167 TALLOC_CTX
*_mem_save_ctr1_0
;
6169 TALLOC_CTX
*_mem_save_ctr2_0
;
6171 TALLOC_CTX
*_mem_save_ctr501_0
;
6172 uint32_t _ptr_ctr501
;
6173 TALLOC_CTX
*_mem_save_ctr502_0
;
6174 uint32_t _ptr_ctr502
;
6175 TALLOC_CTX
*_mem_save_ctr1004_0
;
6176 uint32_t _ptr_ctr1004
;
6177 TALLOC_CTX
*_mem_save_ctr1005_0
;
6178 uint32_t _ptr_ctr1005
;
6179 TALLOC_CTX
*_mem_save_ctr1006_0
;
6180 uint32_t _ptr_ctr1006
;
6181 TALLOC_CTX
*_mem_save_ctr1007_0
;
6182 uint32_t _ptr_ctr1007
;
6183 TALLOC_CTX
*_mem_save_ctr1501_0
;
6184 uint32_t _ptr_ctr1501
;
6185 level
= ndr_pull_get_switch_value(ndr
, r
);
6186 if (ndr_flags
& NDR_SCALARS
) {
6187 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &_level
));
6188 if (_level
!= level
) {
6189 return ndr_pull_error(ndr
, NDR_ERR_BAD_SWITCH
, "Bad switch value %u for r", _level
);
6193 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_ctr0
));
6195 NDR_PULL_ALLOC(ndr
, r
->ctr0
);
6202 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_ctr1
));
6204 NDR_PULL_ALLOC(ndr
, r
->ctr1
);
6211 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_ctr2
));
6213 NDR_PULL_ALLOC(ndr
, r
->ctr2
);
6220 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_ctr501
));
6222 NDR_PULL_ALLOC(ndr
, r
->ctr501
);
6229 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_ctr502
));
6231 NDR_PULL_ALLOC(ndr
, r
->ctr502
);
6238 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_ctr1004
));
6240 NDR_PULL_ALLOC(ndr
, r
->ctr1004
);
6247 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_ctr1005
));
6249 NDR_PULL_ALLOC(ndr
, r
->ctr1005
);
6256 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_ctr1006
));
6258 NDR_PULL_ALLOC(ndr
, r
->ctr1006
);
6265 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_ctr1007
));
6267 NDR_PULL_ALLOC(ndr
, r
->ctr1007
);
6274 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_ctr1501
));
6276 NDR_PULL_ALLOC(ndr
, r
->ctr1501
);
6287 if (ndr_flags
& NDR_BUFFERS
) {
6291 _mem_save_ctr0_0
= NDR_PULL_GET_MEM_CTX(ndr
);
6292 NDR_PULL_SET_MEM_CTX(ndr
, r
->ctr0
, 0);
6293 NDR_CHECK(ndr_pull_srvsvc_NetShareCtr0(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->ctr0
));
6294 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_ctr0_0
, 0);
6300 _mem_save_ctr1_0
= NDR_PULL_GET_MEM_CTX(ndr
);
6301 NDR_PULL_SET_MEM_CTX(ndr
, r
->ctr1
, 0);
6302 NDR_CHECK(ndr_pull_srvsvc_NetShareCtr1(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->ctr1
));
6303 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_ctr1_0
, 0);
6309 _mem_save_ctr2_0
= NDR_PULL_GET_MEM_CTX(ndr
);
6310 NDR_PULL_SET_MEM_CTX(ndr
, r
->ctr2
, 0);
6311 NDR_CHECK(ndr_pull_srvsvc_NetShareCtr2(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->ctr2
));
6312 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_ctr2_0
, 0);
6318 _mem_save_ctr501_0
= NDR_PULL_GET_MEM_CTX(ndr
);
6319 NDR_PULL_SET_MEM_CTX(ndr
, r
->ctr501
, 0);
6320 NDR_CHECK(ndr_pull_srvsvc_NetShareCtr501(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->ctr501
));
6321 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_ctr501_0
, 0);
6327 _mem_save_ctr502_0
= NDR_PULL_GET_MEM_CTX(ndr
);
6328 NDR_PULL_SET_MEM_CTX(ndr
, r
->ctr502
, 0);
6329 NDR_CHECK(ndr_pull_srvsvc_NetShareCtr502(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->ctr502
));
6330 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_ctr502_0
, 0);
6336 _mem_save_ctr1004_0
= NDR_PULL_GET_MEM_CTX(ndr
);
6337 NDR_PULL_SET_MEM_CTX(ndr
, r
->ctr1004
, 0);
6338 NDR_CHECK(ndr_pull_srvsvc_NetShareCtr1004(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->ctr1004
));
6339 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_ctr1004_0
, 0);
6345 _mem_save_ctr1005_0
= NDR_PULL_GET_MEM_CTX(ndr
);
6346 NDR_PULL_SET_MEM_CTX(ndr
, r
->ctr1005
, 0);
6347 NDR_CHECK(ndr_pull_srvsvc_NetShareCtr1005(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->ctr1005
));
6348 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_ctr1005_0
, 0);
6354 _mem_save_ctr1006_0
= NDR_PULL_GET_MEM_CTX(ndr
);
6355 NDR_PULL_SET_MEM_CTX(ndr
, r
->ctr1006
, 0);
6356 NDR_CHECK(ndr_pull_srvsvc_NetShareCtr1006(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->ctr1006
));
6357 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_ctr1006_0
, 0);
6363 _mem_save_ctr1007_0
= NDR_PULL_GET_MEM_CTX(ndr
);
6364 NDR_PULL_SET_MEM_CTX(ndr
, r
->ctr1007
, 0);
6365 NDR_CHECK(ndr_pull_srvsvc_NetShareCtr1007(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->ctr1007
));
6366 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_ctr1007_0
, 0);
6372 _mem_save_ctr1501_0
= NDR_PULL_GET_MEM_CTX(ndr
);
6373 NDR_PULL_SET_MEM_CTX(ndr
, r
->ctr1501
, 0);
6374 NDR_CHECK(ndr_pull_srvsvc_NetShareCtr1501(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->ctr1501
));
6375 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_ctr1501_0
, 0);
6384 return NDR_ERR_SUCCESS
;
6387 _PUBLIC_
void ndr_print_srvsvc_NetShareCtr(struct ndr_print
*ndr
, const char *name
, const union srvsvc_NetShareCtr
*r
)
6390 level
= ndr_print_get_switch_value(ndr
, r
);
6391 ndr_print_union(ndr
, name
, level
, "srvsvc_NetShareCtr");
6394 ndr_print_ptr(ndr
, "ctr0", r
->ctr0
);
6397 ndr_print_srvsvc_NetShareCtr0(ndr
, "ctr0", r
->ctr0
);
6403 ndr_print_ptr(ndr
, "ctr1", r
->ctr1
);
6406 ndr_print_srvsvc_NetShareCtr1(ndr
, "ctr1", r
->ctr1
);
6412 ndr_print_ptr(ndr
, "ctr2", r
->ctr2
);
6415 ndr_print_srvsvc_NetShareCtr2(ndr
, "ctr2", r
->ctr2
);
6421 ndr_print_ptr(ndr
, "ctr501", r
->ctr501
);
6424 ndr_print_srvsvc_NetShareCtr501(ndr
, "ctr501", r
->ctr501
);
6430 ndr_print_ptr(ndr
, "ctr502", r
->ctr502
);
6433 ndr_print_srvsvc_NetShareCtr502(ndr
, "ctr502", r
->ctr502
);
6439 ndr_print_ptr(ndr
, "ctr1004", r
->ctr1004
);
6442 ndr_print_srvsvc_NetShareCtr1004(ndr
, "ctr1004", r
->ctr1004
);
6448 ndr_print_ptr(ndr
, "ctr1005", r
->ctr1005
);
6451 ndr_print_srvsvc_NetShareCtr1005(ndr
, "ctr1005", r
->ctr1005
);
6457 ndr_print_ptr(ndr
, "ctr1006", r
->ctr1006
);
6460 ndr_print_srvsvc_NetShareCtr1006(ndr
, "ctr1006", r
->ctr1006
);
6466 ndr_print_ptr(ndr
, "ctr1007", r
->ctr1007
);
6469 ndr_print_srvsvc_NetShareCtr1007(ndr
, "ctr1007", r
->ctr1007
);
6475 ndr_print_ptr(ndr
, "ctr1501", r
->ctr1501
);
6478 ndr_print_srvsvc_NetShareCtr1501(ndr
, "ctr1501", r
->ctr1501
);
6489 static enum ndr_err_code
ndr_push_srvsvc_NetShareInfoCtr(struct ndr_push
*ndr
, int ndr_flags
, const struct srvsvc_NetShareInfoCtr
*r
)
6491 if (ndr_flags
& NDR_SCALARS
) {
6492 NDR_CHECK(ndr_push_align(ndr
, 4));
6493 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->level
));
6494 NDR_CHECK(ndr_push_set_switch_value(ndr
, &r
->ctr
, r
->level
));
6495 NDR_CHECK(ndr_push_srvsvc_NetShareCtr(ndr
, NDR_SCALARS
, &r
->ctr
));
6497 if (ndr_flags
& NDR_BUFFERS
) {
6498 NDR_CHECK(ndr_push_srvsvc_NetShareCtr(ndr
, NDR_BUFFERS
, &r
->ctr
));
6500 return NDR_ERR_SUCCESS
;
6503 static enum ndr_err_code
ndr_pull_srvsvc_NetShareInfoCtr(struct ndr_pull
*ndr
, int ndr_flags
, struct srvsvc_NetShareInfoCtr
*r
)
6505 if (ndr_flags
& NDR_SCALARS
) {
6506 NDR_CHECK(ndr_pull_align(ndr
, 4));
6507 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->level
));
6508 NDR_CHECK(ndr_pull_set_switch_value(ndr
, &r
->ctr
, r
->level
));
6509 NDR_CHECK(ndr_pull_srvsvc_NetShareCtr(ndr
, NDR_SCALARS
, &r
->ctr
));
6511 if (ndr_flags
& NDR_BUFFERS
) {
6512 NDR_CHECK(ndr_pull_srvsvc_NetShareCtr(ndr
, NDR_BUFFERS
, &r
->ctr
));
6514 return NDR_ERR_SUCCESS
;
6517 _PUBLIC_
void ndr_print_srvsvc_NetShareInfoCtr(struct ndr_print
*ndr
, const char *name
, const struct srvsvc_NetShareInfoCtr
*r
)
6519 ndr_print_struct(ndr
, name
, "srvsvc_NetShareInfoCtr");
6521 ndr_print_uint32(ndr
, "level", r
->level
);
6522 ndr_print_set_switch_value(ndr
, &r
->ctr
, r
->level
);
6523 ndr_print_srvsvc_NetShareCtr(ndr
, "ctr", &r
->ctr
);
6527 _PUBLIC_
enum ndr_err_code
ndr_push_srvsvc_PlatformId(struct ndr_push
*ndr
, int ndr_flags
, enum srvsvc_PlatformId r
)
6529 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
));
6530 return NDR_ERR_SUCCESS
;
6533 _PUBLIC_
enum ndr_err_code
ndr_pull_srvsvc_PlatformId(struct ndr_pull
*ndr
, int ndr_flags
, enum srvsvc_PlatformId
*r
)
6536 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &v
));
6538 return NDR_ERR_SUCCESS
;
6541 _PUBLIC_
void ndr_print_srvsvc_PlatformId(struct ndr_print
*ndr
, const char *name
, enum srvsvc_PlatformId r
)
6543 const char *val
= NULL
;
6546 case PLATFORM_ID_DOS
: val
= "PLATFORM_ID_DOS"; break;
6547 case PLATFORM_ID_OS2
: val
= "PLATFORM_ID_OS2"; break;
6548 case PLATFORM_ID_NT
: val
= "PLATFORM_ID_NT"; break;
6549 case PLATFORM_ID_OSF
: val
= "PLATFORM_ID_OSF"; break;
6550 case PLATFORM_ID_VMS
: val
= "PLATFORM_ID_VMS"; break;
6552 ndr_print_enum(ndr
, name
, "ENUM", val
, r
);
6555 _PUBLIC_
enum ndr_err_code
ndr_push_srvsvc_NetSrvInfo100(struct ndr_push
*ndr
, int ndr_flags
, const struct srvsvc_NetSrvInfo100
*r
)
6557 if (ndr_flags
& NDR_SCALARS
) {
6558 NDR_CHECK(ndr_push_align(ndr
, 4));
6559 NDR_CHECK(ndr_push_srvsvc_PlatformId(ndr
, NDR_SCALARS
, r
->platform_id
));
6560 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->server_name
));
6562 if (ndr_flags
& NDR_BUFFERS
) {
6563 if (r
->server_name
) {
6564 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->server_name
, CH_UTF16
)));
6565 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
6566 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->server_name
, CH_UTF16
)));
6567 NDR_CHECK(ndr_push_charset(ndr
, NDR_SCALARS
, r
->server_name
, ndr_charset_length(r
->server_name
, CH_UTF16
), sizeof(uint16_t), CH_UTF16
));
6570 return NDR_ERR_SUCCESS
;
6573 _PUBLIC_
enum ndr_err_code
ndr_pull_srvsvc_NetSrvInfo100(struct ndr_pull
*ndr
, int ndr_flags
, struct srvsvc_NetSrvInfo100
*r
)
6575 uint32_t _ptr_server_name
;
6576 uint32_t size_server_name_1
= 0;
6577 uint32_t length_server_name_1
= 0;
6578 TALLOC_CTX
*_mem_save_server_name_0
;
6579 if (ndr_flags
& NDR_SCALARS
) {
6580 NDR_CHECK(ndr_pull_align(ndr
, 4));
6581 NDR_CHECK(ndr_pull_srvsvc_PlatformId(ndr
, NDR_SCALARS
, &r
->platform_id
));
6582 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_server_name
));
6583 if (_ptr_server_name
) {
6584 NDR_PULL_ALLOC(ndr
, r
->server_name
);
6586 r
->server_name
= NULL
;
6589 if (ndr_flags
& NDR_BUFFERS
) {
6590 if (r
->server_name
) {
6591 _mem_save_server_name_0
= NDR_PULL_GET_MEM_CTX(ndr
);
6592 NDR_PULL_SET_MEM_CTX(ndr
, r
->server_name
, 0);
6593 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->server_name
));
6594 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->server_name
));
6595 size_server_name_1
= ndr_get_array_size(ndr
, &r
->server_name
);
6596 length_server_name_1
= ndr_get_array_length(ndr
, &r
->server_name
);
6597 if (length_server_name_1
> size_server_name_1
) {
6598 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", size_server_name_1
, length_server_name_1
);
6600 NDR_CHECK(ndr_check_string_terminator(ndr
, length_server_name_1
, sizeof(uint16_t)));
6601 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->server_name
, length_server_name_1
, sizeof(uint16_t), CH_UTF16
));
6602 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_server_name_0
, 0);
6605 return NDR_ERR_SUCCESS
;
6608 _PUBLIC_
void ndr_print_srvsvc_NetSrvInfo100(struct ndr_print
*ndr
, const char *name
, const struct srvsvc_NetSrvInfo100
*r
)
6610 ndr_print_struct(ndr
, name
, "srvsvc_NetSrvInfo100");
6612 ndr_print_srvsvc_PlatformId(ndr
, "platform_id", r
->platform_id
);
6613 ndr_print_ptr(ndr
, "server_name", r
->server_name
);
6615 if (r
->server_name
) {
6616 ndr_print_string(ndr
, "server_name", r
->server_name
);
6622 _PUBLIC_
enum ndr_err_code
ndr_push_srvsvc_NetSrvInfo101(struct ndr_push
*ndr
, int ndr_flags
, const struct srvsvc_NetSrvInfo101
*r
)
6624 if (ndr_flags
& NDR_SCALARS
) {
6625 NDR_CHECK(ndr_push_align(ndr
, 4));
6626 NDR_CHECK(ndr_push_srvsvc_PlatformId(ndr
, NDR_SCALARS
, r
->platform_id
));
6627 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->server_name
));
6628 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->version_major
));
6629 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->version_minor
));
6630 NDR_CHECK(ndr_push_svcctl_ServerType(ndr
, NDR_SCALARS
, r
->server_type
));
6631 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->comment
));
6633 if (ndr_flags
& NDR_BUFFERS
) {
6634 if (r
->server_name
) {
6635 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->server_name
, CH_UTF16
)));
6636 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
6637 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->server_name
, CH_UTF16
)));
6638 NDR_CHECK(ndr_push_charset(ndr
, NDR_SCALARS
, r
->server_name
, ndr_charset_length(r
->server_name
, CH_UTF16
), sizeof(uint16_t), CH_UTF16
));
6641 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->comment
, CH_UTF16
)));
6642 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
6643 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->comment
, CH_UTF16
)));
6644 NDR_CHECK(ndr_push_charset(ndr
, NDR_SCALARS
, r
->comment
, ndr_charset_length(r
->comment
, CH_UTF16
), sizeof(uint16_t), CH_UTF16
));
6647 return NDR_ERR_SUCCESS
;
6650 _PUBLIC_
enum ndr_err_code
ndr_pull_srvsvc_NetSrvInfo101(struct ndr_pull
*ndr
, int ndr_flags
, struct srvsvc_NetSrvInfo101
*r
)
6652 uint32_t _ptr_server_name
;
6653 uint32_t size_server_name_1
= 0;
6654 uint32_t length_server_name_1
= 0;
6655 TALLOC_CTX
*_mem_save_server_name_0
;
6656 uint32_t _ptr_comment
;
6657 uint32_t size_comment_1
= 0;
6658 uint32_t length_comment_1
= 0;
6659 TALLOC_CTX
*_mem_save_comment_0
;
6660 if (ndr_flags
& NDR_SCALARS
) {
6661 NDR_CHECK(ndr_pull_align(ndr
, 4));
6662 NDR_CHECK(ndr_pull_srvsvc_PlatformId(ndr
, NDR_SCALARS
, &r
->platform_id
));
6663 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_server_name
));
6664 if (_ptr_server_name
) {
6665 NDR_PULL_ALLOC(ndr
, r
->server_name
);
6667 r
->server_name
= NULL
;
6669 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->version_major
));
6670 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->version_minor
));
6671 NDR_CHECK(ndr_pull_svcctl_ServerType(ndr
, NDR_SCALARS
, &r
->server_type
));
6672 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_comment
));
6674 NDR_PULL_ALLOC(ndr
, r
->comment
);
6679 if (ndr_flags
& NDR_BUFFERS
) {
6680 if (r
->server_name
) {
6681 _mem_save_server_name_0
= NDR_PULL_GET_MEM_CTX(ndr
);
6682 NDR_PULL_SET_MEM_CTX(ndr
, r
->server_name
, 0);
6683 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->server_name
));
6684 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->server_name
));
6685 size_server_name_1
= ndr_get_array_size(ndr
, &r
->server_name
);
6686 length_server_name_1
= ndr_get_array_length(ndr
, &r
->server_name
);
6687 if (length_server_name_1
> size_server_name_1
) {
6688 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", size_server_name_1
, length_server_name_1
);
6690 NDR_CHECK(ndr_check_string_terminator(ndr
, length_server_name_1
, sizeof(uint16_t)));
6691 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->server_name
, length_server_name_1
, sizeof(uint16_t), CH_UTF16
));
6692 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_server_name_0
, 0);
6695 _mem_save_comment_0
= NDR_PULL_GET_MEM_CTX(ndr
);
6696 NDR_PULL_SET_MEM_CTX(ndr
, r
->comment
, 0);
6697 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->comment
));
6698 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->comment
));
6699 size_comment_1
= ndr_get_array_size(ndr
, &r
->comment
);
6700 length_comment_1
= ndr_get_array_length(ndr
, &r
->comment
);
6701 if (length_comment_1
> size_comment_1
) {
6702 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", size_comment_1
, length_comment_1
);
6704 NDR_CHECK(ndr_check_string_terminator(ndr
, length_comment_1
, sizeof(uint16_t)));
6705 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->comment
, length_comment_1
, sizeof(uint16_t), CH_UTF16
));
6706 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_comment_0
, 0);
6709 return NDR_ERR_SUCCESS
;
6712 _PUBLIC_
void ndr_print_srvsvc_NetSrvInfo101(struct ndr_print
*ndr
, const char *name
, const struct srvsvc_NetSrvInfo101
*r
)
6714 ndr_print_struct(ndr
, name
, "srvsvc_NetSrvInfo101");
6716 ndr_print_srvsvc_PlatformId(ndr
, "platform_id", r
->platform_id
);
6717 ndr_print_ptr(ndr
, "server_name", r
->server_name
);
6719 if (r
->server_name
) {
6720 ndr_print_string(ndr
, "server_name", r
->server_name
);
6723 ndr_print_uint32(ndr
, "version_major", r
->version_major
);
6724 ndr_print_uint32(ndr
, "version_minor", r
->version_minor
);
6725 ndr_print_svcctl_ServerType(ndr
, "server_type", r
->server_type
);
6726 ndr_print_ptr(ndr
, "comment", r
->comment
);
6729 ndr_print_string(ndr
, "comment", r
->comment
);
6735 static enum ndr_err_code
ndr_push_srvsvc_NetSrvInfo102(struct ndr_push
*ndr
, int ndr_flags
, const struct srvsvc_NetSrvInfo102
*r
)
6737 if (ndr_flags
& NDR_SCALARS
) {
6738 NDR_CHECK(ndr_push_align(ndr
, 4));
6739 NDR_CHECK(ndr_push_srvsvc_PlatformId(ndr
, NDR_SCALARS
, r
->platform_id
));
6740 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->server_name
));
6741 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->version_major
));
6742 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->version_minor
));
6743 NDR_CHECK(ndr_push_svcctl_ServerType(ndr
, NDR_SCALARS
, r
->server_type
));
6744 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->comment
));
6745 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->users
));
6746 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->disc
));
6747 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->hidden
));
6748 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->announce
));
6749 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->anndelta
));
6750 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->licenses
));
6751 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->userpath
));
6753 if (ndr_flags
& NDR_BUFFERS
) {
6754 if (r
->server_name
) {
6755 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->server_name
, CH_UTF16
)));
6756 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
6757 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->server_name
, CH_UTF16
)));
6758 NDR_CHECK(ndr_push_charset(ndr
, NDR_SCALARS
, r
->server_name
, ndr_charset_length(r
->server_name
, CH_UTF16
), sizeof(uint16_t), CH_UTF16
));
6761 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->comment
, CH_UTF16
)));
6762 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
6763 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->comment
, CH_UTF16
)));
6764 NDR_CHECK(ndr_push_charset(ndr
, NDR_SCALARS
, r
->comment
, ndr_charset_length(r
->comment
, CH_UTF16
), sizeof(uint16_t), CH_UTF16
));
6767 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->userpath
, CH_UTF16
)));
6768 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
6769 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->userpath
, CH_UTF16
)));
6770 NDR_CHECK(ndr_push_charset(ndr
, NDR_SCALARS
, r
->userpath
, ndr_charset_length(r
->userpath
, CH_UTF16
), sizeof(uint16_t), CH_UTF16
));
6773 return NDR_ERR_SUCCESS
;
6776 static enum ndr_err_code
ndr_pull_srvsvc_NetSrvInfo102(struct ndr_pull
*ndr
, int ndr_flags
, struct srvsvc_NetSrvInfo102
*r
)
6778 uint32_t _ptr_server_name
;
6779 uint32_t size_server_name_1
= 0;
6780 uint32_t length_server_name_1
= 0;
6781 TALLOC_CTX
*_mem_save_server_name_0
;
6782 uint32_t _ptr_comment
;
6783 uint32_t size_comment_1
= 0;
6784 uint32_t length_comment_1
= 0;
6785 TALLOC_CTX
*_mem_save_comment_0
;
6786 uint32_t _ptr_userpath
;
6787 uint32_t size_userpath_1
= 0;
6788 uint32_t length_userpath_1
= 0;
6789 TALLOC_CTX
*_mem_save_userpath_0
;
6790 if (ndr_flags
& NDR_SCALARS
) {
6791 NDR_CHECK(ndr_pull_align(ndr
, 4));
6792 NDR_CHECK(ndr_pull_srvsvc_PlatformId(ndr
, NDR_SCALARS
, &r
->platform_id
));
6793 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_server_name
));
6794 if (_ptr_server_name
) {
6795 NDR_PULL_ALLOC(ndr
, r
->server_name
);
6797 r
->server_name
= NULL
;
6799 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->version_major
));
6800 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->version_minor
));
6801 NDR_CHECK(ndr_pull_svcctl_ServerType(ndr
, NDR_SCALARS
, &r
->server_type
));
6802 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_comment
));
6804 NDR_PULL_ALLOC(ndr
, r
->comment
);
6808 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->users
));
6809 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->disc
));
6810 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->hidden
));
6811 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->announce
));
6812 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->anndelta
));
6813 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->licenses
));
6814 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_userpath
));
6815 if (_ptr_userpath
) {
6816 NDR_PULL_ALLOC(ndr
, r
->userpath
);
6821 if (ndr_flags
& NDR_BUFFERS
) {
6822 if (r
->server_name
) {
6823 _mem_save_server_name_0
= NDR_PULL_GET_MEM_CTX(ndr
);
6824 NDR_PULL_SET_MEM_CTX(ndr
, r
->server_name
, 0);
6825 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->server_name
));
6826 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->server_name
));
6827 size_server_name_1
= ndr_get_array_size(ndr
, &r
->server_name
);
6828 length_server_name_1
= ndr_get_array_length(ndr
, &r
->server_name
);
6829 if (length_server_name_1
> size_server_name_1
) {
6830 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", size_server_name_1
, length_server_name_1
);
6832 NDR_CHECK(ndr_check_string_terminator(ndr
, length_server_name_1
, sizeof(uint16_t)));
6833 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->server_name
, length_server_name_1
, sizeof(uint16_t), CH_UTF16
));
6834 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_server_name_0
, 0);
6837 _mem_save_comment_0
= NDR_PULL_GET_MEM_CTX(ndr
);
6838 NDR_PULL_SET_MEM_CTX(ndr
, r
->comment
, 0);
6839 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->comment
));
6840 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->comment
));
6841 size_comment_1
= ndr_get_array_size(ndr
, &r
->comment
);
6842 length_comment_1
= ndr_get_array_length(ndr
, &r
->comment
);
6843 if (length_comment_1
> size_comment_1
) {
6844 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", size_comment_1
, length_comment_1
);
6846 NDR_CHECK(ndr_check_string_terminator(ndr
, length_comment_1
, sizeof(uint16_t)));
6847 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->comment
, length_comment_1
, sizeof(uint16_t), CH_UTF16
));
6848 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_comment_0
, 0);
6851 _mem_save_userpath_0
= NDR_PULL_GET_MEM_CTX(ndr
);
6852 NDR_PULL_SET_MEM_CTX(ndr
, r
->userpath
, 0);
6853 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->userpath
));
6854 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->userpath
));
6855 size_userpath_1
= ndr_get_array_size(ndr
, &r
->userpath
);
6856 length_userpath_1
= ndr_get_array_length(ndr
, &r
->userpath
);
6857 if (length_userpath_1
> size_userpath_1
) {
6858 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", size_userpath_1
, length_userpath_1
);
6860 NDR_CHECK(ndr_check_string_terminator(ndr
, length_userpath_1
, sizeof(uint16_t)));
6861 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->userpath
, length_userpath_1
, sizeof(uint16_t), CH_UTF16
));
6862 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_userpath_0
, 0);
6865 return NDR_ERR_SUCCESS
;
6868 _PUBLIC_
void ndr_print_srvsvc_NetSrvInfo102(struct ndr_print
*ndr
, const char *name
, const struct srvsvc_NetSrvInfo102
*r
)
6870 ndr_print_struct(ndr
, name
, "srvsvc_NetSrvInfo102");
6872 ndr_print_srvsvc_PlatformId(ndr
, "platform_id", r
->platform_id
);
6873 ndr_print_ptr(ndr
, "server_name", r
->server_name
);
6875 if (r
->server_name
) {
6876 ndr_print_string(ndr
, "server_name", r
->server_name
);
6879 ndr_print_uint32(ndr
, "version_major", r
->version_major
);
6880 ndr_print_uint32(ndr
, "version_minor", r
->version_minor
);
6881 ndr_print_svcctl_ServerType(ndr
, "server_type", r
->server_type
);
6882 ndr_print_ptr(ndr
, "comment", r
->comment
);
6885 ndr_print_string(ndr
, "comment", r
->comment
);
6888 ndr_print_uint32(ndr
, "users", r
->users
);
6889 ndr_print_uint32(ndr
, "disc", r
->disc
);
6890 ndr_print_uint32(ndr
, "hidden", r
->hidden
);
6891 ndr_print_uint32(ndr
, "announce", r
->announce
);
6892 ndr_print_uint32(ndr
, "anndelta", r
->anndelta
);
6893 ndr_print_uint32(ndr
, "licenses", r
->licenses
);
6894 ndr_print_ptr(ndr
, "userpath", r
->userpath
);
6897 ndr_print_string(ndr
, "userpath", r
->userpath
);
6903 static enum ndr_err_code
ndr_push_srvsvc_NetSrvInfo402(struct ndr_push
*ndr
, int ndr_flags
, const struct srvsvc_NetSrvInfo402
*r
)
6905 if (ndr_flags
& NDR_SCALARS
) {
6906 NDR_CHECK(ndr_push_align(ndr
, 4));
6907 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->ulist_mtime
));
6908 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->glist_mtime
));
6909 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->alist_mtime
));
6910 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->alerts
));
6911 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->security
));
6912 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->numadmin
));
6913 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->lanmask
));
6914 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->guestaccount
));
6915 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->chdevs
));
6916 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->chdevqs
));
6917 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->chdevjobs
));
6918 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->connections
));
6919 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->shares
));
6920 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->openfiles
));
6921 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->sessopen
));
6922 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->sesssvc
));
6923 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->sessreqs
));
6924 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->opensearch
));
6925 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->activelocks
));
6926 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->numreqbufs
));
6927 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->sizereqbufs
));
6928 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->numbigbufs
));
6929 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->numfiletasks
));
6930 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->alertsched
));
6931 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->erroralert
));
6932 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->logonalert
));
6933 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->accessalert
));
6934 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->diskalert
));
6935 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->netioalert
));
6936 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->maxaudits
));
6937 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->srvheuristics
));
6939 if (ndr_flags
& NDR_BUFFERS
) {
6941 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->alerts
, CH_UTF16
)));
6942 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
6943 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->alerts
, CH_UTF16
)));
6944 NDR_CHECK(ndr_push_charset(ndr
, NDR_SCALARS
, r
->alerts
, ndr_charset_length(r
->alerts
, CH_UTF16
), sizeof(uint16_t), CH_UTF16
));
6946 if (r
->guestaccount
) {
6947 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->guestaccount
, CH_UTF16
)));
6948 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
6949 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->guestaccount
, CH_UTF16
)));
6950 NDR_CHECK(ndr_push_charset(ndr
, NDR_SCALARS
, r
->guestaccount
, ndr_charset_length(r
->guestaccount
, CH_UTF16
), sizeof(uint16_t), CH_UTF16
));
6952 if (r
->srvheuristics
) {
6953 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->srvheuristics
, CH_UTF16
)));
6954 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
6955 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->srvheuristics
, CH_UTF16
)));
6956 NDR_CHECK(ndr_push_charset(ndr
, NDR_SCALARS
, r
->srvheuristics
, ndr_charset_length(r
->srvheuristics
, CH_UTF16
), sizeof(uint16_t), CH_UTF16
));
6959 return NDR_ERR_SUCCESS
;
6962 static enum ndr_err_code
ndr_pull_srvsvc_NetSrvInfo402(struct ndr_pull
*ndr
, int ndr_flags
, struct srvsvc_NetSrvInfo402
*r
)
6964 uint32_t _ptr_alerts
;
6965 uint32_t size_alerts_1
= 0;
6966 uint32_t length_alerts_1
= 0;
6967 TALLOC_CTX
*_mem_save_alerts_0
;
6968 uint32_t _ptr_guestaccount
;
6969 uint32_t size_guestaccount_1
= 0;
6970 uint32_t length_guestaccount_1
= 0;
6971 TALLOC_CTX
*_mem_save_guestaccount_0
;
6972 uint32_t _ptr_srvheuristics
;
6973 uint32_t size_srvheuristics_1
= 0;
6974 uint32_t length_srvheuristics_1
= 0;
6975 TALLOC_CTX
*_mem_save_srvheuristics_0
;
6976 if (ndr_flags
& NDR_SCALARS
) {
6977 NDR_CHECK(ndr_pull_align(ndr
, 4));
6978 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->ulist_mtime
));
6979 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->glist_mtime
));
6980 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->alist_mtime
));
6981 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_alerts
));
6983 NDR_PULL_ALLOC(ndr
, r
->alerts
);
6987 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->security
));
6988 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->numadmin
));
6989 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->lanmask
));
6990 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_guestaccount
));
6991 if (_ptr_guestaccount
) {
6992 NDR_PULL_ALLOC(ndr
, r
->guestaccount
);
6994 r
->guestaccount
= NULL
;
6996 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->chdevs
));
6997 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->chdevqs
));
6998 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->chdevjobs
));
6999 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->connections
));
7000 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->shares
));
7001 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->openfiles
));
7002 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->sessopen
));
7003 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->sesssvc
));
7004 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->sessreqs
));
7005 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->opensearch
));
7006 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->activelocks
));
7007 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->numreqbufs
));
7008 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->sizereqbufs
));
7009 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->numbigbufs
));
7010 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->numfiletasks
));
7011 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->alertsched
));
7012 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->erroralert
));
7013 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->logonalert
));
7014 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->accessalert
));
7015 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->diskalert
));
7016 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->netioalert
));
7017 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->maxaudits
));
7018 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_srvheuristics
));
7019 if (_ptr_srvheuristics
) {
7020 NDR_PULL_ALLOC(ndr
, r
->srvheuristics
);
7022 r
->srvheuristics
= NULL
;
7025 if (ndr_flags
& NDR_BUFFERS
) {
7027 _mem_save_alerts_0
= NDR_PULL_GET_MEM_CTX(ndr
);
7028 NDR_PULL_SET_MEM_CTX(ndr
, r
->alerts
, 0);
7029 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->alerts
));
7030 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->alerts
));
7031 size_alerts_1
= ndr_get_array_size(ndr
, &r
->alerts
);
7032 length_alerts_1
= ndr_get_array_length(ndr
, &r
->alerts
);
7033 if (length_alerts_1
> size_alerts_1
) {
7034 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", size_alerts_1
, length_alerts_1
);
7036 NDR_CHECK(ndr_check_string_terminator(ndr
, length_alerts_1
, sizeof(uint16_t)));
7037 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->alerts
, length_alerts_1
, sizeof(uint16_t), CH_UTF16
));
7038 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_alerts_0
, 0);
7040 if (r
->guestaccount
) {
7041 _mem_save_guestaccount_0
= NDR_PULL_GET_MEM_CTX(ndr
);
7042 NDR_PULL_SET_MEM_CTX(ndr
, r
->guestaccount
, 0);
7043 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->guestaccount
));
7044 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->guestaccount
));
7045 size_guestaccount_1
= ndr_get_array_size(ndr
, &r
->guestaccount
);
7046 length_guestaccount_1
= ndr_get_array_length(ndr
, &r
->guestaccount
);
7047 if (length_guestaccount_1
> size_guestaccount_1
) {
7048 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", size_guestaccount_1
, length_guestaccount_1
);
7050 NDR_CHECK(ndr_check_string_terminator(ndr
, length_guestaccount_1
, sizeof(uint16_t)));
7051 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->guestaccount
, length_guestaccount_1
, sizeof(uint16_t), CH_UTF16
));
7052 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_guestaccount_0
, 0);
7054 if (r
->srvheuristics
) {
7055 _mem_save_srvheuristics_0
= NDR_PULL_GET_MEM_CTX(ndr
);
7056 NDR_PULL_SET_MEM_CTX(ndr
, r
->srvheuristics
, 0);
7057 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->srvheuristics
));
7058 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->srvheuristics
));
7059 size_srvheuristics_1
= ndr_get_array_size(ndr
, &r
->srvheuristics
);
7060 length_srvheuristics_1
= ndr_get_array_length(ndr
, &r
->srvheuristics
);
7061 if (length_srvheuristics_1
> size_srvheuristics_1
) {
7062 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", size_srvheuristics_1
, length_srvheuristics_1
);
7064 NDR_CHECK(ndr_check_string_terminator(ndr
, length_srvheuristics_1
, sizeof(uint16_t)));
7065 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->srvheuristics
, length_srvheuristics_1
, sizeof(uint16_t), CH_UTF16
));
7066 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_srvheuristics_0
, 0);
7069 return NDR_ERR_SUCCESS
;
7072 _PUBLIC_
void ndr_print_srvsvc_NetSrvInfo402(struct ndr_print
*ndr
, const char *name
, const struct srvsvc_NetSrvInfo402
*r
)
7074 ndr_print_struct(ndr
, name
, "srvsvc_NetSrvInfo402");
7076 ndr_print_uint32(ndr
, "ulist_mtime", r
->ulist_mtime
);
7077 ndr_print_uint32(ndr
, "glist_mtime", r
->glist_mtime
);
7078 ndr_print_uint32(ndr
, "alist_mtime", r
->alist_mtime
);
7079 ndr_print_ptr(ndr
, "alerts", r
->alerts
);
7082 ndr_print_string(ndr
, "alerts", r
->alerts
);
7085 ndr_print_uint32(ndr
, "security", r
->security
);
7086 ndr_print_uint32(ndr
, "numadmin", r
->numadmin
);
7087 ndr_print_uint32(ndr
, "lanmask", r
->lanmask
);
7088 ndr_print_ptr(ndr
, "guestaccount", r
->guestaccount
);
7090 if (r
->guestaccount
) {
7091 ndr_print_string(ndr
, "guestaccount", r
->guestaccount
);
7094 ndr_print_uint32(ndr
, "chdevs", r
->chdevs
);
7095 ndr_print_uint32(ndr
, "chdevqs", r
->chdevqs
);
7096 ndr_print_uint32(ndr
, "chdevjobs", r
->chdevjobs
);
7097 ndr_print_uint32(ndr
, "connections", r
->connections
);
7098 ndr_print_uint32(ndr
, "shares", r
->shares
);
7099 ndr_print_uint32(ndr
, "openfiles", r
->openfiles
);
7100 ndr_print_uint32(ndr
, "sessopen", r
->sessopen
);
7101 ndr_print_uint32(ndr
, "sesssvc", r
->sesssvc
);
7102 ndr_print_uint32(ndr
, "sessreqs", r
->sessreqs
);
7103 ndr_print_uint32(ndr
, "opensearch", r
->opensearch
);
7104 ndr_print_uint32(ndr
, "activelocks", r
->activelocks
);
7105 ndr_print_uint32(ndr
, "numreqbufs", r
->numreqbufs
);
7106 ndr_print_uint32(ndr
, "sizereqbufs", r
->sizereqbufs
);
7107 ndr_print_uint32(ndr
, "numbigbufs", r
->numbigbufs
);
7108 ndr_print_uint32(ndr
, "numfiletasks", r
->numfiletasks
);
7109 ndr_print_uint32(ndr
, "alertsched", r
->alertsched
);
7110 ndr_print_uint32(ndr
, "erroralert", r
->erroralert
);
7111 ndr_print_uint32(ndr
, "logonalert", r
->logonalert
);
7112 ndr_print_uint32(ndr
, "accessalert", r
->accessalert
);
7113 ndr_print_uint32(ndr
, "diskalert", r
->diskalert
);
7114 ndr_print_uint32(ndr
, "netioalert", r
->netioalert
);
7115 ndr_print_uint32(ndr
, "maxaudits", r
->maxaudits
);
7116 ndr_print_ptr(ndr
, "srvheuristics", r
->srvheuristics
);
7118 if (r
->srvheuristics
) {
7119 ndr_print_string(ndr
, "srvheuristics", r
->srvheuristics
);
7125 static enum ndr_err_code
ndr_push_srvsvc_NetSrvInfo403(struct ndr_push
*ndr
, int ndr_flags
, const struct srvsvc_NetSrvInfo403
*r
)
7127 if (ndr_flags
& NDR_SCALARS
) {
7128 NDR_CHECK(ndr_push_align(ndr
, 4));
7129 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->ulist_mtime
));
7130 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->glist_mtime
));
7131 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->alist_mtime
));
7132 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->alerts
));
7133 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->security
));
7134 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->numadmin
));
7135 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->lanmask
));
7136 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->guestaccount
));
7137 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->chdevs
));
7138 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->chdevqs
));
7139 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->chdevjobs
));
7140 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->connections
));
7141 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->shares
));
7142 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->openfiles
));
7143 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->sessopen
));
7144 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->sesssvc
));
7145 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->sessreqs
));
7146 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->opensearch
));
7147 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->activelocks
));
7148 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->numreqbufs
));
7149 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->sizereqbufs
));
7150 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->numbigbufs
));
7151 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->numfiletasks
));
7152 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->alertsched
));
7153 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->erroralert
));
7154 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->logonalert
));
7155 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->accessalert
));
7156 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->diskalert
));
7157 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->netioalert
));
7158 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->maxaudits
));
7159 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->srvheuristics
));
7160 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->auditedevents
));
7161 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->auditprofile
));
7162 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->autopath
));
7164 if (ndr_flags
& NDR_BUFFERS
) {
7166 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->alerts
, CH_UTF16
)));
7167 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
7168 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->alerts
, CH_UTF16
)));
7169 NDR_CHECK(ndr_push_charset(ndr
, NDR_SCALARS
, r
->alerts
, ndr_charset_length(r
->alerts
, CH_UTF16
), sizeof(uint16_t), CH_UTF16
));
7171 if (r
->guestaccount
) {
7172 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->guestaccount
, CH_UTF16
)));
7173 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
7174 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->guestaccount
, CH_UTF16
)));
7175 NDR_CHECK(ndr_push_charset(ndr
, NDR_SCALARS
, r
->guestaccount
, ndr_charset_length(r
->guestaccount
, CH_UTF16
), sizeof(uint16_t), CH_UTF16
));
7177 if (r
->srvheuristics
) {
7178 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->srvheuristics
, CH_UTF16
)));
7179 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
7180 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->srvheuristics
, CH_UTF16
)));
7181 NDR_CHECK(ndr_push_charset(ndr
, NDR_SCALARS
, r
->srvheuristics
, ndr_charset_length(r
->srvheuristics
, CH_UTF16
), sizeof(uint16_t), CH_UTF16
));
7184 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->autopath
, CH_UTF16
)));
7185 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
7186 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->autopath
, CH_UTF16
)));
7187 NDR_CHECK(ndr_push_charset(ndr
, NDR_SCALARS
, r
->autopath
, ndr_charset_length(r
->autopath
, CH_UTF16
), sizeof(uint16_t), CH_UTF16
));
7190 return NDR_ERR_SUCCESS
;
7193 static enum ndr_err_code
ndr_pull_srvsvc_NetSrvInfo403(struct ndr_pull
*ndr
, int ndr_flags
, struct srvsvc_NetSrvInfo403
*r
)
7195 uint32_t _ptr_alerts
;
7196 uint32_t size_alerts_1
= 0;
7197 uint32_t length_alerts_1
= 0;
7198 TALLOC_CTX
*_mem_save_alerts_0
;
7199 uint32_t _ptr_guestaccount
;
7200 uint32_t size_guestaccount_1
= 0;
7201 uint32_t length_guestaccount_1
= 0;
7202 TALLOC_CTX
*_mem_save_guestaccount_0
;
7203 uint32_t _ptr_srvheuristics
;
7204 uint32_t size_srvheuristics_1
= 0;
7205 uint32_t length_srvheuristics_1
= 0;
7206 TALLOC_CTX
*_mem_save_srvheuristics_0
;
7207 uint32_t _ptr_autopath
;
7208 uint32_t size_autopath_1
= 0;
7209 uint32_t length_autopath_1
= 0;
7210 TALLOC_CTX
*_mem_save_autopath_0
;
7211 if (ndr_flags
& NDR_SCALARS
) {
7212 NDR_CHECK(ndr_pull_align(ndr
, 4));
7213 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->ulist_mtime
));
7214 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->glist_mtime
));
7215 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->alist_mtime
));
7216 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_alerts
));
7218 NDR_PULL_ALLOC(ndr
, r
->alerts
);
7222 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->security
));
7223 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->numadmin
));
7224 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->lanmask
));
7225 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_guestaccount
));
7226 if (_ptr_guestaccount
) {
7227 NDR_PULL_ALLOC(ndr
, r
->guestaccount
);
7229 r
->guestaccount
= NULL
;
7231 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->chdevs
));
7232 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->chdevqs
));
7233 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->chdevjobs
));
7234 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->connections
));
7235 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->shares
));
7236 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->openfiles
));
7237 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->sessopen
));
7238 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->sesssvc
));
7239 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->sessreqs
));
7240 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->opensearch
));
7241 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->activelocks
));
7242 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->numreqbufs
));
7243 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->sizereqbufs
));
7244 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->numbigbufs
));
7245 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->numfiletasks
));
7246 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->alertsched
));
7247 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->erroralert
));
7248 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->logonalert
));
7249 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->accessalert
));
7250 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->diskalert
));
7251 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->netioalert
));
7252 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->maxaudits
));
7253 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_srvheuristics
));
7254 if (_ptr_srvheuristics
) {
7255 NDR_PULL_ALLOC(ndr
, r
->srvheuristics
);
7257 r
->srvheuristics
= NULL
;
7259 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->auditedevents
));
7260 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->auditprofile
));
7261 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_autopath
));
7262 if (_ptr_autopath
) {
7263 NDR_PULL_ALLOC(ndr
, r
->autopath
);
7268 if (ndr_flags
& NDR_BUFFERS
) {
7270 _mem_save_alerts_0
= NDR_PULL_GET_MEM_CTX(ndr
);
7271 NDR_PULL_SET_MEM_CTX(ndr
, r
->alerts
, 0);
7272 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->alerts
));
7273 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->alerts
));
7274 size_alerts_1
= ndr_get_array_size(ndr
, &r
->alerts
);
7275 length_alerts_1
= ndr_get_array_length(ndr
, &r
->alerts
);
7276 if (length_alerts_1
> size_alerts_1
) {
7277 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", size_alerts_1
, length_alerts_1
);
7279 NDR_CHECK(ndr_check_string_terminator(ndr
, length_alerts_1
, sizeof(uint16_t)));
7280 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->alerts
, length_alerts_1
, sizeof(uint16_t), CH_UTF16
));
7281 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_alerts_0
, 0);
7283 if (r
->guestaccount
) {
7284 _mem_save_guestaccount_0
= NDR_PULL_GET_MEM_CTX(ndr
);
7285 NDR_PULL_SET_MEM_CTX(ndr
, r
->guestaccount
, 0);
7286 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->guestaccount
));
7287 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->guestaccount
));
7288 size_guestaccount_1
= ndr_get_array_size(ndr
, &r
->guestaccount
);
7289 length_guestaccount_1
= ndr_get_array_length(ndr
, &r
->guestaccount
);
7290 if (length_guestaccount_1
> size_guestaccount_1
) {
7291 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", size_guestaccount_1
, length_guestaccount_1
);
7293 NDR_CHECK(ndr_check_string_terminator(ndr
, length_guestaccount_1
, sizeof(uint16_t)));
7294 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->guestaccount
, length_guestaccount_1
, sizeof(uint16_t), CH_UTF16
));
7295 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_guestaccount_0
, 0);
7297 if (r
->srvheuristics
) {
7298 _mem_save_srvheuristics_0
= NDR_PULL_GET_MEM_CTX(ndr
);
7299 NDR_PULL_SET_MEM_CTX(ndr
, r
->srvheuristics
, 0);
7300 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->srvheuristics
));
7301 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->srvheuristics
));
7302 size_srvheuristics_1
= ndr_get_array_size(ndr
, &r
->srvheuristics
);
7303 length_srvheuristics_1
= ndr_get_array_length(ndr
, &r
->srvheuristics
);
7304 if (length_srvheuristics_1
> size_srvheuristics_1
) {
7305 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", size_srvheuristics_1
, length_srvheuristics_1
);
7307 NDR_CHECK(ndr_check_string_terminator(ndr
, length_srvheuristics_1
, sizeof(uint16_t)));
7308 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->srvheuristics
, length_srvheuristics_1
, sizeof(uint16_t), CH_UTF16
));
7309 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_srvheuristics_0
, 0);
7312 _mem_save_autopath_0
= NDR_PULL_GET_MEM_CTX(ndr
);
7313 NDR_PULL_SET_MEM_CTX(ndr
, r
->autopath
, 0);
7314 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->autopath
));
7315 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->autopath
));
7316 size_autopath_1
= ndr_get_array_size(ndr
, &r
->autopath
);
7317 length_autopath_1
= ndr_get_array_length(ndr
, &r
->autopath
);
7318 if (length_autopath_1
> size_autopath_1
) {
7319 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", size_autopath_1
, length_autopath_1
);
7321 NDR_CHECK(ndr_check_string_terminator(ndr
, length_autopath_1
, sizeof(uint16_t)));
7322 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->autopath
, length_autopath_1
, sizeof(uint16_t), CH_UTF16
));
7323 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_autopath_0
, 0);
7326 return NDR_ERR_SUCCESS
;
7329 _PUBLIC_
void ndr_print_srvsvc_NetSrvInfo403(struct ndr_print
*ndr
, const char *name
, const struct srvsvc_NetSrvInfo403
*r
)
7331 ndr_print_struct(ndr
, name
, "srvsvc_NetSrvInfo403");
7333 ndr_print_uint32(ndr
, "ulist_mtime", r
->ulist_mtime
);
7334 ndr_print_uint32(ndr
, "glist_mtime", r
->glist_mtime
);
7335 ndr_print_uint32(ndr
, "alist_mtime", r
->alist_mtime
);
7336 ndr_print_ptr(ndr
, "alerts", r
->alerts
);
7339 ndr_print_string(ndr
, "alerts", r
->alerts
);
7342 ndr_print_uint32(ndr
, "security", r
->security
);
7343 ndr_print_uint32(ndr
, "numadmin", r
->numadmin
);
7344 ndr_print_uint32(ndr
, "lanmask", r
->lanmask
);
7345 ndr_print_ptr(ndr
, "guestaccount", r
->guestaccount
);
7347 if (r
->guestaccount
) {
7348 ndr_print_string(ndr
, "guestaccount", r
->guestaccount
);
7351 ndr_print_uint32(ndr
, "chdevs", r
->chdevs
);
7352 ndr_print_uint32(ndr
, "chdevqs", r
->chdevqs
);
7353 ndr_print_uint32(ndr
, "chdevjobs", r
->chdevjobs
);
7354 ndr_print_uint32(ndr
, "connections", r
->connections
);
7355 ndr_print_uint32(ndr
, "shares", r
->shares
);
7356 ndr_print_uint32(ndr
, "openfiles", r
->openfiles
);
7357 ndr_print_uint32(ndr
, "sessopen", r
->sessopen
);
7358 ndr_print_uint32(ndr
, "sesssvc", r
->sesssvc
);
7359 ndr_print_uint32(ndr
, "sessreqs", r
->sessreqs
);
7360 ndr_print_uint32(ndr
, "opensearch", r
->opensearch
);
7361 ndr_print_uint32(ndr
, "activelocks", r
->activelocks
);
7362 ndr_print_uint32(ndr
, "numreqbufs", r
->numreqbufs
);
7363 ndr_print_uint32(ndr
, "sizereqbufs", r
->sizereqbufs
);
7364 ndr_print_uint32(ndr
, "numbigbufs", r
->numbigbufs
);
7365 ndr_print_uint32(ndr
, "numfiletasks", r
->numfiletasks
);
7366 ndr_print_uint32(ndr
, "alertsched", r
->alertsched
);
7367 ndr_print_uint32(ndr
, "erroralert", r
->erroralert
);
7368 ndr_print_uint32(ndr
, "logonalert", r
->logonalert
);
7369 ndr_print_uint32(ndr
, "accessalert", r
->accessalert
);
7370 ndr_print_uint32(ndr
, "diskalert", r
->diskalert
);
7371 ndr_print_uint32(ndr
, "netioalert", r
->netioalert
);
7372 ndr_print_uint32(ndr
, "maxaudits", r
->maxaudits
);
7373 ndr_print_ptr(ndr
, "srvheuristics", r
->srvheuristics
);
7375 if (r
->srvheuristics
) {
7376 ndr_print_string(ndr
, "srvheuristics", r
->srvheuristics
);
7379 ndr_print_uint32(ndr
, "auditedevents", r
->auditedevents
);
7380 ndr_print_uint32(ndr
, "auditprofile", r
->auditprofile
);
7381 ndr_print_ptr(ndr
, "autopath", r
->autopath
);
7384 ndr_print_string(ndr
, "autopath", r
->autopath
);
7390 static enum ndr_err_code
ndr_push_srvsvc_NetSrvInfo502(struct ndr_push
*ndr
, int ndr_flags
, const struct srvsvc_NetSrvInfo502
*r
)
7392 if (ndr_flags
& NDR_SCALARS
) {
7393 NDR_CHECK(ndr_push_align(ndr
, 4));
7394 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->sessopen
));
7395 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->sesssvc
));
7396 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->opensearch
));
7397 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->sizereqbufs
));
7398 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->initworkitems
));
7399 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->maxworkitems
));
7400 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->rawworkitems
));
7401 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->irpstacksize
));
7402 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->maxrawbuflen
));
7403 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->sessusers
));
7404 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->sessconns
));
7405 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->maxpagedmemoryusage
));
7406 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->maxnonpagedmemoryusage
));
7407 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->enablesoftcompat
));
7408 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->enableforcedlogoff
));
7409 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->timesource
));
7410 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->acceptdownlevelapis
));
7411 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->lmannounce
));
7413 if (ndr_flags
& NDR_BUFFERS
) {
7415 return NDR_ERR_SUCCESS
;
7418 static enum ndr_err_code
ndr_pull_srvsvc_NetSrvInfo502(struct ndr_pull
*ndr
, int ndr_flags
, struct srvsvc_NetSrvInfo502
*r
)
7420 if (ndr_flags
& NDR_SCALARS
) {
7421 NDR_CHECK(ndr_pull_align(ndr
, 4));
7422 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->sessopen
));
7423 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->sesssvc
));
7424 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->opensearch
));
7425 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->sizereqbufs
));
7426 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->initworkitems
));
7427 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->maxworkitems
));
7428 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->rawworkitems
));
7429 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->irpstacksize
));
7430 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->maxrawbuflen
));
7431 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->sessusers
));
7432 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->sessconns
));
7433 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->maxpagedmemoryusage
));
7434 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->maxnonpagedmemoryusage
));
7435 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->enablesoftcompat
));
7436 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->enableforcedlogoff
));
7437 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->timesource
));
7438 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->acceptdownlevelapis
));
7439 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->lmannounce
));
7441 if (ndr_flags
& NDR_BUFFERS
) {
7443 return NDR_ERR_SUCCESS
;
7446 _PUBLIC_
void ndr_print_srvsvc_NetSrvInfo502(struct ndr_print
*ndr
, const char *name
, const struct srvsvc_NetSrvInfo502
*r
)
7448 ndr_print_struct(ndr
, name
, "srvsvc_NetSrvInfo502");
7450 ndr_print_uint32(ndr
, "sessopen", r
->sessopen
);
7451 ndr_print_uint32(ndr
, "sesssvc", r
->sesssvc
);
7452 ndr_print_uint32(ndr
, "opensearch", r
->opensearch
);
7453 ndr_print_uint32(ndr
, "sizereqbufs", r
->sizereqbufs
);
7454 ndr_print_uint32(ndr
, "initworkitems", r
->initworkitems
);
7455 ndr_print_uint32(ndr
, "maxworkitems", r
->maxworkitems
);
7456 ndr_print_uint32(ndr
, "rawworkitems", r
->rawworkitems
);
7457 ndr_print_uint32(ndr
, "irpstacksize", r
->irpstacksize
);
7458 ndr_print_uint32(ndr
, "maxrawbuflen", r
->maxrawbuflen
);
7459 ndr_print_uint32(ndr
, "sessusers", r
->sessusers
);
7460 ndr_print_uint32(ndr
, "sessconns", r
->sessconns
);
7461 ndr_print_uint32(ndr
, "maxpagedmemoryusage", r
->maxpagedmemoryusage
);
7462 ndr_print_uint32(ndr
, "maxnonpagedmemoryusage", r
->maxnonpagedmemoryusage
);
7463 ndr_print_uint32(ndr
, "enablesoftcompat", r
->enablesoftcompat
);
7464 ndr_print_uint32(ndr
, "enableforcedlogoff", r
->enableforcedlogoff
);
7465 ndr_print_uint32(ndr
, "timesource", r
->timesource
);
7466 ndr_print_uint32(ndr
, "acceptdownlevelapis", r
->acceptdownlevelapis
);
7467 ndr_print_uint32(ndr
, "lmannounce", r
->lmannounce
);
7471 static enum ndr_err_code
ndr_push_srvsvc_NetSrvInfo503(struct ndr_push
*ndr
, int ndr_flags
, const struct srvsvc_NetSrvInfo503
*r
)
7473 if (ndr_flags
& NDR_SCALARS
) {
7474 NDR_CHECK(ndr_push_align(ndr
, 4));
7475 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->sessopen
));
7476 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->sesssvc
));
7477 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->opensearch
));
7478 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->sizereqbufs
));
7479 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->initworkitems
));
7480 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->maxworkitems
));
7481 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->rawworkitems
));
7482 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->irpstacksize
));
7483 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->maxrawbuflen
));
7484 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->sessusers
));
7485 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->sessconns
));
7486 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->maxpagedmemoryusage
));
7487 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->maxnonpagedmemoryusage
));
7488 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->enablesoftcompat
));
7489 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->enableforcedlogoff
));
7490 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->timesource
));
7491 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->acceptdownlevelapis
));
7492 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->lmannounce
));
7493 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->domain
));
7494 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->maxcopyreadlen
));
7495 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->maxcopywritelen
));
7496 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->minkeepsearch
));
7497 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->maxkeepsearch
));
7498 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->minkeepcomplsearch
));
7499 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->maxkeepcomplsearch
));
7500 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->threadcountadd
));
7501 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->numlockthreads
));
7502 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->scavtimeout
));
7503 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->minrcvqueue
));
7504 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->minfreeworkitems
));
7505 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->xactmemsize
));
7506 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->threadpriority
));
7507 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->maxmpxct
));
7508 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->oplockbreakwait
));
7509 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->oplockbreakresponsewait
));
7510 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->enableoplocks
));
7511 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->enableoplockforceclose
));
7512 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->enablefcbopens
));
7513 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->enableraw
));
7514 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->enablesharednetdrives
));
7515 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->minfreeconnections
));
7516 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->maxfreeconnections
));
7518 if (ndr_flags
& NDR_BUFFERS
) {
7520 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->domain
, CH_UTF16
)));
7521 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
7522 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->domain
, CH_UTF16
)));
7523 NDR_CHECK(ndr_push_charset(ndr
, NDR_SCALARS
, r
->domain
, ndr_charset_length(r
->domain
, CH_UTF16
), sizeof(uint16_t), CH_UTF16
));
7526 return NDR_ERR_SUCCESS
;
7529 static enum ndr_err_code
ndr_pull_srvsvc_NetSrvInfo503(struct ndr_pull
*ndr
, int ndr_flags
, struct srvsvc_NetSrvInfo503
*r
)
7531 uint32_t _ptr_domain
;
7532 uint32_t size_domain_1
= 0;
7533 uint32_t length_domain_1
= 0;
7534 TALLOC_CTX
*_mem_save_domain_0
;
7535 if (ndr_flags
& NDR_SCALARS
) {
7536 NDR_CHECK(ndr_pull_align(ndr
, 4));
7537 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->sessopen
));
7538 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->sesssvc
));
7539 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->opensearch
));
7540 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->sizereqbufs
));
7541 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->initworkitems
));
7542 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->maxworkitems
));
7543 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->rawworkitems
));
7544 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->irpstacksize
));
7545 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->maxrawbuflen
));
7546 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->sessusers
));
7547 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->sessconns
));
7548 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->maxpagedmemoryusage
));
7549 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->maxnonpagedmemoryusage
));
7550 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->enablesoftcompat
));
7551 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->enableforcedlogoff
));
7552 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->timesource
));
7553 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->acceptdownlevelapis
));
7554 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->lmannounce
));
7555 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_domain
));
7557 NDR_PULL_ALLOC(ndr
, r
->domain
);
7561 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->maxcopyreadlen
));
7562 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->maxcopywritelen
));
7563 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->minkeepsearch
));
7564 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->maxkeepsearch
));
7565 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->minkeepcomplsearch
));
7566 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->maxkeepcomplsearch
));
7567 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->threadcountadd
));
7568 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->numlockthreads
));
7569 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->scavtimeout
));
7570 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->minrcvqueue
));
7571 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->minfreeworkitems
));
7572 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->xactmemsize
));
7573 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->threadpriority
));
7574 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->maxmpxct
));
7575 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->oplockbreakwait
));
7576 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->oplockbreakresponsewait
));
7577 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->enableoplocks
));
7578 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->enableoplockforceclose
));
7579 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->enablefcbopens
));
7580 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->enableraw
));
7581 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->enablesharednetdrives
));
7582 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->minfreeconnections
));
7583 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->maxfreeconnections
));
7585 if (ndr_flags
& NDR_BUFFERS
) {
7587 _mem_save_domain_0
= NDR_PULL_GET_MEM_CTX(ndr
);
7588 NDR_PULL_SET_MEM_CTX(ndr
, r
->domain
, 0);
7589 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->domain
));
7590 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->domain
));
7591 size_domain_1
= ndr_get_array_size(ndr
, &r
->domain
);
7592 length_domain_1
= ndr_get_array_length(ndr
, &r
->domain
);
7593 if (length_domain_1
> size_domain_1
) {
7594 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", size_domain_1
, length_domain_1
);
7596 NDR_CHECK(ndr_check_string_terminator(ndr
, length_domain_1
, sizeof(uint16_t)));
7597 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->domain
, length_domain_1
, sizeof(uint16_t), CH_UTF16
));
7598 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_domain_0
, 0);
7601 return NDR_ERR_SUCCESS
;
7604 _PUBLIC_
void ndr_print_srvsvc_NetSrvInfo503(struct ndr_print
*ndr
, const char *name
, const struct srvsvc_NetSrvInfo503
*r
)
7606 ndr_print_struct(ndr
, name
, "srvsvc_NetSrvInfo503");
7608 ndr_print_uint32(ndr
, "sessopen", r
->sessopen
);
7609 ndr_print_uint32(ndr
, "sesssvc", r
->sesssvc
);
7610 ndr_print_uint32(ndr
, "opensearch", r
->opensearch
);
7611 ndr_print_uint32(ndr
, "sizereqbufs", r
->sizereqbufs
);
7612 ndr_print_uint32(ndr
, "initworkitems", r
->initworkitems
);
7613 ndr_print_uint32(ndr
, "maxworkitems", r
->maxworkitems
);
7614 ndr_print_uint32(ndr
, "rawworkitems", r
->rawworkitems
);
7615 ndr_print_uint32(ndr
, "irpstacksize", r
->irpstacksize
);
7616 ndr_print_uint32(ndr
, "maxrawbuflen", r
->maxrawbuflen
);
7617 ndr_print_uint32(ndr
, "sessusers", r
->sessusers
);
7618 ndr_print_uint32(ndr
, "sessconns", r
->sessconns
);
7619 ndr_print_uint32(ndr
, "maxpagedmemoryusage", r
->maxpagedmemoryusage
);
7620 ndr_print_uint32(ndr
, "maxnonpagedmemoryusage", r
->maxnonpagedmemoryusage
);
7621 ndr_print_uint32(ndr
, "enablesoftcompat", r
->enablesoftcompat
);
7622 ndr_print_uint32(ndr
, "enableforcedlogoff", r
->enableforcedlogoff
);
7623 ndr_print_uint32(ndr
, "timesource", r
->timesource
);
7624 ndr_print_uint32(ndr
, "acceptdownlevelapis", r
->acceptdownlevelapis
);
7625 ndr_print_uint32(ndr
, "lmannounce", r
->lmannounce
);
7626 ndr_print_ptr(ndr
, "domain", r
->domain
);
7629 ndr_print_string(ndr
, "domain", r
->domain
);
7632 ndr_print_uint32(ndr
, "maxcopyreadlen", r
->maxcopyreadlen
);
7633 ndr_print_uint32(ndr
, "maxcopywritelen", r
->maxcopywritelen
);
7634 ndr_print_uint32(ndr
, "minkeepsearch", r
->minkeepsearch
);
7635 ndr_print_uint32(ndr
, "maxkeepsearch", r
->maxkeepsearch
);
7636 ndr_print_uint32(ndr
, "minkeepcomplsearch", r
->minkeepcomplsearch
);
7637 ndr_print_uint32(ndr
, "maxkeepcomplsearch", r
->maxkeepcomplsearch
);
7638 ndr_print_uint32(ndr
, "threadcountadd", r
->threadcountadd
);
7639 ndr_print_uint32(ndr
, "numlockthreads", r
->numlockthreads
);
7640 ndr_print_uint32(ndr
, "scavtimeout", r
->scavtimeout
);
7641 ndr_print_uint32(ndr
, "minrcvqueue", r
->minrcvqueue
);
7642 ndr_print_uint32(ndr
, "minfreeworkitems", r
->minfreeworkitems
);
7643 ndr_print_uint32(ndr
, "xactmemsize", r
->xactmemsize
);
7644 ndr_print_uint32(ndr
, "threadpriority", r
->threadpriority
);
7645 ndr_print_uint32(ndr
, "maxmpxct", r
->maxmpxct
);
7646 ndr_print_uint32(ndr
, "oplockbreakwait", r
->oplockbreakwait
);
7647 ndr_print_uint32(ndr
, "oplockbreakresponsewait", r
->oplockbreakresponsewait
);
7648 ndr_print_uint32(ndr
, "enableoplocks", r
->enableoplocks
);
7649 ndr_print_uint32(ndr
, "enableoplockforceclose", r
->enableoplockforceclose
);
7650 ndr_print_uint32(ndr
, "enablefcbopens", r
->enablefcbopens
);
7651 ndr_print_uint32(ndr
, "enableraw", r
->enableraw
);
7652 ndr_print_uint32(ndr
, "enablesharednetdrives", r
->enablesharednetdrives
);
7653 ndr_print_uint32(ndr
, "minfreeconnections", r
->minfreeconnections
);
7654 ndr_print_uint32(ndr
, "maxfreeconnections", r
->maxfreeconnections
);
7658 static enum ndr_err_code
ndr_push_srvsvc_NetSrvInfo599(struct ndr_push
*ndr
, int ndr_flags
, const struct srvsvc_NetSrvInfo599
*r
)
7660 if (ndr_flags
& NDR_SCALARS
) {
7661 NDR_CHECK(ndr_push_align(ndr
, 4));
7662 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->sessopen
));
7663 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->sesssvc
));
7664 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->opensearch
));
7665 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->sizereqbufs
));
7666 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->initworkitems
));
7667 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->maxworkitems
));
7668 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->rawworkitems
));
7669 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->irpstacksize
));
7670 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->maxrawbuflen
));
7671 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->sessusers
));
7672 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->sessconns
));
7673 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->maxpagedmemoryusage
));
7674 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->maxnonpagedmemoryusage
));
7675 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->enablesoftcompat
));
7676 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->enableforcedlogoff
));
7677 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->timesource
));
7678 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->acceptdownlevelapis
));
7679 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->lmannounce
));
7680 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->domain
));
7681 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->maxcopyreadlen
));
7682 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->maxcopywritelen
));
7683 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->minkeepsearch
));
7684 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->minkeepcomplsearch
));
7685 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->maxkeepcomplsearch
));
7686 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->threadcountadd
));
7687 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->numlockthreads
));
7688 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->scavtimeout
));
7689 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->minrcvqueue
));
7690 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->minfreeworkitems
));
7691 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->xactmemsize
));
7692 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->threadpriority
));
7693 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->maxmpxct
));
7694 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->oplockbreakwait
));
7695 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->oplockbreakresponsewait
));
7696 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->enableoplocks
));
7697 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->enableoplockforceclose
));
7698 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->enablefcbopens
));
7699 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->enableraw
));
7700 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->enablesharednetdrives
));
7701 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->minfreeconnections
));
7702 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->maxfreeconnections
));
7703 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->initsesstable
));
7704 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->initconntable
));
7705 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->initfiletable
));
7706 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->initsearchtable
));
7707 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->alertsched
));
7708 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->errortreshold
));
7709 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->networkerrortreshold
));
7710 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->diskspacetreshold
));
7711 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->reserved
));
7712 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->maxlinkdelay
));
7713 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->minlinkthroughput
));
7714 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->linkinfovalidtime
));
7715 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->scavqosinfoupdatetime
));
7716 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->maxworkitemidletime
));
7718 if (ndr_flags
& NDR_BUFFERS
) {
7720 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->domain
, CH_UTF16
)));
7721 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
7722 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->domain
, CH_UTF16
)));
7723 NDR_CHECK(ndr_push_charset(ndr
, NDR_SCALARS
, r
->domain
, ndr_charset_length(r
->domain
, CH_UTF16
), sizeof(uint16_t), CH_UTF16
));
7726 return NDR_ERR_SUCCESS
;
7729 static enum ndr_err_code
ndr_pull_srvsvc_NetSrvInfo599(struct ndr_pull
*ndr
, int ndr_flags
, struct srvsvc_NetSrvInfo599
*r
)
7731 uint32_t _ptr_domain
;
7732 uint32_t size_domain_1
= 0;
7733 uint32_t length_domain_1
= 0;
7734 TALLOC_CTX
*_mem_save_domain_0
;
7735 if (ndr_flags
& NDR_SCALARS
) {
7736 NDR_CHECK(ndr_pull_align(ndr
, 4));
7737 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->sessopen
));
7738 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->sesssvc
));
7739 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->opensearch
));
7740 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->sizereqbufs
));
7741 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->initworkitems
));
7742 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->maxworkitems
));
7743 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->rawworkitems
));
7744 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->irpstacksize
));
7745 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->maxrawbuflen
));
7746 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->sessusers
));
7747 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->sessconns
));
7748 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->maxpagedmemoryusage
));
7749 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->maxnonpagedmemoryusage
));
7750 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->enablesoftcompat
));
7751 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->enableforcedlogoff
));
7752 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->timesource
));
7753 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->acceptdownlevelapis
));
7754 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->lmannounce
));
7755 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_domain
));
7757 NDR_PULL_ALLOC(ndr
, r
->domain
);
7761 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->maxcopyreadlen
));
7762 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->maxcopywritelen
));
7763 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->minkeepsearch
));
7764 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->minkeepcomplsearch
));
7765 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->maxkeepcomplsearch
));
7766 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->threadcountadd
));
7767 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->numlockthreads
));
7768 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->scavtimeout
));
7769 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->minrcvqueue
));
7770 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->minfreeworkitems
));
7771 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->xactmemsize
));
7772 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->threadpriority
));
7773 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->maxmpxct
));
7774 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->oplockbreakwait
));
7775 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->oplockbreakresponsewait
));
7776 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->enableoplocks
));
7777 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->enableoplockforceclose
));
7778 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->enablefcbopens
));
7779 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->enableraw
));
7780 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->enablesharednetdrives
));
7781 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->minfreeconnections
));
7782 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->maxfreeconnections
));
7783 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->initsesstable
));
7784 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->initconntable
));
7785 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->initfiletable
));
7786 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->initsearchtable
));
7787 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->alertsched
));
7788 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->errortreshold
));
7789 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->networkerrortreshold
));
7790 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->diskspacetreshold
));
7791 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->reserved
));
7792 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->maxlinkdelay
));
7793 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->minlinkthroughput
));
7794 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->linkinfovalidtime
));
7795 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->scavqosinfoupdatetime
));
7796 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->maxworkitemidletime
));
7798 if (ndr_flags
& NDR_BUFFERS
) {
7800 _mem_save_domain_0
= NDR_PULL_GET_MEM_CTX(ndr
);
7801 NDR_PULL_SET_MEM_CTX(ndr
, r
->domain
, 0);
7802 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->domain
));
7803 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->domain
));
7804 size_domain_1
= ndr_get_array_size(ndr
, &r
->domain
);
7805 length_domain_1
= ndr_get_array_length(ndr
, &r
->domain
);
7806 if (length_domain_1
> size_domain_1
) {
7807 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", size_domain_1
, length_domain_1
);
7809 NDR_CHECK(ndr_check_string_terminator(ndr
, length_domain_1
, sizeof(uint16_t)));
7810 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->domain
, length_domain_1
, sizeof(uint16_t), CH_UTF16
));
7811 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_domain_0
, 0);
7814 return NDR_ERR_SUCCESS
;
7817 _PUBLIC_
void ndr_print_srvsvc_NetSrvInfo599(struct ndr_print
*ndr
, const char *name
, const struct srvsvc_NetSrvInfo599
*r
)
7819 ndr_print_struct(ndr
, name
, "srvsvc_NetSrvInfo599");
7821 ndr_print_uint32(ndr
, "sessopen", r
->sessopen
);
7822 ndr_print_uint32(ndr
, "sesssvc", r
->sesssvc
);
7823 ndr_print_uint32(ndr
, "opensearch", r
->opensearch
);
7824 ndr_print_uint32(ndr
, "sizereqbufs", r
->sizereqbufs
);
7825 ndr_print_uint32(ndr
, "initworkitems", r
->initworkitems
);
7826 ndr_print_uint32(ndr
, "maxworkitems", r
->maxworkitems
);
7827 ndr_print_uint32(ndr
, "rawworkitems", r
->rawworkitems
);
7828 ndr_print_uint32(ndr
, "irpstacksize", r
->irpstacksize
);
7829 ndr_print_uint32(ndr
, "maxrawbuflen", r
->maxrawbuflen
);
7830 ndr_print_uint32(ndr
, "sessusers", r
->sessusers
);
7831 ndr_print_uint32(ndr
, "sessconns", r
->sessconns
);
7832 ndr_print_uint32(ndr
, "maxpagedmemoryusage", r
->maxpagedmemoryusage
);
7833 ndr_print_uint32(ndr
, "maxnonpagedmemoryusage", r
->maxnonpagedmemoryusage
);
7834 ndr_print_uint32(ndr
, "enablesoftcompat", r
->enablesoftcompat
);
7835 ndr_print_uint32(ndr
, "enableforcedlogoff", r
->enableforcedlogoff
);
7836 ndr_print_uint32(ndr
, "timesource", r
->timesource
);
7837 ndr_print_uint32(ndr
, "acceptdownlevelapis", r
->acceptdownlevelapis
);
7838 ndr_print_uint32(ndr
, "lmannounce", r
->lmannounce
);
7839 ndr_print_ptr(ndr
, "domain", r
->domain
);
7842 ndr_print_string(ndr
, "domain", r
->domain
);
7845 ndr_print_uint32(ndr
, "maxcopyreadlen", r
->maxcopyreadlen
);
7846 ndr_print_uint32(ndr
, "maxcopywritelen", r
->maxcopywritelen
);
7847 ndr_print_uint32(ndr
, "minkeepsearch", r
->minkeepsearch
);
7848 ndr_print_uint32(ndr
, "minkeepcomplsearch", r
->minkeepcomplsearch
);
7849 ndr_print_uint32(ndr
, "maxkeepcomplsearch", r
->maxkeepcomplsearch
);
7850 ndr_print_uint32(ndr
, "threadcountadd", r
->threadcountadd
);
7851 ndr_print_uint32(ndr
, "numlockthreads", r
->numlockthreads
);
7852 ndr_print_uint32(ndr
, "scavtimeout", r
->scavtimeout
);
7853 ndr_print_uint32(ndr
, "minrcvqueue", r
->minrcvqueue
);
7854 ndr_print_uint32(ndr
, "minfreeworkitems", r
->minfreeworkitems
);
7855 ndr_print_uint32(ndr
, "xactmemsize", r
->xactmemsize
);
7856 ndr_print_uint32(ndr
, "threadpriority", r
->threadpriority
);
7857 ndr_print_uint32(ndr
, "maxmpxct", r
->maxmpxct
);
7858 ndr_print_uint32(ndr
, "oplockbreakwait", r
->oplockbreakwait
);
7859 ndr_print_uint32(ndr
, "oplockbreakresponsewait", r
->oplockbreakresponsewait
);
7860 ndr_print_uint32(ndr
, "enableoplocks", r
->enableoplocks
);
7861 ndr_print_uint32(ndr
, "enableoplockforceclose", r
->enableoplockforceclose
);
7862 ndr_print_uint32(ndr
, "enablefcbopens", r
->enablefcbopens
);
7863 ndr_print_uint32(ndr
, "enableraw", r
->enableraw
);
7864 ndr_print_uint32(ndr
, "enablesharednetdrives", r
->enablesharednetdrives
);
7865 ndr_print_uint32(ndr
, "minfreeconnections", r
->minfreeconnections
);
7866 ndr_print_uint32(ndr
, "maxfreeconnections", r
->maxfreeconnections
);
7867 ndr_print_uint32(ndr
, "initsesstable", r
->initsesstable
);
7868 ndr_print_uint32(ndr
, "initconntable", r
->initconntable
);
7869 ndr_print_uint32(ndr
, "initfiletable", r
->initfiletable
);
7870 ndr_print_uint32(ndr
, "initsearchtable", r
->initsearchtable
);
7871 ndr_print_uint32(ndr
, "alertsched", r
->alertsched
);
7872 ndr_print_uint32(ndr
, "errortreshold", r
->errortreshold
);
7873 ndr_print_uint32(ndr
, "networkerrortreshold", r
->networkerrortreshold
);
7874 ndr_print_uint32(ndr
, "diskspacetreshold", r
->diskspacetreshold
);
7875 ndr_print_uint32(ndr
, "reserved", r
->reserved
);
7876 ndr_print_uint32(ndr
, "maxlinkdelay", r
->maxlinkdelay
);
7877 ndr_print_uint32(ndr
, "minlinkthroughput", r
->minlinkthroughput
);
7878 ndr_print_uint32(ndr
, "linkinfovalidtime", r
->linkinfovalidtime
);
7879 ndr_print_uint32(ndr
, "scavqosinfoupdatetime", r
->scavqosinfoupdatetime
);
7880 ndr_print_uint32(ndr
, "maxworkitemidletime", r
->maxworkitemidletime
);
7884 static enum ndr_err_code
ndr_push_srvsvc_NetSrvInfo1005(struct ndr_push
*ndr
, int ndr_flags
, const struct srvsvc_NetSrvInfo1005
*r
)
7886 if (ndr_flags
& NDR_SCALARS
) {
7887 NDR_CHECK(ndr_push_align(ndr
, 4));
7888 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->comment
));
7890 if (ndr_flags
& NDR_BUFFERS
) {
7892 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->comment
, CH_UTF16
)));
7893 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
7894 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->comment
, CH_UTF16
)));
7895 NDR_CHECK(ndr_push_charset(ndr
, NDR_SCALARS
, r
->comment
, ndr_charset_length(r
->comment
, CH_UTF16
), sizeof(uint16_t), CH_UTF16
));
7898 return NDR_ERR_SUCCESS
;
7901 static enum ndr_err_code
ndr_pull_srvsvc_NetSrvInfo1005(struct ndr_pull
*ndr
, int ndr_flags
, struct srvsvc_NetSrvInfo1005
*r
)
7903 uint32_t _ptr_comment
;
7904 uint32_t size_comment_1
= 0;
7905 uint32_t length_comment_1
= 0;
7906 TALLOC_CTX
*_mem_save_comment_0
;
7907 if (ndr_flags
& NDR_SCALARS
) {
7908 NDR_CHECK(ndr_pull_align(ndr
, 4));
7909 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_comment
));
7911 NDR_PULL_ALLOC(ndr
, r
->comment
);
7916 if (ndr_flags
& NDR_BUFFERS
) {
7918 _mem_save_comment_0
= NDR_PULL_GET_MEM_CTX(ndr
);
7919 NDR_PULL_SET_MEM_CTX(ndr
, r
->comment
, 0);
7920 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->comment
));
7921 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->comment
));
7922 size_comment_1
= ndr_get_array_size(ndr
, &r
->comment
);
7923 length_comment_1
= ndr_get_array_length(ndr
, &r
->comment
);
7924 if (length_comment_1
> size_comment_1
) {
7925 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", size_comment_1
, length_comment_1
);
7927 NDR_CHECK(ndr_check_string_terminator(ndr
, length_comment_1
, sizeof(uint16_t)));
7928 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->comment
, length_comment_1
, sizeof(uint16_t), CH_UTF16
));
7929 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_comment_0
, 0);
7932 return NDR_ERR_SUCCESS
;
7935 _PUBLIC_
void ndr_print_srvsvc_NetSrvInfo1005(struct ndr_print
*ndr
, const char *name
, const struct srvsvc_NetSrvInfo1005
*r
)
7937 ndr_print_struct(ndr
, name
, "srvsvc_NetSrvInfo1005");
7939 ndr_print_ptr(ndr
, "comment", r
->comment
);
7942 ndr_print_string(ndr
, "comment", r
->comment
);
7948 static enum ndr_err_code
ndr_push_srvsvc_NetSrvInfo1010(struct ndr_push
*ndr
, int ndr_flags
, const struct srvsvc_NetSrvInfo1010
*r
)
7950 if (ndr_flags
& NDR_SCALARS
) {
7951 NDR_CHECK(ndr_push_align(ndr
, 4));
7952 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->disc
));
7954 if (ndr_flags
& NDR_BUFFERS
) {
7956 return NDR_ERR_SUCCESS
;
7959 static enum ndr_err_code
ndr_pull_srvsvc_NetSrvInfo1010(struct ndr_pull
*ndr
, int ndr_flags
, struct srvsvc_NetSrvInfo1010
*r
)
7961 if (ndr_flags
& NDR_SCALARS
) {
7962 NDR_CHECK(ndr_pull_align(ndr
, 4));
7963 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->disc
));
7965 if (ndr_flags
& NDR_BUFFERS
) {
7967 return NDR_ERR_SUCCESS
;
7970 _PUBLIC_
void ndr_print_srvsvc_NetSrvInfo1010(struct ndr_print
*ndr
, const char *name
, const struct srvsvc_NetSrvInfo1010
*r
)
7972 ndr_print_struct(ndr
, name
, "srvsvc_NetSrvInfo1010");
7974 ndr_print_uint32(ndr
, "disc", r
->disc
);
7978 static enum ndr_err_code
ndr_push_srvsvc_NetSrvInfo1016(struct ndr_push
*ndr
, int ndr_flags
, const struct srvsvc_NetSrvInfo1016
*r
)
7980 if (ndr_flags
& NDR_SCALARS
) {
7981 NDR_CHECK(ndr_push_align(ndr
, 4));
7982 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->hidden
));
7984 if (ndr_flags
& NDR_BUFFERS
) {
7986 return NDR_ERR_SUCCESS
;
7989 static enum ndr_err_code
ndr_pull_srvsvc_NetSrvInfo1016(struct ndr_pull
*ndr
, int ndr_flags
, struct srvsvc_NetSrvInfo1016
*r
)
7991 if (ndr_flags
& NDR_SCALARS
) {
7992 NDR_CHECK(ndr_pull_align(ndr
, 4));
7993 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->hidden
));
7995 if (ndr_flags
& NDR_BUFFERS
) {
7997 return NDR_ERR_SUCCESS
;
8000 _PUBLIC_
void ndr_print_srvsvc_NetSrvInfo1016(struct ndr_print
*ndr
, const char *name
, const struct srvsvc_NetSrvInfo1016
*r
)
8002 ndr_print_struct(ndr
, name
, "srvsvc_NetSrvInfo1016");
8004 ndr_print_uint32(ndr
, "hidden", r
->hidden
);
8008 static enum ndr_err_code
ndr_push_srvsvc_NetSrvInfo1017(struct ndr_push
*ndr
, int ndr_flags
, const struct srvsvc_NetSrvInfo1017
*r
)
8010 if (ndr_flags
& NDR_SCALARS
) {
8011 NDR_CHECK(ndr_push_align(ndr
, 4));
8012 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->announce
));
8014 if (ndr_flags
& NDR_BUFFERS
) {
8016 return NDR_ERR_SUCCESS
;
8019 static enum ndr_err_code
ndr_pull_srvsvc_NetSrvInfo1017(struct ndr_pull
*ndr
, int ndr_flags
, struct srvsvc_NetSrvInfo1017
*r
)
8021 if (ndr_flags
& NDR_SCALARS
) {
8022 NDR_CHECK(ndr_pull_align(ndr
, 4));
8023 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->announce
));
8025 if (ndr_flags
& NDR_BUFFERS
) {
8027 return NDR_ERR_SUCCESS
;
8030 _PUBLIC_
void ndr_print_srvsvc_NetSrvInfo1017(struct ndr_print
*ndr
, const char *name
, const struct srvsvc_NetSrvInfo1017
*r
)
8032 ndr_print_struct(ndr
, name
, "srvsvc_NetSrvInfo1017");
8034 ndr_print_uint32(ndr
, "announce", r
->announce
);
8038 static enum ndr_err_code
ndr_push_srvsvc_NetSrvInfo1018(struct ndr_push
*ndr
, int ndr_flags
, const struct srvsvc_NetSrvInfo1018
*r
)
8040 if (ndr_flags
& NDR_SCALARS
) {
8041 NDR_CHECK(ndr_push_align(ndr
, 4));
8042 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->anndelta
));
8044 if (ndr_flags
& NDR_BUFFERS
) {
8046 return NDR_ERR_SUCCESS
;
8049 static enum ndr_err_code
ndr_pull_srvsvc_NetSrvInfo1018(struct ndr_pull
*ndr
, int ndr_flags
, struct srvsvc_NetSrvInfo1018
*r
)
8051 if (ndr_flags
& NDR_SCALARS
) {
8052 NDR_CHECK(ndr_pull_align(ndr
, 4));
8053 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->anndelta
));
8055 if (ndr_flags
& NDR_BUFFERS
) {
8057 return NDR_ERR_SUCCESS
;
8060 _PUBLIC_
void ndr_print_srvsvc_NetSrvInfo1018(struct ndr_print
*ndr
, const char *name
, const struct srvsvc_NetSrvInfo1018
*r
)
8062 ndr_print_struct(ndr
, name
, "srvsvc_NetSrvInfo1018");
8064 ndr_print_uint32(ndr
, "anndelta", r
->anndelta
);
8068 static enum ndr_err_code
ndr_push_srvsvc_NetSrvInfo1107(struct ndr_push
*ndr
, int ndr_flags
, const struct srvsvc_NetSrvInfo1107
*r
)
8070 if (ndr_flags
& NDR_SCALARS
) {
8071 NDR_CHECK(ndr_push_align(ndr
, 4));
8072 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->users
));
8074 if (ndr_flags
& NDR_BUFFERS
) {
8076 return NDR_ERR_SUCCESS
;
8079 static enum ndr_err_code
ndr_pull_srvsvc_NetSrvInfo1107(struct ndr_pull
*ndr
, int ndr_flags
, struct srvsvc_NetSrvInfo1107
*r
)
8081 if (ndr_flags
& NDR_SCALARS
) {
8082 NDR_CHECK(ndr_pull_align(ndr
, 4));
8083 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->users
));
8085 if (ndr_flags
& NDR_BUFFERS
) {
8087 return NDR_ERR_SUCCESS
;
8090 _PUBLIC_
void ndr_print_srvsvc_NetSrvInfo1107(struct ndr_print
*ndr
, const char *name
, const struct srvsvc_NetSrvInfo1107
*r
)
8092 ndr_print_struct(ndr
, name
, "srvsvc_NetSrvInfo1107");
8094 ndr_print_uint32(ndr
, "users", r
->users
);
8098 static enum ndr_err_code
ndr_push_srvsvc_NetSrvInfo1501(struct ndr_push
*ndr
, int ndr_flags
, const struct srvsvc_NetSrvInfo1501
*r
)
8100 if (ndr_flags
& NDR_SCALARS
) {
8101 NDR_CHECK(ndr_push_align(ndr
, 4));
8102 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->sessopens
));
8104 if (ndr_flags
& NDR_BUFFERS
) {
8106 return NDR_ERR_SUCCESS
;
8109 static enum ndr_err_code
ndr_pull_srvsvc_NetSrvInfo1501(struct ndr_pull
*ndr
, int ndr_flags
, struct srvsvc_NetSrvInfo1501
*r
)
8111 if (ndr_flags
& NDR_SCALARS
) {
8112 NDR_CHECK(ndr_pull_align(ndr
, 4));
8113 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->sessopens
));
8115 if (ndr_flags
& NDR_BUFFERS
) {
8117 return NDR_ERR_SUCCESS
;
8120 _PUBLIC_
void ndr_print_srvsvc_NetSrvInfo1501(struct ndr_print
*ndr
, const char *name
, const struct srvsvc_NetSrvInfo1501
*r
)
8122 ndr_print_struct(ndr
, name
, "srvsvc_NetSrvInfo1501");
8124 ndr_print_uint32(ndr
, "sessopens", r
->sessopens
);
8128 static enum ndr_err_code
ndr_push_srvsvc_NetSrvInfo1502(struct ndr_push
*ndr
, int ndr_flags
, const struct srvsvc_NetSrvInfo1502
*r
)
8130 if (ndr_flags
& NDR_SCALARS
) {
8131 NDR_CHECK(ndr_push_align(ndr
, 4));
8132 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->sessvcs
));
8134 if (ndr_flags
& NDR_BUFFERS
) {
8136 return NDR_ERR_SUCCESS
;
8139 static enum ndr_err_code
ndr_pull_srvsvc_NetSrvInfo1502(struct ndr_pull
*ndr
, int ndr_flags
, struct srvsvc_NetSrvInfo1502
*r
)
8141 if (ndr_flags
& NDR_SCALARS
) {
8142 NDR_CHECK(ndr_pull_align(ndr
, 4));
8143 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->sessvcs
));
8145 if (ndr_flags
& NDR_BUFFERS
) {
8147 return NDR_ERR_SUCCESS
;
8150 _PUBLIC_
void ndr_print_srvsvc_NetSrvInfo1502(struct ndr_print
*ndr
, const char *name
, const struct srvsvc_NetSrvInfo1502
*r
)
8152 ndr_print_struct(ndr
, name
, "srvsvc_NetSrvInfo1502");
8154 ndr_print_uint32(ndr
, "sessvcs", r
->sessvcs
);
8158 static enum ndr_err_code
ndr_push_srvsvc_NetSrvInfo1503(struct ndr_push
*ndr
, int ndr_flags
, const struct srvsvc_NetSrvInfo1503
*r
)
8160 if (ndr_flags
& NDR_SCALARS
) {
8161 NDR_CHECK(ndr_push_align(ndr
, 4));
8162 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->opensearch
));
8164 if (ndr_flags
& NDR_BUFFERS
) {
8166 return NDR_ERR_SUCCESS
;
8169 static enum ndr_err_code
ndr_pull_srvsvc_NetSrvInfo1503(struct ndr_pull
*ndr
, int ndr_flags
, struct srvsvc_NetSrvInfo1503
*r
)
8171 if (ndr_flags
& NDR_SCALARS
) {
8172 NDR_CHECK(ndr_pull_align(ndr
, 4));
8173 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->opensearch
));
8175 if (ndr_flags
& NDR_BUFFERS
) {
8177 return NDR_ERR_SUCCESS
;
8180 _PUBLIC_
void ndr_print_srvsvc_NetSrvInfo1503(struct ndr_print
*ndr
, const char *name
, const struct srvsvc_NetSrvInfo1503
*r
)
8182 ndr_print_struct(ndr
, name
, "srvsvc_NetSrvInfo1503");
8184 ndr_print_uint32(ndr
, "opensearch", r
->opensearch
);
8188 static enum ndr_err_code
ndr_push_srvsvc_NetSrvInfo1506(struct ndr_push
*ndr
, int ndr_flags
, const struct srvsvc_NetSrvInfo1506
*r
)
8190 if (ndr_flags
& NDR_SCALARS
) {
8191 NDR_CHECK(ndr_push_align(ndr
, 4));
8192 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->maxworkitems
));
8194 if (ndr_flags
& NDR_BUFFERS
) {
8196 return NDR_ERR_SUCCESS
;
8199 static enum ndr_err_code
ndr_pull_srvsvc_NetSrvInfo1506(struct ndr_pull
*ndr
, int ndr_flags
, struct srvsvc_NetSrvInfo1506
*r
)
8201 if (ndr_flags
& NDR_SCALARS
) {
8202 NDR_CHECK(ndr_pull_align(ndr
, 4));
8203 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->maxworkitems
));
8205 if (ndr_flags
& NDR_BUFFERS
) {
8207 return NDR_ERR_SUCCESS
;
8210 _PUBLIC_
void ndr_print_srvsvc_NetSrvInfo1506(struct ndr_print
*ndr
, const char *name
, const struct srvsvc_NetSrvInfo1506
*r
)
8212 ndr_print_struct(ndr
, name
, "srvsvc_NetSrvInfo1506");
8214 ndr_print_uint32(ndr
, "maxworkitems", r
->maxworkitems
);
8218 static enum ndr_err_code
ndr_push_srvsvc_NetSrvInfo1509(struct ndr_push
*ndr
, int ndr_flags
, const struct srvsvc_NetSrvInfo1509
*r
)
8220 if (ndr_flags
& NDR_SCALARS
) {
8221 NDR_CHECK(ndr_push_align(ndr
, 4));
8222 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->maxrawbuflen
));
8224 if (ndr_flags
& NDR_BUFFERS
) {
8226 return NDR_ERR_SUCCESS
;
8229 static enum ndr_err_code
ndr_pull_srvsvc_NetSrvInfo1509(struct ndr_pull
*ndr
, int ndr_flags
, struct srvsvc_NetSrvInfo1509
*r
)
8231 if (ndr_flags
& NDR_SCALARS
) {
8232 NDR_CHECK(ndr_pull_align(ndr
, 4));
8233 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->maxrawbuflen
));
8235 if (ndr_flags
& NDR_BUFFERS
) {
8237 return NDR_ERR_SUCCESS
;
8240 _PUBLIC_
void ndr_print_srvsvc_NetSrvInfo1509(struct ndr_print
*ndr
, const char *name
, const struct srvsvc_NetSrvInfo1509
*r
)
8242 ndr_print_struct(ndr
, name
, "srvsvc_NetSrvInfo1509");
8244 ndr_print_uint32(ndr
, "maxrawbuflen", r
->maxrawbuflen
);
8248 static enum ndr_err_code
ndr_push_srvsvc_NetSrvInfo1510(struct ndr_push
*ndr
, int ndr_flags
, const struct srvsvc_NetSrvInfo1510
*r
)
8250 if (ndr_flags
& NDR_SCALARS
) {
8251 NDR_CHECK(ndr_push_align(ndr
, 4));
8252 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->sessusers
));
8254 if (ndr_flags
& NDR_BUFFERS
) {
8256 return NDR_ERR_SUCCESS
;
8259 static enum ndr_err_code
ndr_pull_srvsvc_NetSrvInfo1510(struct ndr_pull
*ndr
, int ndr_flags
, struct srvsvc_NetSrvInfo1510
*r
)
8261 if (ndr_flags
& NDR_SCALARS
) {
8262 NDR_CHECK(ndr_pull_align(ndr
, 4));
8263 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->sessusers
));
8265 if (ndr_flags
& NDR_BUFFERS
) {
8267 return NDR_ERR_SUCCESS
;
8270 _PUBLIC_
void ndr_print_srvsvc_NetSrvInfo1510(struct ndr_print
*ndr
, const char *name
, const struct srvsvc_NetSrvInfo1510
*r
)
8272 ndr_print_struct(ndr
, name
, "srvsvc_NetSrvInfo1510");
8274 ndr_print_uint32(ndr
, "sessusers", r
->sessusers
);
8278 static enum ndr_err_code
ndr_push_srvsvc_NetSrvInfo1511(struct ndr_push
*ndr
, int ndr_flags
, const struct srvsvc_NetSrvInfo1511
*r
)
8280 if (ndr_flags
& NDR_SCALARS
) {
8281 NDR_CHECK(ndr_push_align(ndr
, 4));
8282 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->sesscons
));
8284 if (ndr_flags
& NDR_BUFFERS
) {
8286 return NDR_ERR_SUCCESS
;
8289 static enum ndr_err_code
ndr_pull_srvsvc_NetSrvInfo1511(struct ndr_pull
*ndr
, int ndr_flags
, struct srvsvc_NetSrvInfo1511
*r
)
8291 if (ndr_flags
& NDR_SCALARS
) {
8292 NDR_CHECK(ndr_pull_align(ndr
, 4));
8293 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->sesscons
));
8295 if (ndr_flags
& NDR_BUFFERS
) {
8297 return NDR_ERR_SUCCESS
;
8300 _PUBLIC_
void ndr_print_srvsvc_NetSrvInfo1511(struct ndr_print
*ndr
, const char *name
, const struct srvsvc_NetSrvInfo1511
*r
)
8302 ndr_print_struct(ndr
, name
, "srvsvc_NetSrvInfo1511");
8304 ndr_print_uint32(ndr
, "sesscons", r
->sesscons
);
8308 static enum ndr_err_code
ndr_push_srvsvc_NetSrvInfo1512(struct ndr_push
*ndr
, int ndr_flags
, const struct srvsvc_NetSrvInfo1512
*r
)
8310 if (ndr_flags
& NDR_SCALARS
) {
8311 NDR_CHECK(ndr_push_align(ndr
, 4));
8312 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->maxnonpagedmemoryusage
));
8314 if (ndr_flags
& NDR_BUFFERS
) {
8316 return NDR_ERR_SUCCESS
;
8319 static enum ndr_err_code
ndr_pull_srvsvc_NetSrvInfo1512(struct ndr_pull
*ndr
, int ndr_flags
, struct srvsvc_NetSrvInfo1512
*r
)
8321 if (ndr_flags
& NDR_SCALARS
) {
8322 NDR_CHECK(ndr_pull_align(ndr
, 4));
8323 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->maxnonpagedmemoryusage
));
8325 if (ndr_flags
& NDR_BUFFERS
) {
8327 return NDR_ERR_SUCCESS
;
8330 _PUBLIC_
void ndr_print_srvsvc_NetSrvInfo1512(struct ndr_print
*ndr
, const char *name
, const struct srvsvc_NetSrvInfo1512
*r
)
8332 ndr_print_struct(ndr
, name
, "srvsvc_NetSrvInfo1512");
8334 ndr_print_uint32(ndr
, "maxnonpagedmemoryusage", r
->maxnonpagedmemoryusage
);
8338 static enum ndr_err_code
ndr_push_srvsvc_NetSrvInfo1513(struct ndr_push
*ndr
, int ndr_flags
, const struct srvsvc_NetSrvInfo1513
*r
)
8340 if (ndr_flags
& NDR_SCALARS
) {
8341 NDR_CHECK(ndr_push_align(ndr
, 4));
8342 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->maxpagedmemoryusage
));
8344 if (ndr_flags
& NDR_BUFFERS
) {
8346 return NDR_ERR_SUCCESS
;
8349 static enum ndr_err_code
ndr_pull_srvsvc_NetSrvInfo1513(struct ndr_pull
*ndr
, int ndr_flags
, struct srvsvc_NetSrvInfo1513
*r
)
8351 if (ndr_flags
& NDR_SCALARS
) {
8352 NDR_CHECK(ndr_pull_align(ndr
, 4));
8353 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->maxpagedmemoryusage
));
8355 if (ndr_flags
& NDR_BUFFERS
) {
8357 return NDR_ERR_SUCCESS
;
8360 _PUBLIC_
void ndr_print_srvsvc_NetSrvInfo1513(struct ndr_print
*ndr
, const char *name
, const struct srvsvc_NetSrvInfo1513
*r
)
8362 ndr_print_struct(ndr
, name
, "srvsvc_NetSrvInfo1513");
8364 ndr_print_uint32(ndr
, "maxpagedmemoryusage", r
->maxpagedmemoryusage
);
8368 static enum ndr_err_code
ndr_push_srvsvc_NetSrvInfo1514(struct ndr_push
*ndr
, int ndr_flags
, const struct srvsvc_NetSrvInfo1514
*r
)
8370 if (ndr_flags
& NDR_SCALARS
) {
8371 NDR_CHECK(ndr_push_align(ndr
, 4));
8372 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->enablesoftcompat
));
8374 if (ndr_flags
& NDR_BUFFERS
) {
8376 return NDR_ERR_SUCCESS
;
8379 static enum ndr_err_code
ndr_pull_srvsvc_NetSrvInfo1514(struct ndr_pull
*ndr
, int ndr_flags
, struct srvsvc_NetSrvInfo1514
*r
)
8381 if (ndr_flags
& NDR_SCALARS
) {
8382 NDR_CHECK(ndr_pull_align(ndr
, 4));
8383 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->enablesoftcompat
));
8385 if (ndr_flags
& NDR_BUFFERS
) {
8387 return NDR_ERR_SUCCESS
;
8390 _PUBLIC_
void ndr_print_srvsvc_NetSrvInfo1514(struct ndr_print
*ndr
, const char *name
, const struct srvsvc_NetSrvInfo1514
*r
)
8392 ndr_print_struct(ndr
, name
, "srvsvc_NetSrvInfo1514");
8394 ndr_print_uint32(ndr
, "enablesoftcompat", r
->enablesoftcompat
);
8398 static enum ndr_err_code
ndr_push_srvsvc_NetSrvInfo1515(struct ndr_push
*ndr
, int ndr_flags
, const struct srvsvc_NetSrvInfo1515
*r
)
8400 if (ndr_flags
& NDR_SCALARS
) {
8401 NDR_CHECK(ndr_push_align(ndr
, 4));
8402 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->enableforcedlogoff
));
8404 if (ndr_flags
& NDR_BUFFERS
) {
8406 return NDR_ERR_SUCCESS
;
8409 static enum ndr_err_code
ndr_pull_srvsvc_NetSrvInfo1515(struct ndr_pull
*ndr
, int ndr_flags
, struct srvsvc_NetSrvInfo1515
*r
)
8411 if (ndr_flags
& NDR_SCALARS
) {
8412 NDR_CHECK(ndr_pull_align(ndr
, 4));
8413 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->enableforcedlogoff
));
8415 if (ndr_flags
& NDR_BUFFERS
) {
8417 return NDR_ERR_SUCCESS
;
8420 _PUBLIC_
void ndr_print_srvsvc_NetSrvInfo1515(struct ndr_print
*ndr
, const char *name
, const struct srvsvc_NetSrvInfo1515
*r
)
8422 ndr_print_struct(ndr
, name
, "srvsvc_NetSrvInfo1515");
8424 ndr_print_uint32(ndr
, "enableforcedlogoff", r
->enableforcedlogoff
);
8428 static enum ndr_err_code
ndr_push_srvsvc_NetSrvInfo1516(struct ndr_push
*ndr
, int ndr_flags
, const struct srvsvc_NetSrvInfo1516
*r
)
8430 if (ndr_flags
& NDR_SCALARS
) {
8431 NDR_CHECK(ndr_push_align(ndr
, 4));
8432 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->timesource
));
8434 if (ndr_flags
& NDR_BUFFERS
) {
8436 return NDR_ERR_SUCCESS
;
8439 static enum ndr_err_code
ndr_pull_srvsvc_NetSrvInfo1516(struct ndr_pull
*ndr
, int ndr_flags
, struct srvsvc_NetSrvInfo1516
*r
)
8441 if (ndr_flags
& NDR_SCALARS
) {
8442 NDR_CHECK(ndr_pull_align(ndr
, 4));
8443 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->timesource
));
8445 if (ndr_flags
& NDR_BUFFERS
) {
8447 return NDR_ERR_SUCCESS
;
8450 _PUBLIC_
void ndr_print_srvsvc_NetSrvInfo1516(struct ndr_print
*ndr
, const char *name
, const struct srvsvc_NetSrvInfo1516
*r
)
8452 ndr_print_struct(ndr
, name
, "srvsvc_NetSrvInfo1516");
8454 ndr_print_uint32(ndr
, "timesource", r
->timesource
);
8458 static enum ndr_err_code
ndr_push_srvsvc_NetSrvInfo1518(struct ndr_push
*ndr
, int ndr_flags
, const struct srvsvc_NetSrvInfo1518
*r
)
8460 if (ndr_flags
& NDR_SCALARS
) {
8461 NDR_CHECK(ndr_push_align(ndr
, 4));
8462 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->lmannounce
));
8464 if (ndr_flags
& NDR_BUFFERS
) {
8466 return NDR_ERR_SUCCESS
;
8469 static enum ndr_err_code
ndr_pull_srvsvc_NetSrvInfo1518(struct ndr_pull
*ndr
, int ndr_flags
, struct srvsvc_NetSrvInfo1518
*r
)
8471 if (ndr_flags
& NDR_SCALARS
) {
8472 NDR_CHECK(ndr_pull_align(ndr
, 4));
8473 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->lmannounce
));
8475 if (ndr_flags
& NDR_BUFFERS
) {
8477 return NDR_ERR_SUCCESS
;
8480 _PUBLIC_
void ndr_print_srvsvc_NetSrvInfo1518(struct ndr_print
*ndr
, const char *name
, const struct srvsvc_NetSrvInfo1518
*r
)
8482 ndr_print_struct(ndr
, name
, "srvsvc_NetSrvInfo1518");
8484 ndr_print_uint32(ndr
, "lmannounce", r
->lmannounce
);
8488 static enum ndr_err_code
ndr_push_srvsvc_NetSrvInfo1520(struct ndr_push
*ndr
, int ndr_flags
, const struct srvsvc_NetSrvInfo1520
*r
)
8490 if (ndr_flags
& NDR_SCALARS
) {
8491 NDR_CHECK(ndr_push_align(ndr
, 4));
8492 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->maxcopyreadlen
));
8494 if (ndr_flags
& NDR_BUFFERS
) {
8496 return NDR_ERR_SUCCESS
;
8499 static enum ndr_err_code
ndr_pull_srvsvc_NetSrvInfo1520(struct ndr_pull
*ndr
, int ndr_flags
, struct srvsvc_NetSrvInfo1520
*r
)
8501 if (ndr_flags
& NDR_SCALARS
) {
8502 NDR_CHECK(ndr_pull_align(ndr
, 4));
8503 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->maxcopyreadlen
));
8505 if (ndr_flags
& NDR_BUFFERS
) {
8507 return NDR_ERR_SUCCESS
;
8510 _PUBLIC_
void ndr_print_srvsvc_NetSrvInfo1520(struct ndr_print
*ndr
, const char *name
, const struct srvsvc_NetSrvInfo1520
*r
)
8512 ndr_print_struct(ndr
, name
, "srvsvc_NetSrvInfo1520");
8514 ndr_print_uint32(ndr
, "maxcopyreadlen", r
->maxcopyreadlen
);
8518 static enum ndr_err_code
ndr_push_srvsvc_NetSrvInfo1521(struct ndr_push
*ndr
, int ndr_flags
, const struct srvsvc_NetSrvInfo1521
*r
)
8520 if (ndr_flags
& NDR_SCALARS
) {
8521 NDR_CHECK(ndr_push_align(ndr
, 4));
8522 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->maxcopywritelen
));
8524 if (ndr_flags
& NDR_BUFFERS
) {
8526 return NDR_ERR_SUCCESS
;
8529 static enum ndr_err_code
ndr_pull_srvsvc_NetSrvInfo1521(struct ndr_pull
*ndr
, int ndr_flags
, struct srvsvc_NetSrvInfo1521
*r
)
8531 if (ndr_flags
& NDR_SCALARS
) {
8532 NDR_CHECK(ndr_pull_align(ndr
, 4));
8533 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->maxcopywritelen
));
8535 if (ndr_flags
& NDR_BUFFERS
) {
8537 return NDR_ERR_SUCCESS
;
8540 _PUBLIC_
void ndr_print_srvsvc_NetSrvInfo1521(struct ndr_print
*ndr
, const char *name
, const struct srvsvc_NetSrvInfo1521
*r
)
8542 ndr_print_struct(ndr
, name
, "srvsvc_NetSrvInfo1521");
8544 ndr_print_uint32(ndr
, "maxcopywritelen", r
->maxcopywritelen
);
8548 static enum ndr_err_code
ndr_push_srvsvc_NetSrvInfo1522(struct ndr_push
*ndr
, int ndr_flags
, const struct srvsvc_NetSrvInfo1522
*r
)
8550 if (ndr_flags
& NDR_SCALARS
) {
8551 NDR_CHECK(ndr_push_align(ndr
, 4));
8552 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->minkeepsearch
));
8554 if (ndr_flags
& NDR_BUFFERS
) {
8556 return NDR_ERR_SUCCESS
;
8559 static enum ndr_err_code
ndr_pull_srvsvc_NetSrvInfo1522(struct ndr_pull
*ndr
, int ndr_flags
, struct srvsvc_NetSrvInfo1522
*r
)
8561 if (ndr_flags
& NDR_SCALARS
) {
8562 NDR_CHECK(ndr_pull_align(ndr
, 4));
8563 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->minkeepsearch
));
8565 if (ndr_flags
& NDR_BUFFERS
) {
8567 return NDR_ERR_SUCCESS
;
8570 _PUBLIC_
void ndr_print_srvsvc_NetSrvInfo1522(struct ndr_print
*ndr
, const char *name
, const struct srvsvc_NetSrvInfo1522
*r
)
8572 ndr_print_struct(ndr
, name
, "srvsvc_NetSrvInfo1522");
8574 ndr_print_uint32(ndr
, "minkeepsearch", r
->minkeepsearch
);
8578 static enum ndr_err_code
ndr_push_srvsvc_NetSrvInfo1523(struct ndr_push
*ndr
, int ndr_flags
, const struct srvsvc_NetSrvInfo1523
*r
)
8580 if (ndr_flags
& NDR_SCALARS
) {
8581 NDR_CHECK(ndr_push_align(ndr
, 4));
8582 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->maxkeepsearch
));
8584 if (ndr_flags
& NDR_BUFFERS
) {
8586 return NDR_ERR_SUCCESS
;
8589 static enum ndr_err_code
ndr_pull_srvsvc_NetSrvInfo1523(struct ndr_pull
*ndr
, int ndr_flags
, struct srvsvc_NetSrvInfo1523
*r
)
8591 if (ndr_flags
& NDR_SCALARS
) {
8592 NDR_CHECK(ndr_pull_align(ndr
, 4));
8593 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->maxkeepsearch
));
8595 if (ndr_flags
& NDR_BUFFERS
) {
8597 return NDR_ERR_SUCCESS
;
8600 _PUBLIC_
void ndr_print_srvsvc_NetSrvInfo1523(struct ndr_print
*ndr
, const char *name
, const struct srvsvc_NetSrvInfo1523
*r
)
8602 ndr_print_struct(ndr
, name
, "srvsvc_NetSrvInfo1523");
8604 ndr_print_uint32(ndr
, "maxkeepsearch", r
->maxkeepsearch
);
8608 static enum ndr_err_code
ndr_push_srvsvc_NetSrvInfo1524(struct ndr_push
*ndr
, int ndr_flags
, const struct srvsvc_NetSrvInfo1524
*r
)
8610 if (ndr_flags
& NDR_SCALARS
) {
8611 NDR_CHECK(ndr_push_align(ndr
, 4));
8612 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->minkeepcomplsearch
));
8614 if (ndr_flags
& NDR_BUFFERS
) {
8616 return NDR_ERR_SUCCESS
;
8619 static enum ndr_err_code
ndr_pull_srvsvc_NetSrvInfo1524(struct ndr_pull
*ndr
, int ndr_flags
, struct srvsvc_NetSrvInfo1524
*r
)
8621 if (ndr_flags
& NDR_SCALARS
) {
8622 NDR_CHECK(ndr_pull_align(ndr
, 4));
8623 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->minkeepcomplsearch
));
8625 if (ndr_flags
& NDR_BUFFERS
) {
8627 return NDR_ERR_SUCCESS
;
8630 _PUBLIC_
void ndr_print_srvsvc_NetSrvInfo1524(struct ndr_print
*ndr
, const char *name
, const struct srvsvc_NetSrvInfo1524
*r
)
8632 ndr_print_struct(ndr
, name
, "srvsvc_NetSrvInfo1524");
8634 ndr_print_uint32(ndr
, "minkeepcomplsearch", r
->minkeepcomplsearch
);
8638 static enum ndr_err_code
ndr_push_srvsvc_NetSrvInfo1525(struct ndr_push
*ndr
, int ndr_flags
, const struct srvsvc_NetSrvInfo1525
*r
)
8640 if (ndr_flags
& NDR_SCALARS
) {
8641 NDR_CHECK(ndr_push_align(ndr
, 4));
8642 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->maxkeepcomplsearch
));
8644 if (ndr_flags
& NDR_BUFFERS
) {
8646 return NDR_ERR_SUCCESS
;
8649 static enum ndr_err_code
ndr_pull_srvsvc_NetSrvInfo1525(struct ndr_pull
*ndr
, int ndr_flags
, struct srvsvc_NetSrvInfo1525
*r
)
8651 if (ndr_flags
& NDR_SCALARS
) {
8652 NDR_CHECK(ndr_pull_align(ndr
, 4));
8653 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->maxkeepcomplsearch
));
8655 if (ndr_flags
& NDR_BUFFERS
) {
8657 return NDR_ERR_SUCCESS
;
8660 _PUBLIC_
void ndr_print_srvsvc_NetSrvInfo1525(struct ndr_print
*ndr
, const char *name
, const struct srvsvc_NetSrvInfo1525
*r
)
8662 ndr_print_struct(ndr
, name
, "srvsvc_NetSrvInfo1525");
8664 ndr_print_uint32(ndr
, "maxkeepcomplsearch", r
->maxkeepcomplsearch
);
8668 static enum ndr_err_code
ndr_push_srvsvc_NetSrvInfo1528(struct ndr_push
*ndr
, int ndr_flags
, const struct srvsvc_NetSrvInfo1528
*r
)
8670 if (ndr_flags
& NDR_SCALARS
) {
8671 NDR_CHECK(ndr_push_align(ndr
, 4));
8672 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->scavtimeout
));
8674 if (ndr_flags
& NDR_BUFFERS
) {
8676 return NDR_ERR_SUCCESS
;
8679 static enum ndr_err_code
ndr_pull_srvsvc_NetSrvInfo1528(struct ndr_pull
*ndr
, int ndr_flags
, struct srvsvc_NetSrvInfo1528
*r
)
8681 if (ndr_flags
& NDR_SCALARS
) {
8682 NDR_CHECK(ndr_pull_align(ndr
, 4));
8683 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->scavtimeout
));
8685 if (ndr_flags
& NDR_BUFFERS
) {
8687 return NDR_ERR_SUCCESS
;
8690 _PUBLIC_
void ndr_print_srvsvc_NetSrvInfo1528(struct ndr_print
*ndr
, const char *name
, const struct srvsvc_NetSrvInfo1528
*r
)
8692 ndr_print_struct(ndr
, name
, "srvsvc_NetSrvInfo1528");
8694 ndr_print_uint32(ndr
, "scavtimeout", r
->scavtimeout
);
8698 static enum ndr_err_code
ndr_push_srvsvc_NetSrvInfo1529(struct ndr_push
*ndr
, int ndr_flags
, const struct srvsvc_NetSrvInfo1529
*r
)
8700 if (ndr_flags
& NDR_SCALARS
) {
8701 NDR_CHECK(ndr_push_align(ndr
, 4));
8702 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->minrcvqueue
));
8704 if (ndr_flags
& NDR_BUFFERS
) {
8706 return NDR_ERR_SUCCESS
;
8709 static enum ndr_err_code
ndr_pull_srvsvc_NetSrvInfo1529(struct ndr_pull
*ndr
, int ndr_flags
, struct srvsvc_NetSrvInfo1529
*r
)
8711 if (ndr_flags
& NDR_SCALARS
) {
8712 NDR_CHECK(ndr_pull_align(ndr
, 4));
8713 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->minrcvqueue
));
8715 if (ndr_flags
& NDR_BUFFERS
) {
8717 return NDR_ERR_SUCCESS
;
8720 _PUBLIC_
void ndr_print_srvsvc_NetSrvInfo1529(struct ndr_print
*ndr
, const char *name
, const struct srvsvc_NetSrvInfo1529
*r
)
8722 ndr_print_struct(ndr
, name
, "srvsvc_NetSrvInfo1529");
8724 ndr_print_uint32(ndr
, "minrcvqueue", r
->minrcvqueue
);
8728 static enum ndr_err_code
ndr_push_srvsvc_NetSrvInfo1530(struct ndr_push
*ndr
, int ndr_flags
, const struct srvsvc_NetSrvInfo1530
*r
)
8730 if (ndr_flags
& NDR_SCALARS
) {
8731 NDR_CHECK(ndr_push_align(ndr
, 4));
8732 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->minfreeworkitems
));
8734 if (ndr_flags
& NDR_BUFFERS
) {
8736 return NDR_ERR_SUCCESS
;
8739 static enum ndr_err_code
ndr_pull_srvsvc_NetSrvInfo1530(struct ndr_pull
*ndr
, int ndr_flags
, struct srvsvc_NetSrvInfo1530
*r
)
8741 if (ndr_flags
& NDR_SCALARS
) {
8742 NDR_CHECK(ndr_pull_align(ndr
, 4));
8743 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->minfreeworkitems
));
8745 if (ndr_flags
& NDR_BUFFERS
) {
8747 return NDR_ERR_SUCCESS
;
8750 _PUBLIC_
void ndr_print_srvsvc_NetSrvInfo1530(struct ndr_print
*ndr
, const char *name
, const struct srvsvc_NetSrvInfo1530
*r
)
8752 ndr_print_struct(ndr
, name
, "srvsvc_NetSrvInfo1530");
8754 ndr_print_uint32(ndr
, "minfreeworkitems", r
->minfreeworkitems
);
8758 static enum ndr_err_code
ndr_push_srvsvc_NetSrvInfo1533(struct ndr_push
*ndr
, int ndr_flags
, const struct srvsvc_NetSrvInfo1533
*r
)
8760 if (ndr_flags
& NDR_SCALARS
) {
8761 NDR_CHECK(ndr_push_align(ndr
, 4));
8762 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->maxmpxct
));
8764 if (ndr_flags
& NDR_BUFFERS
) {
8766 return NDR_ERR_SUCCESS
;
8769 static enum ndr_err_code
ndr_pull_srvsvc_NetSrvInfo1533(struct ndr_pull
*ndr
, int ndr_flags
, struct srvsvc_NetSrvInfo1533
*r
)
8771 if (ndr_flags
& NDR_SCALARS
) {
8772 NDR_CHECK(ndr_pull_align(ndr
, 4));
8773 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->maxmpxct
));
8775 if (ndr_flags
& NDR_BUFFERS
) {
8777 return NDR_ERR_SUCCESS
;
8780 _PUBLIC_
void ndr_print_srvsvc_NetSrvInfo1533(struct ndr_print
*ndr
, const char *name
, const struct srvsvc_NetSrvInfo1533
*r
)
8782 ndr_print_struct(ndr
, name
, "srvsvc_NetSrvInfo1533");
8784 ndr_print_uint32(ndr
, "maxmpxct", r
->maxmpxct
);
8788 static enum ndr_err_code
ndr_push_srvsvc_NetSrvInfo1534(struct ndr_push
*ndr
, int ndr_flags
, const struct srvsvc_NetSrvInfo1534
*r
)
8790 if (ndr_flags
& NDR_SCALARS
) {
8791 NDR_CHECK(ndr_push_align(ndr
, 4));
8792 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->oplockbreakwait
));
8794 if (ndr_flags
& NDR_BUFFERS
) {
8796 return NDR_ERR_SUCCESS
;
8799 static enum ndr_err_code
ndr_pull_srvsvc_NetSrvInfo1534(struct ndr_pull
*ndr
, int ndr_flags
, struct srvsvc_NetSrvInfo1534
*r
)
8801 if (ndr_flags
& NDR_SCALARS
) {
8802 NDR_CHECK(ndr_pull_align(ndr
, 4));
8803 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->oplockbreakwait
));
8805 if (ndr_flags
& NDR_BUFFERS
) {
8807 return NDR_ERR_SUCCESS
;
8810 _PUBLIC_
void ndr_print_srvsvc_NetSrvInfo1534(struct ndr_print
*ndr
, const char *name
, const struct srvsvc_NetSrvInfo1534
*r
)
8812 ndr_print_struct(ndr
, name
, "srvsvc_NetSrvInfo1534");
8814 ndr_print_uint32(ndr
, "oplockbreakwait", r
->oplockbreakwait
);
8818 static enum ndr_err_code
ndr_push_srvsvc_NetSrvInfo1535(struct ndr_push
*ndr
, int ndr_flags
, const struct srvsvc_NetSrvInfo1535
*r
)
8820 if (ndr_flags
& NDR_SCALARS
) {
8821 NDR_CHECK(ndr_push_align(ndr
, 4));
8822 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->oplockbreakresponsewait
));
8824 if (ndr_flags
& NDR_BUFFERS
) {
8826 return NDR_ERR_SUCCESS
;
8829 static enum ndr_err_code
ndr_pull_srvsvc_NetSrvInfo1535(struct ndr_pull
*ndr
, int ndr_flags
, struct srvsvc_NetSrvInfo1535
*r
)
8831 if (ndr_flags
& NDR_SCALARS
) {
8832 NDR_CHECK(ndr_pull_align(ndr
, 4));
8833 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->oplockbreakresponsewait
));
8835 if (ndr_flags
& NDR_BUFFERS
) {
8837 return NDR_ERR_SUCCESS
;
8840 _PUBLIC_
void ndr_print_srvsvc_NetSrvInfo1535(struct ndr_print
*ndr
, const char *name
, const struct srvsvc_NetSrvInfo1535
*r
)
8842 ndr_print_struct(ndr
, name
, "srvsvc_NetSrvInfo1535");
8844 ndr_print_uint32(ndr
, "oplockbreakresponsewait", r
->oplockbreakresponsewait
);
8848 static enum ndr_err_code
ndr_push_srvsvc_NetSrvInfo1536(struct ndr_push
*ndr
, int ndr_flags
, const struct srvsvc_NetSrvInfo1536
*r
)
8850 if (ndr_flags
& NDR_SCALARS
) {
8851 NDR_CHECK(ndr_push_align(ndr
, 4));
8852 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->enableoplocks
));
8854 if (ndr_flags
& NDR_BUFFERS
) {
8856 return NDR_ERR_SUCCESS
;
8859 static enum ndr_err_code
ndr_pull_srvsvc_NetSrvInfo1536(struct ndr_pull
*ndr
, int ndr_flags
, struct srvsvc_NetSrvInfo1536
*r
)
8861 if (ndr_flags
& NDR_SCALARS
) {
8862 NDR_CHECK(ndr_pull_align(ndr
, 4));
8863 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->enableoplocks
));
8865 if (ndr_flags
& NDR_BUFFERS
) {
8867 return NDR_ERR_SUCCESS
;
8870 _PUBLIC_
void ndr_print_srvsvc_NetSrvInfo1536(struct ndr_print
*ndr
, const char *name
, const struct srvsvc_NetSrvInfo1536
*r
)
8872 ndr_print_struct(ndr
, name
, "srvsvc_NetSrvInfo1536");
8874 ndr_print_uint32(ndr
, "enableoplocks", r
->enableoplocks
);
8878 static enum ndr_err_code
ndr_push_srvsvc_NetSrvInfo1537(struct ndr_push
*ndr
, int ndr_flags
, const struct srvsvc_NetSrvInfo1537
*r
)
8880 if (ndr_flags
& NDR_SCALARS
) {
8881 NDR_CHECK(ndr_push_align(ndr
, 4));
8882 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->enableoplockforceclose
));
8884 if (ndr_flags
& NDR_BUFFERS
) {
8886 return NDR_ERR_SUCCESS
;
8889 static enum ndr_err_code
ndr_pull_srvsvc_NetSrvInfo1537(struct ndr_pull
*ndr
, int ndr_flags
, struct srvsvc_NetSrvInfo1537
*r
)
8891 if (ndr_flags
& NDR_SCALARS
) {
8892 NDR_CHECK(ndr_pull_align(ndr
, 4));
8893 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->enableoplockforceclose
));
8895 if (ndr_flags
& NDR_BUFFERS
) {
8897 return NDR_ERR_SUCCESS
;
8900 _PUBLIC_
void ndr_print_srvsvc_NetSrvInfo1537(struct ndr_print
*ndr
, const char *name
, const struct srvsvc_NetSrvInfo1537
*r
)
8902 ndr_print_struct(ndr
, name
, "srvsvc_NetSrvInfo1537");
8904 ndr_print_uint32(ndr
, "enableoplockforceclose", r
->enableoplockforceclose
);
8908 static enum ndr_err_code
ndr_push_srvsvc_NetSrvInfo1538(struct ndr_push
*ndr
, int ndr_flags
, const struct srvsvc_NetSrvInfo1538
*r
)
8910 if (ndr_flags
& NDR_SCALARS
) {
8911 NDR_CHECK(ndr_push_align(ndr
, 4));
8912 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->enablefcbopens
));
8914 if (ndr_flags
& NDR_BUFFERS
) {
8916 return NDR_ERR_SUCCESS
;
8919 static enum ndr_err_code
ndr_pull_srvsvc_NetSrvInfo1538(struct ndr_pull
*ndr
, int ndr_flags
, struct srvsvc_NetSrvInfo1538
*r
)
8921 if (ndr_flags
& NDR_SCALARS
) {
8922 NDR_CHECK(ndr_pull_align(ndr
, 4));
8923 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->enablefcbopens
));
8925 if (ndr_flags
& NDR_BUFFERS
) {
8927 return NDR_ERR_SUCCESS
;
8930 _PUBLIC_
void ndr_print_srvsvc_NetSrvInfo1538(struct ndr_print
*ndr
, const char *name
, const struct srvsvc_NetSrvInfo1538
*r
)
8932 ndr_print_struct(ndr
, name
, "srvsvc_NetSrvInfo1538");
8934 ndr_print_uint32(ndr
, "enablefcbopens", r
->enablefcbopens
);
8938 static enum ndr_err_code
ndr_push_srvsvc_NetSrvInfo1539(struct ndr_push
*ndr
, int ndr_flags
, const struct srvsvc_NetSrvInfo1539
*r
)
8940 if (ndr_flags
& NDR_SCALARS
) {
8941 NDR_CHECK(ndr_push_align(ndr
, 4));
8942 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->enableraw
));
8944 if (ndr_flags
& NDR_BUFFERS
) {
8946 return NDR_ERR_SUCCESS
;
8949 static enum ndr_err_code
ndr_pull_srvsvc_NetSrvInfo1539(struct ndr_pull
*ndr
, int ndr_flags
, struct srvsvc_NetSrvInfo1539
*r
)
8951 if (ndr_flags
& NDR_SCALARS
) {
8952 NDR_CHECK(ndr_pull_align(ndr
, 4));
8953 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->enableraw
));
8955 if (ndr_flags
& NDR_BUFFERS
) {
8957 return NDR_ERR_SUCCESS
;
8960 _PUBLIC_
void ndr_print_srvsvc_NetSrvInfo1539(struct ndr_print
*ndr
, const char *name
, const struct srvsvc_NetSrvInfo1539
*r
)
8962 ndr_print_struct(ndr
, name
, "srvsvc_NetSrvInfo1539");
8964 ndr_print_uint32(ndr
, "enableraw", r
->enableraw
);
8968 static enum ndr_err_code
ndr_push_srvsvc_NetSrvInfo1540(struct ndr_push
*ndr
, int ndr_flags
, const struct srvsvc_NetSrvInfo1540
*r
)
8970 if (ndr_flags
& NDR_SCALARS
) {
8971 NDR_CHECK(ndr_push_align(ndr
, 4));
8972 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->enablesharednetdrives
));
8974 if (ndr_flags
& NDR_BUFFERS
) {
8976 return NDR_ERR_SUCCESS
;
8979 static enum ndr_err_code
ndr_pull_srvsvc_NetSrvInfo1540(struct ndr_pull
*ndr
, int ndr_flags
, struct srvsvc_NetSrvInfo1540
*r
)
8981 if (ndr_flags
& NDR_SCALARS
) {
8982 NDR_CHECK(ndr_pull_align(ndr
, 4));
8983 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->enablesharednetdrives
));
8985 if (ndr_flags
& NDR_BUFFERS
) {
8987 return NDR_ERR_SUCCESS
;
8990 _PUBLIC_
void ndr_print_srvsvc_NetSrvInfo1540(struct ndr_print
*ndr
, const char *name
, const struct srvsvc_NetSrvInfo1540
*r
)
8992 ndr_print_struct(ndr
, name
, "srvsvc_NetSrvInfo1540");
8994 ndr_print_uint32(ndr
, "enablesharednetdrives", r
->enablesharednetdrives
);
8998 static enum ndr_err_code
ndr_push_srvsvc_NetSrvInfo1541(struct ndr_push
*ndr
, int ndr_flags
, const struct srvsvc_NetSrvInfo1541
*r
)
9000 if (ndr_flags
& NDR_SCALARS
) {
9001 NDR_CHECK(ndr_push_align(ndr
, 4));
9002 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->minfreeconnections
));
9004 if (ndr_flags
& NDR_BUFFERS
) {
9006 return NDR_ERR_SUCCESS
;
9009 static enum ndr_err_code
ndr_pull_srvsvc_NetSrvInfo1541(struct ndr_pull
*ndr
, int ndr_flags
, struct srvsvc_NetSrvInfo1541
*r
)
9011 if (ndr_flags
& NDR_SCALARS
) {
9012 NDR_CHECK(ndr_pull_align(ndr
, 4));
9013 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->minfreeconnections
));
9015 if (ndr_flags
& NDR_BUFFERS
) {
9017 return NDR_ERR_SUCCESS
;
9020 _PUBLIC_
void ndr_print_srvsvc_NetSrvInfo1541(struct ndr_print
*ndr
, const char *name
, const struct srvsvc_NetSrvInfo1541
*r
)
9022 ndr_print_struct(ndr
, name
, "srvsvc_NetSrvInfo1541");
9024 ndr_print_uint32(ndr
, "minfreeconnections", r
->minfreeconnections
);
9028 static enum ndr_err_code
ndr_push_srvsvc_NetSrvInfo1542(struct ndr_push
*ndr
, int ndr_flags
, const struct srvsvc_NetSrvInfo1542
*r
)
9030 if (ndr_flags
& NDR_SCALARS
) {
9031 NDR_CHECK(ndr_push_align(ndr
, 4));
9032 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->maxfreeconnections
));
9034 if (ndr_flags
& NDR_BUFFERS
) {
9036 return NDR_ERR_SUCCESS
;
9039 static enum ndr_err_code
ndr_pull_srvsvc_NetSrvInfo1542(struct ndr_pull
*ndr
, int ndr_flags
, struct srvsvc_NetSrvInfo1542
*r
)
9041 if (ndr_flags
& NDR_SCALARS
) {
9042 NDR_CHECK(ndr_pull_align(ndr
, 4));
9043 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->maxfreeconnections
));
9045 if (ndr_flags
& NDR_BUFFERS
) {
9047 return NDR_ERR_SUCCESS
;
9050 _PUBLIC_
void ndr_print_srvsvc_NetSrvInfo1542(struct ndr_print
*ndr
, const char *name
, const struct srvsvc_NetSrvInfo1542
*r
)
9052 ndr_print_struct(ndr
, name
, "srvsvc_NetSrvInfo1542");
9054 ndr_print_uint32(ndr
, "maxfreeconnections", r
->maxfreeconnections
);
9058 static enum ndr_err_code
ndr_push_srvsvc_NetSrvInfo1543(struct ndr_push
*ndr
, int ndr_flags
, const struct srvsvc_NetSrvInfo1543
*r
)
9060 if (ndr_flags
& NDR_SCALARS
) {
9061 NDR_CHECK(ndr_push_align(ndr
, 4));
9062 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->initsesstable
));
9064 if (ndr_flags
& NDR_BUFFERS
) {
9066 return NDR_ERR_SUCCESS
;
9069 static enum ndr_err_code
ndr_pull_srvsvc_NetSrvInfo1543(struct ndr_pull
*ndr
, int ndr_flags
, struct srvsvc_NetSrvInfo1543
*r
)
9071 if (ndr_flags
& NDR_SCALARS
) {
9072 NDR_CHECK(ndr_pull_align(ndr
, 4));
9073 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->initsesstable
));
9075 if (ndr_flags
& NDR_BUFFERS
) {
9077 return NDR_ERR_SUCCESS
;
9080 _PUBLIC_
void ndr_print_srvsvc_NetSrvInfo1543(struct ndr_print
*ndr
, const char *name
, const struct srvsvc_NetSrvInfo1543
*r
)
9082 ndr_print_struct(ndr
, name
, "srvsvc_NetSrvInfo1543");
9084 ndr_print_uint32(ndr
, "initsesstable", r
->initsesstable
);
9088 static enum ndr_err_code
ndr_push_srvsvc_NetSrvInfo1544(struct ndr_push
*ndr
, int ndr_flags
, const struct srvsvc_NetSrvInfo1544
*r
)
9090 if (ndr_flags
& NDR_SCALARS
) {
9091 NDR_CHECK(ndr_push_align(ndr
, 4));
9092 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->initconntable
));
9094 if (ndr_flags
& NDR_BUFFERS
) {
9096 return NDR_ERR_SUCCESS
;
9099 static enum ndr_err_code
ndr_pull_srvsvc_NetSrvInfo1544(struct ndr_pull
*ndr
, int ndr_flags
, struct srvsvc_NetSrvInfo1544
*r
)
9101 if (ndr_flags
& NDR_SCALARS
) {
9102 NDR_CHECK(ndr_pull_align(ndr
, 4));
9103 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->initconntable
));
9105 if (ndr_flags
& NDR_BUFFERS
) {
9107 return NDR_ERR_SUCCESS
;
9110 _PUBLIC_
void ndr_print_srvsvc_NetSrvInfo1544(struct ndr_print
*ndr
, const char *name
, const struct srvsvc_NetSrvInfo1544
*r
)
9112 ndr_print_struct(ndr
, name
, "srvsvc_NetSrvInfo1544");
9114 ndr_print_uint32(ndr
, "initconntable", r
->initconntable
);
9118 static enum ndr_err_code
ndr_push_srvsvc_NetSrvInfo1545(struct ndr_push
*ndr
, int ndr_flags
, const struct srvsvc_NetSrvInfo1545
*r
)
9120 if (ndr_flags
& NDR_SCALARS
) {
9121 NDR_CHECK(ndr_push_align(ndr
, 4));
9122 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->initfiletable
));
9124 if (ndr_flags
& NDR_BUFFERS
) {
9126 return NDR_ERR_SUCCESS
;
9129 static enum ndr_err_code
ndr_pull_srvsvc_NetSrvInfo1545(struct ndr_pull
*ndr
, int ndr_flags
, struct srvsvc_NetSrvInfo1545
*r
)
9131 if (ndr_flags
& NDR_SCALARS
) {
9132 NDR_CHECK(ndr_pull_align(ndr
, 4));
9133 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->initfiletable
));
9135 if (ndr_flags
& NDR_BUFFERS
) {
9137 return NDR_ERR_SUCCESS
;
9140 _PUBLIC_
void ndr_print_srvsvc_NetSrvInfo1545(struct ndr_print
*ndr
, const char *name
, const struct srvsvc_NetSrvInfo1545
*r
)
9142 ndr_print_struct(ndr
, name
, "srvsvc_NetSrvInfo1545");
9144 ndr_print_uint32(ndr
, "initfiletable", r
->initfiletable
);
9148 static enum ndr_err_code
ndr_push_srvsvc_NetSrvInfo1546(struct ndr_push
*ndr
, int ndr_flags
, const struct srvsvc_NetSrvInfo1546
*r
)
9150 if (ndr_flags
& NDR_SCALARS
) {
9151 NDR_CHECK(ndr_push_align(ndr
, 4));
9152 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->initsearchtable
));
9154 if (ndr_flags
& NDR_BUFFERS
) {
9156 return NDR_ERR_SUCCESS
;
9159 static enum ndr_err_code
ndr_pull_srvsvc_NetSrvInfo1546(struct ndr_pull
*ndr
, int ndr_flags
, struct srvsvc_NetSrvInfo1546
*r
)
9161 if (ndr_flags
& NDR_SCALARS
) {
9162 NDR_CHECK(ndr_pull_align(ndr
, 4));
9163 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->initsearchtable
));
9165 if (ndr_flags
& NDR_BUFFERS
) {
9167 return NDR_ERR_SUCCESS
;
9170 _PUBLIC_
void ndr_print_srvsvc_NetSrvInfo1546(struct ndr_print
*ndr
, const char *name
, const struct srvsvc_NetSrvInfo1546
*r
)
9172 ndr_print_struct(ndr
, name
, "srvsvc_NetSrvInfo1546");
9174 ndr_print_uint32(ndr
, "initsearchtable", r
->initsearchtable
);
9178 static enum ndr_err_code
ndr_push_srvsvc_NetSrvInfo1547(struct ndr_push
*ndr
, int ndr_flags
, const struct srvsvc_NetSrvInfo1547
*r
)
9180 if (ndr_flags
& NDR_SCALARS
) {
9181 NDR_CHECK(ndr_push_align(ndr
, 4));
9182 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->alertsched
));
9184 if (ndr_flags
& NDR_BUFFERS
) {
9186 return NDR_ERR_SUCCESS
;
9189 static enum ndr_err_code
ndr_pull_srvsvc_NetSrvInfo1547(struct ndr_pull
*ndr
, int ndr_flags
, struct srvsvc_NetSrvInfo1547
*r
)
9191 if (ndr_flags
& NDR_SCALARS
) {
9192 NDR_CHECK(ndr_pull_align(ndr
, 4));
9193 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->alertsched
));
9195 if (ndr_flags
& NDR_BUFFERS
) {
9197 return NDR_ERR_SUCCESS
;
9200 _PUBLIC_
void ndr_print_srvsvc_NetSrvInfo1547(struct ndr_print
*ndr
, const char *name
, const struct srvsvc_NetSrvInfo1547
*r
)
9202 ndr_print_struct(ndr
, name
, "srvsvc_NetSrvInfo1547");
9204 ndr_print_uint32(ndr
, "alertsched", r
->alertsched
);
9208 static enum ndr_err_code
ndr_push_srvsvc_NetSrvInfo1548(struct ndr_push
*ndr
, int ndr_flags
, const struct srvsvc_NetSrvInfo1548
*r
)
9210 if (ndr_flags
& NDR_SCALARS
) {
9211 NDR_CHECK(ndr_push_align(ndr
, 4));
9212 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->errortreshold
));
9214 if (ndr_flags
& NDR_BUFFERS
) {
9216 return NDR_ERR_SUCCESS
;
9219 static enum ndr_err_code
ndr_pull_srvsvc_NetSrvInfo1548(struct ndr_pull
*ndr
, int ndr_flags
, struct srvsvc_NetSrvInfo1548
*r
)
9221 if (ndr_flags
& NDR_SCALARS
) {
9222 NDR_CHECK(ndr_pull_align(ndr
, 4));
9223 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->errortreshold
));
9225 if (ndr_flags
& NDR_BUFFERS
) {
9227 return NDR_ERR_SUCCESS
;
9230 _PUBLIC_
void ndr_print_srvsvc_NetSrvInfo1548(struct ndr_print
*ndr
, const char *name
, const struct srvsvc_NetSrvInfo1548
*r
)
9232 ndr_print_struct(ndr
, name
, "srvsvc_NetSrvInfo1548");
9234 ndr_print_uint32(ndr
, "errortreshold", r
->errortreshold
);
9238 static enum ndr_err_code
ndr_push_srvsvc_NetSrvInfo1549(struct ndr_push
*ndr
, int ndr_flags
, const struct srvsvc_NetSrvInfo1549
*r
)
9240 if (ndr_flags
& NDR_SCALARS
) {
9241 NDR_CHECK(ndr_push_align(ndr
, 4));
9242 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->networkerrortreshold
));
9244 if (ndr_flags
& NDR_BUFFERS
) {
9246 return NDR_ERR_SUCCESS
;
9249 static enum ndr_err_code
ndr_pull_srvsvc_NetSrvInfo1549(struct ndr_pull
*ndr
, int ndr_flags
, struct srvsvc_NetSrvInfo1549
*r
)
9251 if (ndr_flags
& NDR_SCALARS
) {
9252 NDR_CHECK(ndr_pull_align(ndr
, 4));
9253 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->networkerrortreshold
));
9255 if (ndr_flags
& NDR_BUFFERS
) {
9257 return NDR_ERR_SUCCESS
;
9260 _PUBLIC_
void ndr_print_srvsvc_NetSrvInfo1549(struct ndr_print
*ndr
, const char *name
, const struct srvsvc_NetSrvInfo1549
*r
)
9262 ndr_print_struct(ndr
, name
, "srvsvc_NetSrvInfo1549");
9264 ndr_print_uint32(ndr
, "networkerrortreshold", r
->networkerrortreshold
);
9268 static enum ndr_err_code
ndr_push_srvsvc_NetSrvInfo1550(struct ndr_push
*ndr
, int ndr_flags
, const struct srvsvc_NetSrvInfo1550
*r
)
9270 if (ndr_flags
& NDR_SCALARS
) {
9271 NDR_CHECK(ndr_push_align(ndr
, 4));
9272 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->diskspacetreshold
));
9274 if (ndr_flags
& NDR_BUFFERS
) {
9276 return NDR_ERR_SUCCESS
;
9279 static enum ndr_err_code
ndr_pull_srvsvc_NetSrvInfo1550(struct ndr_pull
*ndr
, int ndr_flags
, struct srvsvc_NetSrvInfo1550
*r
)
9281 if (ndr_flags
& NDR_SCALARS
) {
9282 NDR_CHECK(ndr_pull_align(ndr
, 4));
9283 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->diskspacetreshold
));
9285 if (ndr_flags
& NDR_BUFFERS
) {
9287 return NDR_ERR_SUCCESS
;
9290 _PUBLIC_
void ndr_print_srvsvc_NetSrvInfo1550(struct ndr_print
*ndr
, const char *name
, const struct srvsvc_NetSrvInfo1550
*r
)
9292 ndr_print_struct(ndr
, name
, "srvsvc_NetSrvInfo1550");
9294 ndr_print_uint32(ndr
, "diskspacetreshold", r
->diskspacetreshold
);
9298 static enum ndr_err_code
ndr_push_srvsvc_NetSrvInfo1552(struct ndr_push
*ndr
, int ndr_flags
, const struct srvsvc_NetSrvInfo1552
*r
)
9300 if (ndr_flags
& NDR_SCALARS
) {
9301 NDR_CHECK(ndr_push_align(ndr
, 4));
9302 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->maxlinkdelay
));
9304 if (ndr_flags
& NDR_BUFFERS
) {
9306 return NDR_ERR_SUCCESS
;
9309 static enum ndr_err_code
ndr_pull_srvsvc_NetSrvInfo1552(struct ndr_pull
*ndr
, int ndr_flags
, struct srvsvc_NetSrvInfo1552
*r
)
9311 if (ndr_flags
& NDR_SCALARS
) {
9312 NDR_CHECK(ndr_pull_align(ndr
, 4));
9313 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->maxlinkdelay
));
9315 if (ndr_flags
& NDR_BUFFERS
) {
9317 return NDR_ERR_SUCCESS
;
9320 _PUBLIC_
void ndr_print_srvsvc_NetSrvInfo1552(struct ndr_print
*ndr
, const char *name
, const struct srvsvc_NetSrvInfo1552
*r
)
9322 ndr_print_struct(ndr
, name
, "srvsvc_NetSrvInfo1552");
9324 ndr_print_uint32(ndr
, "maxlinkdelay", r
->maxlinkdelay
);
9328 static enum ndr_err_code
ndr_push_srvsvc_NetSrvInfo1553(struct ndr_push
*ndr
, int ndr_flags
, const struct srvsvc_NetSrvInfo1553
*r
)
9330 if (ndr_flags
& NDR_SCALARS
) {
9331 NDR_CHECK(ndr_push_align(ndr
, 4));
9332 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->minlinkthroughput
));
9334 if (ndr_flags
& NDR_BUFFERS
) {
9336 return NDR_ERR_SUCCESS
;
9339 static enum ndr_err_code
ndr_pull_srvsvc_NetSrvInfo1553(struct ndr_pull
*ndr
, int ndr_flags
, struct srvsvc_NetSrvInfo1553
*r
)
9341 if (ndr_flags
& NDR_SCALARS
) {
9342 NDR_CHECK(ndr_pull_align(ndr
, 4));
9343 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->minlinkthroughput
));
9345 if (ndr_flags
& NDR_BUFFERS
) {
9347 return NDR_ERR_SUCCESS
;
9350 _PUBLIC_
void ndr_print_srvsvc_NetSrvInfo1553(struct ndr_print
*ndr
, const char *name
, const struct srvsvc_NetSrvInfo1553
*r
)
9352 ndr_print_struct(ndr
, name
, "srvsvc_NetSrvInfo1553");
9354 ndr_print_uint32(ndr
, "minlinkthroughput", r
->minlinkthroughput
);
9358 static enum ndr_err_code
ndr_push_srvsvc_NetSrvInfo1554(struct ndr_push
*ndr
, int ndr_flags
, const struct srvsvc_NetSrvInfo1554
*r
)
9360 if (ndr_flags
& NDR_SCALARS
) {
9361 NDR_CHECK(ndr_push_align(ndr
, 4));
9362 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->linkinfovalidtime
));
9364 if (ndr_flags
& NDR_BUFFERS
) {
9366 return NDR_ERR_SUCCESS
;
9369 static enum ndr_err_code
ndr_pull_srvsvc_NetSrvInfo1554(struct ndr_pull
*ndr
, int ndr_flags
, struct srvsvc_NetSrvInfo1554
*r
)
9371 if (ndr_flags
& NDR_SCALARS
) {
9372 NDR_CHECK(ndr_pull_align(ndr
, 4));
9373 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->linkinfovalidtime
));
9375 if (ndr_flags
& NDR_BUFFERS
) {
9377 return NDR_ERR_SUCCESS
;
9380 _PUBLIC_
void ndr_print_srvsvc_NetSrvInfo1554(struct ndr_print
*ndr
, const char *name
, const struct srvsvc_NetSrvInfo1554
*r
)
9382 ndr_print_struct(ndr
, name
, "srvsvc_NetSrvInfo1554");
9384 ndr_print_uint32(ndr
, "linkinfovalidtime", r
->linkinfovalidtime
);
9388 static enum ndr_err_code
ndr_push_srvsvc_NetSrvInfo1555(struct ndr_push
*ndr
, int ndr_flags
, const struct srvsvc_NetSrvInfo1555
*r
)
9390 if (ndr_flags
& NDR_SCALARS
) {
9391 NDR_CHECK(ndr_push_align(ndr
, 4));
9392 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->scavqosinfoupdatetime
));
9394 if (ndr_flags
& NDR_BUFFERS
) {
9396 return NDR_ERR_SUCCESS
;
9399 static enum ndr_err_code
ndr_pull_srvsvc_NetSrvInfo1555(struct ndr_pull
*ndr
, int ndr_flags
, struct srvsvc_NetSrvInfo1555
*r
)
9401 if (ndr_flags
& NDR_SCALARS
) {
9402 NDR_CHECK(ndr_pull_align(ndr
, 4));
9403 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->scavqosinfoupdatetime
));
9405 if (ndr_flags
& NDR_BUFFERS
) {
9407 return NDR_ERR_SUCCESS
;
9410 _PUBLIC_
void ndr_print_srvsvc_NetSrvInfo1555(struct ndr_print
*ndr
, const char *name
, const struct srvsvc_NetSrvInfo1555
*r
)
9412 ndr_print_struct(ndr
, name
, "srvsvc_NetSrvInfo1555");
9414 ndr_print_uint32(ndr
, "scavqosinfoupdatetime", r
->scavqosinfoupdatetime
);
9418 static enum ndr_err_code
ndr_push_srvsvc_NetSrvInfo1556(struct ndr_push
*ndr
, int ndr_flags
, const struct srvsvc_NetSrvInfo1556
*r
)
9420 if (ndr_flags
& NDR_SCALARS
) {
9421 NDR_CHECK(ndr_push_align(ndr
, 4));
9422 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->maxworkitemidletime
));
9424 if (ndr_flags
& NDR_BUFFERS
) {
9426 return NDR_ERR_SUCCESS
;
9429 static enum ndr_err_code
ndr_pull_srvsvc_NetSrvInfo1556(struct ndr_pull
*ndr
, int ndr_flags
, struct srvsvc_NetSrvInfo1556
*r
)
9431 if (ndr_flags
& NDR_SCALARS
) {
9432 NDR_CHECK(ndr_pull_align(ndr
, 4));
9433 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->maxworkitemidletime
));
9435 if (ndr_flags
& NDR_BUFFERS
) {
9437 return NDR_ERR_SUCCESS
;
9440 _PUBLIC_
void ndr_print_srvsvc_NetSrvInfo1556(struct ndr_print
*ndr
, const char *name
, const struct srvsvc_NetSrvInfo1556
*r
)
9442 ndr_print_struct(ndr
, name
, "srvsvc_NetSrvInfo1556");
9444 ndr_print_uint32(ndr
, "maxworkitemidletime", r
->maxworkitemidletime
);
9448 static enum ndr_err_code
ndr_push_srvsvc_NetSrvInfo(struct ndr_push
*ndr
, int ndr_flags
, const union srvsvc_NetSrvInfo
*r
)
9450 if (ndr_flags
& NDR_SCALARS
) {
9451 int level
= ndr_push_get_switch_value(ndr
, r
);
9452 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, level
));
9455 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->info100
));
9459 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->info101
));
9463 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->info102
));
9467 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->info402
));
9471 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->info403
));
9475 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->info502
));
9479 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->info503
));
9483 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->info599
));
9487 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->info1005
));
9491 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->info1010
));
9495 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->info1016
));
9499 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->info1017
));
9503 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->info1018
));
9507 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->info1107
));
9511 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->info1501
));
9515 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->info1502
));
9519 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->info1503
));
9523 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->info1506
));
9527 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->info1509
));
9531 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->info1510
));
9535 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->info1511
));
9539 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->info1512
));
9543 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->info1513
));
9547 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->info1514
));
9551 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->info1515
));
9555 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->info1516
));
9559 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->info1518
));
9563 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->info1520
));
9567 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->info1521
));
9571 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->info1522
));
9575 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->info1523
));
9579 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->info1524
));
9583 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->info1525
));
9587 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->info1528
));
9591 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->info1529
));
9595 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->info1530
));
9599 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->info1533
));
9603 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->info1534
));
9607 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->info1535
));
9611 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->info1536
));
9615 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->info1537
));
9619 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->info1538
));
9623 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->info1539
));
9627 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->info1540
));
9631 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->info1541
));
9635 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->info1542
));
9639 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->info1543
));
9643 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->info1544
));
9647 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->info1545
));
9651 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->info1546
));
9655 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->info1547
));
9659 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->info1548
));
9663 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->info1549
));
9667 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->info1550
));
9671 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->info1552
));
9675 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->info1553
));
9679 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->info1554
));
9683 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->info1555
));
9687 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->info1556
));
9695 if (ndr_flags
& NDR_BUFFERS
) {
9696 int level
= ndr_push_get_switch_value(ndr
, r
);
9700 NDR_CHECK(ndr_push_srvsvc_NetSrvInfo100(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->info100
));
9706 NDR_CHECK(ndr_push_srvsvc_NetSrvInfo101(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->info101
));
9712 NDR_CHECK(ndr_push_srvsvc_NetSrvInfo102(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->info102
));
9718 NDR_CHECK(ndr_push_srvsvc_NetSrvInfo402(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->info402
));
9724 NDR_CHECK(ndr_push_srvsvc_NetSrvInfo403(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->info403
));
9730 NDR_CHECK(ndr_push_srvsvc_NetSrvInfo502(ndr
, NDR_SCALARS
, r
->info502
));
9736 NDR_CHECK(ndr_push_srvsvc_NetSrvInfo503(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->info503
));
9742 NDR_CHECK(ndr_push_srvsvc_NetSrvInfo599(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->info599
));
9748 NDR_CHECK(ndr_push_srvsvc_NetSrvInfo1005(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->info1005
));
9754 NDR_CHECK(ndr_push_srvsvc_NetSrvInfo1010(ndr
, NDR_SCALARS
, r
->info1010
));
9760 NDR_CHECK(ndr_push_srvsvc_NetSrvInfo1016(ndr
, NDR_SCALARS
, r
->info1016
));
9766 NDR_CHECK(ndr_push_srvsvc_NetSrvInfo1017(ndr
, NDR_SCALARS
, r
->info1017
));
9772 NDR_CHECK(ndr_push_srvsvc_NetSrvInfo1018(ndr
, NDR_SCALARS
, r
->info1018
));
9778 NDR_CHECK(ndr_push_srvsvc_NetSrvInfo1107(ndr
, NDR_SCALARS
, r
->info1107
));
9784 NDR_CHECK(ndr_push_srvsvc_NetSrvInfo1501(ndr
, NDR_SCALARS
, r
->info1501
));
9790 NDR_CHECK(ndr_push_srvsvc_NetSrvInfo1502(ndr
, NDR_SCALARS
, r
->info1502
));
9796 NDR_CHECK(ndr_push_srvsvc_NetSrvInfo1503(ndr
, NDR_SCALARS
, r
->info1503
));
9802 NDR_CHECK(ndr_push_srvsvc_NetSrvInfo1506(ndr
, NDR_SCALARS
, r
->info1506
));
9808 NDR_CHECK(ndr_push_srvsvc_NetSrvInfo1509(ndr
, NDR_SCALARS
, r
->info1509
));
9814 NDR_CHECK(ndr_push_srvsvc_NetSrvInfo1510(ndr
, NDR_SCALARS
, r
->info1510
));
9820 NDR_CHECK(ndr_push_srvsvc_NetSrvInfo1511(ndr
, NDR_SCALARS
, r
->info1511
));
9826 NDR_CHECK(ndr_push_srvsvc_NetSrvInfo1512(ndr
, NDR_SCALARS
, r
->info1512
));
9832 NDR_CHECK(ndr_push_srvsvc_NetSrvInfo1513(ndr
, NDR_SCALARS
, r
->info1513
));
9838 NDR_CHECK(ndr_push_srvsvc_NetSrvInfo1514(ndr
, NDR_SCALARS
, r
->info1514
));
9844 NDR_CHECK(ndr_push_srvsvc_NetSrvInfo1515(ndr
, NDR_SCALARS
, r
->info1515
));
9850 NDR_CHECK(ndr_push_srvsvc_NetSrvInfo1516(ndr
, NDR_SCALARS
, r
->info1516
));
9856 NDR_CHECK(ndr_push_srvsvc_NetSrvInfo1518(ndr
, NDR_SCALARS
, r
->info1518
));
9862 NDR_CHECK(ndr_push_srvsvc_NetSrvInfo1520(ndr
, NDR_SCALARS
, r
->info1520
));
9868 NDR_CHECK(ndr_push_srvsvc_NetSrvInfo1521(ndr
, NDR_SCALARS
, r
->info1521
));
9874 NDR_CHECK(ndr_push_srvsvc_NetSrvInfo1522(ndr
, NDR_SCALARS
, r
->info1522
));
9880 NDR_CHECK(ndr_push_srvsvc_NetSrvInfo1523(ndr
, NDR_SCALARS
, r
->info1523
));
9886 NDR_CHECK(ndr_push_srvsvc_NetSrvInfo1524(ndr
, NDR_SCALARS
, r
->info1524
));
9892 NDR_CHECK(ndr_push_srvsvc_NetSrvInfo1525(ndr
, NDR_SCALARS
, r
->info1525
));
9898 NDR_CHECK(ndr_push_srvsvc_NetSrvInfo1528(ndr
, NDR_SCALARS
, r
->info1528
));
9904 NDR_CHECK(ndr_push_srvsvc_NetSrvInfo1529(ndr
, NDR_SCALARS
, r
->info1529
));
9910 NDR_CHECK(ndr_push_srvsvc_NetSrvInfo1530(ndr
, NDR_SCALARS
, r
->info1530
));
9916 NDR_CHECK(ndr_push_srvsvc_NetSrvInfo1533(ndr
, NDR_SCALARS
, r
->info1533
));
9922 NDR_CHECK(ndr_push_srvsvc_NetSrvInfo1534(ndr
, NDR_SCALARS
, r
->info1534
));
9928 NDR_CHECK(ndr_push_srvsvc_NetSrvInfo1535(ndr
, NDR_SCALARS
, r
->info1535
));
9934 NDR_CHECK(ndr_push_srvsvc_NetSrvInfo1536(ndr
, NDR_SCALARS
, r
->info1536
));
9940 NDR_CHECK(ndr_push_srvsvc_NetSrvInfo1537(ndr
, NDR_SCALARS
, r
->info1537
));
9946 NDR_CHECK(ndr_push_srvsvc_NetSrvInfo1538(ndr
, NDR_SCALARS
, r
->info1538
));
9952 NDR_CHECK(ndr_push_srvsvc_NetSrvInfo1539(ndr
, NDR_SCALARS
, r
->info1539
));
9958 NDR_CHECK(ndr_push_srvsvc_NetSrvInfo1540(ndr
, NDR_SCALARS
, r
->info1540
));
9964 NDR_CHECK(ndr_push_srvsvc_NetSrvInfo1541(ndr
, NDR_SCALARS
, r
->info1541
));
9970 NDR_CHECK(ndr_push_srvsvc_NetSrvInfo1542(ndr
, NDR_SCALARS
, r
->info1542
));
9976 NDR_CHECK(ndr_push_srvsvc_NetSrvInfo1543(ndr
, NDR_SCALARS
, r
->info1543
));
9982 NDR_CHECK(ndr_push_srvsvc_NetSrvInfo1544(ndr
, NDR_SCALARS
, r
->info1544
));
9988 NDR_CHECK(ndr_push_srvsvc_NetSrvInfo1545(ndr
, NDR_SCALARS
, r
->info1545
));
9994 NDR_CHECK(ndr_push_srvsvc_NetSrvInfo1546(ndr
, NDR_SCALARS
, r
->info1546
));
10000 NDR_CHECK(ndr_push_srvsvc_NetSrvInfo1547(ndr
, NDR_SCALARS
, r
->info1547
));
10006 NDR_CHECK(ndr_push_srvsvc_NetSrvInfo1548(ndr
, NDR_SCALARS
, r
->info1548
));
10012 NDR_CHECK(ndr_push_srvsvc_NetSrvInfo1549(ndr
, NDR_SCALARS
, r
->info1549
));
10018 NDR_CHECK(ndr_push_srvsvc_NetSrvInfo1550(ndr
, NDR_SCALARS
, r
->info1550
));
10024 NDR_CHECK(ndr_push_srvsvc_NetSrvInfo1552(ndr
, NDR_SCALARS
, r
->info1552
));
10030 NDR_CHECK(ndr_push_srvsvc_NetSrvInfo1553(ndr
, NDR_SCALARS
, r
->info1553
));
10036 NDR_CHECK(ndr_push_srvsvc_NetSrvInfo1554(ndr
, NDR_SCALARS
, r
->info1554
));
10042 NDR_CHECK(ndr_push_srvsvc_NetSrvInfo1555(ndr
, NDR_SCALARS
, r
->info1555
));
10048 NDR_CHECK(ndr_push_srvsvc_NetSrvInfo1556(ndr
, NDR_SCALARS
, r
->info1556
));
10057 return NDR_ERR_SUCCESS
;
10060 static enum ndr_err_code
ndr_pull_srvsvc_NetSrvInfo(struct ndr_pull
*ndr
, int ndr_flags
, union srvsvc_NetSrvInfo
*r
)
10064 TALLOC_CTX
*_mem_save_info100_0
;
10065 uint32_t _ptr_info100
;
10066 TALLOC_CTX
*_mem_save_info101_0
;
10067 uint32_t _ptr_info101
;
10068 TALLOC_CTX
*_mem_save_info102_0
;
10069 uint32_t _ptr_info102
;
10070 TALLOC_CTX
*_mem_save_info402_0
;
10071 uint32_t _ptr_info402
;
10072 TALLOC_CTX
*_mem_save_info403_0
;
10073 uint32_t _ptr_info403
;
10074 TALLOC_CTX
*_mem_save_info502_0
;
10075 uint32_t _ptr_info502
;
10076 TALLOC_CTX
*_mem_save_info503_0
;
10077 uint32_t _ptr_info503
;
10078 TALLOC_CTX
*_mem_save_info599_0
;
10079 uint32_t _ptr_info599
;
10080 TALLOC_CTX
*_mem_save_info1005_0
;
10081 uint32_t _ptr_info1005
;
10082 TALLOC_CTX
*_mem_save_info1010_0
;
10083 uint32_t _ptr_info1010
;
10084 TALLOC_CTX
*_mem_save_info1016_0
;
10085 uint32_t _ptr_info1016
;
10086 TALLOC_CTX
*_mem_save_info1017_0
;
10087 uint32_t _ptr_info1017
;
10088 TALLOC_CTX
*_mem_save_info1018_0
;
10089 uint32_t _ptr_info1018
;
10090 TALLOC_CTX
*_mem_save_info1107_0
;
10091 uint32_t _ptr_info1107
;
10092 TALLOC_CTX
*_mem_save_info1501_0
;
10093 uint32_t _ptr_info1501
;
10094 TALLOC_CTX
*_mem_save_info1502_0
;
10095 uint32_t _ptr_info1502
;
10096 TALLOC_CTX
*_mem_save_info1503_0
;
10097 uint32_t _ptr_info1503
;
10098 TALLOC_CTX
*_mem_save_info1506_0
;
10099 uint32_t _ptr_info1506
;
10100 TALLOC_CTX
*_mem_save_info1509_0
;
10101 uint32_t _ptr_info1509
;
10102 TALLOC_CTX
*_mem_save_info1510_0
;
10103 uint32_t _ptr_info1510
;
10104 TALLOC_CTX
*_mem_save_info1511_0
;
10105 uint32_t _ptr_info1511
;
10106 TALLOC_CTX
*_mem_save_info1512_0
;
10107 uint32_t _ptr_info1512
;
10108 TALLOC_CTX
*_mem_save_info1513_0
;
10109 uint32_t _ptr_info1513
;
10110 TALLOC_CTX
*_mem_save_info1514_0
;
10111 uint32_t _ptr_info1514
;
10112 TALLOC_CTX
*_mem_save_info1515_0
;
10113 uint32_t _ptr_info1515
;
10114 TALLOC_CTX
*_mem_save_info1516_0
;
10115 uint32_t _ptr_info1516
;
10116 TALLOC_CTX
*_mem_save_info1518_0
;
10117 uint32_t _ptr_info1518
;
10118 TALLOC_CTX
*_mem_save_info1520_0
;
10119 uint32_t _ptr_info1520
;
10120 TALLOC_CTX
*_mem_save_info1521_0
;
10121 uint32_t _ptr_info1521
;
10122 TALLOC_CTX
*_mem_save_info1522_0
;
10123 uint32_t _ptr_info1522
;
10124 TALLOC_CTX
*_mem_save_info1523_0
;
10125 uint32_t _ptr_info1523
;
10126 TALLOC_CTX
*_mem_save_info1524_0
;
10127 uint32_t _ptr_info1524
;
10128 TALLOC_CTX
*_mem_save_info1525_0
;
10129 uint32_t _ptr_info1525
;
10130 TALLOC_CTX
*_mem_save_info1528_0
;
10131 uint32_t _ptr_info1528
;
10132 TALLOC_CTX
*_mem_save_info1529_0
;
10133 uint32_t _ptr_info1529
;
10134 TALLOC_CTX
*_mem_save_info1530_0
;
10135 uint32_t _ptr_info1530
;
10136 TALLOC_CTX
*_mem_save_info1533_0
;
10137 uint32_t _ptr_info1533
;
10138 TALLOC_CTX
*_mem_save_info1534_0
;
10139 uint32_t _ptr_info1534
;
10140 TALLOC_CTX
*_mem_save_info1535_0
;
10141 uint32_t _ptr_info1535
;
10142 TALLOC_CTX
*_mem_save_info1536_0
;
10143 uint32_t _ptr_info1536
;
10144 TALLOC_CTX
*_mem_save_info1537_0
;
10145 uint32_t _ptr_info1537
;
10146 TALLOC_CTX
*_mem_save_info1538_0
;
10147 uint32_t _ptr_info1538
;
10148 TALLOC_CTX
*_mem_save_info1539_0
;
10149 uint32_t _ptr_info1539
;
10150 TALLOC_CTX
*_mem_save_info1540_0
;
10151 uint32_t _ptr_info1540
;
10152 TALLOC_CTX
*_mem_save_info1541_0
;
10153 uint32_t _ptr_info1541
;
10154 TALLOC_CTX
*_mem_save_info1542_0
;
10155 uint32_t _ptr_info1542
;
10156 TALLOC_CTX
*_mem_save_info1543_0
;
10157 uint32_t _ptr_info1543
;
10158 TALLOC_CTX
*_mem_save_info1544_0
;
10159 uint32_t _ptr_info1544
;
10160 TALLOC_CTX
*_mem_save_info1545_0
;
10161 uint32_t _ptr_info1545
;
10162 TALLOC_CTX
*_mem_save_info1546_0
;
10163 uint32_t _ptr_info1546
;
10164 TALLOC_CTX
*_mem_save_info1547_0
;
10165 uint32_t _ptr_info1547
;
10166 TALLOC_CTX
*_mem_save_info1548_0
;
10167 uint32_t _ptr_info1548
;
10168 TALLOC_CTX
*_mem_save_info1549_0
;
10169 uint32_t _ptr_info1549
;
10170 TALLOC_CTX
*_mem_save_info1550_0
;
10171 uint32_t _ptr_info1550
;
10172 TALLOC_CTX
*_mem_save_info1552_0
;
10173 uint32_t _ptr_info1552
;
10174 TALLOC_CTX
*_mem_save_info1553_0
;
10175 uint32_t _ptr_info1553
;
10176 TALLOC_CTX
*_mem_save_info1554_0
;
10177 uint32_t _ptr_info1554
;
10178 TALLOC_CTX
*_mem_save_info1555_0
;
10179 uint32_t _ptr_info1555
;
10180 TALLOC_CTX
*_mem_save_info1556_0
;
10181 uint32_t _ptr_info1556
;
10182 level
= ndr_pull_get_switch_value(ndr
, r
);
10183 if (ndr_flags
& NDR_SCALARS
) {
10184 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &_level
));
10185 if (_level
!= level
) {
10186 return ndr_pull_error(ndr
, NDR_ERR_BAD_SWITCH
, "Bad switch value %u for r", _level
);
10190 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_info100
));
10191 if (_ptr_info100
) {
10192 NDR_PULL_ALLOC(ndr
, r
->info100
);
10199 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_info101
));
10200 if (_ptr_info101
) {
10201 NDR_PULL_ALLOC(ndr
, r
->info101
);
10208 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_info102
));
10209 if (_ptr_info102
) {
10210 NDR_PULL_ALLOC(ndr
, r
->info102
);
10217 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_info402
));
10218 if (_ptr_info402
) {
10219 NDR_PULL_ALLOC(ndr
, r
->info402
);
10226 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_info403
));
10227 if (_ptr_info403
) {
10228 NDR_PULL_ALLOC(ndr
, r
->info403
);
10235 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_info502
));
10236 if (_ptr_info502
) {
10237 NDR_PULL_ALLOC(ndr
, r
->info502
);
10244 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_info503
));
10245 if (_ptr_info503
) {
10246 NDR_PULL_ALLOC(ndr
, r
->info503
);
10253 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_info599
));
10254 if (_ptr_info599
) {
10255 NDR_PULL_ALLOC(ndr
, r
->info599
);
10262 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_info1005
));
10263 if (_ptr_info1005
) {
10264 NDR_PULL_ALLOC(ndr
, r
->info1005
);
10266 r
->info1005
= NULL
;
10271 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_info1010
));
10272 if (_ptr_info1010
) {
10273 NDR_PULL_ALLOC(ndr
, r
->info1010
);
10275 r
->info1010
= NULL
;
10280 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_info1016
));
10281 if (_ptr_info1016
) {
10282 NDR_PULL_ALLOC(ndr
, r
->info1016
);
10284 r
->info1016
= NULL
;
10289 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_info1017
));
10290 if (_ptr_info1017
) {
10291 NDR_PULL_ALLOC(ndr
, r
->info1017
);
10293 r
->info1017
= NULL
;
10298 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_info1018
));
10299 if (_ptr_info1018
) {
10300 NDR_PULL_ALLOC(ndr
, r
->info1018
);
10302 r
->info1018
= NULL
;
10307 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_info1107
));
10308 if (_ptr_info1107
) {
10309 NDR_PULL_ALLOC(ndr
, r
->info1107
);
10311 r
->info1107
= NULL
;
10316 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_info1501
));
10317 if (_ptr_info1501
) {
10318 NDR_PULL_ALLOC(ndr
, r
->info1501
);
10320 r
->info1501
= NULL
;
10325 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_info1502
));
10326 if (_ptr_info1502
) {
10327 NDR_PULL_ALLOC(ndr
, r
->info1502
);
10329 r
->info1502
= NULL
;
10334 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_info1503
));
10335 if (_ptr_info1503
) {
10336 NDR_PULL_ALLOC(ndr
, r
->info1503
);
10338 r
->info1503
= NULL
;
10343 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_info1506
));
10344 if (_ptr_info1506
) {
10345 NDR_PULL_ALLOC(ndr
, r
->info1506
);
10347 r
->info1506
= NULL
;
10352 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_info1509
));
10353 if (_ptr_info1509
) {
10354 NDR_PULL_ALLOC(ndr
, r
->info1509
);
10356 r
->info1509
= NULL
;
10361 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_info1510
));
10362 if (_ptr_info1510
) {
10363 NDR_PULL_ALLOC(ndr
, r
->info1510
);
10365 r
->info1510
= NULL
;
10370 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_info1511
));
10371 if (_ptr_info1511
) {
10372 NDR_PULL_ALLOC(ndr
, r
->info1511
);
10374 r
->info1511
= NULL
;
10379 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_info1512
));
10380 if (_ptr_info1512
) {
10381 NDR_PULL_ALLOC(ndr
, r
->info1512
);
10383 r
->info1512
= NULL
;
10388 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_info1513
));
10389 if (_ptr_info1513
) {
10390 NDR_PULL_ALLOC(ndr
, r
->info1513
);
10392 r
->info1513
= NULL
;
10397 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_info1514
));
10398 if (_ptr_info1514
) {
10399 NDR_PULL_ALLOC(ndr
, r
->info1514
);
10401 r
->info1514
= NULL
;
10406 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_info1515
));
10407 if (_ptr_info1515
) {
10408 NDR_PULL_ALLOC(ndr
, r
->info1515
);
10410 r
->info1515
= NULL
;
10415 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_info1516
));
10416 if (_ptr_info1516
) {
10417 NDR_PULL_ALLOC(ndr
, r
->info1516
);
10419 r
->info1516
= NULL
;
10424 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_info1518
));
10425 if (_ptr_info1518
) {
10426 NDR_PULL_ALLOC(ndr
, r
->info1518
);
10428 r
->info1518
= NULL
;
10433 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_info1520
));
10434 if (_ptr_info1520
) {
10435 NDR_PULL_ALLOC(ndr
, r
->info1520
);
10437 r
->info1520
= NULL
;
10442 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_info1521
));
10443 if (_ptr_info1521
) {
10444 NDR_PULL_ALLOC(ndr
, r
->info1521
);
10446 r
->info1521
= NULL
;
10451 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_info1522
));
10452 if (_ptr_info1522
) {
10453 NDR_PULL_ALLOC(ndr
, r
->info1522
);
10455 r
->info1522
= NULL
;
10460 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_info1523
));
10461 if (_ptr_info1523
) {
10462 NDR_PULL_ALLOC(ndr
, r
->info1523
);
10464 r
->info1523
= NULL
;
10469 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_info1524
));
10470 if (_ptr_info1524
) {
10471 NDR_PULL_ALLOC(ndr
, r
->info1524
);
10473 r
->info1524
= NULL
;
10478 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_info1525
));
10479 if (_ptr_info1525
) {
10480 NDR_PULL_ALLOC(ndr
, r
->info1525
);
10482 r
->info1525
= NULL
;
10487 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_info1528
));
10488 if (_ptr_info1528
) {
10489 NDR_PULL_ALLOC(ndr
, r
->info1528
);
10491 r
->info1528
= NULL
;
10496 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_info1529
));
10497 if (_ptr_info1529
) {
10498 NDR_PULL_ALLOC(ndr
, r
->info1529
);
10500 r
->info1529
= NULL
;
10505 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_info1530
));
10506 if (_ptr_info1530
) {
10507 NDR_PULL_ALLOC(ndr
, r
->info1530
);
10509 r
->info1530
= NULL
;
10514 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_info1533
));
10515 if (_ptr_info1533
) {
10516 NDR_PULL_ALLOC(ndr
, r
->info1533
);
10518 r
->info1533
= NULL
;
10523 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_info1534
));
10524 if (_ptr_info1534
) {
10525 NDR_PULL_ALLOC(ndr
, r
->info1534
);
10527 r
->info1534
= NULL
;
10532 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_info1535
));
10533 if (_ptr_info1535
) {
10534 NDR_PULL_ALLOC(ndr
, r
->info1535
);
10536 r
->info1535
= NULL
;
10541 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_info1536
));
10542 if (_ptr_info1536
) {
10543 NDR_PULL_ALLOC(ndr
, r
->info1536
);
10545 r
->info1536
= NULL
;
10550 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_info1537
));
10551 if (_ptr_info1537
) {
10552 NDR_PULL_ALLOC(ndr
, r
->info1537
);
10554 r
->info1537
= NULL
;
10559 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_info1538
));
10560 if (_ptr_info1538
) {
10561 NDR_PULL_ALLOC(ndr
, r
->info1538
);
10563 r
->info1538
= NULL
;
10568 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_info1539
));
10569 if (_ptr_info1539
) {
10570 NDR_PULL_ALLOC(ndr
, r
->info1539
);
10572 r
->info1539
= NULL
;
10577 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_info1540
));
10578 if (_ptr_info1540
) {
10579 NDR_PULL_ALLOC(ndr
, r
->info1540
);
10581 r
->info1540
= NULL
;
10586 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_info1541
));
10587 if (_ptr_info1541
) {
10588 NDR_PULL_ALLOC(ndr
, r
->info1541
);
10590 r
->info1541
= NULL
;
10595 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_info1542
));
10596 if (_ptr_info1542
) {
10597 NDR_PULL_ALLOC(ndr
, r
->info1542
);
10599 r
->info1542
= NULL
;
10604 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_info1543
));
10605 if (_ptr_info1543
) {
10606 NDR_PULL_ALLOC(ndr
, r
->info1543
);
10608 r
->info1543
= NULL
;
10613 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_info1544
));
10614 if (_ptr_info1544
) {
10615 NDR_PULL_ALLOC(ndr
, r
->info1544
);
10617 r
->info1544
= NULL
;
10622 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_info1545
));
10623 if (_ptr_info1545
) {
10624 NDR_PULL_ALLOC(ndr
, r
->info1545
);
10626 r
->info1545
= NULL
;
10631 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_info1546
));
10632 if (_ptr_info1546
) {
10633 NDR_PULL_ALLOC(ndr
, r
->info1546
);
10635 r
->info1546
= NULL
;
10640 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_info1547
));
10641 if (_ptr_info1547
) {
10642 NDR_PULL_ALLOC(ndr
, r
->info1547
);
10644 r
->info1547
= NULL
;
10649 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_info1548
));
10650 if (_ptr_info1548
) {
10651 NDR_PULL_ALLOC(ndr
, r
->info1548
);
10653 r
->info1548
= NULL
;
10658 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_info1549
));
10659 if (_ptr_info1549
) {
10660 NDR_PULL_ALLOC(ndr
, r
->info1549
);
10662 r
->info1549
= NULL
;
10667 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_info1550
));
10668 if (_ptr_info1550
) {
10669 NDR_PULL_ALLOC(ndr
, r
->info1550
);
10671 r
->info1550
= NULL
;
10676 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_info1552
));
10677 if (_ptr_info1552
) {
10678 NDR_PULL_ALLOC(ndr
, r
->info1552
);
10680 r
->info1552
= NULL
;
10685 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_info1553
));
10686 if (_ptr_info1553
) {
10687 NDR_PULL_ALLOC(ndr
, r
->info1553
);
10689 r
->info1553
= NULL
;
10694 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_info1554
));
10695 if (_ptr_info1554
) {
10696 NDR_PULL_ALLOC(ndr
, r
->info1554
);
10698 r
->info1554
= NULL
;
10703 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_info1555
));
10704 if (_ptr_info1555
) {
10705 NDR_PULL_ALLOC(ndr
, r
->info1555
);
10707 r
->info1555
= NULL
;
10712 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_info1556
));
10713 if (_ptr_info1556
) {
10714 NDR_PULL_ALLOC(ndr
, r
->info1556
);
10716 r
->info1556
= NULL
;
10725 if (ndr_flags
& NDR_BUFFERS
) {
10729 _mem_save_info100_0
= NDR_PULL_GET_MEM_CTX(ndr
);
10730 NDR_PULL_SET_MEM_CTX(ndr
, r
->info100
, 0);
10731 NDR_CHECK(ndr_pull_srvsvc_NetSrvInfo100(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->info100
));
10732 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_info100_0
, 0);
10738 _mem_save_info101_0
= NDR_PULL_GET_MEM_CTX(ndr
);
10739 NDR_PULL_SET_MEM_CTX(ndr
, r
->info101
, 0);
10740 NDR_CHECK(ndr_pull_srvsvc_NetSrvInfo101(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->info101
));
10741 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_info101_0
, 0);
10747 _mem_save_info102_0
= NDR_PULL_GET_MEM_CTX(ndr
);
10748 NDR_PULL_SET_MEM_CTX(ndr
, r
->info102
, 0);
10749 NDR_CHECK(ndr_pull_srvsvc_NetSrvInfo102(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->info102
));
10750 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_info102_0
, 0);
10756 _mem_save_info402_0
= NDR_PULL_GET_MEM_CTX(ndr
);
10757 NDR_PULL_SET_MEM_CTX(ndr
, r
->info402
, 0);
10758 NDR_CHECK(ndr_pull_srvsvc_NetSrvInfo402(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->info402
));
10759 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_info402_0
, 0);
10765 _mem_save_info403_0
= NDR_PULL_GET_MEM_CTX(ndr
);
10766 NDR_PULL_SET_MEM_CTX(ndr
, r
->info403
, 0);
10767 NDR_CHECK(ndr_pull_srvsvc_NetSrvInfo403(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->info403
));
10768 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_info403_0
, 0);
10774 _mem_save_info502_0
= NDR_PULL_GET_MEM_CTX(ndr
);
10775 NDR_PULL_SET_MEM_CTX(ndr
, r
->info502
, 0);
10776 NDR_CHECK(ndr_pull_srvsvc_NetSrvInfo502(ndr
, NDR_SCALARS
, r
->info502
));
10777 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_info502_0
, 0);
10783 _mem_save_info503_0
= NDR_PULL_GET_MEM_CTX(ndr
);
10784 NDR_PULL_SET_MEM_CTX(ndr
, r
->info503
, 0);
10785 NDR_CHECK(ndr_pull_srvsvc_NetSrvInfo503(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->info503
));
10786 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_info503_0
, 0);
10792 _mem_save_info599_0
= NDR_PULL_GET_MEM_CTX(ndr
);
10793 NDR_PULL_SET_MEM_CTX(ndr
, r
->info599
, 0);
10794 NDR_CHECK(ndr_pull_srvsvc_NetSrvInfo599(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->info599
));
10795 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_info599_0
, 0);
10801 _mem_save_info1005_0
= NDR_PULL_GET_MEM_CTX(ndr
);
10802 NDR_PULL_SET_MEM_CTX(ndr
, r
->info1005
, 0);
10803 NDR_CHECK(ndr_pull_srvsvc_NetSrvInfo1005(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->info1005
));
10804 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_info1005_0
, 0);
10810 _mem_save_info1010_0
= NDR_PULL_GET_MEM_CTX(ndr
);
10811 NDR_PULL_SET_MEM_CTX(ndr
, r
->info1010
, 0);
10812 NDR_CHECK(ndr_pull_srvsvc_NetSrvInfo1010(ndr
, NDR_SCALARS
, r
->info1010
));
10813 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_info1010_0
, 0);
10819 _mem_save_info1016_0
= NDR_PULL_GET_MEM_CTX(ndr
);
10820 NDR_PULL_SET_MEM_CTX(ndr
, r
->info1016
, 0);
10821 NDR_CHECK(ndr_pull_srvsvc_NetSrvInfo1016(ndr
, NDR_SCALARS
, r
->info1016
));
10822 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_info1016_0
, 0);
10828 _mem_save_info1017_0
= NDR_PULL_GET_MEM_CTX(ndr
);
10829 NDR_PULL_SET_MEM_CTX(ndr
, r
->info1017
, 0);
10830 NDR_CHECK(ndr_pull_srvsvc_NetSrvInfo1017(ndr
, NDR_SCALARS
, r
->info1017
));
10831 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_info1017_0
, 0);
10837 _mem_save_info1018_0
= NDR_PULL_GET_MEM_CTX(ndr
);
10838 NDR_PULL_SET_MEM_CTX(ndr
, r
->info1018
, 0);
10839 NDR_CHECK(ndr_pull_srvsvc_NetSrvInfo1018(ndr
, NDR_SCALARS
, r
->info1018
));
10840 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_info1018_0
, 0);
10846 _mem_save_info1107_0
= NDR_PULL_GET_MEM_CTX(ndr
);
10847 NDR_PULL_SET_MEM_CTX(ndr
, r
->info1107
, 0);
10848 NDR_CHECK(ndr_pull_srvsvc_NetSrvInfo1107(ndr
, NDR_SCALARS
, r
->info1107
));
10849 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_info1107_0
, 0);
10855 _mem_save_info1501_0
= NDR_PULL_GET_MEM_CTX(ndr
);
10856 NDR_PULL_SET_MEM_CTX(ndr
, r
->info1501
, 0);
10857 NDR_CHECK(ndr_pull_srvsvc_NetSrvInfo1501(ndr
, NDR_SCALARS
, r
->info1501
));
10858 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_info1501_0
, 0);
10864 _mem_save_info1502_0
= NDR_PULL_GET_MEM_CTX(ndr
);
10865 NDR_PULL_SET_MEM_CTX(ndr
, r
->info1502
, 0);
10866 NDR_CHECK(ndr_pull_srvsvc_NetSrvInfo1502(ndr
, NDR_SCALARS
, r
->info1502
));
10867 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_info1502_0
, 0);
10873 _mem_save_info1503_0
= NDR_PULL_GET_MEM_CTX(ndr
);
10874 NDR_PULL_SET_MEM_CTX(ndr
, r
->info1503
, 0);
10875 NDR_CHECK(ndr_pull_srvsvc_NetSrvInfo1503(ndr
, NDR_SCALARS
, r
->info1503
));
10876 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_info1503_0
, 0);
10882 _mem_save_info1506_0
= NDR_PULL_GET_MEM_CTX(ndr
);
10883 NDR_PULL_SET_MEM_CTX(ndr
, r
->info1506
, 0);
10884 NDR_CHECK(ndr_pull_srvsvc_NetSrvInfo1506(ndr
, NDR_SCALARS
, r
->info1506
));
10885 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_info1506_0
, 0);
10891 _mem_save_info1509_0
= NDR_PULL_GET_MEM_CTX(ndr
);
10892 NDR_PULL_SET_MEM_CTX(ndr
, r
->info1509
, 0);
10893 NDR_CHECK(ndr_pull_srvsvc_NetSrvInfo1509(ndr
, NDR_SCALARS
, r
->info1509
));
10894 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_info1509_0
, 0);
10900 _mem_save_info1510_0
= NDR_PULL_GET_MEM_CTX(ndr
);
10901 NDR_PULL_SET_MEM_CTX(ndr
, r
->info1510
, 0);
10902 NDR_CHECK(ndr_pull_srvsvc_NetSrvInfo1510(ndr
, NDR_SCALARS
, r
->info1510
));
10903 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_info1510_0
, 0);
10909 _mem_save_info1511_0
= NDR_PULL_GET_MEM_CTX(ndr
);
10910 NDR_PULL_SET_MEM_CTX(ndr
, r
->info1511
, 0);
10911 NDR_CHECK(ndr_pull_srvsvc_NetSrvInfo1511(ndr
, NDR_SCALARS
, r
->info1511
));
10912 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_info1511_0
, 0);
10918 _mem_save_info1512_0
= NDR_PULL_GET_MEM_CTX(ndr
);
10919 NDR_PULL_SET_MEM_CTX(ndr
, r
->info1512
, 0);
10920 NDR_CHECK(ndr_pull_srvsvc_NetSrvInfo1512(ndr
, NDR_SCALARS
, r
->info1512
));
10921 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_info1512_0
, 0);
10927 _mem_save_info1513_0
= NDR_PULL_GET_MEM_CTX(ndr
);
10928 NDR_PULL_SET_MEM_CTX(ndr
, r
->info1513
, 0);
10929 NDR_CHECK(ndr_pull_srvsvc_NetSrvInfo1513(ndr
, NDR_SCALARS
, r
->info1513
));
10930 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_info1513_0
, 0);
10936 _mem_save_info1514_0
= NDR_PULL_GET_MEM_CTX(ndr
);
10937 NDR_PULL_SET_MEM_CTX(ndr
, r
->info1514
, 0);
10938 NDR_CHECK(ndr_pull_srvsvc_NetSrvInfo1514(ndr
, NDR_SCALARS
, r
->info1514
));
10939 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_info1514_0
, 0);
10945 _mem_save_info1515_0
= NDR_PULL_GET_MEM_CTX(ndr
);
10946 NDR_PULL_SET_MEM_CTX(ndr
, r
->info1515
, 0);
10947 NDR_CHECK(ndr_pull_srvsvc_NetSrvInfo1515(ndr
, NDR_SCALARS
, r
->info1515
));
10948 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_info1515_0
, 0);
10954 _mem_save_info1516_0
= NDR_PULL_GET_MEM_CTX(ndr
);
10955 NDR_PULL_SET_MEM_CTX(ndr
, r
->info1516
, 0);
10956 NDR_CHECK(ndr_pull_srvsvc_NetSrvInfo1516(ndr
, NDR_SCALARS
, r
->info1516
));
10957 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_info1516_0
, 0);
10963 _mem_save_info1518_0
= NDR_PULL_GET_MEM_CTX(ndr
);
10964 NDR_PULL_SET_MEM_CTX(ndr
, r
->info1518
, 0);
10965 NDR_CHECK(ndr_pull_srvsvc_NetSrvInfo1518(ndr
, NDR_SCALARS
, r
->info1518
));
10966 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_info1518_0
, 0);
10972 _mem_save_info1520_0
= NDR_PULL_GET_MEM_CTX(ndr
);
10973 NDR_PULL_SET_MEM_CTX(ndr
, r
->info1520
, 0);
10974 NDR_CHECK(ndr_pull_srvsvc_NetSrvInfo1520(ndr
, NDR_SCALARS
, r
->info1520
));
10975 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_info1520_0
, 0);
10981 _mem_save_info1521_0
= NDR_PULL_GET_MEM_CTX(ndr
);
10982 NDR_PULL_SET_MEM_CTX(ndr
, r
->info1521
, 0);
10983 NDR_CHECK(ndr_pull_srvsvc_NetSrvInfo1521(ndr
, NDR_SCALARS
, r
->info1521
));
10984 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_info1521_0
, 0);
10990 _mem_save_info1522_0
= NDR_PULL_GET_MEM_CTX(ndr
);
10991 NDR_PULL_SET_MEM_CTX(ndr
, r
->info1522
, 0);
10992 NDR_CHECK(ndr_pull_srvsvc_NetSrvInfo1522(ndr
, NDR_SCALARS
, r
->info1522
));
10993 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_info1522_0
, 0);
10999 _mem_save_info1523_0
= NDR_PULL_GET_MEM_CTX(ndr
);
11000 NDR_PULL_SET_MEM_CTX(ndr
, r
->info1523
, 0);
11001 NDR_CHECK(ndr_pull_srvsvc_NetSrvInfo1523(ndr
, NDR_SCALARS
, r
->info1523
));
11002 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_info1523_0
, 0);
11008 _mem_save_info1524_0
= NDR_PULL_GET_MEM_CTX(ndr
);
11009 NDR_PULL_SET_MEM_CTX(ndr
, r
->info1524
, 0);
11010 NDR_CHECK(ndr_pull_srvsvc_NetSrvInfo1524(ndr
, NDR_SCALARS
, r
->info1524
));
11011 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_info1524_0
, 0);
11017 _mem_save_info1525_0
= NDR_PULL_GET_MEM_CTX(ndr
);
11018 NDR_PULL_SET_MEM_CTX(ndr
, r
->info1525
, 0);
11019 NDR_CHECK(ndr_pull_srvsvc_NetSrvInfo1525(ndr
, NDR_SCALARS
, r
->info1525
));
11020 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_info1525_0
, 0);
11026 _mem_save_info1528_0
= NDR_PULL_GET_MEM_CTX(ndr
);
11027 NDR_PULL_SET_MEM_CTX(ndr
, r
->info1528
, 0);
11028 NDR_CHECK(ndr_pull_srvsvc_NetSrvInfo1528(ndr
, NDR_SCALARS
, r
->info1528
));
11029 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_info1528_0
, 0);
11035 _mem_save_info1529_0
= NDR_PULL_GET_MEM_CTX(ndr
);
11036 NDR_PULL_SET_MEM_CTX(ndr
, r
->info1529
, 0);
11037 NDR_CHECK(ndr_pull_srvsvc_NetSrvInfo1529(ndr
, NDR_SCALARS
, r
->info1529
));
11038 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_info1529_0
, 0);
11044 _mem_save_info1530_0
= NDR_PULL_GET_MEM_CTX(ndr
);
11045 NDR_PULL_SET_MEM_CTX(ndr
, r
->info1530
, 0);
11046 NDR_CHECK(ndr_pull_srvsvc_NetSrvInfo1530(ndr
, NDR_SCALARS
, r
->info1530
));
11047 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_info1530_0
, 0);
11053 _mem_save_info1533_0
= NDR_PULL_GET_MEM_CTX(ndr
);
11054 NDR_PULL_SET_MEM_CTX(ndr
, r
->info1533
, 0);
11055 NDR_CHECK(ndr_pull_srvsvc_NetSrvInfo1533(ndr
, NDR_SCALARS
, r
->info1533
));
11056 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_info1533_0
, 0);
11062 _mem_save_info1534_0
= NDR_PULL_GET_MEM_CTX(ndr
);
11063 NDR_PULL_SET_MEM_CTX(ndr
, r
->info1534
, 0);
11064 NDR_CHECK(ndr_pull_srvsvc_NetSrvInfo1534(ndr
, NDR_SCALARS
, r
->info1534
));
11065 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_info1534_0
, 0);
11071 _mem_save_info1535_0
= NDR_PULL_GET_MEM_CTX(ndr
);
11072 NDR_PULL_SET_MEM_CTX(ndr
, r
->info1535
, 0);
11073 NDR_CHECK(ndr_pull_srvsvc_NetSrvInfo1535(ndr
, NDR_SCALARS
, r
->info1535
));
11074 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_info1535_0
, 0);
11080 _mem_save_info1536_0
= NDR_PULL_GET_MEM_CTX(ndr
);
11081 NDR_PULL_SET_MEM_CTX(ndr
, r
->info1536
, 0);
11082 NDR_CHECK(ndr_pull_srvsvc_NetSrvInfo1536(ndr
, NDR_SCALARS
, r
->info1536
));
11083 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_info1536_0
, 0);
11089 _mem_save_info1537_0
= NDR_PULL_GET_MEM_CTX(ndr
);
11090 NDR_PULL_SET_MEM_CTX(ndr
, r
->info1537
, 0);
11091 NDR_CHECK(ndr_pull_srvsvc_NetSrvInfo1537(ndr
, NDR_SCALARS
, r
->info1537
));
11092 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_info1537_0
, 0);
11098 _mem_save_info1538_0
= NDR_PULL_GET_MEM_CTX(ndr
);
11099 NDR_PULL_SET_MEM_CTX(ndr
, r
->info1538
, 0);
11100 NDR_CHECK(ndr_pull_srvsvc_NetSrvInfo1538(ndr
, NDR_SCALARS
, r
->info1538
));
11101 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_info1538_0
, 0);
11107 _mem_save_info1539_0
= NDR_PULL_GET_MEM_CTX(ndr
);
11108 NDR_PULL_SET_MEM_CTX(ndr
, r
->info1539
, 0);
11109 NDR_CHECK(ndr_pull_srvsvc_NetSrvInfo1539(ndr
, NDR_SCALARS
, r
->info1539
));
11110 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_info1539_0
, 0);
11116 _mem_save_info1540_0
= NDR_PULL_GET_MEM_CTX(ndr
);
11117 NDR_PULL_SET_MEM_CTX(ndr
, r
->info1540
, 0);
11118 NDR_CHECK(ndr_pull_srvsvc_NetSrvInfo1540(ndr
, NDR_SCALARS
, r
->info1540
));
11119 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_info1540_0
, 0);
11125 _mem_save_info1541_0
= NDR_PULL_GET_MEM_CTX(ndr
);
11126 NDR_PULL_SET_MEM_CTX(ndr
, r
->info1541
, 0);
11127 NDR_CHECK(ndr_pull_srvsvc_NetSrvInfo1541(ndr
, NDR_SCALARS
, r
->info1541
));
11128 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_info1541_0
, 0);
11134 _mem_save_info1542_0
= NDR_PULL_GET_MEM_CTX(ndr
);
11135 NDR_PULL_SET_MEM_CTX(ndr
, r
->info1542
, 0);
11136 NDR_CHECK(ndr_pull_srvsvc_NetSrvInfo1542(ndr
, NDR_SCALARS
, r
->info1542
));
11137 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_info1542_0
, 0);
11143 _mem_save_info1543_0
= NDR_PULL_GET_MEM_CTX(ndr
);
11144 NDR_PULL_SET_MEM_CTX(ndr
, r
->info1543
, 0);
11145 NDR_CHECK(ndr_pull_srvsvc_NetSrvInfo1543(ndr
, NDR_SCALARS
, r
->info1543
));
11146 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_info1543_0
, 0);
11152 _mem_save_info1544_0
= NDR_PULL_GET_MEM_CTX(ndr
);
11153 NDR_PULL_SET_MEM_CTX(ndr
, r
->info1544
, 0);
11154 NDR_CHECK(ndr_pull_srvsvc_NetSrvInfo1544(ndr
, NDR_SCALARS
, r
->info1544
));
11155 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_info1544_0
, 0);
11161 _mem_save_info1545_0
= NDR_PULL_GET_MEM_CTX(ndr
);
11162 NDR_PULL_SET_MEM_CTX(ndr
, r
->info1545
, 0);
11163 NDR_CHECK(ndr_pull_srvsvc_NetSrvInfo1545(ndr
, NDR_SCALARS
, r
->info1545
));
11164 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_info1545_0
, 0);
11170 _mem_save_info1546_0
= NDR_PULL_GET_MEM_CTX(ndr
);
11171 NDR_PULL_SET_MEM_CTX(ndr
, r
->info1546
, 0);
11172 NDR_CHECK(ndr_pull_srvsvc_NetSrvInfo1546(ndr
, NDR_SCALARS
, r
->info1546
));
11173 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_info1546_0
, 0);
11179 _mem_save_info1547_0
= NDR_PULL_GET_MEM_CTX(ndr
);
11180 NDR_PULL_SET_MEM_CTX(ndr
, r
->info1547
, 0);
11181 NDR_CHECK(ndr_pull_srvsvc_NetSrvInfo1547(ndr
, NDR_SCALARS
, r
->info1547
));
11182 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_info1547_0
, 0);
11188 _mem_save_info1548_0
= NDR_PULL_GET_MEM_CTX(ndr
);
11189 NDR_PULL_SET_MEM_CTX(ndr
, r
->info1548
, 0);
11190 NDR_CHECK(ndr_pull_srvsvc_NetSrvInfo1548(ndr
, NDR_SCALARS
, r
->info1548
));
11191 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_info1548_0
, 0);
11197 _mem_save_info1549_0
= NDR_PULL_GET_MEM_CTX(ndr
);
11198 NDR_PULL_SET_MEM_CTX(ndr
, r
->info1549
, 0);
11199 NDR_CHECK(ndr_pull_srvsvc_NetSrvInfo1549(ndr
, NDR_SCALARS
, r
->info1549
));
11200 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_info1549_0
, 0);
11206 _mem_save_info1550_0
= NDR_PULL_GET_MEM_CTX(ndr
);
11207 NDR_PULL_SET_MEM_CTX(ndr
, r
->info1550
, 0);
11208 NDR_CHECK(ndr_pull_srvsvc_NetSrvInfo1550(ndr
, NDR_SCALARS
, r
->info1550
));
11209 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_info1550_0
, 0);
11215 _mem_save_info1552_0
= NDR_PULL_GET_MEM_CTX(ndr
);
11216 NDR_PULL_SET_MEM_CTX(ndr
, r
->info1552
, 0);
11217 NDR_CHECK(ndr_pull_srvsvc_NetSrvInfo1552(ndr
, NDR_SCALARS
, r
->info1552
));
11218 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_info1552_0
, 0);
11224 _mem_save_info1553_0
= NDR_PULL_GET_MEM_CTX(ndr
);
11225 NDR_PULL_SET_MEM_CTX(ndr
, r
->info1553
, 0);
11226 NDR_CHECK(ndr_pull_srvsvc_NetSrvInfo1553(ndr
, NDR_SCALARS
, r
->info1553
));
11227 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_info1553_0
, 0);
11233 _mem_save_info1554_0
= NDR_PULL_GET_MEM_CTX(ndr
);
11234 NDR_PULL_SET_MEM_CTX(ndr
, r
->info1554
, 0);
11235 NDR_CHECK(ndr_pull_srvsvc_NetSrvInfo1554(ndr
, NDR_SCALARS
, r
->info1554
));
11236 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_info1554_0
, 0);
11242 _mem_save_info1555_0
= NDR_PULL_GET_MEM_CTX(ndr
);
11243 NDR_PULL_SET_MEM_CTX(ndr
, r
->info1555
, 0);
11244 NDR_CHECK(ndr_pull_srvsvc_NetSrvInfo1555(ndr
, NDR_SCALARS
, r
->info1555
));
11245 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_info1555_0
, 0);
11251 _mem_save_info1556_0
= NDR_PULL_GET_MEM_CTX(ndr
);
11252 NDR_PULL_SET_MEM_CTX(ndr
, r
->info1556
, 0);
11253 NDR_CHECK(ndr_pull_srvsvc_NetSrvInfo1556(ndr
, NDR_SCALARS
, r
->info1556
));
11254 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_info1556_0
, 0);
11263 return NDR_ERR_SUCCESS
;
11266 _PUBLIC_
void ndr_print_srvsvc_NetSrvInfo(struct ndr_print
*ndr
, const char *name
, const union srvsvc_NetSrvInfo
*r
)
11269 level
= ndr_print_get_switch_value(ndr
, r
);
11270 ndr_print_union(ndr
, name
, level
, "srvsvc_NetSrvInfo");
11273 ndr_print_ptr(ndr
, "info100", r
->info100
);
11276 ndr_print_srvsvc_NetSrvInfo100(ndr
, "info100", r
->info100
);
11282 ndr_print_ptr(ndr
, "info101", r
->info101
);
11285 ndr_print_srvsvc_NetSrvInfo101(ndr
, "info101", r
->info101
);
11291 ndr_print_ptr(ndr
, "info102", r
->info102
);
11294 ndr_print_srvsvc_NetSrvInfo102(ndr
, "info102", r
->info102
);
11300 ndr_print_ptr(ndr
, "info402", r
->info402
);
11303 ndr_print_srvsvc_NetSrvInfo402(ndr
, "info402", r
->info402
);
11309 ndr_print_ptr(ndr
, "info403", r
->info403
);
11312 ndr_print_srvsvc_NetSrvInfo403(ndr
, "info403", r
->info403
);
11318 ndr_print_ptr(ndr
, "info502", r
->info502
);
11321 ndr_print_srvsvc_NetSrvInfo502(ndr
, "info502", r
->info502
);
11327 ndr_print_ptr(ndr
, "info503", r
->info503
);
11330 ndr_print_srvsvc_NetSrvInfo503(ndr
, "info503", r
->info503
);
11336 ndr_print_ptr(ndr
, "info599", r
->info599
);
11339 ndr_print_srvsvc_NetSrvInfo599(ndr
, "info599", r
->info599
);
11345 ndr_print_ptr(ndr
, "info1005", r
->info1005
);
11348 ndr_print_srvsvc_NetSrvInfo1005(ndr
, "info1005", r
->info1005
);
11354 ndr_print_ptr(ndr
, "info1010", r
->info1010
);
11357 ndr_print_srvsvc_NetSrvInfo1010(ndr
, "info1010", r
->info1010
);
11363 ndr_print_ptr(ndr
, "info1016", r
->info1016
);
11366 ndr_print_srvsvc_NetSrvInfo1016(ndr
, "info1016", r
->info1016
);
11372 ndr_print_ptr(ndr
, "info1017", r
->info1017
);
11375 ndr_print_srvsvc_NetSrvInfo1017(ndr
, "info1017", r
->info1017
);
11381 ndr_print_ptr(ndr
, "info1018", r
->info1018
);
11384 ndr_print_srvsvc_NetSrvInfo1018(ndr
, "info1018", r
->info1018
);
11390 ndr_print_ptr(ndr
, "info1107", r
->info1107
);
11393 ndr_print_srvsvc_NetSrvInfo1107(ndr
, "info1107", r
->info1107
);
11399 ndr_print_ptr(ndr
, "info1501", r
->info1501
);
11402 ndr_print_srvsvc_NetSrvInfo1501(ndr
, "info1501", r
->info1501
);
11408 ndr_print_ptr(ndr
, "info1502", r
->info1502
);
11411 ndr_print_srvsvc_NetSrvInfo1502(ndr
, "info1502", r
->info1502
);
11417 ndr_print_ptr(ndr
, "info1503", r
->info1503
);
11420 ndr_print_srvsvc_NetSrvInfo1503(ndr
, "info1503", r
->info1503
);
11426 ndr_print_ptr(ndr
, "info1506", r
->info1506
);
11429 ndr_print_srvsvc_NetSrvInfo1506(ndr
, "info1506", r
->info1506
);
11435 ndr_print_ptr(ndr
, "info1509", r
->info1509
);
11438 ndr_print_srvsvc_NetSrvInfo1509(ndr
, "info1509", r
->info1509
);
11444 ndr_print_ptr(ndr
, "info1510", r
->info1510
);
11447 ndr_print_srvsvc_NetSrvInfo1510(ndr
, "info1510", r
->info1510
);
11453 ndr_print_ptr(ndr
, "info1511", r
->info1511
);
11456 ndr_print_srvsvc_NetSrvInfo1511(ndr
, "info1511", r
->info1511
);
11462 ndr_print_ptr(ndr
, "info1512", r
->info1512
);
11465 ndr_print_srvsvc_NetSrvInfo1512(ndr
, "info1512", r
->info1512
);
11471 ndr_print_ptr(ndr
, "info1513", r
->info1513
);
11474 ndr_print_srvsvc_NetSrvInfo1513(ndr
, "info1513", r
->info1513
);
11480 ndr_print_ptr(ndr
, "info1514", r
->info1514
);
11483 ndr_print_srvsvc_NetSrvInfo1514(ndr
, "info1514", r
->info1514
);
11489 ndr_print_ptr(ndr
, "info1515", r
->info1515
);
11492 ndr_print_srvsvc_NetSrvInfo1515(ndr
, "info1515", r
->info1515
);
11498 ndr_print_ptr(ndr
, "info1516", r
->info1516
);
11501 ndr_print_srvsvc_NetSrvInfo1516(ndr
, "info1516", r
->info1516
);
11507 ndr_print_ptr(ndr
, "info1518", r
->info1518
);
11510 ndr_print_srvsvc_NetSrvInfo1518(ndr
, "info1518", r
->info1518
);
11516 ndr_print_ptr(ndr
, "info1520", r
->info1520
);
11519 ndr_print_srvsvc_NetSrvInfo1520(ndr
, "info1520", r
->info1520
);
11525 ndr_print_ptr(ndr
, "info1521", r
->info1521
);
11528 ndr_print_srvsvc_NetSrvInfo1521(ndr
, "info1521", r
->info1521
);
11534 ndr_print_ptr(ndr
, "info1522", r
->info1522
);
11537 ndr_print_srvsvc_NetSrvInfo1522(ndr
, "info1522", r
->info1522
);
11543 ndr_print_ptr(ndr
, "info1523", r
->info1523
);
11546 ndr_print_srvsvc_NetSrvInfo1523(ndr
, "info1523", r
->info1523
);
11552 ndr_print_ptr(ndr
, "info1524", r
->info1524
);
11555 ndr_print_srvsvc_NetSrvInfo1524(ndr
, "info1524", r
->info1524
);
11561 ndr_print_ptr(ndr
, "info1525", r
->info1525
);
11564 ndr_print_srvsvc_NetSrvInfo1525(ndr
, "info1525", r
->info1525
);
11570 ndr_print_ptr(ndr
, "info1528", r
->info1528
);
11573 ndr_print_srvsvc_NetSrvInfo1528(ndr
, "info1528", r
->info1528
);
11579 ndr_print_ptr(ndr
, "info1529", r
->info1529
);
11582 ndr_print_srvsvc_NetSrvInfo1529(ndr
, "info1529", r
->info1529
);
11588 ndr_print_ptr(ndr
, "info1530", r
->info1530
);
11591 ndr_print_srvsvc_NetSrvInfo1530(ndr
, "info1530", r
->info1530
);
11597 ndr_print_ptr(ndr
, "info1533", r
->info1533
);
11600 ndr_print_srvsvc_NetSrvInfo1533(ndr
, "info1533", r
->info1533
);
11606 ndr_print_ptr(ndr
, "info1534", r
->info1534
);
11609 ndr_print_srvsvc_NetSrvInfo1534(ndr
, "info1534", r
->info1534
);
11615 ndr_print_ptr(ndr
, "info1535", r
->info1535
);
11618 ndr_print_srvsvc_NetSrvInfo1535(ndr
, "info1535", r
->info1535
);
11624 ndr_print_ptr(ndr
, "info1536", r
->info1536
);
11627 ndr_print_srvsvc_NetSrvInfo1536(ndr
, "info1536", r
->info1536
);
11633 ndr_print_ptr(ndr
, "info1537", r
->info1537
);
11636 ndr_print_srvsvc_NetSrvInfo1537(ndr
, "info1537", r
->info1537
);
11642 ndr_print_ptr(ndr
, "info1538", r
->info1538
);
11645 ndr_print_srvsvc_NetSrvInfo1538(ndr
, "info1538", r
->info1538
);
11651 ndr_print_ptr(ndr
, "info1539", r
->info1539
);
11654 ndr_print_srvsvc_NetSrvInfo1539(ndr
, "info1539", r
->info1539
);
11660 ndr_print_ptr(ndr
, "info1540", r
->info1540
);
11663 ndr_print_srvsvc_NetSrvInfo1540(ndr
, "info1540", r
->info1540
);
11669 ndr_print_ptr(ndr
, "info1541", r
->info1541
);
11672 ndr_print_srvsvc_NetSrvInfo1541(ndr
, "info1541", r
->info1541
);
11678 ndr_print_ptr(ndr
, "info1542", r
->info1542
);
11681 ndr_print_srvsvc_NetSrvInfo1542(ndr
, "info1542", r
->info1542
);
11687 ndr_print_ptr(ndr
, "info1543", r
->info1543
);
11690 ndr_print_srvsvc_NetSrvInfo1543(ndr
, "info1543", r
->info1543
);
11696 ndr_print_ptr(ndr
, "info1544", r
->info1544
);
11699 ndr_print_srvsvc_NetSrvInfo1544(ndr
, "info1544", r
->info1544
);
11705 ndr_print_ptr(ndr
, "info1545", r
->info1545
);
11708 ndr_print_srvsvc_NetSrvInfo1545(ndr
, "info1545", r
->info1545
);
11714 ndr_print_ptr(ndr
, "info1546", r
->info1546
);
11717 ndr_print_srvsvc_NetSrvInfo1546(ndr
, "info1546", r
->info1546
);
11723 ndr_print_ptr(ndr
, "info1547", r
->info1547
);
11726 ndr_print_srvsvc_NetSrvInfo1547(ndr
, "info1547", r
->info1547
);
11732 ndr_print_ptr(ndr
, "info1548", r
->info1548
);
11735 ndr_print_srvsvc_NetSrvInfo1548(ndr
, "info1548", r
->info1548
);
11741 ndr_print_ptr(ndr
, "info1549", r
->info1549
);
11744 ndr_print_srvsvc_NetSrvInfo1549(ndr
, "info1549", r
->info1549
);
11750 ndr_print_ptr(ndr
, "info1550", r
->info1550
);
11753 ndr_print_srvsvc_NetSrvInfo1550(ndr
, "info1550", r
->info1550
);
11759 ndr_print_ptr(ndr
, "info1552", r
->info1552
);
11762 ndr_print_srvsvc_NetSrvInfo1552(ndr
, "info1552", r
->info1552
);
11768 ndr_print_ptr(ndr
, "info1553", r
->info1553
);
11771 ndr_print_srvsvc_NetSrvInfo1553(ndr
, "info1553", r
->info1553
);
11777 ndr_print_ptr(ndr
, "info1554", r
->info1554
);
11780 ndr_print_srvsvc_NetSrvInfo1554(ndr
, "info1554", r
->info1554
);
11786 ndr_print_ptr(ndr
, "info1555", r
->info1555
);
11789 ndr_print_srvsvc_NetSrvInfo1555(ndr
, "info1555", r
->info1555
);
11795 ndr_print_ptr(ndr
, "info1556", r
->info1556
);
11798 ndr_print_srvsvc_NetSrvInfo1556(ndr
, "info1556", r
->info1556
);
11809 static enum ndr_err_code
ndr_push_srvsvc_NetDiskInfo0(struct ndr_push
*ndr
, int ndr_flags
, const struct srvsvc_NetDiskInfo0
*r
)
11811 if (ndr_flags
& NDR_SCALARS
) {
11812 NDR_CHECK(ndr_push_align(ndr
, 4));
11813 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
11814 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, strlen(r
->disk
) + 1));
11815 NDR_CHECK(ndr_push_charset(ndr
, NDR_SCALARS
, r
->disk
, strlen(r
->disk
) + 1, sizeof(uint16_t), CH_UTF16
));
11817 if (ndr_flags
& NDR_BUFFERS
) {
11819 return NDR_ERR_SUCCESS
;
11822 static enum ndr_err_code
ndr_pull_srvsvc_NetDiskInfo0(struct ndr_pull
*ndr
, int ndr_flags
, struct srvsvc_NetDiskInfo0
*r
)
11824 uint32_t size_disk_0
= 0;
11825 if (ndr_flags
& NDR_SCALARS
) {
11826 NDR_CHECK(ndr_pull_align(ndr
, 4));
11827 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->__disk_offset
));
11828 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->__disk_length
));
11829 size_disk_0
= r
->__disk_length
;
11830 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->disk
, size_disk_0
, sizeof(uint16_t), CH_UTF16
));
11832 if (ndr_flags
& NDR_BUFFERS
) {
11834 return NDR_ERR_SUCCESS
;
11837 _PUBLIC_
void ndr_print_srvsvc_NetDiskInfo0(struct ndr_print
*ndr
, const char *name
, const struct srvsvc_NetDiskInfo0
*r
)
11839 ndr_print_struct(ndr
, name
, "srvsvc_NetDiskInfo0");
11841 ndr_print_uint32(ndr
, "__disk_offset", (ndr
->flags
& LIBNDR_PRINT_SET_VALUES
)?0:r
->__disk_offset
);
11842 ndr_print_uint32(ndr
, "__disk_length", (ndr
->flags
& LIBNDR_PRINT_SET_VALUES
)?strlen(r
->disk
) + 1:r
->__disk_length
);
11843 ndr_print_string(ndr
, "disk", r
->disk
);
11847 static enum ndr_err_code
ndr_push_srvsvc_NetDiskInfo(struct ndr_push
*ndr
, int ndr_flags
, const struct srvsvc_NetDiskInfo
*r
)
11849 uint32_t cntr_disks_1
;
11850 if (ndr_flags
& NDR_SCALARS
) {
11851 NDR_CHECK(ndr_push_align(ndr
, 4));
11852 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->count
));
11853 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->disks
));
11855 if (ndr_flags
& NDR_BUFFERS
) {
11857 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->count
));
11858 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
11859 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->count
));
11860 for (cntr_disks_1
= 0; cntr_disks_1
< r
->count
; cntr_disks_1
++) {
11861 NDR_CHECK(ndr_push_srvsvc_NetDiskInfo0(ndr
, NDR_SCALARS
, &r
->disks
[cntr_disks_1
]));
11865 return NDR_ERR_SUCCESS
;
11868 static enum ndr_err_code
ndr_pull_srvsvc_NetDiskInfo(struct ndr_pull
*ndr
, int ndr_flags
, struct srvsvc_NetDiskInfo
*r
)
11870 uint32_t _ptr_disks
;
11871 uint32_t size_disks_1
= 0;
11872 uint32_t length_disks_1
= 0;
11873 uint32_t cntr_disks_1
;
11874 TALLOC_CTX
*_mem_save_disks_0
;
11875 TALLOC_CTX
*_mem_save_disks_1
;
11876 if (ndr_flags
& NDR_SCALARS
) {
11877 NDR_CHECK(ndr_pull_align(ndr
, 4));
11878 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->count
));
11879 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_disks
));
11881 NDR_PULL_ALLOC(ndr
, r
->disks
);
11886 if (ndr_flags
& NDR_BUFFERS
) {
11888 _mem_save_disks_0
= NDR_PULL_GET_MEM_CTX(ndr
);
11889 NDR_PULL_SET_MEM_CTX(ndr
, r
->disks
, 0);
11890 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->disks
));
11891 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->disks
));
11892 size_disks_1
= ndr_get_array_size(ndr
, &r
->disks
);
11893 length_disks_1
= ndr_get_array_length(ndr
, &r
->disks
);
11894 if (length_disks_1
> size_disks_1
) {
11895 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", size_disks_1
, length_disks_1
);
11897 NDR_PULL_ALLOC_N(ndr
, r
->disks
, size_disks_1
);
11898 _mem_save_disks_1
= NDR_PULL_GET_MEM_CTX(ndr
);
11899 NDR_PULL_SET_MEM_CTX(ndr
, r
->disks
, 0);
11900 for (cntr_disks_1
= 0; cntr_disks_1
< length_disks_1
; cntr_disks_1
++) {
11901 NDR_CHECK(ndr_pull_srvsvc_NetDiskInfo0(ndr
, NDR_SCALARS
, &r
->disks
[cntr_disks_1
]));
11903 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_disks_1
, 0);
11904 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_disks_0
, 0);
11907 NDR_CHECK(ndr_check_array_size(ndr
, (void*)&r
->disks
, r
->count
));
11910 NDR_CHECK(ndr_check_array_length(ndr
, (void*)&r
->disks
, r
->count
));
11913 return NDR_ERR_SUCCESS
;
11916 _PUBLIC_
void ndr_print_srvsvc_NetDiskInfo(struct ndr_print
*ndr
, const char *name
, const struct srvsvc_NetDiskInfo
*r
)
11918 uint32_t cntr_disks_1
;
11919 ndr_print_struct(ndr
, name
, "srvsvc_NetDiskInfo");
11921 ndr_print_uint32(ndr
, "count", r
->count
);
11922 ndr_print_ptr(ndr
, "disks", r
->disks
);
11925 ndr
->print(ndr
, "%s: ARRAY(%d)", "disks", (int)r
->count
);
11927 for (cntr_disks_1
=0;cntr_disks_1
<r
->count
;cntr_disks_1
++) {
11929 if (asprintf(&idx_1
, "[%d]", cntr_disks_1
) != -1) {
11930 ndr_print_srvsvc_NetDiskInfo0(ndr
, "disks", &r
->disks
[cntr_disks_1
]);
11940 static enum ndr_err_code
ndr_push_srvsvc_Statistics(struct ndr_push
*ndr
, int ndr_flags
, const struct srvsvc_Statistics
*r
)
11942 if (ndr_flags
& NDR_SCALARS
) {
11943 NDR_CHECK(ndr_push_align(ndr
, 4));
11944 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->start
));
11945 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->fopens
));
11946 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->devopens
));
11947 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->jobsqueued
));
11948 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->sopens
));
11949 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->stimeouts
));
11950 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->serrorout
));
11951 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->pwerrors
));
11952 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->permerrors
));
11953 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->syserrors
));
11954 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->bytessent_low
));
11955 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->bytessent_high
));
11956 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->bytesrcvd_low
));
11957 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->bytesrcvd_high
));
11958 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->avresponse
));
11959 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->reqbufneed
));
11960 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->bigbufneed
));
11962 if (ndr_flags
& NDR_BUFFERS
) {
11964 return NDR_ERR_SUCCESS
;
11967 static enum ndr_err_code
ndr_pull_srvsvc_Statistics(struct ndr_pull
*ndr
, int ndr_flags
, struct srvsvc_Statistics
*r
)
11969 if (ndr_flags
& NDR_SCALARS
) {
11970 NDR_CHECK(ndr_pull_align(ndr
, 4));
11971 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->start
));
11972 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->fopens
));
11973 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->devopens
));
11974 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->jobsqueued
));
11975 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->sopens
));
11976 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->stimeouts
));
11977 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->serrorout
));
11978 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->pwerrors
));
11979 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->permerrors
));
11980 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->syserrors
));
11981 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->bytessent_low
));
11982 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->bytessent_high
));
11983 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->bytesrcvd_low
));
11984 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->bytesrcvd_high
));
11985 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->avresponse
));
11986 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->reqbufneed
));
11987 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->bigbufneed
));
11989 if (ndr_flags
& NDR_BUFFERS
) {
11991 return NDR_ERR_SUCCESS
;
11994 _PUBLIC_
void ndr_print_srvsvc_Statistics(struct ndr_print
*ndr
, const char *name
, const struct srvsvc_Statistics
*r
)
11996 ndr_print_struct(ndr
, name
, "srvsvc_Statistics");
11998 ndr_print_uint32(ndr
, "start", r
->start
);
11999 ndr_print_uint32(ndr
, "fopens", r
->fopens
);
12000 ndr_print_uint32(ndr
, "devopens", r
->devopens
);
12001 ndr_print_uint32(ndr
, "jobsqueued", r
->jobsqueued
);
12002 ndr_print_uint32(ndr
, "sopens", r
->sopens
);
12003 ndr_print_uint32(ndr
, "stimeouts", r
->stimeouts
);
12004 ndr_print_uint32(ndr
, "serrorout", r
->serrorout
);
12005 ndr_print_uint32(ndr
, "pwerrors", r
->pwerrors
);
12006 ndr_print_uint32(ndr
, "permerrors", r
->permerrors
);
12007 ndr_print_uint32(ndr
, "syserrors", r
->syserrors
);
12008 ndr_print_uint32(ndr
, "bytessent_low", r
->bytessent_low
);
12009 ndr_print_uint32(ndr
, "bytessent_high", r
->bytessent_high
);
12010 ndr_print_uint32(ndr
, "bytesrcvd_low", r
->bytesrcvd_low
);
12011 ndr_print_uint32(ndr
, "bytesrcvd_high", r
->bytesrcvd_high
);
12012 ndr_print_uint32(ndr
, "avresponse", r
->avresponse
);
12013 ndr_print_uint32(ndr
, "reqbufneed", r
->reqbufneed
);
12014 ndr_print_uint32(ndr
, "bigbufneed", r
->bigbufneed
);
12018 static enum ndr_err_code
ndr_push_srvsvc_NetTransportInfo0(struct ndr_push
*ndr
, int ndr_flags
, const struct srvsvc_NetTransportInfo0
*r
)
12020 if (ndr_flags
& NDR_SCALARS
) {
12021 NDR_CHECK(ndr_push_align(ndr
, 4));
12022 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->vcs
));
12023 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->name
));
12024 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->addr
));
12025 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->addr_len
));
12026 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->net_addr
));
12028 if (ndr_flags
& NDR_BUFFERS
) {
12030 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->name
, CH_UTF16
)));
12031 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
12032 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->name
, CH_UTF16
)));
12033 NDR_CHECK(ndr_push_charset(ndr
, NDR_SCALARS
, r
->name
, ndr_charset_length(r
->name
, CH_UTF16
), sizeof(uint16_t), CH_UTF16
));
12036 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->addr_len
));
12037 NDR_CHECK(ndr_push_array_uint8(ndr
, NDR_SCALARS
, r
->addr
, r
->addr_len
));
12040 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->net_addr
, CH_UTF16
)));
12041 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
12042 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->net_addr
, CH_UTF16
)));
12043 NDR_CHECK(ndr_push_charset(ndr
, NDR_SCALARS
, r
->net_addr
, ndr_charset_length(r
->net_addr
, CH_UTF16
), sizeof(uint16_t), CH_UTF16
));
12046 return NDR_ERR_SUCCESS
;
12049 static enum ndr_err_code
ndr_pull_srvsvc_NetTransportInfo0(struct ndr_pull
*ndr
, int ndr_flags
, struct srvsvc_NetTransportInfo0
*r
)
12051 uint32_t _ptr_name
;
12052 uint32_t size_name_1
= 0;
12053 uint32_t length_name_1
= 0;
12054 TALLOC_CTX
*_mem_save_name_0
;
12055 uint32_t _ptr_addr
;
12056 uint32_t size_addr_1
= 0;
12057 TALLOC_CTX
*_mem_save_addr_0
;
12058 uint32_t _ptr_net_addr
;
12059 uint32_t size_net_addr_1
= 0;
12060 uint32_t length_net_addr_1
= 0;
12061 TALLOC_CTX
*_mem_save_net_addr_0
;
12062 if (ndr_flags
& NDR_SCALARS
) {
12063 NDR_CHECK(ndr_pull_align(ndr
, 4));
12064 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->vcs
));
12065 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_name
));
12067 NDR_PULL_ALLOC(ndr
, r
->name
);
12071 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_addr
));
12073 NDR_PULL_ALLOC(ndr
, r
->addr
);
12077 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->addr_len
));
12078 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_net_addr
));
12079 if (_ptr_net_addr
) {
12080 NDR_PULL_ALLOC(ndr
, r
->net_addr
);
12082 r
->net_addr
= NULL
;
12085 if (ndr_flags
& NDR_BUFFERS
) {
12087 _mem_save_name_0
= NDR_PULL_GET_MEM_CTX(ndr
);
12088 NDR_PULL_SET_MEM_CTX(ndr
, r
->name
, 0);
12089 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->name
));
12090 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->name
));
12091 size_name_1
= ndr_get_array_size(ndr
, &r
->name
);
12092 length_name_1
= ndr_get_array_length(ndr
, &r
->name
);
12093 if (length_name_1
> size_name_1
) {
12094 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", size_name_1
, length_name_1
);
12096 NDR_CHECK(ndr_check_string_terminator(ndr
, length_name_1
, sizeof(uint16_t)));
12097 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->name
, length_name_1
, sizeof(uint16_t), CH_UTF16
));
12098 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_name_0
, 0);
12101 _mem_save_addr_0
= NDR_PULL_GET_MEM_CTX(ndr
);
12102 NDR_PULL_SET_MEM_CTX(ndr
, r
->addr
, 0);
12103 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->addr
));
12104 size_addr_1
= ndr_get_array_size(ndr
, &r
->addr
);
12105 NDR_PULL_ALLOC_N(ndr
, r
->addr
, size_addr_1
);
12106 NDR_CHECK(ndr_pull_array_uint8(ndr
, NDR_SCALARS
, r
->addr
, size_addr_1
));
12107 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_addr_0
, 0);
12110 _mem_save_net_addr_0
= NDR_PULL_GET_MEM_CTX(ndr
);
12111 NDR_PULL_SET_MEM_CTX(ndr
, r
->net_addr
, 0);
12112 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->net_addr
));
12113 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->net_addr
));
12114 size_net_addr_1
= ndr_get_array_size(ndr
, &r
->net_addr
);
12115 length_net_addr_1
= ndr_get_array_length(ndr
, &r
->net_addr
);
12116 if (length_net_addr_1
> size_net_addr_1
) {
12117 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", size_net_addr_1
, length_net_addr_1
);
12119 NDR_CHECK(ndr_check_string_terminator(ndr
, length_net_addr_1
, sizeof(uint16_t)));
12120 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->net_addr
, length_net_addr_1
, sizeof(uint16_t), CH_UTF16
));
12121 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_net_addr_0
, 0);
12124 NDR_CHECK(ndr_check_array_size(ndr
, (void*)&r
->addr
, r
->addr_len
));
12127 return NDR_ERR_SUCCESS
;
12130 _PUBLIC_
void ndr_print_srvsvc_NetTransportInfo0(struct ndr_print
*ndr
, const char *name
, const struct srvsvc_NetTransportInfo0
*r
)
12132 ndr_print_struct(ndr
, name
, "srvsvc_NetTransportInfo0");
12134 ndr_print_uint32(ndr
, "vcs", r
->vcs
);
12135 ndr_print_ptr(ndr
, "name", r
->name
);
12138 ndr_print_string(ndr
, "name", r
->name
);
12141 ndr_print_ptr(ndr
, "addr", r
->addr
);
12144 ndr_print_array_uint8(ndr
, "addr", r
->addr
, r
->addr_len
);
12147 ndr_print_uint32(ndr
, "addr_len", r
->addr_len
);
12148 ndr_print_ptr(ndr
, "net_addr", r
->net_addr
);
12151 ndr_print_string(ndr
, "net_addr", r
->net_addr
);
12157 static enum ndr_err_code
ndr_push_srvsvc_NetTransportCtr0(struct ndr_push
*ndr
, int ndr_flags
, const struct srvsvc_NetTransportCtr0
*r
)
12159 uint32_t cntr_array_1
;
12160 if (ndr_flags
& NDR_SCALARS
) {
12161 NDR_CHECK(ndr_push_align(ndr
, 4));
12162 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->count
));
12163 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->array
));
12165 if (ndr_flags
& NDR_BUFFERS
) {
12167 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->count
));
12168 for (cntr_array_1
= 0; cntr_array_1
< r
->count
; cntr_array_1
++) {
12169 NDR_CHECK(ndr_push_srvsvc_NetTransportInfo0(ndr
, NDR_SCALARS
, &r
->array
[cntr_array_1
]));
12171 for (cntr_array_1
= 0; cntr_array_1
< r
->count
; cntr_array_1
++) {
12172 NDR_CHECK(ndr_push_srvsvc_NetTransportInfo0(ndr
, NDR_BUFFERS
, &r
->array
[cntr_array_1
]));
12176 return NDR_ERR_SUCCESS
;
12179 static enum ndr_err_code
ndr_pull_srvsvc_NetTransportCtr0(struct ndr_pull
*ndr
, int ndr_flags
, struct srvsvc_NetTransportCtr0
*r
)
12181 uint32_t _ptr_array
;
12182 uint32_t size_array_1
= 0;
12183 uint32_t cntr_array_1
;
12184 TALLOC_CTX
*_mem_save_array_0
;
12185 TALLOC_CTX
*_mem_save_array_1
;
12186 if (ndr_flags
& NDR_SCALARS
) {
12187 NDR_CHECK(ndr_pull_align(ndr
, 4));
12188 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->count
));
12189 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_array
));
12191 NDR_PULL_ALLOC(ndr
, r
->array
);
12196 if (ndr_flags
& NDR_BUFFERS
) {
12198 _mem_save_array_0
= NDR_PULL_GET_MEM_CTX(ndr
);
12199 NDR_PULL_SET_MEM_CTX(ndr
, r
->array
, 0);
12200 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->array
));
12201 size_array_1
= ndr_get_array_size(ndr
, &r
->array
);
12202 NDR_PULL_ALLOC_N(ndr
, r
->array
, size_array_1
);
12203 _mem_save_array_1
= NDR_PULL_GET_MEM_CTX(ndr
);
12204 NDR_PULL_SET_MEM_CTX(ndr
, r
->array
, 0);
12205 for (cntr_array_1
= 0; cntr_array_1
< size_array_1
; cntr_array_1
++) {
12206 NDR_CHECK(ndr_pull_srvsvc_NetTransportInfo0(ndr
, NDR_SCALARS
, &r
->array
[cntr_array_1
]));
12208 for (cntr_array_1
= 0; cntr_array_1
< size_array_1
; cntr_array_1
++) {
12209 NDR_CHECK(ndr_pull_srvsvc_NetTransportInfo0(ndr
, NDR_BUFFERS
, &r
->array
[cntr_array_1
]));
12211 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_array_1
, 0);
12212 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_array_0
, 0);
12215 NDR_CHECK(ndr_check_array_size(ndr
, (void*)&r
->array
, r
->count
));
12218 return NDR_ERR_SUCCESS
;
12221 _PUBLIC_
void ndr_print_srvsvc_NetTransportCtr0(struct ndr_print
*ndr
, const char *name
, const struct srvsvc_NetTransportCtr0
*r
)
12223 uint32_t cntr_array_1
;
12224 ndr_print_struct(ndr
, name
, "srvsvc_NetTransportCtr0");
12226 ndr_print_uint32(ndr
, "count", r
->count
);
12227 ndr_print_ptr(ndr
, "array", r
->array
);
12230 ndr
->print(ndr
, "%s: ARRAY(%d)", "array", (int)r
->count
);
12232 for (cntr_array_1
=0;cntr_array_1
<r
->count
;cntr_array_1
++) {
12234 if (asprintf(&idx_1
, "[%d]", cntr_array_1
) != -1) {
12235 ndr_print_srvsvc_NetTransportInfo0(ndr
, "array", &r
->array
[cntr_array_1
]);
12245 static enum ndr_err_code
ndr_push_srvsvc_NetTransportInfo1(struct ndr_push
*ndr
, int ndr_flags
, const struct srvsvc_NetTransportInfo1
*r
)
12247 if (ndr_flags
& NDR_SCALARS
) {
12248 NDR_CHECK(ndr_push_align(ndr
, 4));
12249 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->vcs
));
12250 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->name
));
12251 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->addr
));
12252 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->addr_len
));
12253 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->net_addr
));
12254 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->domain
));
12256 if (ndr_flags
& NDR_BUFFERS
) {
12258 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->name
, CH_UTF16
)));
12259 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
12260 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->name
, CH_UTF16
)));
12261 NDR_CHECK(ndr_push_charset(ndr
, NDR_SCALARS
, r
->name
, ndr_charset_length(r
->name
, CH_UTF16
), sizeof(uint16_t), CH_UTF16
));
12264 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->addr_len
));
12265 NDR_CHECK(ndr_push_array_uint8(ndr
, NDR_SCALARS
, r
->addr
, r
->addr_len
));
12268 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->net_addr
, CH_UTF16
)));
12269 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
12270 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->net_addr
, CH_UTF16
)));
12271 NDR_CHECK(ndr_push_charset(ndr
, NDR_SCALARS
, r
->net_addr
, ndr_charset_length(r
->net_addr
, CH_UTF16
), sizeof(uint16_t), CH_UTF16
));
12274 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->domain
, CH_UTF16
)));
12275 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
12276 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->domain
, CH_UTF16
)));
12277 NDR_CHECK(ndr_push_charset(ndr
, NDR_SCALARS
, r
->domain
, ndr_charset_length(r
->domain
, CH_UTF16
), sizeof(uint16_t), CH_UTF16
));
12280 return NDR_ERR_SUCCESS
;
12283 static enum ndr_err_code
ndr_pull_srvsvc_NetTransportInfo1(struct ndr_pull
*ndr
, int ndr_flags
, struct srvsvc_NetTransportInfo1
*r
)
12285 uint32_t _ptr_name
;
12286 uint32_t size_name_1
= 0;
12287 uint32_t length_name_1
= 0;
12288 TALLOC_CTX
*_mem_save_name_0
;
12289 uint32_t _ptr_addr
;
12290 uint32_t size_addr_1
= 0;
12291 TALLOC_CTX
*_mem_save_addr_0
;
12292 uint32_t _ptr_net_addr
;
12293 uint32_t size_net_addr_1
= 0;
12294 uint32_t length_net_addr_1
= 0;
12295 TALLOC_CTX
*_mem_save_net_addr_0
;
12296 uint32_t _ptr_domain
;
12297 uint32_t size_domain_1
= 0;
12298 uint32_t length_domain_1
= 0;
12299 TALLOC_CTX
*_mem_save_domain_0
;
12300 if (ndr_flags
& NDR_SCALARS
) {
12301 NDR_CHECK(ndr_pull_align(ndr
, 4));
12302 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->vcs
));
12303 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_name
));
12305 NDR_PULL_ALLOC(ndr
, r
->name
);
12309 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_addr
));
12311 NDR_PULL_ALLOC(ndr
, r
->addr
);
12315 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->addr_len
));
12316 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_net_addr
));
12317 if (_ptr_net_addr
) {
12318 NDR_PULL_ALLOC(ndr
, r
->net_addr
);
12320 r
->net_addr
= NULL
;
12322 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_domain
));
12324 NDR_PULL_ALLOC(ndr
, r
->domain
);
12329 if (ndr_flags
& NDR_BUFFERS
) {
12331 _mem_save_name_0
= NDR_PULL_GET_MEM_CTX(ndr
);
12332 NDR_PULL_SET_MEM_CTX(ndr
, r
->name
, 0);
12333 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->name
));
12334 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->name
));
12335 size_name_1
= ndr_get_array_size(ndr
, &r
->name
);
12336 length_name_1
= ndr_get_array_length(ndr
, &r
->name
);
12337 if (length_name_1
> size_name_1
) {
12338 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", size_name_1
, length_name_1
);
12340 NDR_CHECK(ndr_check_string_terminator(ndr
, length_name_1
, sizeof(uint16_t)));
12341 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->name
, length_name_1
, sizeof(uint16_t), CH_UTF16
));
12342 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_name_0
, 0);
12345 _mem_save_addr_0
= NDR_PULL_GET_MEM_CTX(ndr
);
12346 NDR_PULL_SET_MEM_CTX(ndr
, r
->addr
, 0);
12347 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->addr
));
12348 size_addr_1
= ndr_get_array_size(ndr
, &r
->addr
);
12349 NDR_PULL_ALLOC_N(ndr
, r
->addr
, size_addr_1
);
12350 NDR_CHECK(ndr_pull_array_uint8(ndr
, NDR_SCALARS
, r
->addr
, size_addr_1
));
12351 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_addr_0
, 0);
12354 _mem_save_net_addr_0
= NDR_PULL_GET_MEM_CTX(ndr
);
12355 NDR_PULL_SET_MEM_CTX(ndr
, r
->net_addr
, 0);
12356 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->net_addr
));
12357 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->net_addr
));
12358 size_net_addr_1
= ndr_get_array_size(ndr
, &r
->net_addr
);
12359 length_net_addr_1
= ndr_get_array_length(ndr
, &r
->net_addr
);
12360 if (length_net_addr_1
> size_net_addr_1
) {
12361 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", size_net_addr_1
, length_net_addr_1
);
12363 NDR_CHECK(ndr_check_string_terminator(ndr
, length_net_addr_1
, sizeof(uint16_t)));
12364 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->net_addr
, length_net_addr_1
, sizeof(uint16_t), CH_UTF16
));
12365 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_net_addr_0
, 0);
12368 _mem_save_domain_0
= NDR_PULL_GET_MEM_CTX(ndr
);
12369 NDR_PULL_SET_MEM_CTX(ndr
, r
->domain
, 0);
12370 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->domain
));
12371 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->domain
));
12372 size_domain_1
= ndr_get_array_size(ndr
, &r
->domain
);
12373 length_domain_1
= ndr_get_array_length(ndr
, &r
->domain
);
12374 if (length_domain_1
> size_domain_1
) {
12375 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", size_domain_1
, length_domain_1
);
12377 NDR_CHECK(ndr_check_string_terminator(ndr
, length_domain_1
, sizeof(uint16_t)));
12378 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->domain
, length_domain_1
, sizeof(uint16_t), CH_UTF16
));
12379 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_domain_0
, 0);
12382 NDR_CHECK(ndr_check_array_size(ndr
, (void*)&r
->addr
, r
->addr_len
));
12385 return NDR_ERR_SUCCESS
;
12388 _PUBLIC_
void ndr_print_srvsvc_NetTransportInfo1(struct ndr_print
*ndr
, const char *name
, const struct srvsvc_NetTransportInfo1
*r
)
12390 ndr_print_struct(ndr
, name
, "srvsvc_NetTransportInfo1");
12392 ndr_print_uint32(ndr
, "vcs", r
->vcs
);
12393 ndr_print_ptr(ndr
, "name", r
->name
);
12396 ndr_print_string(ndr
, "name", r
->name
);
12399 ndr_print_ptr(ndr
, "addr", r
->addr
);
12402 ndr_print_array_uint8(ndr
, "addr", r
->addr
, r
->addr_len
);
12405 ndr_print_uint32(ndr
, "addr_len", r
->addr_len
);
12406 ndr_print_ptr(ndr
, "net_addr", r
->net_addr
);
12409 ndr_print_string(ndr
, "net_addr", r
->net_addr
);
12412 ndr_print_ptr(ndr
, "domain", r
->domain
);
12415 ndr_print_string(ndr
, "domain", r
->domain
);
12421 static enum ndr_err_code
ndr_push_srvsvc_NetTransportCtr1(struct ndr_push
*ndr
, int ndr_flags
, const struct srvsvc_NetTransportCtr1
*r
)
12423 uint32_t cntr_array_1
;
12424 if (ndr_flags
& NDR_SCALARS
) {
12425 NDR_CHECK(ndr_push_align(ndr
, 4));
12426 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->count
));
12427 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->array
));
12429 if (ndr_flags
& NDR_BUFFERS
) {
12431 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->count
));
12432 for (cntr_array_1
= 0; cntr_array_1
< r
->count
; cntr_array_1
++) {
12433 NDR_CHECK(ndr_push_srvsvc_NetTransportInfo1(ndr
, NDR_SCALARS
, &r
->array
[cntr_array_1
]));
12435 for (cntr_array_1
= 0; cntr_array_1
< r
->count
; cntr_array_1
++) {
12436 NDR_CHECK(ndr_push_srvsvc_NetTransportInfo1(ndr
, NDR_BUFFERS
, &r
->array
[cntr_array_1
]));
12440 return NDR_ERR_SUCCESS
;
12443 static enum ndr_err_code
ndr_pull_srvsvc_NetTransportCtr1(struct ndr_pull
*ndr
, int ndr_flags
, struct srvsvc_NetTransportCtr1
*r
)
12445 uint32_t _ptr_array
;
12446 uint32_t size_array_1
= 0;
12447 uint32_t cntr_array_1
;
12448 TALLOC_CTX
*_mem_save_array_0
;
12449 TALLOC_CTX
*_mem_save_array_1
;
12450 if (ndr_flags
& NDR_SCALARS
) {
12451 NDR_CHECK(ndr_pull_align(ndr
, 4));
12452 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->count
));
12453 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_array
));
12455 NDR_PULL_ALLOC(ndr
, r
->array
);
12460 if (ndr_flags
& NDR_BUFFERS
) {
12462 _mem_save_array_0
= NDR_PULL_GET_MEM_CTX(ndr
);
12463 NDR_PULL_SET_MEM_CTX(ndr
, r
->array
, 0);
12464 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->array
));
12465 size_array_1
= ndr_get_array_size(ndr
, &r
->array
);
12466 NDR_PULL_ALLOC_N(ndr
, r
->array
, size_array_1
);
12467 _mem_save_array_1
= NDR_PULL_GET_MEM_CTX(ndr
);
12468 NDR_PULL_SET_MEM_CTX(ndr
, r
->array
, 0);
12469 for (cntr_array_1
= 0; cntr_array_1
< size_array_1
; cntr_array_1
++) {
12470 NDR_CHECK(ndr_pull_srvsvc_NetTransportInfo1(ndr
, NDR_SCALARS
, &r
->array
[cntr_array_1
]));
12472 for (cntr_array_1
= 0; cntr_array_1
< size_array_1
; cntr_array_1
++) {
12473 NDR_CHECK(ndr_pull_srvsvc_NetTransportInfo1(ndr
, NDR_BUFFERS
, &r
->array
[cntr_array_1
]));
12475 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_array_1
, 0);
12476 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_array_0
, 0);
12479 NDR_CHECK(ndr_check_array_size(ndr
, (void*)&r
->array
, r
->count
));
12482 return NDR_ERR_SUCCESS
;
12485 _PUBLIC_
void ndr_print_srvsvc_NetTransportCtr1(struct ndr_print
*ndr
, const char *name
, const struct srvsvc_NetTransportCtr1
*r
)
12487 uint32_t cntr_array_1
;
12488 ndr_print_struct(ndr
, name
, "srvsvc_NetTransportCtr1");
12490 ndr_print_uint32(ndr
, "count", r
->count
);
12491 ndr_print_ptr(ndr
, "array", r
->array
);
12494 ndr
->print(ndr
, "%s: ARRAY(%d)", "array", (int)r
->count
);
12496 for (cntr_array_1
=0;cntr_array_1
<r
->count
;cntr_array_1
++) {
12498 if (asprintf(&idx_1
, "[%d]", cntr_array_1
) != -1) {
12499 ndr_print_srvsvc_NetTransportInfo1(ndr
, "array", &r
->array
[cntr_array_1
]);
12509 static enum ndr_err_code
ndr_push_srvsvc_NetTransportInfo2(struct ndr_push
*ndr
, int ndr_flags
, const struct srvsvc_NetTransportInfo2
*r
)
12511 if (ndr_flags
& NDR_SCALARS
) {
12512 NDR_CHECK(ndr_push_align(ndr
, 4));
12513 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->vcs
));
12514 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->name
));
12515 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->addr
));
12516 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->addr_len
));
12517 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->net_addr
));
12518 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->domain
));
12519 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->unknown
));
12521 if (ndr_flags
& NDR_BUFFERS
) {
12523 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->name
, CH_UTF16
)));
12524 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
12525 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->name
, CH_UTF16
)));
12526 NDR_CHECK(ndr_push_charset(ndr
, NDR_SCALARS
, r
->name
, ndr_charset_length(r
->name
, CH_UTF16
), sizeof(uint16_t), CH_UTF16
));
12529 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->addr_len
));
12530 NDR_CHECK(ndr_push_array_uint8(ndr
, NDR_SCALARS
, r
->addr
, r
->addr_len
));
12533 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->net_addr
, CH_UTF16
)));
12534 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
12535 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->net_addr
, CH_UTF16
)));
12536 NDR_CHECK(ndr_push_charset(ndr
, NDR_SCALARS
, r
->net_addr
, ndr_charset_length(r
->net_addr
, CH_UTF16
), sizeof(uint16_t), CH_UTF16
));
12539 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->domain
, CH_UTF16
)));
12540 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
12541 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->domain
, CH_UTF16
)));
12542 NDR_CHECK(ndr_push_charset(ndr
, NDR_SCALARS
, r
->domain
, ndr_charset_length(r
->domain
, CH_UTF16
), sizeof(uint16_t), CH_UTF16
));
12545 return NDR_ERR_SUCCESS
;
12548 static enum ndr_err_code
ndr_pull_srvsvc_NetTransportInfo2(struct ndr_pull
*ndr
, int ndr_flags
, struct srvsvc_NetTransportInfo2
*r
)
12550 uint32_t _ptr_name
;
12551 uint32_t size_name_1
= 0;
12552 uint32_t length_name_1
= 0;
12553 TALLOC_CTX
*_mem_save_name_0
;
12554 uint32_t _ptr_addr
;
12555 uint32_t size_addr_1
= 0;
12556 TALLOC_CTX
*_mem_save_addr_0
;
12557 uint32_t _ptr_net_addr
;
12558 uint32_t size_net_addr_1
= 0;
12559 uint32_t length_net_addr_1
= 0;
12560 TALLOC_CTX
*_mem_save_net_addr_0
;
12561 uint32_t _ptr_domain
;
12562 uint32_t size_domain_1
= 0;
12563 uint32_t length_domain_1
= 0;
12564 TALLOC_CTX
*_mem_save_domain_0
;
12565 if (ndr_flags
& NDR_SCALARS
) {
12566 NDR_CHECK(ndr_pull_align(ndr
, 4));
12567 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->vcs
));
12568 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_name
));
12570 NDR_PULL_ALLOC(ndr
, r
->name
);
12574 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_addr
));
12576 NDR_PULL_ALLOC(ndr
, r
->addr
);
12580 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->addr_len
));
12581 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_net_addr
));
12582 if (_ptr_net_addr
) {
12583 NDR_PULL_ALLOC(ndr
, r
->net_addr
);
12585 r
->net_addr
= NULL
;
12587 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_domain
));
12589 NDR_PULL_ALLOC(ndr
, r
->domain
);
12593 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->unknown
));
12595 if (ndr_flags
& NDR_BUFFERS
) {
12597 _mem_save_name_0
= NDR_PULL_GET_MEM_CTX(ndr
);
12598 NDR_PULL_SET_MEM_CTX(ndr
, r
->name
, 0);
12599 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->name
));
12600 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->name
));
12601 size_name_1
= ndr_get_array_size(ndr
, &r
->name
);
12602 length_name_1
= ndr_get_array_length(ndr
, &r
->name
);
12603 if (length_name_1
> size_name_1
) {
12604 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", size_name_1
, length_name_1
);
12606 NDR_CHECK(ndr_check_string_terminator(ndr
, length_name_1
, sizeof(uint16_t)));
12607 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->name
, length_name_1
, sizeof(uint16_t), CH_UTF16
));
12608 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_name_0
, 0);
12611 _mem_save_addr_0
= NDR_PULL_GET_MEM_CTX(ndr
);
12612 NDR_PULL_SET_MEM_CTX(ndr
, r
->addr
, 0);
12613 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->addr
));
12614 size_addr_1
= ndr_get_array_size(ndr
, &r
->addr
);
12615 NDR_PULL_ALLOC_N(ndr
, r
->addr
, size_addr_1
);
12616 NDR_CHECK(ndr_pull_array_uint8(ndr
, NDR_SCALARS
, r
->addr
, size_addr_1
));
12617 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_addr_0
, 0);
12620 _mem_save_net_addr_0
= NDR_PULL_GET_MEM_CTX(ndr
);
12621 NDR_PULL_SET_MEM_CTX(ndr
, r
->net_addr
, 0);
12622 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->net_addr
));
12623 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->net_addr
));
12624 size_net_addr_1
= ndr_get_array_size(ndr
, &r
->net_addr
);
12625 length_net_addr_1
= ndr_get_array_length(ndr
, &r
->net_addr
);
12626 if (length_net_addr_1
> size_net_addr_1
) {
12627 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", size_net_addr_1
, length_net_addr_1
);
12629 NDR_CHECK(ndr_check_string_terminator(ndr
, length_net_addr_1
, sizeof(uint16_t)));
12630 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->net_addr
, length_net_addr_1
, sizeof(uint16_t), CH_UTF16
));
12631 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_net_addr_0
, 0);
12634 _mem_save_domain_0
= NDR_PULL_GET_MEM_CTX(ndr
);
12635 NDR_PULL_SET_MEM_CTX(ndr
, r
->domain
, 0);
12636 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->domain
));
12637 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->domain
));
12638 size_domain_1
= ndr_get_array_size(ndr
, &r
->domain
);
12639 length_domain_1
= ndr_get_array_length(ndr
, &r
->domain
);
12640 if (length_domain_1
> size_domain_1
) {
12641 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", size_domain_1
, length_domain_1
);
12643 NDR_CHECK(ndr_check_string_terminator(ndr
, length_domain_1
, sizeof(uint16_t)));
12644 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->domain
, length_domain_1
, sizeof(uint16_t), CH_UTF16
));
12645 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_domain_0
, 0);
12648 NDR_CHECK(ndr_check_array_size(ndr
, (void*)&r
->addr
, r
->addr_len
));
12651 return NDR_ERR_SUCCESS
;
12654 _PUBLIC_
void ndr_print_srvsvc_NetTransportInfo2(struct ndr_print
*ndr
, const char *name
, const struct srvsvc_NetTransportInfo2
*r
)
12656 ndr_print_struct(ndr
, name
, "srvsvc_NetTransportInfo2");
12658 ndr_print_uint32(ndr
, "vcs", r
->vcs
);
12659 ndr_print_ptr(ndr
, "name", r
->name
);
12662 ndr_print_string(ndr
, "name", r
->name
);
12665 ndr_print_ptr(ndr
, "addr", r
->addr
);
12668 ndr_print_array_uint8(ndr
, "addr", r
->addr
, r
->addr_len
);
12671 ndr_print_uint32(ndr
, "addr_len", r
->addr_len
);
12672 ndr_print_ptr(ndr
, "net_addr", r
->net_addr
);
12675 ndr_print_string(ndr
, "net_addr", r
->net_addr
);
12678 ndr_print_ptr(ndr
, "domain", r
->domain
);
12681 ndr_print_string(ndr
, "domain", r
->domain
);
12684 ndr_print_uint32(ndr
, "unknown", r
->unknown
);
12688 static enum ndr_err_code
ndr_push_srvsvc_NetTransportCtr2(struct ndr_push
*ndr
, int ndr_flags
, const struct srvsvc_NetTransportCtr2
*r
)
12690 uint32_t cntr_array_1
;
12691 if (ndr_flags
& NDR_SCALARS
) {
12692 NDR_CHECK(ndr_push_align(ndr
, 4));
12693 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->count
));
12694 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->array
));
12696 if (ndr_flags
& NDR_BUFFERS
) {
12698 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->count
));
12699 for (cntr_array_1
= 0; cntr_array_1
< r
->count
; cntr_array_1
++) {
12700 NDR_CHECK(ndr_push_srvsvc_NetTransportInfo2(ndr
, NDR_SCALARS
, &r
->array
[cntr_array_1
]));
12702 for (cntr_array_1
= 0; cntr_array_1
< r
->count
; cntr_array_1
++) {
12703 NDR_CHECK(ndr_push_srvsvc_NetTransportInfo2(ndr
, NDR_BUFFERS
, &r
->array
[cntr_array_1
]));
12707 return NDR_ERR_SUCCESS
;
12710 static enum ndr_err_code
ndr_pull_srvsvc_NetTransportCtr2(struct ndr_pull
*ndr
, int ndr_flags
, struct srvsvc_NetTransportCtr2
*r
)
12712 uint32_t _ptr_array
;
12713 uint32_t size_array_1
= 0;
12714 uint32_t cntr_array_1
;
12715 TALLOC_CTX
*_mem_save_array_0
;
12716 TALLOC_CTX
*_mem_save_array_1
;
12717 if (ndr_flags
& NDR_SCALARS
) {
12718 NDR_CHECK(ndr_pull_align(ndr
, 4));
12719 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->count
));
12720 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_array
));
12722 NDR_PULL_ALLOC(ndr
, r
->array
);
12727 if (ndr_flags
& NDR_BUFFERS
) {
12729 _mem_save_array_0
= NDR_PULL_GET_MEM_CTX(ndr
);
12730 NDR_PULL_SET_MEM_CTX(ndr
, r
->array
, 0);
12731 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->array
));
12732 size_array_1
= ndr_get_array_size(ndr
, &r
->array
);
12733 NDR_PULL_ALLOC_N(ndr
, r
->array
, size_array_1
);
12734 _mem_save_array_1
= NDR_PULL_GET_MEM_CTX(ndr
);
12735 NDR_PULL_SET_MEM_CTX(ndr
, r
->array
, 0);
12736 for (cntr_array_1
= 0; cntr_array_1
< size_array_1
; cntr_array_1
++) {
12737 NDR_CHECK(ndr_pull_srvsvc_NetTransportInfo2(ndr
, NDR_SCALARS
, &r
->array
[cntr_array_1
]));
12739 for (cntr_array_1
= 0; cntr_array_1
< size_array_1
; cntr_array_1
++) {
12740 NDR_CHECK(ndr_pull_srvsvc_NetTransportInfo2(ndr
, NDR_BUFFERS
, &r
->array
[cntr_array_1
]));
12742 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_array_1
, 0);
12743 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_array_0
, 0);
12746 NDR_CHECK(ndr_check_array_size(ndr
, (void*)&r
->array
, r
->count
));
12749 return NDR_ERR_SUCCESS
;
12752 _PUBLIC_
void ndr_print_srvsvc_NetTransportCtr2(struct ndr_print
*ndr
, const char *name
, const struct srvsvc_NetTransportCtr2
*r
)
12754 uint32_t cntr_array_1
;
12755 ndr_print_struct(ndr
, name
, "srvsvc_NetTransportCtr2");
12757 ndr_print_uint32(ndr
, "count", r
->count
);
12758 ndr_print_ptr(ndr
, "array", r
->array
);
12761 ndr
->print(ndr
, "%s: ARRAY(%d)", "array", (int)r
->count
);
12763 for (cntr_array_1
=0;cntr_array_1
<r
->count
;cntr_array_1
++) {
12765 if (asprintf(&idx_1
, "[%d]", cntr_array_1
) != -1) {
12766 ndr_print_srvsvc_NetTransportInfo2(ndr
, "array", &r
->array
[cntr_array_1
]);
12776 static enum ndr_err_code
ndr_push_srvsvc_NetTransportInfo3(struct ndr_push
*ndr
, int ndr_flags
, const struct srvsvc_NetTransportInfo3
*r
)
12778 if (ndr_flags
& NDR_SCALARS
) {
12779 NDR_CHECK(ndr_push_align(ndr
, 4));
12780 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->vcs
));
12781 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->name
));
12782 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->addr
));
12783 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->addr_len
));
12784 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->net_addr
));
12785 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->domain
));
12786 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->unknown1
));
12787 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->unknown2
));
12788 NDR_CHECK(ndr_push_array_uint8(ndr
, NDR_SCALARS
, r
->unknown3
, 256));
12790 if (ndr_flags
& NDR_BUFFERS
) {
12792 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->name
, CH_UTF16
)));
12793 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
12794 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->name
, CH_UTF16
)));
12795 NDR_CHECK(ndr_push_charset(ndr
, NDR_SCALARS
, r
->name
, ndr_charset_length(r
->name
, CH_UTF16
), sizeof(uint16_t), CH_UTF16
));
12798 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->addr_len
));
12799 NDR_CHECK(ndr_push_array_uint8(ndr
, NDR_SCALARS
, r
->addr
, r
->addr_len
));
12802 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->net_addr
, CH_UTF16
)));
12803 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
12804 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->net_addr
, CH_UTF16
)));
12805 NDR_CHECK(ndr_push_charset(ndr
, NDR_SCALARS
, r
->net_addr
, ndr_charset_length(r
->net_addr
, CH_UTF16
), sizeof(uint16_t), CH_UTF16
));
12808 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->domain
, CH_UTF16
)));
12809 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
12810 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->domain
, CH_UTF16
)));
12811 NDR_CHECK(ndr_push_charset(ndr
, NDR_SCALARS
, r
->domain
, ndr_charset_length(r
->domain
, CH_UTF16
), sizeof(uint16_t), CH_UTF16
));
12814 return NDR_ERR_SUCCESS
;
12817 static enum ndr_err_code
ndr_pull_srvsvc_NetTransportInfo3(struct ndr_pull
*ndr
, int ndr_flags
, struct srvsvc_NetTransportInfo3
*r
)
12819 uint32_t _ptr_name
;
12820 uint32_t size_name_1
= 0;
12821 uint32_t length_name_1
= 0;
12822 TALLOC_CTX
*_mem_save_name_0
;
12823 uint32_t _ptr_addr
;
12824 uint32_t size_addr_1
= 0;
12825 TALLOC_CTX
*_mem_save_addr_0
;
12826 uint32_t _ptr_net_addr
;
12827 uint32_t size_net_addr_1
= 0;
12828 uint32_t length_net_addr_1
= 0;
12829 TALLOC_CTX
*_mem_save_net_addr_0
;
12830 uint32_t _ptr_domain
;
12831 uint32_t size_domain_1
= 0;
12832 uint32_t length_domain_1
= 0;
12833 TALLOC_CTX
*_mem_save_domain_0
;
12834 uint32_t size_unknown3_0
= 0;
12835 if (ndr_flags
& NDR_SCALARS
) {
12836 NDR_CHECK(ndr_pull_align(ndr
, 4));
12837 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->vcs
));
12838 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_name
));
12840 NDR_PULL_ALLOC(ndr
, r
->name
);
12844 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_addr
));
12846 NDR_PULL_ALLOC(ndr
, r
->addr
);
12850 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->addr_len
));
12851 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_net_addr
));
12852 if (_ptr_net_addr
) {
12853 NDR_PULL_ALLOC(ndr
, r
->net_addr
);
12855 r
->net_addr
= NULL
;
12857 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_domain
));
12859 NDR_PULL_ALLOC(ndr
, r
->domain
);
12863 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->unknown1
));
12864 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->unknown2
));
12865 size_unknown3_0
= 256;
12866 NDR_CHECK(ndr_pull_array_uint8(ndr
, NDR_SCALARS
, r
->unknown3
, size_unknown3_0
));
12868 if (ndr_flags
& NDR_BUFFERS
) {
12870 _mem_save_name_0
= NDR_PULL_GET_MEM_CTX(ndr
);
12871 NDR_PULL_SET_MEM_CTX(ndr
, r
->name
, 0);
12872 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->name
));
12873 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->name
));
12874 size_name_1
= ndr_get_array_size(ndr
, &r
->name
);
12875 length_name_1
= ndr_get_array_length(ndr
, &r
->name
);
12876 if (length_name_1
> size_name_1
) {
12877 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", size_name_1
, length_name_1
);
12879 NDR_CHECK(ndr_check_string_terminator(ndr
, length_name_1
, sizeof(uint16_t)));
12880 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->name
, length_name_1
, sizeof(uint16_t), CH_UTF16
));
12881 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_name_0
, 0);
12884 _mem_save_addr_0
= NDR_PULL_GET_MEM_CTX(ndr
);
12885 NDR_PULL_SET_MEM_CTX(ndr
, r
->addr
, 0);
12886 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->addr
));
12887 size_addr_1
= ndr_get_array_size(ndr
, &r
->addr
);
12888 NDR_PULL_ALLOC_N(ndr
, r
->addr
, size_addr_1
);
12889 NDR_CHECK(ndr_pull_array_uint8(ndr
, NDR_SCALARS
, r
->addr
, size_addr_1
));
12890 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_addr_0
, 0);
12893 _mem_save_net_addr_0
= NDR_PULL_GET_MEM_CTX(ndr
);
12894 NDR_PULL_SET_MEM_CTX(ndr
, r
->net_addr
, 0);
12895 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->net_addr
));
12896 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->net_addr
));
12897 size_net_addr_1
= ndr_get_array_size(ndr
, &r
->net_addr
);
12898 length_net_addr_1
= ndr_get_array_length(ndr
, &r
->net_addr
);
12899 if (length_net_addr_1
> size_net_addr_1
) {
12900 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", size_net_addr_1
, length_net_addr_1
);
12902 NDR_CHECK(ndr_check_string_terminator(ndr
, length_net_addr_1
, sizeof(uint16_t)));
12903 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->net_addr
, length_net_addr_1
, sizeof(uint16_t), CH_UTF16
));
12904 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_net_addr_0
, 0);
12907 _mem_save_domain_0
= NDR_PULL_GET_MEM_CTX(ndr
);
12908 NDR_PULL_SET_MEM_CTX(ndr
, r
->domain
, 0);
12909 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->domain
));
12910 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->domain
));
12911 size_domain_1
= ndr_get_array_size(ndr
, &r
->domain
);
12912 length_domain_1
= ndr_get_array_length(ndr
, &r
->domain
);
12913 if (length_domain_1
> size_domain_1
) {
12914 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", size_domain_1
, length_domain_1
);
12916 NDR_CHECK(ndr_check_string_terminator(ndr
, length_domain_1
, sizeof(uint16_t)));
12917 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->domain
, length_domain_1
, sizeof(uint16_t), CH_UTF16
));
12918 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_domain_0
, 0);
12921 NDR_CHECK(ndr_check_array_size(ndr
, (void*)&r
->addr
, r
->addr_len
));
12924 return NDR_ERR_SUCCESS
;
12927 _PUBLIC_
void ndr_print_srvsvc_NetTransportInfo3(struct ndr_print
*ndr
, const char *name
, const struct srvsvc_NetTransportInfo3
*r
)
12929 ndr_print_struct(ndr
, name
, "srvsvc_NetTransportInfo3");
12931 ndr_print_uint32(ndr
, "vcs", r
->vcs
);
12932 ndr_print_ptr(ndr
, "name", r
->name
);
12935 ndr_print_string(ndr
, "name", r
->name
);
12938 ndr_print_ptr(ndr
, "addr", r
->addr
);
12941 ndr_print_array_uint8(ndr
, "addr", r
->addr
, r
->addr_len
);
12944 ndr_print_uint32(ndr
, "addr_len", r
->addr_len
);
12945 ndr_print_ptr(ndr
, "net_addr", r
->net_addr
);
12948 ndr_print_string(ndr
, "net_addr", r
->net_addr
);
12951 ndr_print_ptr(ndr
, "domain", r
->domain
);
12954 ndr_print_string(ndr
, "domain", r
->domain
);
12957 ndr_print_uint32(ndr
, "unknown1", r
->unknown1
);
12958 ndr_print_uint32(ndr
, "unknown2", r
->unknown2
);
12959 ndr_print_array_uint8(ndr
, "unknown3", r
->unknown3
, 256);
12963 static enum ndr_err_code
ndr_push_srvsvc_NetTransportCtr3(struct ndr_push
*ndr
, int ndr_flags
, const struct srvsvc_NetTransportCtr3
*r
)
12965 uint32_t cntr_array_1
;
12966 if (ndr_flags
& NDR_SCALARS
) {
12967 NDR_CHECK(ndr_push_align(ndr
, 4));
12968 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->count
));
12969 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->array
));
12971 if (ndr_flags
& NDR_BUFFERS
) {
12973 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->count
));
12974 for (cntr_array_1
= 0; cntr_array_1
< r
->count
; cntr_array_1
++) {
12975 NDR_CHECK(ndr_push_srvsvc_NetTransportInfo3(ndr
, NDR_SCALARS
, &r
->array
[cntr_array_1
]));
12977 for (cntr_array_1
= 0; cntr_array_1
< r
->count
; cntr_array_1
++) {
12978 NDR_CHECK(ndr_push_srvsvc_NetTransportInfo3(ndr
, NDR_BUFFERS
, &r
->array
[cntr_array_1
]));
12982 return NDR_ERR_SUCCESS
;
12985 static enum ndr_err_code
ndr_pull_srvsvc_NetTransportCtr3(struct ndr_pull
*ndr
, int ndr_flags
, struct srvsvc_NetTransportCtr3
*r
)
12987 uint32_t _ptr_array
;
12988 uint32_t size_array_1
= 0;
12989 uint32_t cntr_array_1
;
12990 TALLOC_CTX
*_mem_save_array_0
;
12991 TALLOC_CTX
*_mem_save_array_1
;
12992 if (ndr_flags
& NDR_SCALARS
) {
12993 NDR_CHECK(ndr_pull_align(ndr
, 4));
12994 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->count
));
12995 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_array
));
12997 NDR_PULL_ALLOC(ndr
, r
->array
);
13002 if (ndr_flags
& NDR_BUFFERS
) {
13004 _mem_save_array_0
= NDR_PULL_GET_MEM_CTX(ndr
);
13005 NDR_PULL_SET_MEM_CTX(ndr
, r
->array
, 0);
13006 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->array
));
13007 size_array_1
= ndr_get_array_size(ndr
, &r
->array
);
13008 NDR_PULL_ALLOC_N(ndr
, r
->array
, size_array_1
);
13009 _mem_save_array_1
= NDR_PULL_GET_MEM_CTX(ndr
);
13010 NDR_PULL_SET_MEM_CTX(ndr
, r
->array
, 0);
13011 for (cntr_array_1
= 0; cntr_array_1
< size_array_1
; cntr_array_1
++) {
13012 NDR_CHECK(ndr_pull_srvsvc_NetTransportInfo3(ndr
, NDR_SCALARS
, &r
->array
[cntr_array_1
]));
13014 for (cntr_array_1
= 0; cntr_array_1
< size_array_1
; cntr_array_1
++) {
13015 NDR_CHECK(ndr_pull_srvsvc_NetTransportInfo3(ndr
, NDR_BUFFERS
, &r
->array
[cntr_array_1
]));
13017 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_array_1
, 0);
13018 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_array_0
, 0);
13021 NDR_CHECK(ndr_check_array_size(ndr
, (void*)&r
->array
, r
->count
));
13024 return NDR_ERR_SUCCESS
;
13027 _PUBLIC_
void ndr_print_srvsvc_NetTransportCtr3(struct ndr_print
*ndr
, const char *name
, const struct srvsvc_NetTransportCtr3
*r
)
13029 uint32_t cntr_array_1
;
13030 ndr_print_struct(ndr
, name
, "srvsvc_NetTransportCtr3");
13032 ndr_print_uint32(ndr
, "count", r
->count
);
13033 ndr_print_ptr(ndr
, "array", r
->array
);
13036 ndr
->print(ndr
, "%s: ARRAY(%d)", "array", (int)r
->count
);
13038 for (cntr_array_1
=0;cntr_array_1
<r
->count
;cntr_array_1
++) {
13040 if (asprintf(&idx_1
, "[%d]", cntr_array_1
) != -1) {
13041 ndr_print_srvsvc_NetTransportInfo3(ndr
, "array", &r
->array
[cntr_array_1
]);
13051 static enum ndr_err_code
ndr_push_srvsvc_NetTransportCtr(struct ndr_push
*ndr
, int ndr_flags
, const union srvsvc_NetTransportCtr
*r
)
13053 if (ndr_flags
& NDR_SCALARS
) {
13054 int level
= ndr_push_get_switch_value(ndr
, r
);
13055 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, level
));
13058 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->ctr0
));
13062 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->ctr1
));
13066 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->ctr2
));
13070 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->ctr3
));
13078 if (ndr_flags
& NDR_BUFFERS
) {
13079 int level
= ndr_push_get_switch_value(ndr
, r
);
13083 NDR_CHECK(ndr_push_srvsvc_NetTransportCtr0(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->ctr0
));
13089 NDR_CHECK(ndr_push_srvsvc_NetTransportCtr1(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->ctr1
));
13095 NDR_CHECK(ndr_push_srvsvc_NetTransportCtr2(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->ctr2
));
13101 NDR_CHECK(ndr_push_srvsvc_NetTransportCtr3(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->ctr3
));
13110 return NDR_ERR_SUCCESS
;
13113 static enum ndr_err_code
ndr_pull_srvsvc_NetTransportCtr(struct ndr_pull
*ndr
, int ndr_flags
, union srvsvc_NetTransportCtr
*r
)
13117 TALLOC_CTX
*_mem_save_ctr0_0
;
13118 uint32_t _ptr_ctr0
;
13119 TALLOC_CTX
*_mem_save_ctr1_0
;
13120 uint32_t _ptr_ctr1
;
13121 TALLOC_CTX
*_mem_save_ctr2_0
;
13122 uint32_t _ptr_ctr2
;
13123 TALLOC_CTX
*_mem_save_ctr3_0
;
13124 uint32_t _ptr_ctr3
;
13125 level
= ndr_pull_get_switch_value(ndr
, r
);
13126 if (ndr_flags
& NDR_SCALARS
) {
13127 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &_level
));
13128 if (_level
!= level
) {
13129 return ndr_pull_error(ndr
, NDR_ERR_BAD_SWITCH
, "Bad switch value %u for r", _level
);
13133 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_ctr0
));
13135 NDR_PULL_ALLOC(ndr
, r
->ctr0
);
13142 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_ctr1
));
13144 NDR_PULL_ALLOC(ndr
, r
->ctr1
);
13151 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_ctr2
));
13153 NDR_PULL_ALLOC(ndr
, r
->ctr2
);
13160 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_ctr3
));
13162 NDR_PULL_ALLOC(ndr
, r
->ctr3
);
13173 if (ndr_flags
& NDR_BUFFERS
) {
13177 _mem_save_ctr0_0
= NDR_PULL_GET_MEM_CTX(ndr
);
13178 NDR_PULL_SET_MEM_CTX(ndr
, r
->ctr0
, 0);
13179 NDR_CHECK(ndr_pull_srvsvc_NetTransportCtr0(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->ctr0
));
13180 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_ctr0_0
, 0);
13186 _mem_save_ctr1_0
= NDR_PULL_GET_MEM_CTX(ndr
);
13187 NDR_PULL_SET_MEM_CTX(ndr
, r
->ctr1
, 0);
13188 NDR_CHECK(ndr_pull_srvsvc_NetTransportCtr1(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->ctr1
));
13189 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_ctr1_0
, 0);
13195 _mem_save_ctr2_0
= NDR_PULL_GET_MEM_CTX(ndr
);
13196 NDR_PULL_SET_MEM_CTX(ndr
, r
->ctr2
, 0);
13197 NDR_CHECK(ndr_pull_srvsvc_NetTransportCtr2(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->ctr2
));
13198 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_ctr2_0
, 0);
13204 _mem_save_ctr3_0
= NDR_PULL_GET_MEM_CTX(ndr
);
13205 NDR_PULL_SET_MEM_CTX(ndr
, r
->ctr3
, 0);
13206 NDR_CHECK(ndr_pull_srvsvc_NetTransportCtr3(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->ctr3
));
13207 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_ctr3_0
, 0);
13216 return NDR_ERR_SUCCESS
;
13219 _PUBLIC_
void ndr_print_srvsvc_NetTransportCtr(struct ndr_print
*ndr
, const char *name
, const union srvsvc_NetTransportCtr
*r
)
13222 level
= ndr_print_get_switch_value(ndr
, r
);
13223 ndr_print_union(ndr
, name
, level
, "srvsvc_NetTransportCtr");
13226 ndr_print_ptr(ndr
, "ctr0", r
->ctr0
);
13229 ndr_print_srvsvc_NetTransportCtr0(ndr
, "ctr0", r
->ctr0
);
13235 ndr_print_ptr(ndr
, "ctr1", r
->ctr1
);
13238 ndr_print_srvsvc_NetTransportCtr1(ndr
, "ctr1", r
->ctr1
);
13244 ndr_print_ptr(ndr
, "ctr2", r
->ctr2
);
13247 ndr_print_srvsvc_NetTransportCtr2(ndr
, "ctr2", r
->ctr2
);
13253 ndr_print_ptr(ndr
, "ctr3", r
->ctr3
);
13256 ndr_print_srvsvc_NetTransportCtr3(ndr
, "ctr3", r
->ctr3
);
13267 static enum ndr_err_code
ndr_push_srvsvc_NetTransportInfoCtr(struct ndr_push
*ndr
, int ndr_flags
, const struct srvsvc_NetTransportInfoCtr
*r
)
13269 if (ndr_flags
& NDR_SCALARS
) {
13270 NDR_CHECK(ndr_push_align(ndr
, 4));
13271 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->level
));
13272 NDR_CHECK(ndr_push_set_switch_value(ndr
, &r
->ctr
, r
->level
));
13273 NDR_CHECK(ndr_push_srvsvc_NetTransportCtr(ndr
, NDR_SCALARS
, &r
->ctr
));
13275 if (ndr_flags
& NDR_BUFFERS
) {
13276 NDR_CHECK(ndr_push_srvsvc_NetTransportCtr(ndr
, NDR_BUFFERS
, &r
->ctr
));
13278 return NDR_ERR_SUCCESS
;
13281 static enum ndr_err_code
ndr_pull_srvsvc_NetTransportInfoCtr(struct ndr_pull
*ndr
, int ndr_flags
, struct srvsvc_NetTransportInfoCtr
*r
)
13283 if (ndr_flags
& NDR_SCALARS
) {
13284 NDR_CHECK(ndr_pull_align(ndr
, 4));
13285 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->level
));
13286 NDR_CHECK(ndr_pull_set_switch_value(ndr
, &r
->ctr
, r
->level
));
13287 NDR_CHECK(ndr_pull_srvsvc_NetTransportCtr(ndr
, NDR_SCALARS
, &r
->ctr
));
13289 if (ndr_flags
& NDR_BUFFERS
) {
13290 NDR_CHECK(ndr_pull_srvsvc_NetTransportCtr(ndr
, NDR_BUFFERS
, &r
->ctr
));
13292 return NDR_ERR_SUCCESS
;
13295 _PUBLIC_
void ndr_print_srvsvc_NetTransportInfoCtr(struct ndr_print
*ndr
, const char *name
, const struct srvsvc_NetTransportInfoCtr
*r
)
13297 ndr_print_struct(ndr
, name
, "srvsvc_NetTransportInfoCtr");
13299 ndr_print_uint32(ndr
, "level", r
->level
);
13300 ndr_print_set_switch_value(ndr
, &r
->ctr
, r
->level
);
13301 ndr_print_srvsvc_NetTransportCtr(ndr
, "ctr", &r
->ctr
);
13305 static enum ndr_err_code
ndr_push_srvsvc_NetRemoteTODInfo(struct ndr_push
*ndr
, int ndr_flags
, const struct srvsvc_NetRemoteTODInfo
*r
)
13307 if (ndr_flags
& NDR_SCALARS
) {
13308 NDR_CHECK(ndr_push_align(ndr
, 4));
13309 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->elapsed
));
13310 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->msecs
));
13311 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->hours
));
13312 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->mins
));
13313 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->secs
));
13314 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->hunds
));
13315 NDR_CHECK(ndr_push_int32(ndr
, NDR_SCALARS
, r
->timezone
));
13316 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->tinterval
));
13317 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->day
));
13318 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->month
));
13319 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->year
));
13320 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->weekday
));
13322 if (ndr_flags
& NDR_BUFFERS
) {
13324 return NDR_ERR_SUCCESS
;
13327 static enum ndr_err_code
ndr_pull_srvsvc_NetRemoteTODInfo(struct ndr_pull
*ndr
, int ndr_flags
, struct srvsvc_NetRemoteTODInfo
*r
)
13329 if (ndr_flags
& NDR_SCALARS
) {
13330 NDR_CHECK(ndr_pull_align(ndr
, 4));
13331 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->elapsed
));
13332 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->msecs
));
13333 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->hours
));
13334 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->mins
));
13335 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->secs
));
13336 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->hunds
));
13337 NDR_CHECK(ndr_pull_int32(ndr
, NDR_SCALARS
, &r
->timezone
));
13338 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->tinterval
));
13339 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->day
));
13340 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->month
));
13341 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->year
));
13342 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->weekday
));
13344 if (ndr_flags
& NDR_BUFFERS
) {
13346 return NDR_ERR_SUCCESS
;
13349 _PUBLIC_
void ndr_print_srvsvc_NetRemoteTODInfo(struct ndr_print
*ndr
, const char *name
, const struct srvsvc_NetRemoteTODInfo
*r
)
13351 ndr_print_struct(ndr
, name
, "srvsvc_NetRemoteTODInfo");
13353 ndr_print_uint32(ndr
, "elapsed", r
->elapsed
);
13354 ndr_print_uint32(ndr
, "msecs", r
->msecs
);
13355 ndr_print_uint32(ndr
, "hours", r
->hours
);
13356 ndr_print_uint32(ndr
, "mins", r
->mins
);
13357 ndr_print_uint32(ndr
, "secs", r
->secs
);
13358 ndr_print_uint32(ndr
, "hunds", r
->hunds
);
13359 ndr_print_int32(ndr
, "timezone", r
->timezone
);
13360 ndr_print_uint32(ndr
, "tinterval", r
->tinterval
);
13361 ndr_print_uint32(ndr
, "day", r
->day
);
13362 ndr_print_uint32(ndr
, "month", r
->month
);
13363 ndr_print_uint32(ndr
, "year", r
->year
);
13364 ndr_print_uint32(ndr
, "weekday", r
->weekday
);
13368 static enum ndr_err_code
ndr_push_srvsvc_NetTransportInfo(struct ndr_push
*ndr
, int ndr_flags
, const union srvsvc_NetTransportInfo
*r
)
13370 if (ndr_flags
& NDR_SCALARS
) {
13371 int level
= ndr_push_get_switch_value(ndr
, r
);
13372 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, level
));
13375 NDR_CHECK(ndr_push_srvsvc_NetTransportInfo0(ndr
, NDR_SCALARS
, &r
->info0
));
13379 NDR_CHECK(ndr_push_srvsvc_NetTransportInfo1(ndr
, NDR_SCALARS
, &r
->info1
));
13383 NDR_CHECK(ndr_push_srvsvc_NetTransportInfo2(ndr
, NDR_SCALARS
, &r
->info2
));
13387 NDR_CHECK(ndr_push_srvsvc_NetTransportInfo3(ndr
, NDR_SCALARS
, &r
->info3
));
13391 return ndr_push_error(ndr
, NDR_ERR_BAD_SWITCH
, "Bad switch value %u", level
);
13394 if (ndr_flags
& NDR_BUFFERS
) {
13395 int level
= ndr_push_get_switch_value(ndr
, r
);
13398 NDR_CHECK(ndr_push_srvsvc_NetTransportInfo0(ndr
, NDR_BUFFERS
, &r
->info0
));
13402 NDR_CHECK(ndr_push_srvsvc_NetTransportInfo1(ndr
, NDR_BUFFERS
, &r
->info1
));
13406 NDR_CHECK(ndr_push_srvsvc_NetTransportInfo2(ndr
, NDR_BUFFERS
, &r
->info2
));
13410 NDR_CHECK(ndr_push_srvsvc_NetTransportInfo3(ndr
, NDR_BUFFERS
, &r
->info3
));
13414 return ndr_push_error(ndr
, NDR_ERR_BAD_SWITCH
, "Bad switch value %u", level
);
13417 return NDR_ERR_SUCCESS
;
13420 static enum ndr_err_code
ndr_pull_srvsvc_NetTransportInfo(struct ndr_pull
*ndr
, int ndr_flags
, union srvsvc_NetTransportInfo
*r
)
13424 level
= ndr_pull_get_switch_value(ndr
, r
);
13425 if (ndr_flags
& NDR_SCALARS
) {
13426 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &_level
));
13427 if (_level
!= level
) {
13428 return ndr_pull_error(ndr
, NDR_ERR_BAD_SWITCH
, "Bad switch value %u for r", _level
);
13432 NDR_CHECK(ndr_pull_srvsvc_NetTransportInfo0(ndr
, NDR_SCALARS
, &r
->info0
));
13436 NDR_CHECK(ndr_pull_srvsvc_NetTransportInfo1(ndr
, NDR_SCALARS
, &r
->info1
));
13440 NDR_CHECK(ndr_pull_srvsvc_NetTransportInfo2(ndr
, NDR_SCALARS
, &r
->info2
));
13444 NDR_CHECK(ndr_pull_srvsvc_NetTransportInfo3(ndr
, NDR_SCALARS
, &r
->info3
));
13448 return ndr_pull_error(ndr
, NDR_ERR_BAD_SWITCH
, "Bad switch value %u", level
);
13451 if (ndr_flags
& NDR_BUFFERS
) {
13454 NDR_CHECK(ndr_pull_srvsvc_NetTransportInfo0(ndr
, NDR_BUFFERS
, &r
->info0
));
13458 NDR_CHECK(ndr_pull_srvsvc_NetTransportInfo1(ndr
, NDR_BUFFERS
, &r
->info1
));
13462 NDR_CHECK(ndr_pull_srvsvc_NetTransportInfo2(ndr
, NDR_BUFFERS
, &r
->info2
));
13466 NDR_CHECK(ndr_pull_srvsvc_NetTransportInfo3(ndr
, NDR_BUFFERS
, &r
->info3
));
13470 return ndr_pull_error(ndr
, NDR_ERR_BAD_SWITCH
, "Bad switch value %u", level
);
13473 return NDR_ERR_SUCCESS
;
13476 _PUBLIC_
void ndr_print_srvsvc_NetTransportInfo(struct ndr_print
*ndr
, const char *name
, const union srvsvc_NetTransportInfo
*r
)
13479 level
= ndr_print_get_switch_value(ndr
, r
);
13480 ndr_print_union(ndr
, name
, level
, "srvsvc_NetTransportInfo");
13483 ndr_print_srvsvc_NetTransportInfo0(ndr
, "info0", &r
->info0
);
13487 ndr_print_srvsvc_NetTransportInfo1(ndr
, "info1", &r
->info1
);
13491 ndr_print_srvsvc_NetTransportInfo2(ndr
, "info2", &r
->info2
);
13495 ndr_print_srvsvc_NetTransportInfo3(ndr
, "info3", &r
->info3
);
13499 ndr_print_bad_level(ndr
, name
, level
);
13503 static enum ndr_err_code
ndr_push_srvsvc_NetCharDevEnum(struct ndr_push
*ndr
, int flags
, const struct srvsvc_NetCharDevEnum
*r
)
13505 if (flags
& NDR_IN
) {
13506 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->in
.server_unc
));
13507 if (r
->in
.server_unc
) {
13508 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.server_unc
, CH_UTF16
)));
13509 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
13510 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.server_unc
, CH_UTF16
)));
13511 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
));
13513 if (r
->in
.info_ctr
== NULL
) {
13514 return ndr_push_error(ndr
, NDR_ERR_INVALID_POINTER
, "NULL [ref] pointer");
13516 NDR_CHECK(ndr_push_srvsvc_NetCharDevInfoCtr(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->in
.info_ctr
));
13517 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->in
.max_buffer
));
13518 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->in
.resume_handle
));
13519 if (r
->in
.resume_handle
) {
13520 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, *r
->in
.resume_handle
));
13523 if (flags
& NDR_OUT
) {
13524 if (r
->out
.info_ctr
== NULL
) {
13525 return ndr_push_error(ndr
, NDR_ERR_INVALID_POINTER
, "NULL [ref] pointer");
13527 NDR_CHECK(ndr_push_srvsvc_NetCharDevInfoCtr(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->out
.info_ctr
));
13528 if (r
->out
.totalentries
== NULL
) {
13529 return ndr_push_error(ndr
, NDR_ERR_INVALID_POINTER
, "NULL [ref] pointer");
13531 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, *r
->out
.totalentries
));
13532 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->out
.resume_handle
));
13533 if (r
->out
.resume_handle
) {
13534 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, *r
->out
.resume_handle
));
13536 NDR_CHECK(ndr_push_WERROR(ndr
, NDR_SCALARS
, r
->out
.result
));
13538 return NDR_ERR_SUCCESS
;
13541 static enum ndr_err_code
ndr_pull_srvsvc_NetCharDevEnum(struct ndr_pull
*ndr
, int flags
, struct srvsvc_NetCharDevEnum
*r
)
13543 uint32_t _ptr_server_unc
;
13544 uint32_t size_server_unc_1
= 0;
13545 uint32_t length_server_unc_1
= 0;
13546 uint32_t _ptr_resume_handle
;
13547 TALLOC_CTX
*_mem_save_server_unc_0
;
13548 TALLOC_CTX
*_mem_save_info_ctr_0
;
13549 TALLOC_CTX
*_mem_save_totalentries_0
;
13550 TALLOC_CTX
*_mem_save_resume_handle_0
;
13551 if (flags
& NDR_IN
) {
13552 ZERO_STRUCT(r
->out
);
13554 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_server_unc
));
13555 if (_ptr_server_unc
) {
13556 NDR_PULL_ALLOC(ndr
, r
->in
.server_unc
);
13558 r
->in
.server_unc
= NULL
;
13560 if (r
->in
.server_unc
) {
13561 _mem_save_server_unc_0
= NDR_PULL_GET_MEM_CTX(ndr
);
13562 NDR_PULL_SET_MEM_CTX(ndr
, r
->in
.server_unc
, 0);
13563 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->in
.server_unc
));
13564 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->in
.server_unc
));
13565 size_server_unc_1
= ndr_get_array_size(ndr
, &r
->in
.server_unc
);
13566 length_server_unc_1
= ndr_get_array_length(ndr
, &r
->in
.server_unc
);
13567 if (length_server_unc_1
> size_server_unc_1
) {
13568 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", size_server_unc_1
, length_server_unc_1
);
13570 NDR_CHECK(ndr_check_string_terminator(ndr
, length_server_unc_1
, sizeof(uint16_t)));
13571 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->in
.server_unc
, length_server_unc_1
, sizeof(uint16_t), CH_UTF16
));
13572 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_server_unc_0
, 0);
13574 if (ndr
->flags
& LIBNDR_FLAG_REF_ALLOC
) {
13575 NDR_PULL_ALLOC(ndr
, r
->in
.info_ctr
);
13577 _mem_save_info_ctr_0
= NDR_PULL_GET_MEM_CTX(ndr
);
13578 NDR_PULL_SET_MEM_CTX(ndr
, r
->in
.info_ctr
, LIBNDR_FLAG_REF_ALLOC
);
13579 NDR_CHECK(ndr_pull_srvsvc_NetCharDevInfoCtr(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->in
.info_ctr
));
13580 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_info_ctr_0
, LIBNDR_FLAG_REF_ALLOC
);
13581 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->in
.max_buffer
));
13582 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_resume_handle
));
13583 if (_ptr_resume_handle
) {
13584 NDR_PULL_ALLOC(ndr
, r
->in
.resume_handle
);
13586 r
->in
.resume_handle
= NULL
;
13588 if (r
->in
.resume_handle
) {
13589 _mem_save_resume_handle_0
= NDR_PULL_GET_MEM_CTX(ndr
);
13590 NDR_PULL_SET_MEM_CTX(ndr
, r
->in
.resume_handle
, 0);
13591 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, r
->in
.resume_handle
));
13592 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_resume_handle_0
, 0);
13594 NDR_PULL_ALLOC(ndr
, r
->out
.info_ctr
);
13595 *r
->out
.info_ctr
= *r
->in
.info_ctr
;
13596 NDR_PULL_ALLOC(ndr
, r
->out
.totalentries
);
13597 ZERO_STRUCTP(r
->out
.totalentries
);
13599 if (flags
& NDR_OUT
) {
13600 if (ndr
->flags
& LIBNDR_FLAG_REF_ALLOC
) {
13601 NDR_PULL_ALLOC(ndr
, r
->out
.info_ctr
);
13603 _mem_save_info_ctr_0
= NDR_PULL_GET_MEM_CTX(ndr
);
13604 NDR_PULL_SET_MEM_CTX(ndr
, r
->out
.info_ctr
, LIBNDR_FLAG_REF_ALLOC
);
13605 NDR_CHECK(ndr_pull_srvsvc_NetCharDevInfoCtr(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->out
.info_ctr
));
13606 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_info_ctr_0
, LIBNDR_FLAG_REF_ALLOC
);
13607 if (ndr
->flags
& LIBNDR_FLAG_REF_ALLOC
) {
13608 NDR_PULL_ALLOC(ndr
, r
->out
.totalentries
);
13610 _mem_save_totalentries_0
= NDR_PULL_GET_MEM_CTX(ndr
);
13611 NDR_PULL_SET_MEM_CTX(ndr
, r
->out
.totalentries
, LIBNDR_FLAG_REF_ALLOC
);
13612 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, r
->out
.totalentries
));
13613 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_totalentries_0
, LIBNDR_FLAG_REF_ALLOC
);
13614 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_resume_handle
));
13615 if (_ptr_resume_handle
) {
13616 NDR_PULL_ALLOC(ndr
, r
->out
.resume_handle
);
13618 r
->out
.resume_handle
= NULL
;
13620 if (r
->out
.resume_handle
) {
13621 _mem_save_resume_handle_0
= NDR_PULL_GET_MEM_CTX(ndr
);
13622 NDR_PULL_SET_MEM_CTX(ndr
, r
->out
.resume_handle
, 0);
13623 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, r
->out
.resume_handle
));
13624 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_resume_handle_0
, 0);
13626 NDR_CHECK(ndr_pull_WERROR(ndr
, NDR_SCALARS
, &r
->out
.result
));
13628 return NDR_ERR_SUCCESS
;
13631 _PUBLIC_
void ndr_print_srvsvc_NetCharDevEnum(struct ndr_print
*ndr
, const char *name
, int flags
, const struct srvsvc_NetCharDevEnum
*r
)
13633 ndr_print_struct(ndr
, name
, "srvsvc_NetCharDevEnum");
13635 if (flags
& NDR_SET_VALUES
) {
13636 ndr
->flags
|= LIBNDR_PRINT_SET_VALUES
;
13638 if (flags
& NDR_IN
) {
13639 ndr_print_struct(ndr
, "in", "srvsvc_NetCharDevEnum");
13641 ndr_print_ptr(ndr
, "server_unc", r
->in
.server_unc
);
13643 if (r
->in
.server_unc
) {
13644 ndr_print_string(ndr
, "server_unc", r
->in
.server_unc
);
13647 ndr_print_ptr(ndr
, "info_ctr", r
->in
.info_ctr
);
13649 ndr_print_srvsvc_NetCharDevInfoCtr(ndr
, "info_ctr", r
->in
.info_ctr
);
13651 ndr_print_uint32(ndr
, "max_buffer", r
->in
.max_buffer
);
13652 ndr_print_ptr(ndr
, "resume_handle", r
->in
.resume_handle
);
13654 if (r
->in
.resume_handle
) {
13655 ndr_print_uint32(ndr
, "resume_handle", *r
->in
.resume_handle
);
13660 if (flags
& NDR_OUT
) {
13661 ndr_print_struct(ndr
, "out", "srvsvc_NetCharDevEnum");
13663 ndr_print_ptr(ndr
, "info_ctr", r
->out
.info_ctr
);
13665 ndr_print_srvsvc_NetCharDevInfoCtr(ndr
, "info_ctr", r
->out
.info_ctr
);
13667 ndr_print_ptr(ndr
, "totalentries", r
->out
.totalentries
);
13669 ndr_print_uint32(ndr
, "totalentries", *r
->out
.totalentries
);
13671 ndr_print_ptr(ndr
, "resume_handle", r
->out
.resume_handle
);
13673 if (r
->out
.resume_handle
) {
13674 ndr_print_uint32(ndr
, "resume_handle", *r
->out
.resume_handle
);
13677 ndr_print_WERROR(ndr
, "result", r
->out
.result
);
13683 static enum ndr_err_code
ndr_push_srvsvc_NetCharDevGetInfo(struct ndr_push
*ndr
, int flags
, const struct srvsvc_NetCharDevGetInfo
*r
)
13685 if (flags
& NDR_IN
) {
13686 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->in
.server_unc
));
13687 if (r
->in
.server_unc
) {
13688 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.server_unc
, CH_UTF16
)));
13689 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
13690 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.server_unc
, CH_UTF16
)));
13691 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
));
13693 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.device_name
, CH_UTF16
)));
13694 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
13695 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.device_name
, CH_UTF16
)));
13696 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
));
13697 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->in
.level
));
13699 if (flags
& NDR_OUT
) {
13700 if (r
->out
.info
== NULL
) {
13701 return ndr_push_error(ndr
, NDR_ERR_INVALID_POINTER
, "NULL [ref] pointer");
13703 NDR_CHECK(ndr_push_set_switch_value(ndr
, r
->out
.info
, r
->in
.level
));
13704 NDR_CHECK(ndr_push_srvsvc_NetCharDevInfo(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->out
.info
));
13705 NDR_CHECK(ndr_push_WERROR(ndr
, NDR_SCALARS
, r
->out
.result
));
13707 return NDR_ERR_SUCCESS
;
13710 static enum ndr_err_code
ndr_pull_srvsvc_NetCharDevGetInfo(struct ndr_pull
*ndr
, int flags
, struct srvsvc_NetCharDevGetInfo
*r
)
13712 uint32_t _ptr_server_unc
;
13713 uint32_t size_server_unc_1
= 0;
13714 uint32_t length_server_unc_1
= 0;
13715 uint32_t size_device_name_0
= 0;
13716 uint32_t length_device_name_0
= 0;
13717 TALLOC_CTX
*_mem_save_server_unc_0
;
13718 TALLOC_CTX
*_mem_save_info_0
;
13719 if (flags
& NDR_IN
) {
13720 ZERO_STRUCT(r
->out
);
13722 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_server_unc
));
13723 if (_ptr_server_unc
) {
13724 NDR_PULL_ALLOC(ndr
, r
->in
.server_unc
);
13726 r
->in
.server_unc
= NULL
;
13728 if (r
->in
.server_unc
) {
13729 _mem_save_server_unc_0
= NDR_PULL_GET_MEM_CTX(ndr
);
13730 NDR_PULL_SET_MEM_CTX(ndr
, r
->in
.server_unc
, 0);
13731 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->in
.server_unc
));
13732 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->in
.server_unc
));
13733 size_server_unc_1
= ndr_get_array_size(ndr
, &r
->in
.server_unc
);
13734 length_server_unc_1
= ndr_get_array_length(ndr
, &r
->in
.server_unc
);
13735 if (length_server_unc_1
> size_server_unc_1
) {
13736 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", size_server_unc_1
, length_server_unc_1
);
13738 NDR_CHECK(ndr_check_string_terminator(ndr
, length_server_unc_1
, sizeof(uint16_t)));
13739 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->in
.server_unc
, length_server_unc_1
, sizeof(uint16_t), CH_UTF16
));
13740 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_server_unc_0
, 0);
13742 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->in
.device_name
));
13743 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->in
.device_name
));
13744 size_device_name_0
= ndr_get_array_size(ndr
, &r
->in
.device_name
);
13745 length_device_name_0
= ndr_get_array_length(ndr
, &r
->in
.device_name
);
13746 if (length_device_name_0
> size_device_name_0
) {
13747 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", size_device_name_0
, length_device_name_0
);
13749 NDR_CHECK(ndr_check_string_terminator(ndr
, length_device_name_0
, sizeof(uint16_t)));
13750 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->in
.device_name
, length_device_name_0
, sizeof(uint16_t), CH_UTF16
));
13751 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->in
.level
));
13752 NDR_PULL_ALLOC(ndr
, r
->out
.info
);
13753 ZERO_STRUCTP(r
->out
.info
);
13755 if (flags
& NDR_OUT
) {
13756 if (ndr
->flags
& LIBNDR_FLAG_REF_ALLOC
) {
13757 NDR_PULL_ALLOC(ndr
, r
->out
.info
);
13759 _mem_save_info_0
= NDR_PULL_GET_MEM_CTX(ndr
);
13760 NDR_PULL_SET_MEM_CTX(ndr
, r
->out
.info
, LIBNDR_FLAG_REF_ALLOC
);
13761 NDR_CHECK(ndr_pull_set_switch_value(ndr
, r
->out
.info
, r
->in
.level
));
13762 NDR_CHECK(ndr_pull_srvsvc_NetCharDevInfo(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->out
.info
));
13763 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_info_0
, LIBNDR_FLAG_REF_ALLOC
);
13764 NDR_CHECK(ndr_pull_WERROR(ndr
, NDR_SCALARS
, &r
->out
.result
));
13766 return NDR_ERR_SUCCESS
;
13769 _PUBLIC_
void ndr_print_srvsvc_NetCharDevGetInfo(struct ndr_print
*ndr
, const char *name
, int flags
, const struct srvsvc_NetCharDevGetInfo
*r
)
13771 ndr_print_struct(ndr
, name
, "srvsvc_NetCharDevGetInfo");
13773 if (flags
& NDR_SET_VALUES
) {
13774 ndr
->flags
|= LIBNDR_PRINT_SET_VALUES
;
13776 if (flags
& NDR_IN
) {
13777 ndr_print_struct(ndr
, "in", "srvsvc_NetCharDevGetInfo");
13779 ndr_print_ptr(ndr
, "server_unc", r
->in
.server_unc
);
13781 if (r
->in
.server_unc
) {
13782 ndr_print_string(ndr
, "server_unc", r
->in
.server_unc
);
13785 ndr_print_string(ndr
, "device_name", r
->in
.device_name
);
13786 ndr_print_uint32(ndr
, "level", r
->in
.level
);
13789 if (flags
& NDR_OUT
) {
13790 ndr_print_struct(ndr
, "out", "srvsvc_NetCharDevGetInfo");
13792 ndr_print_ptr(ndr
, "info", r
->out
.info
);
13794 ndr_print_set_switch_value(ndr
, r
->out
.info
, r
->in
.level
);
13795 ndr_print_srvsvc_NetCharDevInfo(ndr
, "info", r
->out
.info
);
13797 ndr_print_WERROR(ndr
, "result", r
->out
.result
);
13803 static enum ndr_err_code
ndr_push_srvsvc_NetCharDevControl(struct ndr_push
*ndr
, int flags
, const struct srvsvc_NetCharDevControl
*r
)
13805 if (flags
& NDR_IN
) {
13806 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->in
.server_unc
));
13807 if (r
->in
.server_unc
) {
13808 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.server_unc
, CH_UTF16
)));
13809 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
13810 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.server_unc
, CH_UTF16
)));
13811 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
));
13813 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.device_name
, CH_UTF16
)));
13814 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
13815 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.device_name
, CH_UTF16
)));
13816 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
));
13817 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->in
.opcode
));
13819 if (flags
& NDR_OUT
) {
13820 NDR_CHECK(ndr_push_WERROR(ndr
, NDR_SCALARS
, r
->out
.result
));
13822 return NDR_ERR_SUCCESS
;
13825 static enum ndr_err_code
ndr_pull_srvsvc_NetCharDevControl(struct ndr_pull
*ndr
, int flags
, struct srvsvc_NetCharDevControl
*r
)
13827 uint32_t _ptr_server_unc
;
13828 uint32_t size_server_unc_1
= 0;
13829 uint32_t length_server_unc_1
= 0;
13830 uint32_t size_device_name_0
= 0;
13831 uint32_t length_device_name_0
= 0;
13832 TALLOC_CTX
*_mem_save_server_unc_0
;
13833 if (flags
& NDR_IN
) {
13834 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_server_unc
));
13835 if (_ptr_server_unc
) {
13836 NDR_PULL_ALLOC(ndr
, r
->in
.server_unc
);
13838 r
->in
.server_unc
= NULL
;
13840 if (r
->in
.server_unc
) {
13841 _mem_save_server_unc_0
= NDR_PULL_GET_MEM_CTX(ndr
);
13842 NDR_PULL_SET_MEM_CTX(ndr
, r
->in
.server_unc
, 0);
13843 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->in
.server_unc
));
13844 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->in
.server_unc
));
13845 size_server_unc_1
= ndr_get_array_size(ndr
, &r
->in
.server_unc
);
13846 length_server_unc_1
= ndr_get_array_length(ndr
, &r
->in
.server_unc
);
13847 if (length_server_unc_1
> size_server_unc_1
) {
13848 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", size_server_unc_1
, length_server_unc_1
);
13850 NDR_CHECK(ndr_check_string_terminator(ndr
, length_server_unc_1
, sizeof(uint16_t)));
13851 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->in
.server_unc
, length_server_unc_1
, sizeof(uint16_t), CH_UTF16
));
13852 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_server_unc_0
, 0);
13854 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->in
.device_name
));
13855 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->in
.device_name
));
13856 size_device_name_0
= ndr_get_array_size(ndr
, &r
->in
.device_name
);
13857 length_device_name_0
= ndr_get_array_length(ndr
, &r
->in
.device_name
);
13858 if (length_device_name_0
> size_device_name_0
) {
13859 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", size_device_name_0
, length_device_name_0
);
13861 NDR_CHECK(ndr_check_string_terminator(ndr
, length_device_name_0
, sizeof(uint16_t)));
13862 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->in
.device_name
, length_device_name_0
, sizeof(uint16_t), CH_UTF16
));
13863 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->in
.opcode
));
13865 if (flags
& NDR_OUT
) {
13866 NDR_CHECK(ndr_pull_WERROR(ndr
, NDR_SCALARS
, &r
->out
.result
));
13868 return NDR_ERR_SUCCESS
;
13871 _PUBLIC_
void ndr_print_srvsvc_NetCharDevControl(struct ndr_print
*ndr
, const char *name
, int flags
, const struct srvsvc_NetCharDevControl
*r
)
13873 ndr_print_struct(ndr
, name
, "srvsvc_NetCharDevControl");
13875 if (flags
& NDR_SET_VALUES
) {
13876 ndr
->flags
|= LIBNDR_PRINT_SET_VALUES
;
13878 if (flags
& NDR_IN
) {
13879 ndr_print_struct(ndr
, "in", "srvsvc_NetCharDevControl");
13881 ndr_print_ptr(ndr
, "server_unc", r
->in
.server_unc
);
13883 if (r
->in
.server_unc
) {
13884 ndr_print_string(ndr
, "server_unc", r
->in
.server_unc
);
13887 ndr_print_string(ndr
, "device_name", r
->in
.device_name
);
13888 ndr_print_uint32(ndr
, "opcode", r
->in
.opcode
);
13891 if (flags
& NDR_OUT
) {
13892 ndr_print_struct(ndr
, "out", "srvsvc_NetCharDevControl");
13894 ndr_print_WERROR(ndr
, "result", r
->out
.result
);
13900 static enum ndr_err_code
ndr_push_srvsvc_NetCharDevQEnum(struct ndr_push
*ndr
, int flags
, const struct srvsvc_NetCharDevQEnum
*r
)
13902 if (flags
& NDR_IN
) {
13903 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->in
.server_unc
));
13904 if (r
->in
.server_unc
) {
13905 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.server_unc
, CH_UTF16
)));
13906 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
13907 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.server_unc
, CH_UTF16
)));
13908 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
));
13910 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->in
.user
));
13912 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.user
, CH_UTF16
)));
13913 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
13914 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.user
, CH_UTF16
)));
13915 NDR_CHECK(ndr_push_charset(ndr
, NDR_SCALARS
, r
->in
.user
, ndr_charset_length(r
->in
.user
, CH_UTF16
), sizeof(uint16_t), CH_UTF16
));
13917 if (r
->in
.info_ctr
== NULL
) {
13918 return ndr_push_error(ndr
, NDR_ERR_INVALID_POINTER
, "NULL [ref] pointer");
13920 NDR_CHECK(ndr_push_srvsvc_NetCharDevQInfoCtr(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->in
.info_ctr
));
13921 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->in
.max_buffer
));
13922 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->in
.resume_handle
));
13923 if (r
->in
.resume_handle
) {
13924 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, *r
->in
.resume_handle
));
13927 if (flags
& NDR_OUT
) {
13928 if (r
->out
.info_ctr
== NULL
) {
13929 return ndr_push_error(ndr
, NDR_ERR_INVALID_POINTER
, "NULL [ref] pointer");
13931 NDR_CHECK(ndr_push_srvsvc_NetCharDevQInfoCtr(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->out
.info_ctr
));
13932 if (r
->out
.totalentries
== NULL
) {
13933 return ndr_push_error(ndr
, NDR_ERR_INVALID_POINTER
, "NULL [ref] pointer");
13935 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, *r
->out
.totalentries
));
13936 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->out
.resume_handle
));
13937 if (r
->out
.resume_handle
) {
13938 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, *r
->out
.resume_handle
));
13940 NDR_CHECK(ndr_push_WERROR(ndr
, NDR_SCALARS
, r
->out
.result
));
13942 return NDR_ERR_SUCCESS
;
13945 static enum ndr_err_code
ndr_pull_srvsvc_NetCharDevQEnum(struct ndr_pull
*ndr
, int flags
, struct srvsvc_NetCharDevQEnum
*r
)
13947 uint32_t _ptr_server_unc
;
13948 uint32_t size_server_unc_1
= 0;
13949 uint32_t length_server_unc_1
= 0;
13950 uint32_t _ptr_user
;
13951 uint32_t size_user_1
= 0;
13952 uint32_t length_user_1
= 0;
13953 uint32_t _ptr_resume_handle
;
13954 TALLOC_CTX
*_mem_save_server_unc_0
;
13955 TALLOC_CTX
*_mem_save_user_0
;
13956 TALLOC_CTX
*_mem_save_info_ctr_0
;
13957 TALLOC_CTX
*_mem_save_totalentries_0
;
13958 TALLOC_CTX
*_mem_save_resume_handle_0
;
13959 if (flags
& NDR_IN
) {
13960 ZERO_STRUCT(r
->out
);
13962 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_server_unc
));
13963 if (_ptr_server_unc
) {
13964 NDR_PULL_ALLOC(ndr
, r
->in
.server_unc
);
13966 r
->in
.server_unc
= NULL
;
13968 if (r
->in
.server_unc
) {
13969 _mem_save_server_unc_0
= NDR_PULL_GET_MEM_CTX(ndr
);
13970 NDR_PULL_SET_MEM_CTX(ndr
, r
->in
.server_unc
, 0);
13971 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->in
.server_unc
));
13972 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->in
.server_unc
));
13973 size_server_unc_1
= ndr_get_array_size(ndr
, &r
->in
.server_unc
);
13974 length_server_unc_1
= ndr_get_array_length(ndr
, &r
->in
.server_unc
);
13975 if (length_server_unc_1
> size_server_unc_1
) {
13976 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", size_server_unc_1
, length_server_unc_1
);
13978 NDR_CHECK(ndr_check_string_terminator(ndr
, length_server_unc_1
, sizeof(uint16_t)));
13979 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->in
.server_unc
, length_server_unc_1
, sizeof(uint16_t), CH_UTF16
));
13980 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_server_unc_0
, 0);
13982 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_user
));
13984 NDR_PULL_ALLOC(ndr
, r
->in
.user
);
13989 _mem_save_user_0
= NDR_PULL_GET_MEM_CTX(ndr
);
13990 NDR_PULL_SET_MEM_CTX(ndr
, r
->in
.user
, 0);
13991 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->in
.user
));
13992 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->in
.user
));
13993 size_user_1
= ndr_get_array_size(ndr
, &r
->in
.user
);
13994 length_user_1
= ndr_get_array_length(ndr
, &r
->in
.user
);
13995 if (length_user_1
> size_user_1
) {
13996 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", size_user_1
, length_user_1
);
13998 NDR_CHECK(ndr_check_string_terminator(ndr
, length_user_1
, sizeof(uint16_t)));
13999 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->in
.user
, length_user_1
, sizeof(uint16_t), CH_UTF16
));
14000 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_user_0
, 0);
14002 if (ndr
->flags
& LIBNDR_FLAG_REF_ALLOC
) {
14003 NDR_PULL_ALLOC(ndr
, r
->in
.info_ctr
);
14005 _mem_save_info_ctr_0
= NDR_PULL_GET_MEM_CTX(ndr
);
14006 NDR_PULL_SET_MEM_CTX(ndr
, r
->in
.info_ctr
, LIBNDR_FLAG_REF_ALLOC
);
14007 NDR_CHECK(ndr_pull_srvsvc_NetCharDevQInfoCtr(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->in
.info_ctr
));
14008 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_info_ctr_0
, LIBNDR_FLAG_REF_ALLOC
);
14009 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->in
.max_buffer
));
14010 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_resume_handle
));
14011 if (_ptr_resume_handle
) {
14012 NDR_PULL_ALLOC(ndr
, r
->in
.resume_handle
);
14014 r
->in
.resume_handle
= NULL
;
14016 if (r
->in
.resume_handle
) {
14017 _mem_save_resume_handle_0
= NDR_PULL_GET_MEM_CTX(ndr
);
14018 NDR_PULL_SET_MEM_CTX(ndr
, r
->in
.resume_handle
, 0);
14019 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, r
->in
.resume_handle
));
14020 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_resume_handle_0
, 0);
14022 NDR_PULL_ALLOC(ndr
, r
->out
.info_ctr
);
14023 *r
->out
.info_ctr
= *r
->in
.info_ctr
;
14024 NDR_PULL_ALLOC(ndr
, r
->out
.totalentries
);
14025 ZERO_STRUCTP(r
->out
.totalentries
);
14027 if (flags
& NDR_OUT
) {
14028 if (ndr
->flags
& LIBNDR_FLAG_REF_ALLOC
) {
14029 NDR_PULL_ALLOC(ndr
, r
->out
.info_ctr
);
14031 _mem_save_info_ctr_0
= NDR_PULL_GET_MEM_CTX(ndr
);
14032 NDR_PULL_SET_MEM_CTX(ndr
, r
->out
.info_ctr
, LIBNDR_FLAG_REF_ALLOC
);
14033 NDR_CHECK(ndr_pull_srvsvc_NetCharDevQInfoCtr(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->out
.info_ctr
));
14034 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_info_ctr_0
, LIBNDR_FLAG_REF_ALLOC
);
14035 if (ndr
->flags
& LIBNDR_FLAG_REF_ALLOC
) {
14036 NDR_PULL_ALLOC(ndr
, r
->out
.totalentries
);
14038 _mem_save_totalentries_0
= NDR_PULL_GET_MEM_CTX(ndr
);
14039 NDR_PULL_SET_MEM_CTX(ndr
, r
->out
.totalentries
, LIBNDR_FLAG_REF_ALLOC
);
14040 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, r
->out
.totalentries
));
14041 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_totalentries_0
, LIBNDR_FLAG_REF_ALLOC
);
14042 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_resume_handle
));
14043 if (_ptr_resume_handle
) {
14044 NDR_PULL_ALLOC(ndr
, r
->out
.resume_handle
);
14046 r
->out
.resume_handle
= NULL
;
14048 if (r
->out
.resume_handle
) {
14049 _mem_save_resume_handle_0
= NDR_PULL_GET_MEM_CTX(ndr
);
14050 NDR_PULL_SET_MEM_CTX(ndr
, r
->out
.resume_handle
, 0);
14051 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, r
->out
.resume_handle
));
14052 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_resume_handle_0
, 0);
14054 NDR_CHECK(ndr_pull_WERROR(ndr
, NDR_SCALARS
, &r
->out
.result
));
14056 return NDR_ERR_SUCCESS
;
14059 _PUBLIC_
void ndr_print_srvsvc_NetCharDevQEnum(struct ndr_print
*ndr
, const char *name
, int flags
, const struct srvsvc_NetCharDevQEnum
*r
)
14061 ndr_print_struct(ndr
, name
, "srvsvc_NetCharDevQEnum");
14063 if (flags
& NDR_SET_VALUES
) {
14064 ndr
->flags
|= LIBNDR_PRINT_SET_VALUES
;
14066 if (flags
& NDR_IN
) {
14067 ndr_print_struct(ndr
, "in", "srvsvc_NetCharDevQEnum");
14069 ndr_print_ptr(ndr
, "server_unc", r
->in
.server_unc
);
14071 if (r
->in
.server_unc
) {
14072 ndr_print_string(ndr
, "server_unc", r
->in
.server_unc
);
14075 ndr_print_ptr(ndr
, "user", r
->in
.user
);
14078 ndr_print_string(ndr
, "user", r
->in
.user
);
14081 ndr_print_ptr(ndr
, "info_ctr", r
->in
.info_ctr
);
14083 ndr_print_srvsvc_NetCharDevQInfoCtr(ndr
, "info_ctr", r
->in
.info_ctr
);
14085 ndr_print_uint32(ndr
, "max_buffer", r
->in
.max_buffer
);
14086 ndr_print_ptr(ndr
, "resume_handle", r
->in
.resume_handle
);
14088 if (r
->in
.resume_handle
) {
14089 ndr_print_uint32(ndr
, "resume_handle", *r
->in
.resume_handle
);
14094 if (flags
& NDR_OUT
) {
14095 ndr_print_struct(ndr
, "out", "srvsvc_NetCharDevQEnum");
14097 ndr_print_ptr(ndr
, "info_ctr", r
->out
.info_ctr
);
14099 ndr_print_srvsvc_NetCharDevQInfoCtr(ndr
, "info_ctr", r
->out
.info_ctr
);
14101 ndr_print_ptr(ndr
, "totalentries", r
->out
.totalentries
);
14103 ndr_print_uint32(ndr
, "totalentries", *r
->out
.totalentries
);
14105 ndr_print_ptr(ndr
, "resume_handle", r
->out
.resume_handle
);
14107 if (r
->out
.resume_handle
) {
14108 ndr_print_uint32(ndr
, "resume_handle", *r
->out
.resume_handle
);
14111 ndr_print_WERROR(ndr
, "result", r
->out
.result
);
14117 static enum ndr_err_code
ndr_push_srvsvc_NetCharDevQGetInfo(struct ndr_push
*ndr
, int flags
, const struct srvsvc_NetCharDevQGetInfo
*r
)
14119 if (flags
& NDR_IN
) {
14120 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->in
.server_unc
));
14121 if (r
->in
.server_unc
) {
14122 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.server_unc
, CH_UTF16
)));
14123 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
14124 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.server_unc
, CH_UTF16
)));
14125 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
));
14127 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.queue_name
, CH_UTF16
)));
14128 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
14129 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.queue_name
, CH_UTF16
)));
14130 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
));
14131 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.user
, CH_UTF16
)));
14132 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
14133 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.user
, CH_UTF16
)));
14134 NDR_CHECK(ndr_push_charset(ndr
, NDR_SCALARS
, r
->in
.user
, ndr_charset_length(r
->in
.user
, CH_UTF16
), sizeof(uint16_t), CH_UTF16
));
14135 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->in
.level
));
14137 if (flags
& NDR_OUT
) {
14138 if (r
->out
.info
== NULL
) {
14139 return ndr_push_error(ndr
, NDR_ERR_INVALID_POINTER
, "NULL [ref] pointer");
14141 NDR_CHECK(ndr_push_set_switch_value(ndr
, r
->out
.info
, r
->in
.level
));
14142 NDR_CHECK(ndr_push_srvsvc_NetCharDevQInfo(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->out
.info
));
14143 NDR_CHECK(ndr_push_WERROR(ndr
, NDR_SCALARS
, r
->out
.result
));
14145 return NDR_ERR_SUCCESS
;
14148 static enum ndr_err_code
ndr_pull_srvsvc_NetCharDevQGetInfo(struct ndr_pull
*ndr
, int flags
, struct srvsvc_NetCharDevQGetInfo
*r
)
14150 uint32_t _ptr_server_unc
;
14151 uint32_t size_server_unc_1
= 0;
14152 uint32_t length_server_unc_1
= 0;
14153 uint32_t size_queue_name_0
= 0;
14154 uint32_t length_queue_name_0
= 0;
14155 uint32_t size_user_0
= 0;
14156 uint32_t length_user_0
= 0;
14157 TALLOC_CTX
*_mem_save_server_unc_0
;
14158 TALLOC_CTX
*_mem_save_info_0
;
14159 if (flags
& NDR_IN
) {
14160 ZERO_STRUCT(r
->out
);
14162 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_server_unc
));
14163 if (_ptr_server_unc
) {
14164 NDR_PULL_ALLOC(ndr
, r
->in
.server_unc
);
14166 r
->in
.server_unc
= NULL
;
14168 if (r
->in
.server_unc
) {
14169 _mem_save_server_unc_0
= NDR_PULL_GET_MEM_CTX(ndr
);
14170 NDR_PULL_SET_MEM_CTX(ndr
, r
->in
.server_unc
, 0);
14171 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->in
.server_unc
));
14172 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->in
.server_unc
));
14173 size_server_unc_1
= ndr_get_array_size(ndr
, &r
->in
.server_unc
);
14174 length_server_unc_1
= ndr_get_array_length(ndr
, &r
->in
.server_unc
);
14175 if (length_server_unc_1
> size_server_unc_1
) {
14176 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", size_server_unc_1
, length_server_unc_1
);
14178 NDR_CHECK(ndr_check_string_terminator(ndr
, length_server_unc_1
, sizeof(uint16_t)));
14179 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->in
.server_unc
, length_server_unc_1
, sizeof(uint16_t), CH_UTF16
));
14180 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_server_unc_0
, 0);
14182 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->in
.queue_name
));
14183 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->in
.queue_name
));
14184 size_queue_name_0
= ndr_get_array_size(ndr
, &r
->in
.queue_name
);
14185 length_queue_name_0
= ndr_get_array_length(ndr
, &r
->in
.queue_name
);
14186 if (length_queue_name_0
> size_queue_name_0
) {
14187 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", size_queue_name_0
, length_queue_name_0
);
14189 NDR_CHECK(ndr_check_string_terminator(ndr
, length_queue_name_0
, sizeof(uint16_t)));
14190 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->in
.queue_name
, length_queue_name_0
, sizeof(uint16_t), CH_UTF16
));
14191 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->in
.user
));
14192 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->in
.user
));
14193 size_user_0
= ndr_get_array_size(ndr
, &r
->in
.user
);
14194 length_user_0
= ndr_get_array_length(ndr
, &r
->in
.user
);
14195 if (length_user_0
> size_user_0
) {
14196 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", size_user_0
, length_user_0
);
14198 NDR_CHECK(ndr_check_string_terminator(ndr
, length_user_0
, sizeof(uint16_t)));
14199 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->in
.user
, length_user_0
, sizeof(uint16_t), CH_UTF16
));
14200 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->in
.level
));
14201 NDR_PULL_ALLOC(ndr
, r
->out
.info
);
14202 ZERO_STRUCTP(r
->out
.info
);
14204 if (flags
& NDR_OUT
) {
14205 if (ndr
->flags
& LIBNDR_FLAG_REF_ALLOC
) {
14206 NDR_PULL_ALLOC(ndr
, r
->out
.info
);
14208 _mem_save_info_0
= NDR_PULL_GET_MEM_CTX(ndr
);
14209 NDR_PULL_SET_MEM_CTX(ndr
, r
->out
.info
, LIBNDR_FLAG_REF_ALLOC
);
14210 NDR_CHECK(ndr_pull_set_switch_value(ndr
, r
->out
.info
, r
->in
.level
));
14211 NDR_CHECK(ndr_pull_srvsvc_NetCharDevQInfo(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->out
.info
));
14212 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_info_0
, LIBNDR_FLAG_REF_ALLOC
);
14213 NDR_CHECK(ndr_pull_WERROR(ndr
, NDR_SCALARS
, &r
->out
.result
));
14215 return NDR_ERR_SUCCESS
;
14218 _PUBLIC_
void ndr_print_srvsvc_NetCharDevQGetInfo(struct ndr_print
*ndr
, const char *name
, int flags
, const struct srvsvc_NetCharDevQGetInfo
*r
)
14220 ndr_print_struct(ndr
, name
, "srvsvc_NetCharDevQGetInfo");
14222 if (flags
& NDR_SET_VALUES
) {
14223 ndr
->flags
|= LIBNDR_PRINT_SET_VALUES
;
14225 if (flags
& NDR_IN
) {
14226 ndr_print_struct(ndr
, "in", "srvsvc_NetCharDevQGetInfo");
14228 ndr_print_ptr(ndr
, "server_unc", r
->in
.server_unc
);
14230 if (r
->in
.server_unc
) {
14231 ndr_print_string(ndr
, "server_unc", r
->in
.server_unc
);
14234 ndr_print_string(ndr
, "queue_name", r
->in
.queue_name
);
14235 ndr_print_string(ndr
, "user", r
->in
.user
);
14236 ndr_print_uint32(ndr
, "level", r
->in
.level
);
14239 if (flags
& NDR_OUT
) {
14240 ndr_print_struct(ndr
, "out", "srvsvc_NetCharDevQGetInfo");
14242 ndr_print_ptr(ndr
, "info", r
->out
.info
);
14244 ndr_print_set_switch_value(ndr
, r
->out
.info
, r
->in
.level
);
14245 ndr_print_srvsvc_NetCharDevQInfo(ndr
, "info", r
->out
.info
);
14247 ndr_print_WERROR(ndr
, "result", r
->out
.result
);
14253 static enum ndr_err_code
ndr_push_srvsvc_NetCharDevQSetInfo(struct ndr_push
*ndr
, int flags
, const struct srvsvc_NetCharDevQSetInfo
*r
)
14255 if (flags
& NDR_IN
) {
14256 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->in
.server_unc
));
14257 if (r
->in
.server_unc
) {
14258 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.server_unc
, CH_UTF16
)));
14259 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
14260 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.server_unc
, CH_UTF16
)));
14261 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
));
14263 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.queue_name
, CH_UTF16
)));
14264 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
14265 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.queue_name
, CH_UTF16
)));
14266 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
));
14267 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->in
.level
));
14268 NDR_CHECK(ndr_push_set_switch_value(ndr
, &r
->in
.info
, r
->in
.level
));
14269 NDR_CHECK(ndr_push_srvsvc_NetCharDevQInfo(ndr
, NDR_SCALARS
|NDR_BUFFERS
, &r
->in
.info
));
14270 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->in
.parm_error
));
14271 if (r
->in
.parm_error
) {
14272 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, *r
->in
.parm_error
));
14275 if (flags
& NDR_OUT
) {
14276 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->out
.parm_error
));
14277 if (r
->out
.parm_error
) {
14278 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, *r
->out
.parm_error
));
14280 NDR_CHECK(ndr_push_WERROR(ndr
, NDR_SCALARS
, r
->out
.result
));
14282 return NDR_ERR_SUCCESS
;
14285 static enum ndr_err_code
ndr_pull_srvsvc_NetCharDevQSetInfo(struct ndr_pull
*ndr
, int flags
, struct srvsvc_NetCharDevQSetInfo
*r
)
14287 uint32_t _ptr_server_unc
;
14288 uint32_t size_server_unc_1
= 0;
14289 uint32_t length_server_unc_1
= 0;
14290 uint32_t size_queue_name_0
= 0;
14291 uint32_t length_queue_name_0
= 0;
14292 uint32_t _ptr_parm_error
;
14293 TALLOC_CTX
*_mem_save_server_unc_0
;
14294 TALLOC_CTX
*_mem_save_parm_error_0
;
14295 if (flags
& NDR_IN
) {
14296 ZERO_STRUCT(r
->out
);
14298 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_server_unc
));
14299 if (_ptr_server_unc
) {
14300 NDR_PULL_ALLOC(ndr
, r
->in
.server_unc
);
14302 r
->in
.server_unc
= NULL
;
14304 if (r
->in
.server_unc
) {
14305 _mem_save_server_unc_0
= NDR_PULL_GET_MEM_CTX(ndr
);
14306 NDR_PULL_SET_MEM_CTX(ndr
, r
->in
.server_unc
, 0);
14307 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->in
.server_unc
));
14308 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->in
.server_unc
));
14309 size_server_unc_1
= ndr_get_array_size(ndr
, &r
->in
.server_unc
);
14310 length_server_unc_1
= ndr_get_array_length(ndr
, &r
->in
.server_unc
);
14311 if (length_server_unc_1
> size_server_unc_1
) {
14312 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", size_server_unc_1
, length_server_unc_1
);
14314 NDR_CHECK(ndr_check_string_terminator(ndr
, length_server_unc_1
, sizeof(uint16_t)));
14315 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->in
.server_unc
, length_server_unc_1
, sizeof(uint16_t), CH_UTF16
));
14316 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_server_unc_0
, 0);
14318 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->in
.queue_name
));
14319 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->in
.queue_name
));
14320 size_queue_name_0
= ndr_get_array_size(ndr
, &r
->in
.queue_name
);
14321 length_queue_name_0
= ndr_get_array_length(ndr
, &r
->in
.queue_name
);
14322 if (length_queue_name_0
> size_queue_name_0
) {
14323 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", size_queue_name_0
, length_queue_name_0
);
14325 NDR_CHECK(ndr_check_string_terminator(ndr
, length_queue_name_0
, sizeof(uint16_t)));
14326 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->in
.queue_name
, length_queue_name_0
, sizeof(uint16_t), CH_UTF16
));
14327 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->in
.level
));
14328 NDR_CHECK(ndr_pull_set_switch_value(ndr
, &r
->in
.info
, r
->in
.level
));
14329 NDR_CHECK(ndr_pull_srvsvc_NetCharDevQInfo(ndr
, NDR_SCALARS
|NDR_BUFFERS
, &r
->in
.info
));
14330 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_parm_error
));
14331 if (_ptr_parm_error
) {
14332 NDR_PULL_ALLOC(ndr
, r
->in
.parm_error
);
14334 r
->in
.parm_error
= NULL
;
14336 if (r
->in
.parm_error
) {
14337 _mem_save_parm_error_0
= NDR_PULL_GET_MEM_CTX(ndr
);
14338 NDR_PULL_SET_MEM_CTX(ndr
, r
->in
.parm_error
, 0);
14339 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, r
->in
.parm_error
));
14340 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_parm_error_0
, 0);
14343 if (flags
& NDR_OUT
) {
14344 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_parm_error
));
14345 if (_ptr_parm_error
) {
14346 NDR_PULL_ALLOC(ndr
, r
->out
.parm_error
);
14348 r
->out
.parm_error
= NULL
;
14350 if (r
->out
.parm_error
) {
14351 _mem_save_parm_error_0
= NDR_PULL_GET_MEM_CTX(ndr
);
14352 NDR_PULL_SET_MEM_CTX(ndr
, r
->out
.parm_error
, 0);
14353 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, r
->out
.parm_error
));
14354 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_parm_error_0
, 0);
14356 NDR_CHECK(ndr_pull_WERROR(ndr
, NDR_SCALARS
, &r
->out
.result
));
14358 return NDR_ERR_SUCCESS
;
14361 _PUBLIC_
void ndr_print_srvsvc_NetCharDevQSetInfo(struct ndr_print
*ndr
, const char *name
, int flags
, const struct srvsvc_NetCharDevQSetInfo
*r
)
14363 ndr_print_struct(ndr
, name
, "srvsvc_NetCharDevQSetInfo");
14365 if (flags
& NDR_SET_VALUES
) {
14366 ndr
->flags
|= LIBNDR_PRINT_SET_VALUES
;
14368 if (flags
& NDR_IN
) {
14369 ndr_print_struct(ndr
, "in", "srvsvc_NetCharDevQSetInfo");
14371 ndr_print_ptr(ndr
, "server_unc", r
->in
.server_unc
);
14373 if (r
->in
.server_unc
) {
14374 ndr_print_string(ndr
, "server_unc", r
->in
.server_unc
);
14377 ndr_print_string(ndr
, "queue_name", r
->in
.queue_name
);
14378 ndr_print_uint32(ndr
, "level", r
->in
.level
);
14379 ndr_print_set_switch_value(ndr
, &r
->in
.info
, r
->in
.level
);
14380 ndr_print_srvsvc_NetCharDevQInfo(ndr
, "info", &r
->in
.info
);
14381 ndr_print_ptr(ndr
, "parm_error", r
->in
.parm_error
);
14383 if (r
->in
.parm_error
) {
14384 ndr_print_uint32(ndr
, "parm_error", *r
->in
.parm_error
);
14389 if (flags
& NDR_OUT
) {
14390 ndr_print_struct(ndr
, "out", "srvsvc_NetCharDevQSetInfo");
14392 ndr_print_ptr(ndr
, "parm_error", r
->out
.parm_error
);
14394 if (r
->out
.parm_error
) {
14395 ndr_print_uint32(ndr
, "parm_error", *r
->out
.parm_error
);
14398 ndr_print_WERROR(ndr
, "result", r
->out
.result
);
14404 static enum ndr_err_code
ndr_push_srvsvc_NetCharDevQPurge(struct ndr_push
*ndr
, int flags
, const struct srvsvc_NetCharDevQPurge
*r
)
14406 if (flags
& NDR_IN
) {
14407 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->in
.server_unc
));
14408 if (r
->in
.server_unc
) {
14409 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.server_unc
, CH_UTF16
)));
14410 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
14411 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.server_unc
, CH_UTF16
)));
14412 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
));
14414 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.queue_name
, CH_UTF16
)));
14415 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
14416 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.queue_name
, CH_UTF16
)));
14417 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
));
14419 if (flags
& NDR_OUT
) {
14420 NDR_CHECK(ndr_push_WERROR(ndr
, NDR_SCALARS
, r
->out
.result
));
14422 return NDR_ERR_SUCCESS
;
14425 static enum ndr_err_code
ndr_pull_srvsvc_NetCharDevQPurge(struct ndr_pull
*ndr
, int flags
, struct srvsvc_NetCharDevQPurge
*r
)
14427 uint32_t _ptr_server_unc
;
14428 uint32_t size_server_unc_1
= 0;
14429 uint32_t length_server_unc_1
= 0;
14430 uint32_t size_queue_name_0
= 0;
14431 uint32_t length_queue_name_0
= 0;
14432 TALLOC_CTX
*_mem_save_server_unc_0
;
14433 if (flags
& NDR_IN
) {
14434 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_server_unc
));
14435 if (_ptr_server_unc
) {
14436 NDR_PULL_ALLOC(ndr
, r
->in
.server_unc
);
14438 r
->in
.server_unc
= NULL
;
14440 if (r
->in
.server_unc
) {
14441 _mem_save_server_unc_0
= NDR_PULL_GET_MEM_CTX(ndr
);
14442 NDR_PULL_SET_MEM_CTX(ndr
, r
->in
.server_unc
, 0);
14443 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->in
.server_unc
));
14444 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->in
.server_unc
));
14445 size_server_unc_1
= ndr_get_array_size(ndr
, &r
->in
.server_unc
);
14446 length_server_unc_1
= ndr_get_array_length(ndr
, &r
->in
.server_unc
);
14447 if (length_server_unc_1
> size_server_unc_1
) {
14448 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", size_server_unc_1
, length_server_unc_1
);
14450 NDR_CHECK(ndr_check_string_terminator(ndr
, length_server_unc_1
, sizeof(uint16_t)));
14451 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->in
.server_unc
, length_server_unc_1
, sizeof(uint16_t), CH_UTF16
));
14452 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_server_unc_0
, 0);
14454 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->in
.queue_name
));
14455 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->in
.queue_name
));
14456 size_queue_name_0
= ndr_get_array_size(ndr
, &r
->in
.queue_name
);
14457 length_queue_name_0
= ndr_get_array_length(ndr
, &r
->in
.queue_name
);
14458 if (length_queue_name_0
> size_queue_name_0
) {
14459 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", size_queue_name_0
, length_queue_name_0
);
14461 NDR_CHECK(ndr_check_string_terminator(ndr
, length_queue_name_0
, sizeof(uint16_t)));
14462 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->in
.queue_name
, length_queue_name_0
, sizeof(uint16_t), CH_UTF16
));
14464 if (flags
& NDR_OUT
) {
14465 NDR_CHECK(ndr_pull_WERROR(ndr
, NDR_SCALARS
, &r
->out
.result
));
14467 return NDR_ERR_SUCCESS
;
14470 _PUBLIC_
void ndr_print_srvsvc_NetCharDevQPurge(struct ndr_print
*ndr
, const char *name
, int flags
, const struct srvsvc_NetCharDevQPurge
*r
)
14472 ndr_print_struct(ndr
, name
, "srvsvc_NetCharDevQPurge");
14474 if (flags
& NDR_SET_VALUES
) {
14475 ndr
->flags
|= LIBNDR_PRINT_SET_VALUES
;
14477 if (flags
& NDR_IN
) {
14478 ndr_print_struct(ndr
, "in", "srvsvc_NetCharDevQPurge");
14480 ndr_print_ptr(ndr
, "server_unc", r
->in
.server_unc
);
14482 if (r
->in
.server_unc
) {
14483 ndr_print_string(ndr
, "server_unc", r
->in
.server_unc
);
14486 ndr_print_string(ndr
, "queue_name", r
->in
.queue_name
);
14489 if (flags
& NDR_OUT
) {
14490 ndr_print_struct(ndr
, "out", "srvsvc_NetCharDevQPurge");
14492 ndr_print_WERROR(ndr
, "result", r
->out
.result
);
14498 static enum ndr_err_code
ndr_push_srvsvc_NetCharDevQPurgeSelf(struct ndr_push
*ndr
, int flags
, const struct srvsvc_NetCharDevQPurgeSelf
*r
)
14500 if (flags
& NDR_IN
) {
14501 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->in
.server_unc
));
14502 if (r
->in
.server_unc
) {
14503 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.server_unc
, CH_UTF16
)));
14504 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
14505 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.server_unc
, CH_UTF16
)));
14506 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
));
14508 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.queue_name
, CH_UTF16
)));
14509 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
14510 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.queue_name
, CH_UTF16
)));
14511 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
));
14512 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.computer_name
, CH_UTF16
)));
14513 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
14514 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.computer_name
, CH_UTF16
)));
14515 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
));
14517 if (flags
& NDR_OUT
) {
14518 NDR_CHECK(ndr_push_WERROR(ndr
, NDR_SCALARS
, r
->out
.result
));
14520 return NDR_ERR_SUCCESS
;
14523 static enum ndr_err_code
ndr_pull_srvsvc_NetCharDevQPurgeSelf(struct ndr_pull
*ndr
, int flags
, struct srvsvc_NetCharDevQPurgeSelf
*r
)
14525 uint32_t _ptr_server_unc
;
14526 uint32_t size_server_unc_1
= 0;
14527 uint32_t length_server_unc_1
= 0;
14528 uint32_t size_queue_name_0
= 0;
14529 uint32_t length_queue_name_0
= 0;
14530 uint32_t size_computer_name_0
= 0;
14531 uint32_t length_computer_name_0
= 0;
14532 TALLOC_CTX
*_mem_save_server_unc_0
;
14533 if (flags
& NDR_IN
) {
14534 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_server_unc
));
14535 if (_ptr_server_unc
) {
14536 NDR_PULL_ALLOC(ndr
, r
->in
.server_unc
);
14538 r
->in
.server_unc
= NULL
;
14540 if (r
->in
.server_unc
) {
14541 _mem_save_server_unc_0
= NDR_PULL_GET_MEM_CTX(ndr
);
14542 NDR_PULL_SET_MEM_CTX(ndr
, r
->in
.server_unc
, 0);
14543 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->in
.server_unc
));
14544 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->in
.server_unc
));
14545 size_server_unc_1
= ndr_get_array_size(ndr
, &r
->in
.server_unc
);
14546 length_server_unc_1
= ndr_get_array_length(ndr
, &r
->in
.server_unc
);
14547 if (length_server_unc_1
> size_server_unc_1
) {
14548 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", size_server_unc_1
, length_server_unc_1
);
14550 NDR_CHECK(ndr_check_string_terminator(ndr
, length_server_unc_1
, sizeof(uint16_t)));
14551 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->in
.server_unc
, length_server_unc_1
, sizeof(uint16_t), CH_UTF16
));
14552 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_server_unc_0
, 0);
14554 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->in
.queue_name
));
14555 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->in
.queue_name
));
14556 size_queue_name_0
= ndr_get_array_size(ndr
, &r
->in
.queue_name
);
14557 length_queue_name_0
= ndr_get_array_length(ndr
, &r
->in
.queue_name
);
14558 if (length_queue_name_0
> size_queue_name_0
) {
14559 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", size_queue_name_0
, length_queue_name_0
);
14561 NDR_CHECK(ndr_check_string_terminator(ndr
, length_queue_name_0
, sizeof(uint16_t)));
14562 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->in
.queue_name
, length_queue_name_0
, sizeof(uint16_t), CH_UTF16
));
14563 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->in
.computer_name
));
14564 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->in
.computer_name
));
14565 size_computer_name_0
= ndr_get_array_size(ndr
, &r
->in
.computer_name
);
14566 length_computer_name_0
= ndr_get_array_length(ndr
, &r
->in
.computer_name
);
14567 if (length_computer_name_0
> size_computer_name_0
) {
14568 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", size_computer_name_0
, length_computer_name_0
);
14570 NDR_CHECK(ndr_check_string_terminator(ndr
, length_computer_name_0
, sizeof(uint16_t)));
14571 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->in
.computer_name
, length_computer_name_0
, sizeof(uint16_t), CH_UTF16
));
14573 if (flags
& NDR_OUT
) {
14574 NDR_CHECK(ndr_pull_WERROR(ndr
, NDR_SCALARS
, &r
->out
.result
));
14576 return NDR_ERR_SUCCESS
;
14579 _PUBLIC_
void ndr_print_srvsvc_NetCharDevQPurgeSelf(struct ndr_print
*ndr
, const char *name
, int flags
, const struct srvsvc_NetCharDevQPurgeSelf
*r
)
14581 ndr_print_struct(ndr
, name
, "srvsvc_NetCharDevQPurgeSelf");
14583 if (flags
& NDR_SET_VALUES
) {
14584 ndr
->flags
|= LIBNDR_PRINT_SET_VALUES
;
14586 if (flags
& NDR_IN
) {
14587 ndr_print_struct(ndr
, "in", "srvsvc_NetCharDevQPurgeSelf");
14589 ndr_print_ptr(ndr
, "server_unc", r
->in
.server_unc
);
14591 if (r
->in
.server_unc
) {
14592 ndr_print_string(ndr
, "server_unc", r
->in
.server_unc
);
14595 ndr_print_string(ndr
, "queue_name", r
->in
.queue_name
);
14596 ndr_print_string(ndr
, "computer_name", r
->in
.computer_name
);
14599 if (flags
& NDR_OUT
) {
14600 ndr_print_struct(ndr
, "out", "srvsvc_NetCharDevQPurgeSelf");
14602 ndr_print_WERROR(ndr
, "result", r
->out
.result
);
14608 static enum ndr_err_code
ndr_push_srvsvc_NetConnEnum(struct ndr_push
*ndr
, int flags
, const struct srvsvc_NetConnEnum
*r
)
14610 if (flags
& NDR_IN
) {
14611 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->in
.server_unc
));
14612 if (r
->in
.server_unc
) {
14613 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.server_unc
, CH_UTF16
)));
14614 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
14615 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.server_unc
, CH_UTF16
)));
14616 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
));
14618 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->in
.path
));
14620 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.path
, CH_UTF16
)));
14621 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
14622 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.path
, CH_UTF16
)));
14623 NDR_CHECK(ndr_push_charset(ndr
, NDR_SCALARS
, r
->in
.path
, ndr_charset_length(r
->in
.path
, CH_UTF16
), sizeof(uint16_t), CH_UTF16
));
14625 if (r
->in
.info_ctr
== NULL
) {
14626 return ndr_push_error(ndr
, NDR_ERR_INVALID_POINTER
, "NULL [ref] pointer");
14628 NDR_CHECK(ndr_push_srvsvc_NetConnInfoCtr(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->in
.info_ctr
));
14629 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->in
.max_buffer
));
14630 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->in
.resume_handle
));
14631 if (r
->in
.resume_handle
) {
14632 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, *r
->in
.resume_handle
));
14635 if (flags
& NDR_OUT
) {
14636 if (r
->out
.info_ctr
== NULL
) {
14637 return ndr_push_error(ndr
, NDR_ERR_INVALID_POINTER
, "NULL [ref] pointer");
14639 NDR_CHECK(ndr_push_srvsvc_NetConnInfoCtr(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->out
.info_ctr
));
14640 if (r
->out
.totalentries
== NULL
) {
14641 return ndr_push_error(ndr
, NDR_ERR_INVALID_POINTER
, "NULL [ref] pointer");
14643 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, *r
->out
.totalentries
));
14644 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->out
.resume_handle
));
14645 if (r
->out
.resume_handle
) {
14646 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, *r
->out
.resume_handle
));
14648 NDR_CHECK(ndr_push_WERROR(ndr
, NDR_SCALARS
, r
->out
.result
));
14650 return NDR_ERR_SUCCESS
;
14653 static enum ndr_err_code
ndr_pull_srvsvc_NetConnEnum(struct ndr_pull
*ndr
, int flags
, struct srvsvc_NetConnEnum
*r
)
14655 uint32_t _ptr_server_unc
;
14656 uint32_t size_server_unc_1
= 0;
14657 uint32_t length_server_unc_1
= 0;
14658 uint32_t _ptr_path
;
14659 uint32_t size_path_1
= 0;
14660 uint32_t length_path_1
= 0;
14661 uint32_t _ptr_resume_handle
;
14662 TALLOC_CTX
*_mem_save_server_unc_0
;
14663 TALLOC_CTX
*_mem_save_path_0
;
14664 TALLOC_CTX
*_mem_save_info_ctr_0
;
14665 TALLOC_CTX
*_mem_save_totalentries_0
;
14666 TALLOC_CTX
*_mem_save_resume_handle_0
;
14667 if (flags
& NDR_IN
) {
14668 ZERO_STRUCT(r
->out
);
14670 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_server_unc
));
14671 if (_ptr_server_unc
) {
14672 NDR_PULL_ALLOC(ndr
, r
->in
.server_unc
);
14674 r
->in
.server_unc
= NULL
;
14676 if (r
->in
.server_unc
) {
14677 _mem_save_server_unc_0
= NDR_PULL_GET_MEM_CTX(ndr
);
14678 NDR_PULL_SET_MEM_CTX(ndr
, r
->in
.server_unc
, 0);
14679 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->in
.server_unc
));
14680 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->in
.server_unc
));
14681 size_server_unc_1
= ndr_get_array_size(ndr
, &r
->in
.server_unc
);
14682 length_server_unc_1
= ndr_get_array_length(ndr
, &r
->in
.server_unc
);
14683 if (length_server_unc_1
> size_server_unc_1
) {
14684 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", size_server_unc_1
, length_server_unc_1
);
14686 NDR_CHECK(ndr_check_string_terminator(ndr
, length_server_unc_1
, sizeof(uint16_t)));
14687 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->in
.server_unc
, length_server_unc_1
, sizeof(uint16_t), CH_UTF16
));
14688 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_server_unc_0
, 0);
14690 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_path
));
14692 NDR_PULL_ALLOC(ndr
, r
->in
.path
);
14697 _mem_save_path_0
= NDR_PULL_GET_MEM_CTX(ndr
);
14698 NDR_PULL_SET_MEM_CTX(ndr
, r
->in
.path
, 0);
14699 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->in
.path
));
14700 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->in
.path
));
14701 size_path_1
= ndr_get_array_size(ndr
, &r
->in
.path
);
14702 length_path_1
= ndr_get_array_length(ndr
, &r
->in
.path
);
14703 if (length_path_1
> size_path_1
) {
14704 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", size_path_1
, length_path_1
);
14706 NDR_CHECK(ndr_check_string_terminator(ndr
, length_path_1
, sizeof(uint16_t)));
14707 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->in
.path
, length_path_1
, sizeof(uint16_t), CH_UTF16
));
14708 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_path_0
, 0);
14710 if (ndr
->flags
& LIBNDR_FLAG_REF_ALLOC
) {
14711 NDR_PULL_ALLOC(ndr
, r
->in
.info_ctr
);
14713 _mem_save_info_ctr_0
= NDR_PULL_GET_MEM_CTX(ndr
);
14714 NDR_PULL_SET_MEM_CTX(ndr
, r
->in
.info_ctr
, LIBNDR_FLAG_REF_ALLOC
);
14715 NDR_CHECK(ndr_pull_srvsvc_NetConnInfoCtr(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->in
.info_ctr
));
14716 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_info_ctr_0
, LIBNDR_FLAG_REF_ALLOC
);
14717 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->in
.max_buffer
));
14718 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_resume_handle
));
14719 if (_ptr_resume_handle
) {
14720 NDR_PULL_ALLOC(ndr
, r
->in
.resume_handle
);
14722 r
->in
.resume_handle
= NULL
;
14724 if (r
->in
.resume_handle
) {
14725 _mem_save_resume_handle_0
= NDR_PULL_GET_MEM_CTX(ndr
);
14726 NDR_PULL_SET_MEM_CTX(ndr
, r
->in
.resume_handle
, 0);
14727 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, r
->in
.resume_handle
));
14728 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_resume_handle_0
, 0);
14730 NDR_PULL_ALLOC(ndr
, r
->out
.info_ctr
);
14731 *r
->out
.info_ctr
= *r
->in
.info_ctr
;
14732 NDR_PULL_ALLOC(ndr
, r
->out
.totalentries
);
14733 ZERO_STRUCTP(r
->out
.totalentries
);
14735 if (flags
& NDR_OUT
) {
14736 if (ndr
->flags
& LIBNDR_FLAG_REF_ALLOC
) {
14737 NDR_PULL_ALLOC(ndr
, r
->out
.info_ctr
);
14739 _mem_save_info_ctr_0
= NDR_PULL_GET_MEM_CTX(ndr
);
14740 NDR_PULL_SET_MEM_CTX(ndr
, r
->out
.info_ctr
, LIBNDR_FLAG_REF_ALLOC
);
14741 NDR_CHECK(ndr_pull_srvsvc_NetConnInfoCtr(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->out
.info_ctr
));
14742 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_info_ctr_0
, LIBNDR_FLAG_REF_ALLOC
);
14743 if (ndr
->flags
& LIBNDR_FLAG_REF_ALLOC
) {
14744 NDR_PULL_ALLOC(ndr
, r
->out
.totalentries
);
14746 _mem_save_totalentries_0
= NDR_PULL_GET_MEM_CTX(ndr
);
14747 NDR_PULL_SET_MEM_CTX(ndr
, r
->out
.totalentries
, LIBNDR_FLAG_REF_ALLOC
);
14748 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, r
->out
.totalentries
));
14749 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_totalentries_0
, LIBNDR_FLAG_REF_ALLOC
);
14750 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_resume_handle
));
14751 if (_ptr_resume_handle
) {
14752 NDR_PULL_ALLOC(ndr
, r
->out
.resume_handle
);
14754 r
->out
.resume_handle
= NULL
;
14756 if (r
->out
.resume_handle
) {
14757 _mem_save_resume_handle_0
= NDR_PULL_GET_MEM_CTX(ndr
);
14758 NDR_PULL_SET_MEM_CTX(ndr
, r
->out
.resume_handle
, 0);
14759 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, r
->out
.resume_handle
));
14760 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_resume_handle_0
, 0);
14762 NDR_CHECK(ndr_pull_WERROR(ndr
, NDR_SCALARS
, &r
->out
.result
));
14764 return NDR_ERR_SUCCESS
;
14767 _PUBLIC_
void ndr_print_srvsvc_NetConnEnum(struct ndr_print
*ndr
, const char *name
, int flags
, const struct srvsvc_NetConnEnum
*r
)
14769 ndr_print_struct(ndr
, name
, "srvsvc_NetConnEnum");
14771 if (flags
& NDR_SET_VALUES
) {
14772 ndr
->flags
|= LIBNDR_PRINT_SET_VALUES
;
14774 if (flags
& NDR_IN
) {
14775 ndr_print_struct(ndr
, "in", "srvsvc_NetConnEnum");
14777 ndr_print_ptr(ndr
, "server_unc", r
->in
.server_unc
);
14779 if (r
->in
.server_unc
) {
14780 ndr_print_string(ndr
, "server_unc", r
->in
.server_unc
);
14783 ndr_print_ptr(ndr
, "path", r
->in
.path
);
14786 ndr_print_string(ndr
, "path", r
->in
.path
);
14789 ndr_print_ptr(ndr
, "info_ctr", r
->in
.info_ctr
);
14791 ndr_print_srvsvc_NetConnInfoCtr(ndr
, "info_ctr", r
->in
.info_ctr
);
14793 ndr_print_uint32(ndr
, "max_buffer", r
->in
.max_buffer
);
14794 ndr_print_ptr(ndr
, "resume_handle", r
->in
.resume_handle
);
14796 if (r
->in
.resume_handle
) {
14797 ndr_print_uint32(ndr
, "resume_handle", *r
->in
.resume_handle
);
14802 if (flags
& NDR_OUT
) {
14803 ndr_print_struct(ndr
, "out", "srvsvc_NetConnEnum");
14805 ndr_print_ptr(ndr
, "info_ctr", r
->out
.info_ctr
);
14807 ndr_print_srvsvc_NetConnInfoCtr(ndr
, "info_ctr", r
->out
.info_ctr
);
14809 ndr_print_ptr(ndr
, "totalentries", r
->out
.totalentries
);
14811 ndr_print_uint32(ndr
, "totalentries", *r
->out
.totalentries
);
14813 ndr_print_ptr(ndr
, "resume_handle", r
->out
.resume_handle
);
14815 if (r
->out
.resume_handle
) {
14816 ndr_print_uint32(ndr
, "resume_handle", *r
->out
.resume_handle
);
14819 ndr_print_WERROR(ndr
, "result", r
->out
.result
);
14825 static enum ndr_err_code
ndr_push_srvsvc_NetFileEnum(struct ndr_push
*ndr
, int flags
, const struct srvsvc_NetFileEnum
*r
)
14827 if (flags
& NDR_IN
) {
14828 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->in
.server_unc
));
14829 if (r
->in
.server_unc
) {
14830 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.server_unc
, CH_UTF16
)));
14831 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
14832 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.server_unc
, CH_UTF16
)));
14833 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
));
14835 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->in
.path
));
14837 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.path
, CH_UTF16
)));
14838 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
14839 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.path
, CH_UTF16
)));
14840 NDR_CHECK(ndr_push_charset(ndr
, NDR_SCALARS
, r
->in
.path
, ndr_charset_length(r
->in
.path
, CH_UTF16
), sizeof(uint16_t), CH_UTF16
));
14842 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->in
.user
));
14844 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.user
, CH_UTF16
)));
14845 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
14846 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.user
, CH_UTF16
)));
14847 NDR_CHECK(ndr_push_charset(ndr
, NDR_SCALARS
, r
->in
.user
, ndr_charset_length(r
->in
.user
, CH_UTF16
), sizeof(uint16_t), CH_UTF16
));
14849 if (r
->in
.info_ctr
== NULL
) {
14850 return ndr_push_error(ndr
, NDR_ERR_INVALID_POINTER
, "NULL [ref] pointer");
14852 NDR_CHECK(ndr_push_srvsvc_NetFileInfoCtr(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->in
.info_ctr
));
14853 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->in
.max_buffer
));
14854 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->in
.resume_handle
));
14855 if (r
->in
.resume_handle
) {
14856 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, *r
->in
.resume_handle
));
14859 if (flags
& NDR_OUT
) {
14860 if (r
->out
.info_ctr
== NULL
) {
14861 return ndr_push_error(ndr
, NDR_ERR_INVALID_POINTER
, "NULL [ref] pointer");
14863 NDR_CHECK(ndr_push_srvsvc_NetFileInfoCtr(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->out
.info_ctr
));
14864 if (r
->out
.totalentries
== NULL
) {
14865 return ndr_push_error(ndr
, NDR_ERR_INVALID_POINTER
, "NULL [ref] pointer");
14867 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, *r
->out
.totalentries
));
14868 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->out
.resume_handle
));
14869 if (r
->out
.resume_handle
) {
14870 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, *r
->out
.resume_handle
));
14872 NDR_CHECK(ndr_push_WERROR(ndr
, NDR_SCALARS
, r
->out
.result
));
14874 return NDR_ERR_SUCCESS
;
14877 static enum ndr_err_code
ndr_pull_srvsvc_NetFileEnum(struct ndr_pull
*ndr
, int flags
, struct srvsvc_NetFileEnum
*r
)
14879 uint32_t _ptr_server_unc
;
14880 uint32_t size_server_unc_1
= 0;
14881 uint32_t length_server_unc_1
= 0;
14882 uint32_t _ptr_path
;
14883 uint32_t size_path_1
= 0;
14884 uint32_t length_path_1
= 0;
14885 uint32_t _ptr_user
;
14886 uint32_t size_user_1
= 0;
14887 uint32_t length_user_1
= 0;
14888 uint32_t _ptr_resume_handle
;
14889 TALLOC_CTX
*_mem_save_server_unc_0
;
14890 TALLOC_CTX
*_mem_save_path_0
;
14891 TALLOC_CTX
*_mem_save_user_0
;
14892 TALLOC_CTX
*_mem_save_info_ctr_0
;
14893 TALLOC_CTX
*_mem_save_totalentries_0
;
14894 TALLOC_CTX
*_mem_save_resume_handle_0
;
14895 if (flags
& NDR_IN
) {
14896 ZERO_STRUCT(r
->out
);
14898 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_server_unc
));
14899 if (_ptr_server_unc
) {
14900 NDR_PULL_ALLOC(ndr
, r
->in
.server_unc
);
14902 r
->in
.server_unc
= NULL
;
14904 if (r
->in
.server_unc
) {
14905 _mem_save_server_unc_0
= NDR_PULL_GET_MEM_CTX(ndr
);
14906 NDR_PULL_SET_MEM_CTX(ndr
, r
->in
.server_unc
, 0);
14907 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->in
.server_unc
));
14908 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->in
.server_unc
));
14909 size_server_unc_1
= ndr_get_array_size(ndr
, &r
->in
.server_unc
);
14910 length_server_unc_1
= ndr_get_array_length(ndr
, &r
->in
.server_unc
);
14911 if (length_server_unc_1
> size_server_unc_1
) {
14912 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", size_server_unc_1
, length_server_unc_1
);
14914 NDR_CHECK(ndr_check_string_terminator(ndr
, length_server_unc_1
, sizeof(uint16_t)));
14915 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->in
.server_unc
, length_server_unc_1
, sizeof(uint16_t), CH_UTF16
));
14916 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_server_unc_0
, 0);
14918 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_path
));
14920 NDR_PULL_ALLOC(ndr
, r
->in
.path
);
14925 _mem_save_path_0
= NDR_PULL_GET_MEM_CTX(ndr
);
14926 NDR_PULL_SET_MEM_CTX(ndr
, r
->in
.path
, 0);
14927 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->in
.path
));
14928 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->in
.path
));
14929 size_path_1
= ndr_get_array_size(ndr
, &r
->in
.path
);
14930 length_path_1
= ndr_get_array_length(ndr
, &r
->in
.path
);
14931 if (length_path_1
> size_path_1
) {
14932 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", size_path_1
, length_path_1
);
14934 NDR_CHECK(ndr_check_string_terminator(ndr
, length_path_1
, sizeof(uint16_t)));
14935 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->in
.path
, length_path_1
, sizeof(uint16_t), CH_UTF16
));
14936 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_path_0
, 0);
14938 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_user
));
14940 NDR_PULL_ALLOC(ndr
, r
->in
.user
);
14945 _mem_save_user_0
= NDR_PULL_GET_MEM_CTX(ndr
);
14946 NDR_PULL_SET_MEM_CTX(ndr
, r
->in
.user
, 0);
14947 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->in
.user
));
14948 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->in
.user
));
14949 size_user_1
= ndr_get_array_size(ndr
, &r
->in
.user
);
14950 length_user_1
= ndr_get_array_length(ndr
, &r
->in
.user
);
14951 if (length_user_1
> size_user_1
) {
14952 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", size_user_1
, length_user_1
);
14954 NDR_CHECK(ndr_check_string_terminator(ndr
, length_user_1
, sizeof(uint16_t)));
14955 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->in
.user
, length_user_1
, sizeof(uint16_t), CH_UTF16
));
14956 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_user_0
, 0);
14958 if (ndr
->flags
& LIBNDR_FLAG_REF_ALLOC
) {
14959 NDR_PULL_ALLOC(ndr
, r
->in
.info_ctr
);
14961 _mem_save_info_ctr_0
= NDR_PULL_GET_MEM_CTX(ndr
);
14962 NDR_PULL_SET_MEM_CTX(ndr
, r
->in
.info_ctr
, LIBNDR_FLAG_REF_ALLOC
);
14963 NDR_CHECK(ndr_pull_srvsvc_NetFileInfoCtr(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->in
.info_ctr
));
14964 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_info_ctr_0
, LIBNDR_FLAG_REF_ALLOC
);
14965 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->in
.max_buffer
));
14966 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_resume_handle
));
14967 if (_ptr_resume_handle
) {
14968 NDR_PULL_ALLOC(ndr
, r
->in
.resume_handle
);
14970 r
->in
.resume_handle
= NULL
;
14972 if (r
->in
.resume_handle
) {
14973 _mem_save_resume_handle_0
= NDR_PULL_GET_MEM_CTX(ndr
);
14974 NDR_PULL_SET_MEM_CTX(ndr
, r
->in
.resume_handle
, 0);
14975 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, r
->in
.resume_handle
));
14976 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_resume_handle_0
, 0);
14978 NDR_PULL_ALLOC(ndr
, r
->out
.info_ctr
);
14979 *r
->out
.info_ctr
= *r
->in
.info_ctr
;
14980 NDR_PULL_ALLOC(ndr
, r
->out
.totalentries
);
14981 ZERO_STRUCTP(r
->out
.totalentries
);
14983 if (flags
& NDR_OUT
) {
14984 if (ndr
->flags
& LIBNDR_FLAG_REF_ALLOC
) {
14985 NDR_PULL_ALLOC(ndr
, r
->out
.info_ctr
);
14987 _mem_save_info_ctr_0
= NDR_PULL_GET_MEM_CTX(ndr
);
14988 NDR_PULL_SET_MEM_CTX(ndr
, r
->out
.info_ctr
, LIBNDR_FLAG_REF_ALLOC
);
14989 NDR_CHECK(ndr_pull_srvsvc_NetFileInfoCtr(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->out
.info_ctr
));
14990 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_info_ctr_0
, LIBNDR_FLAG_REF_ALLOC
);
14991 if (ndr
->flags
& LIBNDR_FLAG_REF_ALLOC
) {
14992 NDR_PULL_ALLOC(ndr
, r
->out
.totalentries
);
14994 _mem_save_totalentries_0
= NDR_PULL_GET_MEM_CTX(ndr
);
14995 NDR_PULL_SET_MEM_CTX(ndr
, r
->out
.totalentries
, LIBNDR_FLAG_REF_ALLOC
);
14996 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, r
->out
.totalentries
));
14997 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_totalentries_0
, LIBNDR_FLAG_REF_ALLOC
);
14998 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_resume_handle
));
14999 if (_ptr_resume_handle
) {
15000 NDR_PULL_ALLOC(ndr
, r
->out
.resume_handle
);
15002 r
->out
.resume_handle
= NULL
;
15004 if (r
->out
.resume_handle
) {
15005 _mem_save_resume_handle_0
= NDR_PULL_GET_MEM_CTX(ndr
);
15006 NDR_PULL_SET_MEM_CTX(ndr
, r
->out
.resume_handle
, 0);
15007 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, r
->out
.resume_handle
));
15008 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_resume_handle_0
, 0);
15010 NDR_CHECK(ndr_pull_WERROR(ndr
, NDR_SCALARS
, &r
->out
.result
));
15012 return NDR_ERR_SUCCESS
;
15015 _PUBLIC_
void ndr_print_srvsvc_NetFileEnum(struct ndr_print
*ndr
, const char *name
, int flags
, const struct srvsvc_NetFileEnum
*r
)
15017 ndr_print_struct(ndr
, name
, "srvsvc_NetFileEnum");
15019 if (flags
& NDR_SET_VALUES
) {
15020 ndr
->flags
|= LIBNDR_PRINT_SET_VALUES
;
15022 if (flags
& NDR_IN
) {
15023 ndr_print_struct(ndr
, "in", "srvsvc_NetFileEnum");
15025 ndr_print_ptr(ndr
, "server_unc", r
->in
.server_unc
);
15027 if (r
->in
.server_unc
) {
15028 ndr_print_string(ndr
, "server_unc", r
->in
.server_unc
);
15031 ndr_print_ptr(ndr
, "path", r
->in
.path
);
15034 ndr_print_string(ndr
, "path", r
->in
.path
);
15037 ndr_print_ptr(ndr
, "user", r
->in
.user
);
15040 ndr_print_string(ndr
, "user", r
->in
.user
);
15043 ndr_print_ptr(ndr
, "info_ctr", r
->in
.info_ctr
);
15045 ndr_print_srvsvc_NetFileInfoCtr(ndr
, "info_ctr", r
->in
.info_ctr
);
15047 ndr_print_uint32(ndr
, "max_buffer", r
->in
.max_buffer
);
15048 ndr_print_ptr(ndr
, "resume_handle", r
->in
.resume_handle
);
15050 if (r
->in
.resume_handle
) {
15051 ndr_print_uint32(ndr
, "resume_handle", *r
->in
.resume_handle
);
15056 if (flags
& NDR_OUT
) {
15057 ndr_print_struct(ndr
, "out", "srvsvc_NetFileEnum");
15059 ndr_print_ptr(ndr
, "info_ctr", r
->out
.info_ctr
);
15061 ndr_print_srvsvc_NetFileInfoCtr(ndr
, "info_ctr", r
->out
.info_ctr
);
15063 ndr_print_ptr(ndr
, "totalentries", r
->out
.totalentries
);
15065 ndr_print_uint32(ndr
, "totalentries", *r
->out
.totalentries
);
15067 ndr_print_ptr(ndr
, "resume_handle", r
->out
.resume_handle
);
15069 if (r
->out
.resume_handle
) {
15070 ndr_print_uint32(ndr
, "resume_handle", *r
->out
.resume_handle
);
15073 ndr_print_WERROR(ndr
, "result", r
->out
.result
);
15079 static enum ndr_err_code
ndr_push_srvsvc_NetFileGetInfo(struct ndr_push
*ndr
, int flags
, const struct srvsvc_NetFileGetInfo
*r
)
15081 if (flags
& NDR_IN
) {
15082 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->in
.server_unc
));
15083 if (r
->in
.server_unc
) {
15084 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.server_unc
, CH_UTF16
)));
15085 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
15086 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.server_unc
, CH_UTF16
)));
15087 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
));
15089 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->in
.fid
));
15090 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->in
.level
));
15092 if (flags
& NDR_OUT
) {
15093 if (r
->out
.info
== NULL
) {
15094 return ndr_push_error(ndr
, NDR_ERR_INVALID_POINTER
, "NULL [ref] pointer");
15096 NDR_CHECK(ndr_push_set_switch_value(ndr
, r
->out
.info
, r
->in
.level
));
15097 NDR_CHECK(ndr_push_srvsvc_NetFileInfo(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->out
.info
));
15098 NDR_CHECK(ndr_push_WERROR(ndr
, NDR_SCALARS
, r
->out
.result
));
15100 return NDR_ERR_SUCCESS
;
15103 static enum ndr_err_code
ndr_pull_srvsvc_NetFileGetInfo(struct ndr_pull
*ndr
, int flags
, struct srvsvc_NetFileGetInfo
*r
)
15105 uint32_t _ptr_server_unc
;
15106 uint32_t size_server_unc_1
= 0;
15107 uint32_t length_server_unc_1
= 0;
15108 TALLOC_CTX
*_mem_save_server_unc_0
;
15109 TALLOC_CTX
*_mem_save_info_0
;
15110 if (flags
& NDR_IN
) {
15111 ZERO_STRUCT(r
->out
);
15113 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_server_unc
));
15114 if (_ptr_server_unc
) {
15115 NDR_PULL_ALLOC(ndr
, r
->in
.server_unc
);
15117 r
->in
.server_unc
= NULL
;
15119 if (r
->in
.server_unc
) {
15120 _mem_save_server_unc_0
= NDR_PULL_GET_MEM_CTX(ndr
);
15121 NDR_PULL_SET_MEM_CTX(ndr
, r
->in
.server_unc
, 0);
15122 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->in
.server_unc
));
15123 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->in
.server_unc
));
15124 size_server_unc_1
= ndr_get_array_size(ndr
, &r
->in
.server_unc
);
15125 length_server_unc_1
= ndr_get_array_length(ndr
, &r
->in
.server_unc
);
15126 if (length_server_unc_1
> size_server_unc_1
) {
15127 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", size_server_unc_1
, length_server_unc_1
);
15129 NDR_CHECK(ndr_check_string_terminator(ndr
, length_server_unc_1
, sizeof(uint16_t)));
15130 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->in
.server_unc
, length_server_unc_1
, sizeof(uint16_t), CH_UTF16
));
15131 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_server_unc_0
, 0);
15133 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->in
.fid
));
15134 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->in
.level
));
15135 NDR_PULL_ALLOC(ndr
, r
->out
.info
);
15136 ZERO_STRUCTP(r
->out
.info
);
15138 if (flags
& NDR_OUT
) {
15139 if (ndr
->flags
& LIBNDR_FLAG_REF_ALLOC
) {
15140 NDR_PULL_ALLOC(ndr
, r
->out
.info
);
15142 _mem_save_info_0
= NDR_PULL_GET_MEM_CTX(ndr
);
15143 NDR_PULL_SET_MEM_CTX(ndr
, r
->out
.info
, LIBNDR_FLAG_REF_ALLOC
);
15144 NDR_CHECK(ndr_pull_set_switch_value(ndr
, r
->out
.info
, r
->in
.level
));
15145 NDR_CHECK(ndr_pull_srvsvc_NetFileInfo(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->out
.info
));
15146 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_info_0
, LIBNDR_FLAG_REF_ALLOC
);
15147 NDR_CHECK(ndr_pull_WERROR(ndr
, NDR_SCALARS
, &r
->out
.result
));
15149 return NDR_ERR_SUCCESS
;
15152 _PUBLIC_
void ndr_print_srvsvc_NetFileGetInfo(struct ndr_print
*ndr
, const char *name
, int flags
, const struct srvsvc_NetFileGetInfo
*r
)
15154 ndr_print_struct(ndr
, name
, "srvsvc_NetFileGetInfo");
15156 if (flags
& NDR_SET_VALUES
) {
15157 ndr
->flags
|= LIBNDR_PRINT_SET_VALUES
;
15159 if (flags
& NDR_IN
) {
15160 ndr_print_struct(ndr
, "in", "srvsvc_NetFileGetInfo");
15162 ndr_print_ptr(ndr
, "server_unc", r
->in
.server_unc
);
15164 if (r
->in
.server_unc
) {
15165 ndr_print_string(ndr
, "server_unc", r
->in
.server_unc
);
15168 ndr_print_uint32(ndr
, "fid", r
->in
.fid
);
15169 ndr_print_uint32(ndr
, "level", r
->in
.level
);
15172 if (flags
& NDR_OUT
) {
15173 ndr_print_struct(ndr
, "out", "srvsvc_NetFileGetInfo");
15175 ndr_print_ptr(ndr
, "info", r
->out
.info
);
15177 ndr_print_set_switch_value(ndr
, r
->out
.info
, r
->in
.level
);
15178 ndr_print_srvsvc_NetFileInfo(ndr
, "info", r
->out
.info
);
15180 ndr_print_WERROR(ndr
, "result", r
->out
.result
);
15186 static enum ndr_err_code
ndr_push_srvsvc_NetFileClose(struct ndr_push
*ndr
, int flags
, const struct srvsvc_NetFileClose
*r
)
15188 if (flags
& NDR_IN
) {
15189 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->in
.server_unc
));
15190 if (r
->in
.server_unc
) {
15191 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.server_unc
, CH_UTF16
)));
15192 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
15193 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.server_unc
, CH_UTF16
)));
15194 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
));
15196 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->in
.fid
));
15198 if (flags
& NDR_OUT
) {
15199 NDR_CHECK(ndr_push_WERROR(ndr
, NDR_SCALARS
, r
->out
.result
));
15201 return NDR_ERR_SUCCESS
;
15204 static enum ndr_err_code
ndr_pull_srvsvc_NetFileClose(struct ndr_pull
*ndr
, int flags
, struct srvsvc_NetFileClose
*r
)
15206 uint32_t _ptr_server_unc
;
15207 uint32_t size_server_unc_1
= 0;
15208 uint32_t length_server_unc_1
= 0;
15209 TALLOC_CTX
*_mem_save_server_unc_0
;
15210 if (flags
& NDR_IN
) {
15211 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_server_unc
));
15212 if (_ptr_server_unc
) {
15213 NDR_PULL_ALLOC(ndr
, r
->in
.server_unc
);
15215 r
->in
.server_unc
= NULL
;
15217 if (r
->in
.server_unc
) {
15218 _mem_save_server_unc_0
= NDR_PULL_GET_MEM_CTX(ndr
);
15219 NDR_PULL_SET_MEM_CTX(ndr
, r
->in
.server_unc
, 0);
15220 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->in
.server_unc
));
15221 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->in
.server_unc
));
15222 size_server_unc_1
= ndr_get_array_size(ndr
, &r
->in
.server_unc
);
15223 length_server_unc_1
= ndr_get_array_length(ndr
, &r
->in
.server_unc
);
15224 if (length_server_unc_1
> size_server_unc_1
) {
15225 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", size_server_unc_1
, length_server_unc_1
);
15227 NDR_CHECK(ndr_check_string_terminator(ndr
, length_server_unc_1
, sizeof(uint16_t)));
15228 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->in
.server_unc
, length_server_unc_1
, sizeof(uint16_t), CH_UTF16
));
15229 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_server_unc_0
, 0);
15231 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->in
.fid
));
15233 if (flags
& NDR_OUT
) {
15234 NDR_CHECK(ndr_pull_WERROR(ndr
, NDR_SCALARS
, &r
->out
.result
));
15236 return NDR_ERR_SUCCESS
;
15239 _PUBLIC_
void ndr_print_srvsvc_NetFileClose(struct ndr_print
*ndr
, const char *name
, int flags
, const struct srvsvc_NetFileClose
*r
)
15241 ndr_print_struct(ndr
, name
, "srvsvc_NetFileClose");
15243 if (flags
& NDR_SET_VALUES
) {
15244 ndr
->flags
|= LIBNDR_PRINT_SET_VALUES
;
15246 if (flags
& NDR_IN
) {
15247 ndr_print_struct(ndr
, "in", "srvsvc_NetFileClose");
15249 ndr_print_ptr(ndr
, "server_unc", r
->in
.server_unc
);
15251 if (r
->in
.server_unc
) {
15252 ndr_print_string(ndr
, "server_unc", r
->in
.server_unc
);
15255 ndr_print_uint32(ndr
, "fid", r
->in
.fid
);
15258 if (flags
& NDR_OUT
) {
15259 ndr_print_struct(ndr
, "out", "srvsvc_NetFileClose");
15261 ndr_print_WERROR(ndr
, "result", r
->out
.result
);
15267 static enum ndr_err_code
ndr_push_srvsvc_NetSessEnum(struct ndr_push
*ndr
, int flags
, const struct srvsvc_NetSessEnum
*r
)
15269 if (flags
& NDR_IN
) {
15270 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->in
.server_unc
));
15271 if (r
->in
.server_unc
) {
15272 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.server_unc
, CH_UTF16
)));
15273 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
15274 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.server_unc
, CH_UTF16
)));
15275 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
));
15277 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->in
.client
));
15278 if (r
->in
.client
) {
15279 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.client
, CH_UTF16
)));
15280 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
15281 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.client
, CH_UTF16
)));
15282 NDR_CHECK(ndr_push_charset(ndr
, NDR_SCALARS
, r
->in
.client
, ndr_charset_length(r
->in
.client
, CH_UTF16
), sizeof(uint16_t), CH_UTF16
));
15284 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->in
.user
));
15286 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.user
, CH_UTF16
)));
15287 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
15288 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.user
, CH_UTF16
)));
15289 NDR_CHECK(ndr_push_charset(ndr
, NDR_SCALARS
, r
->in
.user
, ndr_charset_length(r
->in
.user
, CH_UTF16
), sizeof(uint16_t), CH_UTF16
));
15291 if (r
->in
.info_ctr
== NULL
) {
15292 return ndr_push_error(ndr
, NDR_ERR_INVALID_POINTER
, "NULL [ref] pointer");
15294 NDR_CHECK(ndr_push_srvsvc_NetSessInfoCtr(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->in
.info_ctr
));
15295 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->in
.max_buffer
));
15296 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->in
.resume_handle
));
15297 if (r
->in
.resume_handle
) {
15298 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, *r
->in
.resume_handle
));
15301 if (flags
& NDR_OUT
) {
15302 if (r
->out
.info_ctr
== NULL
) {
15303 return ndr_push_error(ndr
, NDR_ERR_INVALID_POINTER
, "NULL [ref] pointer");
15305 NDR_CHECK(ndr_push_srvsvc_NetSessInfoCtr(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->out
.info_ctr
));
15306 if (r
->out
.totalentries
== NULL
) {
15307 return ndr_push_error(ndr
, NDR_ERR_INVALID_POINTER
, "NULL [ref] pointer");
15309 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, *r
->out
.totalentries
));
15310 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->out
.resume_handle
));
15311 if (r
->out
.resume_handle
) {
15312 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, *r
->out
.resume_handle
));
15314 NDR_CHECK(ndr_push_WERROR(ndr
, NDR_SCALARS
, r
->out
.result
));
15316 return NDR_ERR_SUCCESS
;
15319 static enum ndr_err_code
ndr_pull_srvsvc_NetSessEnum(struct ndr_pull
*ndr
, int flags
, struct srvsvc_NetSessEnum
*r
)
15321 uint32_t _ptr_server_unc
;
15322 uint32_t size_server_unc_1
= 0;
15323 uint32_t length_server_unc_1
= 0;
15324 uint32_t _ptr_client
;
15325 uint32_t size_client_1
= 0;
15326 uint32_t length_client_1
= 0;
15327 uint32_t _ptr_user
;
15328 uint32_t size_user_1
= 0;
15329 uint32_t length_user_1
= 0;
15330 uint32_t _ptr_resume_handle
;
15331 TALLOC_CTX
*_mem_save_server_unc_0
;
15332 TALLOC_CTX
*_mem_save_client_0
;
15333 TALLOC_CTX
*_mem_save_user_0
;
15334 TALLOC_CTX
*_mem_save_info_ctr_0
;
15335 TALLOC_CTX
*_mem_save_totalentries_0
;
15336 TALLOC_CTX
*_mem_save_resume_handle_0
;
15337 if (flags
& NDR_IN
) {
15338 ZERO_STRUCT(r
->out
);
15340 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_server_unc
));
15341 if (_ptr_server_unc
) {
15342 NDR_PULL_ALLOC(ndr
, r
->in
.server_unc
);
15344 r
->in
.server_unc
= NULL
;
15346 if (r
->in
.server_unc
) {
15347 _mem_save_server_unc_0
= NDR_PULL_GET_MEM_CTX(ndr
);
15348 NDR_PULL_SET_MEM_CTX(ndr
, r
->in
.server_unc
, 0);
15349 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->in
.server_unc
));
15350 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->in
.server_unc
));
15351 size_server_unc_1
= ndr_get_array_size(ndr
, &r
->in
.server_unc
);
15352 length_server_unc_1
= ndr_get_array_length(ndr
, &r
->in
.server_unc
);
15353 if (length_server_unc_1
> size_server_unc_1
) {
15354 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", size_server_unc_1
, length_server_unc_1
);
15356 NDR_CHECK(ndr_check_string_terminator(ndr
, length_server_unc_1
, sizeof(uint16_t)));
15357 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->in
.server_unc
, length_server_unc_1
, sizeof(uint16_t), CH_UTF16
));
15358 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_server_unc_0
, 0);
15360 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_client
));
15362 NDR_PULL_ALLOC(ndr
, r
->in
.client
);
15364 r
->in
.client
= NULL
;
15366 if (r
->in
.client
) {
15367 _mem_save_client_0
= NDR_PULL_GET_MEM_CTX(ndr
);
15368 NDR_PULL_SET_MEM_CTX(ndr
, r
->in
.client
, 0);
15369 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->in
.client
));
15370 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->in
.client
));
15371 size_client_1
= ndr_get_array_size(ndr
, &r
->in
.client
);
15372 length_client_1
= ndr_get_array_length(ndr
, &r
->in
.client
);
15373 if (length_client_1
> size_client_1
) {
15374 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", size_client_1
, length_client_1
);
15376 NDR_CHECK(ndr_check_string_terminator(ndr
, length_client_1
, sizeof(uint16_t)));
15377 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->in
.client
, length_client_1
, sizeof(uint16_t), CH_UTF16
));
15378 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_client_0
, 0);
15380 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_user
));
15382 NDR_PULL_ALLOC(ndr
, r
->in
.user
);
15387 _mem_save_user_0
= NDR_PULL_GET_MEM_CTX(ndr
);
15388 NDR_PULL_SET_MEM_CTX(ndr
, r
->in
.user
, 0);
15389 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->in
.user
));
15390 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->in
.user
));
15391 size_user_1
= ndr_get_array_size(ndr
, &r
->in
.user
);
15392 length_user_1
= ndr_get_array_length(ndr
, &r
->in
.user
);
15393 if (length_user_1
> size_user_1
) {
15394 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", size_user_1
, length_user_1
);
15396 NDR_CHECK(ndr_check_string_terminator(ndr
, length_user_1
, sizeof(uint16_t)));
15397 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->in
.user
, length_user_1
, sizeof(uint16_t), CH_UTF16
));
15398 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_user_0
, 0);
15400 if (ndr
->flags
& LIBNDR_FLAG_REF_ALLOC
) {
15401 NDR_PULL_ALLOC(ndr
, r
->in
.info_ctr
);
15403 _mem_save_info_ctr_0
= NDR_PULL_GET_MEM_CTX(ndr
);
15404 NDR_PULL_SET_MEM_CTX(ndr
, r
->in
.info_ctr
, LIBNDR_FLAG_REF_ALLOC
);
15405 NDR_CHECK(ndr_pull_srvsvc_NetSessInfoCtr(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->in
.info_ctr
));
15406 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_info_ctr_0
, LIBNDR_FLAG_REF_ALLOC
);
15407 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->in
.max_buffer
));
15408 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_resume_handle
));
15409 if (_ptr_resume_handle
) {
15410 NDR_PULL_ALLOC(ndr
, r
->in
.resume_handle
);
15412 r
->in
.resume_handle
= NULL
;
15414 if (r
->in
.resume_handle
) {
15415 _mem_save_resume_handle_0
= NDR_PULL_GET_MEM_CTX(ndr
);
15416 NDR_PULL_SET_MEM_CTX(ndr
, r
->in
.resume_handle
, 0);
15417 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, r
->in
.resume_handle
));
15418 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_resume_handle_0
, 0);
15420 NDR_PULL_ALLOC(ndr
, r
->out
.info_ctr
);
15421 *r
->out
.info_ctr
= *r
->in
.info_ctr
;
15422 NDR_PULL_ALLOC(ndr
, r
->out
.totalentries
);
15423 ZERO_STRUCTP(r
->out
.totalentries
);
15425 if (flags
& NDR_OUT
) {
15426 if (ndr
->flags
& LIBNDR_FLAG_REF_ALLOC
) {
15427 NDR_PULL_ALLOC(ndr
, r
->out
.info_ctr
);
15429 _mem_save_info_ctr_0
= NDR_PULL_GET_MEM_CTX(ndr
);
15430 NDR_PULL_SET_MEM_CTX(ndr
, r
->out
.info_ctr
, LIBNDR_FLAG_REF_ALLOC
);
15431 NDR_CHECK(ndr_pull_srvsvc_NetSessInfoCtr(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->out
.info_ctr
));
15432 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_info_ctr_0
, LIBNDR_FLAG_REF_ALLOC
);
15433 if (ndr
->flags
& LIBNDR_FLAG_REF_ALLOC
) {
15434 NDR_PULL_ALLOC(ndr
, r
->out
.totalentries
);
15436 _mem_save_totalentries_0
= NDR_PULL_GET_MEM_CTX(ndr
);
15437 NDR_PULL_SET_MEM_CTX(ndr
, r
->out
.totalentries
, LIBNDR_FLAG_REF_ALLOC
);
15438 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, r
->out
.totalentries
));
15439 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_totalentries_0
, LIBNDR_FLAG_REF_ALLOC
);
15440 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_resume_handle
));
15441 if (_ptr_resume_handle
) {
15442 NDR_PULL_ALLOC(ndr
, r
->out
.resume_handle
);
15444 r
->out
.resume_handle
= NULL
;
15446 if (r
->out
.resume_handle
) {
15447 _mem_save_resume_handle_0
= NDR_PULL_GET_MEM_CTX(ndr
);
15448 NDR_PULL_SET_MEM_CTX(ndr
, r
->out
.resume_handle
, 0);
15449 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, r
->out
.resume_handle
));
15450 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_resume_handle_0
, 0);
15452 NDR_CHECK(ndr_pull_WERROR(ndr
, NDR_SCALARS
, &r
->out
.result
));
15454 return NDR_ERR_SUCCESS
;
15457 _PUBLIC_
void ndr_print_srvsvc_NetSessEnum(struct ndr_print
*ndr
, const char *name
, int flags
, const struct srvsvc_NetSessEnum
*r
)
15459 ndr_print_struct(ndr
, name
, "srvsvc_NetSessEnum");
15461 if (flags
& NDR_SET_VALUES
) {
15462 ndr
->flags
|= LIBNDR_PRINT_SET_VALUES
;
15464 if (flags
& NDR_IN
) {
15465 ndr_print_struct(ndr
, "in", "srvsvc_NetSessEnum");
15467 ndr_print_ptr(ndr
, "server_unc", r
->in
.server_unc
);
15469 if (r
->in
.server_unc
) {
15470 ndr_print_string(ndr
, "server_unc", r
->in
.server_unc
);
15473 ndr_print_ptr(ndr
, "client", r
->in
.client
);
15475 if (r
->in
.client
) {
15476 ndr_print_string(ndr
, "client", r
->in
.client
);
15479 ndr_print_ptr(ndr
, "user", r
->in
.user
);
15482 ndr_print_string(ndr
, "user", r
->in
.user
);
15485 ndr_print_ptr(ndr
, "info_ctr", r
->in
.info_ctr
);
15487 ndr_print_srvsvc_NetSessInfoCtr(ndr
, "info_ctr", r
->in
.info_ctr
);
15489 ndr_print_uint32(ndr
, "max_buffer", r
->in
.max_buffer
);
15490 ndr_print_ptr(ndr
, "resume_handle", r
->in
.resume_handle
);
15492 if (r
->in
.resume_handle
) {
15493 ndr_print_uint32(ndr
, "resume_handle", *r
->in
.resume_handle
);
15498 if (flags
& NDR_OUT
) {
15499 ndr_print_struct(ndr
, "out", "srvsvc_NetSessEnum");
15501 ndr_print_ptr(ndr
, "info_ctr", r
->out
.info_ctr
);
15503 ndr_print_srvsvc_NetSessInfoCtr(ndr
, "info_ctr", r
->out
.info_ctr
);
15505 ndr_print_ptr(ndr
, "totalentries", r
->out
.totalentries
);
15507 ndr_print_uint32(ndr
, "totalentries", *r
->out
.totalentries
);
15509 ndr_print_ptr(ndr
, "resume_handle", r
->out
.resume_handle
);
15511 if (r
->out
.resume_handle
) {
15512 ndr_print_uint32(ndr
, "resume_handle", *r
->out
.resume_handle
);
15515 ndr_print_WERROR(ndr
, "result", r
->out
.result
);
15521 static enum ndr_err_code
ndr_push_srvsvc_NetSessDel(struct ndr_push
*ndr
, int flags
, const struct srvsvc_NetSessDel
*r
)
15523 if (flags
& NDR_IN
) {
15524 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->in
.server_unc
));
15525 if (r
->in
.server_unc
) {
15526 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.server_unc
, CH_UTF16
)));
15527 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
15528 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.server_unc
, CH_UTF16
)));
15529 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
));
15531 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->in
.client
));
15532 if (r
->in
.client
) {
15533 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.client
, CH_UTF16
)));
15534 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
15535 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.client
, CH_UTF16
)));
15536 NDR_CHECK(ndr_push_charset(ndr
, NDR_SCALARS
, r
->in
.client
, ndr_charset_length(r
->in
.client
, CH_UTF16
), sizeof(uint16_t), CH_UTF16
));
15538 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->in
.user
));
15540 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.user
, CH_UTF16
)));
15541 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
15542 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.user
, CH_UTF16
)));
15543 NDR_CHECK(ndr_push_charset(ndr
, NDR_SCALARS
, r
->in
.user
, ndr_charset_length(r
->in
.user
, CH_UTF16
), sizeof(uint16_t), CH_UTF16
));
15546 if (flags
& NDR_OUT
) {
15547 NDR_CHECK(ndr_push_WERROR(ndr
, NDR_SCALARS
, r
->out
.result
));
15549 return NDR_ERR_SUCCESS
;
15552 static enum ndr_err_code
ndr_pull_srvsvc_NetSessDel(struct ndr_pull
*ndr
, int flags
, struct srvsvc_NetSessDel
*r
)
15554 uint32_t _ptr_server_unc
;
15555 uint32_t size_server_unc_1
= 0;
15556 uint32_t length_server_unc_1
= 0;
15557 uint32_t _ptr_client
;
15558 uint32_t size_client_1
= 0;
15559 uint32_t length_client_1
= 0;
15560 uint32_t _ptr_user
;
15561 uint32_t size_user_1
= 0;
15562 uint32_t length_user_1
= 0;
15563 TALLOC_CTX
*_mem_save_server_unc_0
;
15564 TALLOC_CTX
*_mem_save_client_0
;
15565 TALLOC_CTX
*_mem_save_user_0
;
15566 if (flags
& NDR_IN
) {
15567 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_server_unc
));
15568 if (_ptr_server_unc
) {
15569 NDR_PULL_ALLOC(ndr
, r
->in
.server_unc
);
15571 r
->in
.server_unc
= NULL
;
15573 if (r
->in
.server_unc
) {
15574 _mem_save_server_unc_0
= NDR_PULL_GET_MEM_CTX(ndr
);
15575 NDR_PULL_SET_MEM_CTX(ndr
, r
->in
.server_unc
, 0);
15576 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->in
.server_unc
));
15577 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->in
.server_unc
));
15578 size_server_unc_1
= ndr_get_array_size(ndr
, &r
->in
.server_unc
);
15579 length_server_unc_1
= ndr_get_array_length(ndr
, &r
->in
.server_unc
);
15580 if (length_server_unc_1
> size_server_unc_1
) {
15581 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", size_server_unc_1
, length_server_unc_1
);
15583 NDR_CHECK(ndr_check_string_terminator(ndr
, length_server_unc_1
, sizeof(uint16_t)));
15584 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->in
.server_unc
, length_server_unc_1
, sizeof(uint16_t), CH_UTF16
));
15585 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_server_unc_0
, 0);
15587 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_client
));
15589 NDR_PULL_ALLOC(ndr
, r
->in
.client
);
15591 r
->in
.client
= NULL
;
15593 if (r
->in
.client
) {
15594 _mem_save_client_0
= NDR_PULL_GET_MEM_CTX(ndr
);
15595 NDR_PULL_SET_MEM_CTX(ndr
, r
->in
.client
, 0);
15596 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->in
.client
));
15597 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->in
.client
));
15598 size_client_1
= ndr_get_array_size(ndr
, &r
->in
.client
);
15599 length_client_1
= ndr_get_array_length(ndr
, &r
->in
.client
);
15600 if (length_client_1
> size_client_1
) {
15601 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", size_client_1
, length_client_1
);
15603 NDR_CHECK(ndr_check_string_terminator(ndr
, length_client_1
, sizeof(uint16_t)));
15604 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->in
.client
, length_client_1
, sizeof(uint16_t), CH_UTF16
));
15605 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_client_0
, 0);
15607 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_user
));
15609 NDR_PULL_ALLOC(ndr
, r
->in
.user
);
15614 _mem_save_user_0
= NDR_PULL_GET_MEM_CTX(ndr
);
15615 NDR_PULL_SET_MEM_CTX(ndr
, r
->in
.user
, 0);
15616 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->in
.user
));
15617 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->in
.user
));
15618 size_user_1
= ndr_get_array_size(ndr
, &r
->in
.user
);
15619 length_user_1
= ndr_get_array_length(ndr
, &r
->in
.user
);
15620 if (length_user_1
> size_user_1
) {
15621 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", size_user_1
, length_user_1
);
15623 NDR_CHECK(ndr_check_string_terminator(ndr
, length_user_1
, sizeof(uint16_t)));
15624 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->in
.user
, length_user_1
, sizeof(uint16_t), CH_UTF16
));
15625 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_user_0
, 0);
15628 if (flags
& NDR_OUT
) {
15629 NDR_CHECK(ndr_pull_WERROR(ndr
, NDR_SCALARS
, &r
->out
.result
));
15631 return NDR_ERR_SUCCESS
;
15634 _PUBLIC_
void ndr_print_srvsvc_NetSessDel(struct ndr_print
*ndr
, const char *name
, int flags
, const struct srvsvc_NetSessDel
*r
)
15636 ndr_print_struct(ndr
, name
, "srvsvc_NetSessDel");
15638 if (flags
& NDR_SET_VALUES
) {
15639 ndr
->flags
|= LIBNDR_PRINT_SET_VALUES
;
15641 if (flags
& NDR_IN
) {
15642 ndr_print_struct(ndr
, "in", "srvsvc_NetSessDel");
15644 ndr_print_ptr(ndr
, "server_unc", r
->in
.server_unc
);
15646 if (r
->in
.server_unc
) {
15647 ndr_print_string(ndr
, "server_unc", r
->in
.server_unc
);
15650 ndr_print_ptr(ndr
, "client", r
->in
.client
);
15652 if (r
->in
.client
) {
15653 ndr_print_string(ndr
, "client", r
->in
.client
);
15656 ndr_print_ptr(ndr
, "user", r
->in
.user
);
15659 ndr_print_string(ndr
, "user", r
->in
.user
);
15664 if (flags
& NDR_OUT
) {
15665 ndr_print_struct(ndr
, "out", "srvsvc_NetSessDel");
15667 ndr_print_WERROR(ndr
, "result", r
->out
.result
);
15673 static enum ndr_err_code
ndr_push_srvsvc_NetShareAdd(struct ndr_push
*ndr
, int flags
, const struct srvsvc_NetShareAdd
*r
)
15675 if (flags
& NDR_IN
) {
15676 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->in
.server_unc
));
15677 if (r
->in
.server_unc
) {
15678 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.server_unc
, CH_UTF16
)));
15679 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
15680 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.server_unc
, CH_UTF16
)));
15681 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
));
15683 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->in
.level
));
15684 if (r
->in
.info
== NULL
) {
15685 return ndr_push_error(ndr
, NDR_ERR_INVALID_POINTER
, "NULL [ref] pointer");
15687 NDR_CHECK(ndr_push_set_switch_value(ndr
, r
->in
.info
, r
->in
.level
));
15688 NDR_CHECK(ndr_push_srvsvc_NetShareInfo(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->in
.info
));
15689 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->in
.parm_error
));
15690 if (r
->in
.parm_error
) {
15691 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, *r
->in
.parm_error
));
15694 if (flags
& NDR_OUT
) {
15695 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->out
.parm_error
));
15696 if (r
->out
.parm_error
) {
15697 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, *r
->out
.parm_error
));
15699 NDR_CHECK(ndr_push_WERROR(ndr
, NDR_SCALARS
, r
->out
.result
));
15701 return NDR_ERR_SUCCESS
;
15704 static enum ndr_err_code
ndr_pull_srvsvc_NetShareAdd(struct ndr_pull
*ndr
, int flags
, struct srvsvc_NetShareAdd
*r
)
15706 uint32_t _ptr_server_unc
;
15707 uint32_t size_server_unc_1
= 0;
15708 uint32_t length_server_unc_1
= 0;
15709 uint32_t _ptr_parm_error
;
15710 TALLOC_CTX
*_mem_save_server_unc_0
;
15711 TALLOC_CTX
*_mem_save_info_0
;
15712 TALLOC_CTX
*_mem_save_parm_error_0
;
15713 if (flags
& NDR_IN
) {
15714 ZERO_STRUCT(r
->out
);
15716 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_server_unc
));
15717 if (_ptr_server_unc
) {
15718 NDR_PULL_ALLOC(ndr
, r
->in
.server_unc
);
15720 r
->in
.server_unc
= NULL
;
15722 if (r
->in
.server_unc
) {
15723 _mem_save_server_unc_0
= NDR_PULL_GET_MEM_CTX(ndr
);
15724 NDR_PULL_SET_MEM_CTX(ndr
, r
->in
.server_unc
, 0);
15725 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->in
.server_unc
));
15726 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->in
.server_unc
));
15727 size_server_unc_1
= ndr_get_array_size(ndr
, &r
->in
.server_unc
);
15728 length_server_unc_1
= ndr_get_array_length(ndr
, &r
->in
.server_unc
);
15729 if (length_server_unc_1
> size_server_unc_1
) {
15730 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", size_server_unc_1
, length_server_unc_1
);
15732 NDR_CHECK(ndr_check_string_terminator(ndr
, length_server_unc_1
, sizeof(uint16_t)));
15733 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->in
.server_unc
, length_server_unc_1
, sizeof(uint16_t), CH_UTF16
));
15734 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_server_unc_0
, 0);
15736 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->in
.level
));
15737 if (ndr
->flags
& LIBNDR_FLAG_REF_ALLOC
) {
15738 NDR_PULL_ALLOC(ndr
, r
->in
.info
);
15740 _mem_save_info_0
= NDR_PULL_GET_MEM_CTX(ndr
);
15741 NDR_PULL_SET_MEM_CTX(ndr
, r
->in
.info
, LIBNDR_FLAG_REF_ALLOC
);
15742 NDR_CHECK(ndr_pull_set_switch_value(ndr
, r
->in
.info
, r
->in
.level
));
15743 NDR_CHECK(ndr_pull_srvsvc_NetShareInfo(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->in
.info
));
15744 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_info_0
, LIBNDR_FLAG_REF_ALLOC
);
15745 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_parm_error
));
15746 if (_ptr_parm_error
) {
15747 NDR_PULL_ALLOC(ndr
, r
->in
.parm_error
);
15749 r
->in
.parm_error
= NULL
;
15751 if (r
->in
.parm_error
) {
15752 _mem_save_parm_error_0
= NDR_PULL_GET_MEM_CTX(ndr
);
15753 NDR_PULL_SET_MEM_CTX(ndr
, r
->in
.parm_error
, 0);
15754 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, r
->in
.parm_error
));
15755 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_parm_error_0
, 0);
15758 if (flags
& NDR_OUT
) {
15759 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_parm_error
));
15760 if (_ptr_parm_error
) {
15761 NDR_PULL_ALLOC(ndr
, r
->out
.parm_error
);
15763 r
->out
.parm_error
= NULL
;
15765 if (r
->out
.parm_error
) {
15766 _mem_save_parm_error_0
= NDR_PULL_GET_MEM_CTX(ndr
);
15767 NDR_PULL_SET_MEM_CTX(ndr
, r
->out
.parm_error
, 0);
15768 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, r
->out
.parm_error
));
15769 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_parm_error_0
, 0);
15771 NDR_CHECK(ndr_pull_WERROR(ndr
, NDR_SCALARS
, &r
->out
.result
));
15773 return NDR_ERR_SUCCESS
;
15776 _PUBLIC_
void ndr_print_srvsvc_NetShareAdd(struct ndr_print
*ndr
, const char *name
, int flags
, const struct srvsvc_NetShareAdd
*r
)
15778 ndr_print_struct(ndr
, name
, "srvsvc_NetShareAdd");
15780 if (flags
& NDR_SET_VALUES
) {
15781 ndr
->flags
|= LIBNDR_PRINT_SET_VALUES
;
15783 if (flags
& NDR_IN
) {
15784 ndr_print_struct(ndr
, "in", "srvsvc_NetShareAdd");
15786 ndr_print_ptr(ndr
, "server_unc", r
->in
.server_unc
);
15788 if (r
->in
.server_unc
) {
15789 ndr_print_string(ndr
, "server_unc", r
->in
.server_unc
);
15792 ndr_print_uint32(ndr
, "level", r
->in
.level
);
15793 ndr_print_ptr(ndr
, "info", r
->in
.info
);
15795 ndr_print_set_switch_value(ndr
, r
->in
.info
, r
->in
.level
);
15796 ndr_print_srvsvc_NetShareInfo(ndr
, "info", r
->in
.info
);
15798 ndr_print_ptr(ndr
, "parm_error", r
->in
.parm_error
);
15800 if (r
->in
.parm_error
) {
15801 ndr_print_uint32(ndr
, "parm_error", *r
->in
.parm_error
);
15806 if (flags
& NDR_OUT
) {
15807 ndr_print_struct(ndr
, "out", "srvsvc_NetShareAdd");
15809 ndr_print_ptr(ndr
, "parm_error", r
->out
.parm_error
);
15811 if (r
->out
.parm_error
) {
15812 ndr_print_uint32(ndr
, "parm_error", *r
->out
.parm_error
);
15815 ndr_print_WERROR(ndr
, "result", r
->out
.result
);
15821 static enum ndr_err_code
ndr_push_srvsvc_NetShareEnumAll(struct ndr_push
*ndr
, int flags
, const struct srvsvc_NetShareEnumAll
*r
)
15823 if (flags
& NDR_IN
) {
15824 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->in
.server_unc
));
15825 if (r
->in
.server_unc
) {
15826 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.server_unc
, CH_UTF16
)));
15827 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
15828 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.server_unc
, CH_UTF16
)));
15829 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
));
15831 if (r
->in
.info_ctr
== NULL
) {
15832 return ndr_push_error(ndr
, NDR_ERR_INVALID_POINTER
, "NULL [ref] pointer");
15834 NDR_CHECK(ndr_push_srvsvc_NetShareInfoCtr(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->in
.info_ctr
));
15835 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->in
.max_buffer
));
15836 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->in
.resume_handle
));
15837 if (r
->in
.resume_handle
) {
15838 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, *r
->in
.resume_handle
));
15841 if (flags
& NDR_OUT
) {
15842 if (r
->out
.info_ctr
== NULL
) {
15843 return ndr_push_error(ndr
, NDR_ERR_INVALID_POINTER
, "NULL [ref] pointer");
15845 NDR_CHECK(ndr_push_srvsvc_NetShareInfoCtr(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->out
.info_ctr
));
15846 if (r
->out
.totalentries
== NULL
) {
15847 return ndr_push_error(ndr
, NDR_ERR_INVALID_POINTER
, "NULL [ref] pointer");
15849 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, *r
->out
.totalentries
));
15850 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->out
.resume_handle
));
15851 if (r
->out
.resume_handle
) {
15852 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, *r
->out
.resume_handle
));
15854 NDR_CHECK(ndr_push_WERROR(ndr
, NDR_SCALARS
, r
->out
.result
));
15856 return NDR_ERR_SUCCESS
;
15859 static enum ndr_err_code
ndr_pull_srvsvc_NetShareEnumAll(struct ndr_pull
*ndr
, int flags
, struct srvsvc_NetShareEnumAll
*r
)
15861 uint32_t _ptr_server_unc
;
15862 uint32_t size_server_unc_1
= 0;
15863 uint32_t length_server_unc_1
= 0;
15864 uint32_t _ptr_resume_handle
;
15865 TALLOC_CTX
*_mem_save_server_unc_0
;
15866 TALLOC_CTX
*_mem_save_info_ctr_0
;
15867 TALLOC_CTX
*_mem_save_totalentries_0
;
15868 TALLOC_CTX
*_mem_save_resume_handle_0
;
15869 if (flags
& NDR_IN
) {
15870 ZERO_STRUCT(r
->out
);
15872 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_server_unc
));
15873 if (_ptr_server_unc
) {
15874 NDR_PULL_ALLOC(ndr
, r
->in
.server_unc
);
15876 r
->in
.server_unc
= NULL
;
15878 if (r
->in
.server_unc
) {
15879 _mem_save_server_unc_0
= NDR_PULL_GET_MEM_CTX(ndr
);
15880 NDR_PULL_SET_MEM_CTX(ndr
, r
->in
.server_unc
, 0);
15881 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->in
.server_unc
));
15882 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->in
.server_unc
));
15883 size_server_unc_1
= ndr_get_array_size(ndr
, &r
->in
.server_unc
);
15884 length_server_unc_1
= ndr_get_array_length(ndr
, &r
->in
.server_unc
);
15885 if (length_server_unc_1
> size_server_unc_1
) {
15886 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", size_server_unc_1
, length_server_unc_1
);
15888 NDR_CHECK(ndr_check_string_terminator(ndr
, length_server_unc_1
, sizeof(uint16_t)));
15889 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->in
.server_unc
, length_server_unc_1
, sizeof(uint16_t), CH_UTF16
));
15890 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_server_unc_0
, 0);
15892 if (ndr
->flags
& LIBNDR_FLAG_REF_ALLOC
) {
15893 NDR_PULL_ALLOC(ndr
, r
->in
.info_ctr
);
15895 _mem_save_info_ctr_0
= NDR_PULL_GET_MEM_CTX(ndr
);
15896 NDR_PULL_SET_MEM_CTX(ndr
, r
->in
.info_ctr
, LIBNDR_FLAG_REF_ALLOC
);
15897 NDR_CHECK(ndr_pull_srvsvc_NetShareInfoCtr(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->in
.info_ctr
));
15898 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_info_ctr_0
, LIBNDR_FLAG_REF_ALLOC
);
15899 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->in
.max_buffer
));
15900 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_resume_handle
));
15901 if (_ptr_resume_handle
) {
15902 NDR_PULL_ALLOC(ndr
, r
->in
.resume_handle
);
15904 r
->in
.resume_handle
= NULL
;
15906 if (r
->in
.resume_handle
) {
15907 _mem_save_resume_handle_0
= NDR_PULL_GET_MEM_CTX(ndr
);
15908 NDR_PULL_SET_MEM_CTX(ndr
, r
->in
.resume_handle
, 0);
15909 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, r
->in
.resume_handle
));
15910 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_resume_handle_0
, 0);
15912 NDR_PULL_ALLOC(ndr
, r
->out
.info_ctr
);
15913 *r
->out
.info_ctr
= *r
->in
.info_ctr
;
15914 NDR_PULL_ALLOC(ndr
, r
->out
.totalentries
);
15915 ZERO_STRUCTP(r
->out
.totalentries
);
15917 if (flags
& NDR_OUT
) {
15918 if (ndr
->flags
& LIBNDR_FLAG_REF_ALLOC
) {
15919 NDR_PULL_ALLOC(ndr
, r
->out
.info_ctr
);
15921 _mem_save_info_ctr_0
= NDR_PULL_GET_MEM_CTX(ndr
);
15922 NDR_PULL_SET_MEM_CTX(ndr
, r
->out
.info_ctr
, LIBNDR_FLAG_REF_ALLOC
);
15923 NDR_CHECK(ndr_pull_srvsvc_NetShareInfoCtr(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->out
.info_ctr
));
15924 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_info_ctr_0
, LIBNDR_FLAG_REF_ALLOC
);
15925 if (ndr
->flags
& LIBNDR_FLAG_REF_ALLOC
) {
15926 NDR_PULL_ALLOC(ndr
, r
->out
.totalentries
);
15928 _mem_save_totalentries_0
= NDR_PULL_GET_MEM_CTX(ndr
);
15929 NDR_PULL_SET_MEM_CTX(ndr
, r
->out
.totalentries
, LIBNDR_FLAG_REF_ALLOC
);
15930 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, r
->out
.totalentries
));
15931 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_totalentries_0
, LIBNDR_FLAG_REF_ALLOC
);
15932 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_resume_handle
));
15933 if (_ptr_resume_handle
) {
15934 NDR_PULL_ALLOC(ndr
, r
->out
.resume_handle
);
15936 r
->out
.resume_handle
= NULL
;
15938 if (r
->out
.resume_handle
) {
15939 _mem_save_resume_handle_0
= NDR_PULL_GET_MEM_CTX(ndr
);
15940 NDR_PULL_SET_MEM_CTX(ndr
, r
->out
.resume_handle
, 0);
15941 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, r
->out
.resume_handle
));
15942 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_resume_handle_0
, 0);
15944 NDR_CHECK(ndr_pull_WERROR(ndr
, NDR_SCALARS
, &r
->out
.result
));
15946 return NDR_ERR_SUCCESS
;
15949 _PUBLIC_
void ndr_print_srvsvc_NetShareEnumAll(struct ndr_print
*ndr
, const char *name
, int flags
, const struct srvsvc_NetShareEnumAll
*r
)
15951 ndr_print_struct(ndr
, name
, "srvsvc_NetShareEnumAll");
15953 if (flags
& NDR_SET_VALUES
) {
15954 ndr
->flags
|= LIBNDR_PRINT_SET_VALUES
;
15956 if (flags
& NDR_IN
) {
15957 ndr_print_struct(ndr
, "in", "srvsvc_NetShareEnumAll");
15959 ndr_print_ptr(ndr
, "server_unc", r
->in
.server_unc
);
15961 if (r
->in
.server_unc
) {
15962 ndr_print_string(ndr
, "server_unc", r
->in
.server_unc
);
15965 ndr_print_ptr(ndr
, "info_ctr", r
->in
.info_ctr
);
15967 ndr_print_srvsvc_NetShareInfoCtr(ndr
, "info_ctr", r
->in
.info_ctr
);
15969 ndr_print_uint32(ndr
, "max_buffer", r
->in
.max_buffer
);
15970 ndr_print_ptr(ndr
, "resume_handle", r
->in
.resume_handle
);
15972 if (r
->in
.resume_handle
) {
15973 ndr_print_uint32(ndr
, "resume_handle", *r
->in
.resume_handle
);
15978 if (flags
& NDR_OUT
) {
15979 ndr_print_struct(ndr
, "out", "srvsvc_NetShareEnumAll");
15981 ndr_print_ptr(ndr
, "info_ctr", r
->out
.info_ctr
);
15983 ndr_print_srvsvc_NetShareInfoCtr(ndr
, "info_ctr", r
->out
.info_ctr
);
15985 ndr_print_ptr(ndr
, "totalentries", r
->out
.totalentries
);
15987 ndr_print_uint32(ndr
, "totalentries", *r
->out
.totalentries
);
15989 ndr_print_ptr(ndr
, "resume_handle", r
->out
.resume_handle
);
15991 if (r
->out
.resume_handle
) {
15992 ndr_print_uint32(ndr
, "resume_handle", *r
->out
.resume_handle
);
15995 ndr_print_WERROR(ndr
, "result", r
->out
.result
);
16001 static enum ndr_err_code
ndr_push_srvsvc_NetShareGetInfo(struct ndr_push
*ndr
, int flags
, const struct srvsvc_NetShareGetInfo
*r
)
16003 if (flags
& NDR_IN
) {
16004 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->in
.server_unc
));
16005 if (r
->in
.server_unc
) {
16006 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.server_unc
, CH_UTF16
)));
16007 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
16008 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.server_unc
, CH_UTF16
)));
16009 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
));
16011 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.share_name
, CH_UTF16
)));
16012 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
16013 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.share_name
, CH_UTF16
)));
16014 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
));
16015 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->in
.level
));
16017 if (flags
& NDR_OUT
) {
16018 if (r
->out
.info
== NULL
) {
16019 return ndr_push_error(ndr
, NDR_ERR_INVALID_POINTER
, "NULL [ref] pointer");
16021 NDR_CHECK(ndr_push_set_switch_value(ndr
, r
->out
.info
, r
->in
.level
));
16022 NDR_CHECK(ndr_push_srvsvc_NetShareInfo(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->out
.info
));
16023 NDR_CHECK(ndr_push_WERROR(ndr
, NDR_SCALARS
, r
->out
.result
));
16025 return NDR_ERR_SUCCESS
;
16028 static enum ndr_err_code
ndr_pull_srvsvc_NetShareGetInfo(struct ndr_pull
*ndr
, int flags
, struct srvsvc_NetShareGetInfo
*r
)
16030 uint32_t _ptr_server_unc
;
16031 uint32_t size_server_unc_1
= 0;
16032 uint32_t length_server_unc_1
= 0;
16033 uint32_t size_share_name_0
= 0;
16034 uint32_t length_share_name_0
= 0;
16035 TALLOC_CTX
*_mem_save_server_unc_0
;
16036 TALLOC_CTX
*_mem_save_info_0
;
16037 if (flags
& NDR_IN
) {
16038 ZERO_STRUCT(r
->out
);
16040 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_server_unc
));
16041 if (_ptr_server_unc
) {
16042 NDR_PULL_ALLOC(ndr
, r
->in
.server_unc
);
16044 r
->in
.server_unc
= NULL
;
16046 if (r
->in
.server_unc
) {
16047 _mem_save_server_unc_0
= NDR_PULL_GET_MEM_CTX(ndr
);
16048 NDR_PULL_SET_MEM_CTX(ndr
, r
->in
.server_unc
, 0);
16049 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->in
.server_unc
));
16050 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->in
.server_unc
));
16051 size_server_unc_1
= ndr_get_array_size(ndr
, &r
->in
.server_unc
);
16052 length_server_unc_1
= ndr_get_array_length(ndr
, &r
->in
.server_unc
);
16053 if (length_server_unc_1
> size_server_unc_1
) {
16054 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", size_server_unc_1
, length_server_unc_1
);
16056 NDR_CHECK(ndr_check_string_terminator(ndr
, length_server_unc_1
, sizeof(uint16_t)));
16057 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->in
.server_unc
, length_server_unc_1
, sizeof(uint16_t), CH_UTF16
));
16058 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_server_unc_0
, 0);
16060 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->in
.share_name
));
16061 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->in
.share_name
));
16062 size_share_name_0
= ndr_get_array_size(ndr
, &r
->in
.share_name
);
16063 length_share_name_0
= ndr_get_array_length(ndr
, &r
->in
.share_name
);
16064 if (length_share_name_0
> size_share_name_0
) {
16065 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", size_share_name_0
, length_share_name_0
);
16067 NDR_CHECK(ndr_check_string_terminator(ndr
, length_share_name_0
, sizeof(uint16_t)));
16068 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->in
.share_name
, length_share_name_0
, sizeof(uint16_t), CH_UTF16
));
16069 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->in
.level
));
16070 NDR_PULL_ALLOC(ndr
, r
->out
.info
);
16071 ZERO_STRUCTP(r
->out
.info
);
16073 if (flags
& NDR_OUT
) {
16074 if (ndr
->flags
& LIBNDR_FLAG_REF_ALLOC
) {
16075 NDR_PULL_ALLOC(ndr
, r
->out
.info
);
16077 _mem_save_info_0
= NDR_PULL_GET_MEM_CTX(ndr
);
16078 NDR_PULL_SET_MEM_CTX(ndr
, r
->out
.info
, LIBNDR_FLAG_REF_ALLOC
);
16079 NDR_CHECK(ndr_pull_set_switch_value(ndr
, r
->out
.info
, r
->in
.level
));
16080 NDR_CHECK(ndr_pull_srvsvc_NetShareInfo(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->out
.info
));
16081 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_info_0
, LIBNDR_FLAG_REF_ALLOC
);
16082 NDR_CHECK(ndr_pull_WERROR(ndr
, NDR_SCALARS
, &r
->out
.result
));
16084 return NDR_ERR_SUCCESS
;
16087 _PUBLIC_
void ndr_print_srvsvc_NetShareGetInfo(struct ndr_print
*ndr
, const char *name
, int flags
, const struct srvsvc_NetShareGetInfo
*r
)
16089 ndr_print_struct(ndr
, name
, "srvsvc_NetShareGetInfo");
16091 if (flags
& NDR_SET_VALUES
) {
16092 ndr
->flags
|= LIBNDR_PRINT_SET_VALUES
;
16094 if (flags
& NDR_IN
) {
16095 ndr_print_struct(ndr
, "in", "srvsvc_NetShareGetInfo");
16097 ndr_print_ptr(ndr
, "server_unc", r
->in
.server_unc
);
16099 if (r
->in
.server_unc
) {
16100 ndr_print_string(ndr
, "server_unc", r
->in
.server_unc
);
16103 ndr_print_string(ndr
, "share_name", r
->in
.share_name
);
16104 ndr_print_uint32(ndr
, "level", r
->in
.level
);
16107 if (flags
& NDR_OUT
) {
16108 ndr_print_struct(ndr
, "out", "srvsvc_NetShareGetInfo");
16110 ndr_print_ptr(ndr
, "info", r
->out
.info
);
16112 ndr_print_set_switch_value(ndr
, r
->out
.info
, r
->in
.level
);
16113 ndr_print_srvsvc_NetShareInfo(ndr
, "info", r
->out
.info
);
16115 ndr_print_WERROR(ndr
, "result", r
->out
.result
);
16121 static enum ndr_err_code
ndr_push_srvsvc_NetShareSetInfo(struct ndr_push
*ndr
, int flags
, const struct srvsvc_NetShareSetInfo
*r
)
16123 if (flags
& NDR_IN
) {
16124 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->in
.server_unc
));
16125 if (r
->in
.server_unc
) {
16126 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.server_unc
, CH_UTF16
)));
16127 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
16128 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.server_unc
, CH_UTF16
)));
16129 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
));
16131 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.share_name
, CH_UTF16
)));
16132 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
16133 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.share_name
, CH_UTF16
)));
16134 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
));
16135 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->in
.level
));
16136 if (r
->in
.info
== NULL
) {
16137 return ndr_push_error(ndr
, NDR_ERR_INVALID_POINTER
, "NULL [ref] pointer");
16139 NDR_CHECK(ndr_push_set_switch_value(ndr
, r
->in
.info
, r
->in
.level
));
16140 NDR_CHECK(ndr_push_srvsvc_NetShareInfo(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->in
.info
));
16141 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->in
.parm_error
));
16142 if (r
->in
.parm_error
) {
16143 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, *r
->in
.parm_error
));
16146 if (flags
& NDR_OUT
) {
16147 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->out
.parm_error
));
16148 if (r
->out
.parm_error
) {
16149 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, *r
->out
.parm_error
));
16151 NDR_CHECK(ndr_push_WERROR(ndr
, NDR_SCALARS
, r
->out
.result
));
16153 return NDR_ERR_SUCCESS
;
16156 static enum ndr_err_code
ndr_pull_srvsvc_NetShareSetInfo(struct ndr_pull
*ndr
, int flags
, struct srvsvc_NetShareSetInfo
*r
)
16158 uint32_t _ptr_server_unc
;
16159 uint32_t size_server_unc_1
= 0;
16160 uint32_t length_server_unc_1
= 0;
16161 uint32_t size_share_name_0
= 0;
16162 uint32_t length_share_name_0
= 0;
16163 uint32_t _ptr_parm_error
;
16164 TALLOC_CTX
*_mem_save_server_unc_0
;
16165 TALLOC_CTX
*_mem_save_info_0
;
16166 TALLOC_CTX
*_mem_save_parm_error_0
;
16167 if (flags
& NDR_IN
) {
16168 ZERO_STRUCT(r
->out
);
16170 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_server_unc
));
16171 if (_ptr_server_unc
) {
16172 NDR_PULL_ALLOC(ndr
, r
->in
.server_unc
);
16174 r
->in
.server_unc
= NULL
;
16176 if (r
->in
.server_unc
) {
16177 _mem_save_server_unc_0
= NDR_PULL_GET_MEM_CTX(ndr
);
16178 NDR_PULL_SET_MEM_CTX(ndr
, r
->in
.server_unc
, 0);
16179 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->in
.server_unc
));
16180 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->in
.server_unc
));
16181 size_server_unc_1
= ndr_get_array_size(ndr
, &r
->in
.server_unc
);
16182 length_server_unc_1
= ndr_get_array_length(ndr
, &r
->in
.server_unc
);
16183 if (length_server_unc_1
> size_server_unc_1
) {
16184 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", size_server_unc_1
, length_server_unc_1
);
16186 NDR_CHECK(ndr_check_string_terminator(ndr
, length_server_unc_1
, sizeof(uint16_t)));
16187 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->in
.server_unc
, length_server_unc_1
, sizeof(uint16_t), CH_UTF16
));
16188 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_server_unc_0
, 0);
16190 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->in
.share_name
));
16191 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->in
.share_name
));
16192 size_share_name_0
= ndr_get_array_size(ndr
, &r
->in
.share_name
);
16193 length_share_name_0
= ndr_get_array_length(ndr
, &r
->in
.share_name
);
16194 if (length_share_name_0
> size_share_name_0
) {
16195 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", size_share_name_0
, length_share_name_0
);
16197 NDR_CHECK(ndr_check_string_terminator(ndr
, length_share_name_0
, sizeof(uint16_t)));
16198 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->in
.share_name
, length_share_name_0
, sizeof(uint16_t), CH_UTF16
));
16199 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->in
.level
));
16200 if (ndr
->flags
& LIBNDR_FLAG_REF_ALLOC
) {
16201 NDR_PULL_ALLOC(ndr
, r
->in
.info
);
16203 _mem_save_info_0
= NDR_PULL_GET_MEM_CTX(ndr
);
16204 NDR_PULL_SET_MEM_CTX(ndr
, r
->in
.info
, LIBNDR_FLAG_REF_ALLOC
);
16205 NDR_CHECK(ndr_pull_set_switch_value(ndr
, r
->in
.info
, r
->in
.level
));
16206 NDR_CHECK(ndr_pull_srvsvc_NetShareInfo(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->in
.info
));
16207 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_info_0
, LIBNDR_FLAG_REF_ALLOC
);
16208 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_parm_error
));
16209 if (_ptr_parm_error
) {
16210 NDR_PULL_ALLOC(ndr
, r
->in
.parm_error
);
16212 r
->in
.parm_error
= NULL
;
16214 if (r
->in
.parm_error
) {
16215 _mem_save_parm_error_0
= NDR_PULL_GET_MEM_CTX(ndr
);
16216 NDR_PULL_SET_MEM_CTX(ndr
, r
->in
.parm_error
, 0);
16217 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, r
->in
.parm_error
));
16218 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_parm_error_0
, 0);
16221 if (flags
& NDR_OUT
) {
16222 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_parm_error
));
16223 if (_ptr_parm_error
) {
16224 NDR_PULL_ALLOC(ndr
, r
->out
.parm_error
);
16226 r
->out
.parm_error
= NULL
;
16228 if (r
->out
.parm_error
) {
16229 _mem_save_parm_error_0
= NDR_PULL_GET_MEM_CTX(ndr
);
16230 NDR_PULL_SET_MEM_CTX(ndr
, r
->out
.parm_error
, 0);
16231 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, r
->out
.parm_error
));
16232 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_parm_error_0
, 0);
16234 NDR_CHECK(ndr_pull_WERROR(ndr
, NDR_SCALARS
, &r
->out
.result
));
16236 return NDR_ERR_SUCCESS
;
16239 _PUBLIC_
void ndr_print_srvsvc_NetShareSetInfo(struct ndr_print
*ndr
, const char *name
, int flags
, const struct srvsvc_NetShareSetInfo
*r
)
16241 ndr_print_struct(ndr
, name
, "srvsvc_NetShareSetInfo");
16243 if (flags
& NDR_SET_VALUES
) {
16244 ndr
->flags
|= LIBNDR_PRINT_SET_VALUES
;
16246 if (flags
& NDR_IN
) {
16247 ndr_print_struct(ndr
, "in", "srvsvc_NetShareSetInfo");
16249 ndr_print_ptr(ndr
, "server_unc", r
->in
.server_unc
);
16251 if (r
->in
.server_unc
) {
16252 ndr_print_string(ndr
, "server_unc", r
->in
.server_unc
);
16255 ndr_print_string(ndr
, "share_name", r
->in
.share_name
);
16256 ndr_print_uint32(ndr
, "level", r
->in
.level
);
16257 ndr_print_ptr(ndr
, "info", r
->in
.info
);
16259 ndr_print_set_switch_value(ndr
, r
->in
.info
, r
->in
.level
);
16260 ndr_print_srvsvc_NetShareInfo(ndr
, "info", r
->in
.info
);
16262 ndr_print_ptr(ndr
, "parm_error", r
->in
.parm_error
);
16264 if (r
->in
.parm_error
) {
16265 ndr_print_uint32(ndr
, "parm_error", *r
->in
.parm_error
);
16270 if (flags
& NDR_OUT
) {
16271 ndr_print_struct(ndr
, "out", "srvsvc_NetShareSetInfo");
16273 ndr_print_ptr(ndr
, "parm_error", r
->out
.parm_error
);
16275 if (r
->out
.parm_error
) {
16276 ndr_print_uint32(ndr
, "parm_error", *r
->out
.parm_error
);
16279 ndr_print_WERROR(ndr
, "result", r
->out
.result
);
16285 static enum ndr_err_code
ndr_push_srvsvc_NetShareDel(struct ndr_push
*ndr
, int flags
, const struct srvsvc_NetShareDel
*r
)
16287 if (flags
& NDR_IN
) {
16288 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->in
.server_unc
));
16289 if (r
->in
.server_unc
) {
16290 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.server_unc
, CH_UTF16
)));
16291 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
16292 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.server_unc
, CH_UTF16
)));
16293 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
));
16295 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.share_name
, CH_UTF16
)));
16296 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
16297 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.share_name
, CH_UTF16
)));
16298 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
));
16299 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->in
.reserved
));
16301 if (flags
& NDR_OUT
) {
16302 NDR_CHECK(ndr_push_WERROR(ndr
, NDR_SCALARS
, r
->out
.result
));
16304 return NDR_ERR_SUCCESS
;
16307 static enum ndr_err_code
ndr_pull_srvsvc_NetShareDel(struct ndr_pull
*ndr
, int flags
, struct srvsvc_NetShareDel
*r
)
16309 uint32_t _ptr_server_unc
;
16310 uint32_t size_server_unc_1
= 0;
16311 uint32_t length_server_unc_1
= 0;
16312 uint32_t size_share_name_0
= 0;
16313 uint32_t length_share_name_0
= 0;
16314 TALLOC_CTX
*_mem_save_server_unc_0
;
16315 if (flags
& NDR_IN
) {
16316 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_server_unc
));
16317 if (_ptr_server_unc
) {
16318 NDR_PULL_ALLOC(ndr
, r
->in
.server_unc
);
16320 r
->in
.server_unc
= NULL
;
16322 if (r
->in
.server_unc
) {
16323 _mem_save_server_unc_0
= NDR_PULL_GET_MEM_CTX(ndr
);
16324 NDR_PULL_SET_MEM_CTX(ndr
, r
->in
.server_unc
, 0);
16325 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->in
.server_unc
));
16326 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->in
.server_unc
));
16327 size_server_unc_1
= ndr_get_array_size(ndr
, &r
->in
.server_unc
);
16328 length_server_unc_1
= ndr_get_array_length(ndr
, &r
->in
.server_unc
);
16329 if (length_server_unc_1
> size_server_unc_1
) {
16330 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", size_server_unc_1
, length_server_unc_1
);
16332 NDR_CHECK(ndr_check_string_terminator(ndr
, length_server_unc_1
, sizeof(uint16_t)));
16333 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->in
.server_unc
, length_server_unc_1
, sizeof(uint16_t), CH_UTF16
));
16334 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_server_unc_0
, 0);
16336 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->in
.share_name
));
16337 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->in
.share_name
));
16338 size_share_name_0
= ndr_get_array_size(ndr
, &r
->in
.share_name
);
16339 length_share_name_0
= ndr_get_array_length(ndr
, &r
->in
.share_name
);
16340 if (length_share_name_0
> size_share_name_0
) {
16341 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", size_share_name_0
, length_share_name_0
);
16343 NDR_CHECK(ndr_check_string_terminator(ndr
, length_share_name_0
, sizeof(uint16_t)));
16344 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->in
.share_name
, length_share_name_0
, sizeof(uint16_t), CH_UTF16
));
16345 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->in
.reserved
));
16347 if (flags
& NDR_OUT
) {
16348 NDR_CHECK(ndr_pull_WERROR(ndr
, NDR_SCALARS
, &r
->out
.result
));
16350 return NDR_ERR_SUCCESS
;
16353 _PUBLIC_
void ndr_print_srvsvc_NetShareDel(struct ndr_print
*ndr
, const char *name
, int flags
, const struct srvsvc_NetShareDel
*r
)
16355 ndr_print_struct(ndr
, name
, "srvsvc_NetShareDel");
16357 if (flags
& NDR_SET_VALUES
) {
16358 ndr
->flags
|= LIBNDR_PRINT_SET_VALUES
;
16360 if (flags
& NDR_IN
) {
16361 ndr_print_struct(ndr
, "in", "srvsvc_NetShareDel");
16363 ndr_print_ptr(ndr
, "server_unc", r
->in
.server_unc
);
16365 if (r
->in
.server_unc
) {
16366 ndr_print_string(ndr
, "server_unc", r
->in
.server_unc
);
16369 ndr_print_string(ndr
, "share_name", r
->in
.share_name
);
16370 ndr_print_uint32(ndr
, "reserved", r
->in
.reserved
);
16373 if (flags
& NDR_OUT
) {
16374 ndr_print_struct(ndr
, "out", "srvsvc_NetShareDel");
16376 ndr_print_WERROR(ndr
, "result", r
->out
.result
);
16382 static enum ndr_err_code
ndr_push_srvsvc_NetShareDelSticky(struct ndr_push
*ndr
, int flags
, const struct srvsvc_NetShareDelSticky
*r
)
16384 if (flags
& NDR_IN
) {
16385 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->in
.server_unc
));
16386 if (r
->in
.server_unc
) {
16387 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.server_unc
, CH_UTF16
)));
16388 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
16389 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.server_unc
, CH_UTF16
)));
16390 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
));
16392 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.share_name
, CH_UTF16
)));
16393 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
16394 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.share_name
, CH_UTF16
)));
16395 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
));
16396 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->in
.reserved
));
16398 if (flags
& NDR_OUT
) {
16399 NDR_CHECK(ndr_push_WERROR(ndr
, NDR_SCALARS
, r
->out
.result
));
16401 return NDR_ERR_SUCCESS
;
16404 static enum ndr_err_code
ndr_pull_srvsvc_NetShareDelSticky(struct ndr_pull
*ndr
, int flags
, struct srvsvc_NetShareDelSticky
*r
)
16406 uint32_t _ptr_server_unc
;
16407 uint32_t size_server_unc_1
= 0;
16408 uint32_t length_server_unc_1
= 0;
16409 uint32_t size_share_name_0
= 0;
16410 uint32_t length_share_name_0
= 0;
16411 TALLOC_CTX
*_mem_save_server_unc_0
;
16412 if (flags
& NDR_IN
) {
16413 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_server_unc
));
16414 if (_ptr_server_unc
) {
16415 NDR_PULL_ALLOC(ndr
, r
->in
.server_unc
);
16417 r
->in
.server_unc
= NULL
;
16419 if (r
->in
.server_unc
) {
16420 _mem_save_server_unc_0
= NDR_PULL_GET_MEM_CTX(ndr
);
16421 NDR_PULL_SET_MEM_CTX(ndr
, r
->in
.server_unc
, 0);
16422 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->in
.server_unc
));
16423 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->in
.server_unc
));
16424 size_server_unc_1
= ndr_get_array_size(ndr
, &r
->in
.server_unc
);
16425 length_server_unc_1
= ndr_get_array_length(ndr
, &r
->in
.server_unc
);
16426 if (length_server_unc_1
> size_server_unc_1
) {
16427 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", size_server_unc_1
, length_server_unc_1
);
16429 NDR_CHECK(ndr_check_string_terminator(ndr
, length_server_unc_1
, sizeof(uint16_t)));
16430 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->in
.server_unc
, length_server_unc_1
, sizeof(uint16_t), CH_UTF16
));
16431 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_server_unc_0
, 0);
16433 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->in
.share_name
));
16434 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->in
.share_name
));
16435 size_share_name_0
= ndr_get_array_size(ndr
, &r
->in
.share_name
);
16436 length_share_name_0
= ndr_get_array_length(ndr
, &r
->in
.share_name
);
16437 if (length_share_name_0
> size_share_name_0
) {
16438 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", size_share_name_0
, length_share_name_0
);
16440 NDR_CHECK(ndr_check_string_terminator(ndr
, length_share_name_0
, sizeof(uint16_t)));
16441 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->in
.share_name
, length_share_name_0
, sizeof(uint16_t), CH_UTF16
));
16442 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->in
.reserved
));
16444 if (flags
& NDR_OUT
) {
16445 NDR_CHECK(ndr_pull_WERROR(ndr
, NDR_SCALARS
, &r
->out
.result
));
16447 return NDR_ERR_SUCCESS
;
16450 _PUBLIC_
void ndr_print_srvsvc_NetShareDelSticky(struct ndr_print
*ndr
, const char *name
, int flags
, const struct srvsvc_NetShareDelSticky
*r
)
16452 ndr_print_struct(ndr
, name
, "srvsvc_NetShareDelSticky");
16454 if (flags
& NDR_SET_VALUES
) {
16455 ndr
->flags
|= LIBNDR_PRINT_SET_VALUES
;
16457 if (flags
& NDR_IN
) {
16458 ndr_print_struct(ndr
, "in", "srvsvc_NetShareDelSticky");
16460 ndr_print_ptr(ndr
, "server_unc", r
->in
.server_unc
);
16462 if (r
->in
.server_unc
) {
16463 ndr_print_string(ndr
, "server_unc", r
->in
.server_unc
);
16466 ndr_print_string(ndr
, "share_name", r
->in
.share_name
);
16467 ndr_print_uint32(ndr
, "reserved", r
->in
.reserved
);
16470 if (flags
& NDR_OUT
) {
16471 ndr_print_struct(ndr
, "out", "srvsvc_NetShareDelSticky");
16473 ndr_print_WERROR(ndr
, "result", r
->out
.result
);
16479 static enum ndr_err_code
ndr_push_srvsvc_NetShareCheck(struct ndr_push
*ndr
, int flags
, const struct srvsvc_NetShareCheck
*r
)
16481 if (flags
& NDR_IN
) {
16482 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->in
.server_unc
));
16483 if (r
->in
.server_unc
) {
16484 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.server_unc
, CH_UTF16
)));
16485 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
16486 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.server_unc
, CH_UTF16
)));
16487 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
));
16489 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.device_name
, CH_UTF16
)));
16490 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
16491 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.device_name
, CH_UTF16
)));
16492 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
));
16494 if (flags
& NDR_OUT
) {
16495 if (r
->out
.type
== NULL
) {
16496 return ndr_push_error(ndr
, NDR_ERR_INVALID_POINTER
, "NULL [ref] pointer");
16498 NDR_CHECK(ndr_push_srvsvc_ShareType(ndr
, NDR_SCALARS
, *r
->out
.type
));
16499 NDR_CHECK(ndr_push_WERROR(ndr
, NDR_SCALARS
, r
->out
.result
));
16501 return NDR_ERR_SUCCESS
;
16504 static enum ndr_err_code
ndr_pull_srvsvc_NetShareCheck(struct ndr_pull
*ndr
, int flags
, struct srvsvc_NetShareCheck
*r
)
16506 uint32_t _ptr_server_unc
;
16507 uint32_t size_server_unc_1
= 0;
16508 uint32_t length_server_unc_1
= 0;
16509 uint32_t size_device_name_0
= 0;
16510 uint32_t length_device_name_0
= 0;
16511 TALLOC_CTX
*_mem_save_server_unc_0
;
16512 TALLOC_CTX
*_mem_save_type_0
;
16513 if (flags
& NDR_IN
) {
16514 ZERO_STRUCT(r
->out
);
16516 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_server_unc
));
16517 if (_ptr_server_unc
) {
16518 NDR_PULL_ALLOC(ndr
, r
->in
.server_unc
);
16520 r
->in
.server_unc
= NULL
;
16522 if (r
->in
.server_unc
) {
16523 _mem_save_server_unc_0
= NDR_PULL_GET_MEM_CTX(ndr
);
16524 NDR_PULL_SET_MEM_CTX(ndr
, r
->in
.server_unc
, 0);
16525 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->in
.server_unc
));
16526 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->in
.server_unc
));
16527 size_server_unc_1
= ndr_get_array_size(ndr
, &r
->in
.server_unc
);
16528 length_server_unc_1
= ndr_get_array_length(ndr
, &r
->in
.server_unc
);
16529 if (length_server_unc_1
> size_server_unc_1
) {
16530 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", size_server_unc_1
, length_server_unc_1
);
16532 NDR_CHECK(ndr_check_string_terminator(ndr
, length_server_unc_1
, sizeof(uint16_t)));
16533 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->in
.server_unc
, length_server_unc_1
, sizeof(uint16_t), CH_UTF16
));
16534 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_server_unc_0
, 0);
16536 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->in
.device_name
));
16537 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->in
.device_name
));
16538 size_device_name_0
= ndr_get_array_size(ndr
, &r
->in
.device_name
);
16539 length_device_name_0
= ndr_get_array_length(ndr
, &r
->in
.device_name
);
16540 if (length_device_name_0
> size_device_name_0
) {
16541 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", size_device_name_0
, length_device_name_0
);
16543 NDR_CHECK(ndr_check_string_terminator(ndr
, length_device_name_0
, sizeof(uint16_t)));
16544 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->in
.device_name
, length_device_name_0
, sizeof(uint16_t), CH_UTF16
));
16545 NDR_PULL_ALLOC(ndr
, r
->out
.type
);
16546 ZERO_STRUCTP(r
->out
.type
);
16548 if (flags
& NDR_OUT
) {
16549 if (ndr
->flags
& LIBNDR_FLAG_REF_ALLOC
) {
16550 NDR_PULL_ALLOC(ndr
, r
->out
.type
);
16552 _mem_save_type_0
= NDR_PULL_GET_MEM_CTX(ndr
);
16553 NDR_PULL_SET_MEM_CTX(ndr
, r
->out
.type
, LIBNDR_FLAG_REF_ALLOC
);
16554 NDR_CHECK(ndr_pull_srvsvc_ShareType(ndr
, NDR_SCALARS
, r
->out
.type
));
16555 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_type_0
, LIBNDR_FLAG_REF_ALLOC
);
16556 NDR_CHECK(ndr_pull_WERROR(ndr
, NDR_SCALARS
, &r
->out
.result
));
16558 return NDR_ERR_SUCCESS
;
16561 _PUBLIC_
void ndr_print_srvsvc_NetShareCheck(struct ndr_print
*ndr
, const char *name
, int flags
, const struct srvsvc_NetShareCheck
*r
)
16563 ndr_print_struct(ndr
, name
, "srvsvc_NetShareCheck");
16565 if (flags
& NDR_SET_VALUES
) {
16566 ndr
->flags
|= LIBNDR_PRINT_SET_VALUES
;
16568 if (flags
& NDR_IN
) {
16569 ndr_print_struct(ndr
, "in", "srvsvc_NetShareCheck");
16571 ndr_print_ptr(ndr
, "server_unc", r
->in
.server_unc
);
16573 if (r
->in
.server_unc
) {
16574 ndr_print_string(ndr
, "server_unc", r
->in
.server_unc
);
16577 ndr_print_string(ndr
, "device_name", r
->in
.device_name
);
16580 if (flags
& NDR_OUT
) {
16581 ndr_print_struct(ndr
, "out", "srvsvc_NetShareCheck");
16583 ndr_print_ptr(ndr
, "type", r
->out
.type
);
16585 ndr_print_srvsvc_ShareType(ndr
, "type", *r
->out
.type
);
16587 ndr_print_WERROR(ndr
, "result", r
->out
.result
);
16593 static enum ndr_err_code
ndr_push_srvsvc_NetSrvGetInfo(struct ndr_push
*ndr
, int flags
, const struct srvsvc_NetSrvGetInfo
*r
)
16595 if (flags
& NDR_IN
) {
16596 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->in
.server_unc
));
16597 if (r
->in
.server_unc
) {
16598 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.server_unc
, CH_UTF16
)));
16599 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
16600 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.server_unc
, CH_UTF16
)));
16601 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
));
16603 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->in
.level
));
16605 if (flags
& NDR_OUT
) {
16606 if (r
->out
.info
== NULL
) {
16607 return ndr_push_error(ndr
, NDR_ERR_INVALID_POINTER
, "NULL [ref] pointer");
16609 NDR_CHECK(ndr_push_set_switch_value(ndr
, r
->out
.info
, r
->in
.level
));
16610 NDR_CHECK(ndr_push_srvsvc_NetSrvInfo(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->out
.info
));
16611 NDR_CHECK(ndr_push_WERROR(ndr
, NDR_SCALARS
, r
->out
.result
));
16613 return NDR_ERR_SUCCESS
;
16616 static enum ndr_err_code
ndr_pull_srvsvc_NetSrvGetInfo(struct ndr_pull
*ndr
, int flags
, struct srvsvc_NetSrvGetInfo
*r
)
16618 uint32_t _ptr_server_unc
;
16619 uint32_t size_server_unc_1
= 0;
16620 uint32_t length_server_unc_1
= 0;
16621 TALLOC_CTX
*_mem_save_server_unc_0
;
16622 TALLOC_CTX
*_mem_save_info_0
;
16623 if (flags
& NDR_IN
) {
16624 ZERO_STRUCT(r
->out
);
16626 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_server_unc
));
16627 if (_ptr_server_unc
) {
16628 NDR_PULL_ALLOC(ndr
, r
->in
.server_unc
);
16630 r
->in
.server_unc
= NULL
;
16632 if (r
->in
.server_unc
) {
16633 _mem_save_server_unc_0
= NDR_PULL_GET_MEM_CTX(ndr
);
16634 NDR_PULL_SET_MEM_CTX(ndr
, r
->in
.server_unc
, 0);
16635 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->in
.server_unc
));
16636 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->in
.server_unc
));
16637 size_server_unc_1
= ndr_get_array_size(ndr
, &r
->in
.server_unc
);
16638 length_server_unc_1
= ndr_get_array_length(ndr
, &r
->in
.server_unc
);
16639 if (length_server_unc_1
> size_server_unc_1
) {
16640 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", size_server_unc_1
, length_server_unc_1
);
16642 NDR_CHECK(ndr_check_string_terminator(ndr
, length_server_unc_1
, sizeof(uint16_t)));
16643 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->in
.server_unc
, length_server_unc_1
, sizeof(uint16_t), CH_UTF16
));
16644 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_server_unc_0
, 0);
16646 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->in
.level
));
16647 NDR_PULL_ALLOC(ndr
, r
->out
.info
);
16648 ZERO_STRUCTP(r
->out
.info
);
16650 if (flags
& NDR_OUT
) {
16651 if (ndr
->flags
& LIBNDR_FLAG_REF_ALLOC
) {
16652 NDR_PULL_ALLOC(ndr
, r
->out
.info
);
16654 _mem_save_info_0
= NDR_PULL_GET_MEM_CTX(ndr
);
16655 NDR_PULL_SET_MEM_CTX(ndr
, r
->out
.info
, LIBNDR_FLAG_REF_ALLOC
);
16656 NDR_CHECK(ndr_pull_set_switch_value(ndr
, r
->out
.info
, r
->in
.level
));
16657 NDR_CHECK(ndr_pull_srvsvc_NetSrvInfo(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->out
.info
));
16658 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_info_0
, LIBNDR_FLAG_REF_ALLOC
);
16659 NDR_CHECK(ndr_pull_WERROR(ndr
, NDR_SCALARS
, &r
->out
.result
));
16661 return NDR_ERR_SUCCESS
;
16664 _PUBLIC_
void ndr_print_srvsvc_NetSrvGetInfo(struct ndr_print
*ndr
, const char *name
, int flags
, const struct srvsvc_NetSrvGetInfo
*r
)
16666 ndr_print_struct(ndr
, name
, "srvsvc_NetSrvGetInfo");
16668 if (flags
& NDR_SET_VALUES
) {
16669 ndr
->flags
|= LIBNDR_PRINT_SET_VALUES
;
16671 if (flags
& NDR_IN
) {
16672 ndr_print_struct(ndr
, "in", "srvsvc_NetSrvGetInfo");
16674 ndr_print_ptr(ndr
, "server_unc", r
->in
.server_unc
);
16676 if (r
->in
.server_unc
) {
16677 ndr_print_string(ndr
, "server_unc", r
->in
.server_unc
);
16680 ndr_print_uint32(ndr
, "level", r
->in
.level
);
16683 if (flags
& NDR_OUT
) {
16684 ndr_print_struct(ndr
, "out", "srvsvc_NetSrvGetInfo");
16686 ndr_print_ptr(ndr
, "info", r
->out
.info
);
16688 ndr_print_set_switch_value(ndr
, r
->out
.info
, r
->in
.level
);
16689 ndr_print_srvsvc_NetSrvInfo(ndr
, "info", r
->out
.info
);
16691 ndr_print_WERROR(ndr
, "result", r
->out
.result
);
16697 static enum ndr_err_code
ndr_push_srvsvc_NetSrvSetInfo(struct ndr_push
*ndr
, int flags
, const struct srvsvc_NetSrvSetInfo
*r
)
16699 if (flags
& NDR_IN
) {
16700 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->in
.server_unc
));
16701 if (r
->in
.server_unc
) {
16702 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.server_unc
, CH_UTF16
)));
16703 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
16704 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.server_unc
, CH_UTF16
)));
16705 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
));
16707 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->in
.level
));
16708 if (r
->in
.info
== NULL
) {
16709 return ndr_push_error(ndr
, NDR_ERR_INVALID_POINTER
, "NULL [ref] pointer");
16711 NDR_CHECK(ndr_push_set_switch_value(ndr
, r
->in
.info
, r
->in
.level
));
16712 NDR_CHECK(ndr_push_srvsvc_NetSrvInfo(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->in
.info
));
16713 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->in
.parm_error
));
16714 if (r
->in
.parm_error
) {
16715 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, *r
->in
.parm_error
));
16718 if (flags
& NDR_OUT
) {
16719 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->out
.parm_error
));
16720 if (r
->out
.parm_error
) {
16721 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, *r
->out
.parm_error
));
16723 NDR_CHECK(ndr_push_WERROR(ndr
, NDR_SCALARS
, r
->out
.result
));
16725 return NDR_ERR_SUCCESS
;
16728 static enum ndr_err_code
ndr_pull_srvsvc_NetSrvSetInfo(struct ndr_pull
*ndr
, int flags
, struct srvsvc_NetSrvSetInfo
*r
)
16730 uint32_t _ptr_server_unc
;
16731 uint32_t size_server_unc_1
= 0;
16732 uint32_t length_server_unc_1
= 0;
16733 uint32_t _ptr_parm_error
;
16734 TALLOC_CTX
*_mem_save_server_unc_0
;
16735 TALLOC_CTX
*_mem_save_info_0
;
16736 TALLOC_CTX
*_mem_save_parm_error_0
;
16737 if (flags
& NDR_IN
) {
16738 ZERO_STRUCT(r
->out
);
16740 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_server_unc
));
16741 if (_ptr_server_unc
) {
16742 NDR_PULL_ALLOC(ndr
, r
->in
.server_unc
);
16744 r
->in
.server_unc
= NULL
;
16746 if (r
->in
.server_unc
) {
16747 _mem_save_server_unc_0
= NDR_PULL_GET_MEM_CTX(ndr
);
16748 NDR_PULL_SET_MEM_CTX(ndr
, r
->in
.server_unc
, 0);
16749 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->in
.server_unc
));
16750 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->in
.server_unc
));
16751 size_server_unc_1
= ndr_get_array_size(ndr
, &r
->in
.server_unc
);
16752 length_server_unc_1
= ndr_get_array_length(ndr
, &r
->in
.server_unc
);
16753 if (length_server_unc_1
> size_server_unc_1
) {
16754 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", size_server_unc_1
, length_server_unc_1
);
16756 NDR_CHECK(ndr_check_string_terminator(ndr
, length_server_unc_1
, sizeof(uint16_t)));
16757 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->in
.server_unc
, length_server_unc_1
, sizeof(uint16_t), CH_UTF16
));
16758 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_server_unc_0
, 0);
16760 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->in
.level
));
16761 if (ndr
->flags
& LIBNDR_FLAG_REF_ALLOC
) {
16762 NDR_PULL_ALLOC(ndr
, r
->in
.info
);
16764 _mem_save_info_0
= NDR_PULL_GET_MEM_CTX(ndr
);
16765 NDR_PULL_SET_MEM_CTX(ndr
, r
->in
.info
, LIBNDR_FLAG_REF_ALLOC
);
16766 NDR_CHECK(ndr_pull_set_switch_value(ndr
, r
->in
.info
, r
->in
.level
));
16767 NDR_CHECK(ndr_pull_srvsvc_NetSrvInfo(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->in
.info
));
16768 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_info_0
, LIBNDR_FLAG_REF_ALLOC
);
16769 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_parm_error
));
16770 if (_ptr_parm_error
) {
16771 NDR_PULL_ALLOC(ndr
, r
->in
.parm_error
);
16773 r
->in
.parm_error
= NULL
;
16775 if (r
->in
.parm_error
) {
16776 _mem_save_parm_error_0
= NDR_PULL_GET_MEM_CTX(ndr
);
16777 NDR_PULL_SET_MEM_CTX(ndr
, r
->in
.parm_error
, 0);
16778 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, r
->in
.parm_error
));
16779 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_parm_error_0
, 0);
16782 if (flags
& NDR_OUT
) {
16783 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_parm_error
));
16784 if (_ptr_parm_error
) {
16785 NDR_PULL_ALLOC(ndr
, r
->out
.parm_error
);
16787 r
->out
.parm_error
= NULL
;
16789 if (r
->out
.parm_error
) {
16790 _mem_save_parm_error_0
= NDR_PULL_GET_MEM_CTX(ndr
);
16791 NDR_PULL_SET_MEM_CTX(ndr
, r
->out
.parm_error
, 0);
16792 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, r
->out
.parm_error
));
16793 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_parm_error_0
, 0);
16795 NDR_CHECK(ndr_pull_WERROR(ndr
, NDR_SCALARS
, &r
->out
.result
));
16797 return NDR_ERR_SUCCESS
;
16800 _PUBLIC_
void ndr_print_srvsvc_NetSrvSetInfo(struct ndr_print
*ndr
, const char *name
, int flags
, const struct srvsvc_NetSrvSetInfo
*r
)
16802 ndr_print_struct(ndr
, name
, "srvsvc_NetSrvSetInfo");
16804 if (flags
& NDR_SET_VALUES
) {
16805 ndr
->flags
|= LIBNDR_PRINT_SET_VALUES
;
16807 if (flags
& NDR_IN
) {
16808 ndr_print_struct(ndr
, "in", "srvsvc_NetSrvSetInfo");
16810 ndr_print_ptr(ndr
, "server_unc", r
->in
.server_unc
);
16812 if (r
->in
.server_unc
) {
16813 ndr_print_string(ndr
, "server_unc", r
->in
.server_unc
);
16816 ndr_print_uint32(ndr
, "level", r
->in
.level
);
16817 ndr_print_ptr(ndr
, "info", r
->in
.info
);
16819 ndr_print_set_switch_value(ndr
, r
->in
.info
, r
->in
.level
);
16820 ndr_print_srvsvc_NetSrvInfo(ndr
, "info", r
->in
.info
);
16822 ndr_print_ptr(ndr
, "parm_error", r
->in
.parm_error
);
16824 if (r
->in
.parm_error
) {
16825 ndr_print_uint32(ndr
, "parm_error", *r
->in
.parm_error
);
16830 if (flags
& NDR_OUT
) {
16831 ndr_print_struct(ndr
, "out", "srvsvc_NetSrvSetInfo");
16833 ndr_print_ptr(ndr
, "parm_error", r
->out
.parm_error
);
16835 if (r
->out
.parm_error
) {
16836 ndr_print_uint32(ndr
, "parm_error", *r
->out
.parm_error
);
16839 ndr_print_WERROR(ndr
, "result", r
->out
.result
);
16845 static enum ndr_err_code
ndr_push_srvsvc_NetDiskEnum(struct ndr_push
*ndr
, int flags
, const struct srvsvc_NetDiskEnum
*r
)
16847 if (flags
& NDR_IN
) {
16848 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->in
.server_unc
));
16849 if (r
->in
.server_unc
) {
16850 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.server_unc
, CH_UTF16
)));
16851 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
16852 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.server_unc
, CH_UTF16
)));
16853 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
));
16855 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->in
.level
));
16856 if (r
->in
.info
== NULL
) {
16857 return ndr_push_error(ndr
, NDR_ERR_INVALID_POINTER
, "NULL [ref] pointer");
16859 NDR_CHECK(ndr_push_srvsvc_NetDiskInfo(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->in
.info
));
16860 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->in
.maxlen
));
16861 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->in
.resume_handle
));
16862 if (r
->in
.resume_handle
) {
16863 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, *r
->in
.resume_handle
));
16866 if (flags
& NDR_OUT
) {
16867 if (r
->out
.info
== NULL
) {
16868 return ndr_push_error(ndr
, NDR_ERR_INVALID_POINTER
, "NULL [ref] pointer");
16870 NDR_CHECK(ndr_push_srvsvc_NetDiskInfo(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->out
.info
));
16871 if (r
->out
.totalentries
== NULL
) {
16872 return ndr_push_error(ndr
, NDR_ERR_INVALID_POINTER
, "NULL [ref] pointer");
16874 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, *r
->out
.totalentries
));
16875 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->out
.resume_handle
));
16876 if (r
->out
.resume_handle
) {
16877 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, *r
->out
.resume_handle
));
16879 NDR_CHECK(ndr_push_WERROR(ndr
, NDR_SCALARS
, r
->out
.result
));
16881 return NDR_ERR_SUCCESS
;
16884 static enum ndr_err_code
ndr_pull_srvsvc_NetDiskEnum(struct ndr_pull
*ndr
, int flags
, struct srvsvc_NetDiskEnum
*r
)
16886 uint32_t _ptr_server_unc
;
16887 uint32_t size_server_unc_1
= 0;
16888 uint32_t length_server_unc_1
= 0;
16889 uint32_t _ptr_resume_handle
;
16890 TALLOC_CTX
*_mem_save_server_unc_0
;
16891 TALLOC_CTX
*_mem_save_info_0
;
16892 TALLOC_CTX
*_mem_save_totalentries_0
;
16893 TALLOC_CTX
*_mem_save_resume_handle_0
;
16894 if (flags
& NDR_IN
) {
16895 ZERO_STRUCT(r
->out
);
16897 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_server_unc
));
16898 if (_ptr_server_unc
) {
16899 NDR_PULL_ALLOC(ndr
, r
->in
.server_unc
);
16901 r
->in
.server_unc
= NULL
;
16903 if (r
->in
.server_unc
) {
16904 _mem_save_server_unc_0
= NDR_PULL_GET_MEM_CTX(ndr
);
16905 NDR_PULL_SET_MEM_CTX(ndr
, r
->in
.server_unc
, 0);
16906 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->in
.server_unc
));
16907 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->in
.server_unc
));
16908 size_server_unc_1
= ndr_get_array_size(ndr
, &r
->in
.server_unc
);
16909 length_server_unc_1
= ndr_get_array_length(ndr
, &r
->in
.server_unc
);
16910 if (length_server_unc_1
> size_server_unc_1
) {
16911 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", size_server_unc_1
, length_server_unc_1
);
16913 NDR_CHECK(ndr_check_string_terminator(ndr
, length_server_unc_1
, sizeof(uint16_t)));
16914 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->in
.server_unc
, length_server_unc_1
, sizeof(uint16_t), CH_UTF16
));
16915 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_server_unc_0
, 0);
16917 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->in
.level
));
16918 if (ndr
->flags
& LIBNDR_FLAG_REF_ALLOC
) {
16919 NDR_PULL_ALLOC(ndr
, r
->in
.info
);
16921 _mem_save_info_0
= NDR_PULL_GET_MEM_CTX(ndr
);
16922 NDR_PULL_SET_MEM_CTX(ndr
, r
->in
.info
, LIBNDR_FLAG_REF_ALLOC
);
16923 NDR_CHECK(ndr_pull_srvsvc_NetDiskInfo(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->in
.info
));
16924 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_info_0
, LIBNDR_FLAG_REF_ALLOC
);
16925 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->in
.maxlen
));
16926 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_resume_handle
));
16927 if (_ptr_resume_handle
) {
16928 NDR_PULL_ALLOC(ndr
, r
->in
.resume_handle
);
16930 r
->in
.resume_handle
= NULL
;
16932 if (r
->in
.resume_handle
) {
16933 _mem_save_resume_handle_0
= NDR_PULL_GET_MEM_CTX(ndr
);
16934 NDR_PULL_SET_MEM_CTX(ndr
, r
->in
.resume_handle
, 0);
16935 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, r
->in
.resume_handle
));
16936 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_resume_handle_0
, 0);
16938 NDR_PULL_ALLOC(ndr
, r
->out
.info
);
16939 *r
->out
.info
= *r
->in
.info
;
16940 NDR_PULL_ALLOC(ndr
, r
->out
.totalentries
);
16941 ZERO_STRUCTP(r
->out
.totalentries
);
16943 if (flags
& NDR_OUT
) {
16944 if (ndr
->flags
& LIBNDR_FLAG_REF_ALLOC
) {
16945 NDR_PULL_ALLOC(ndr
, r
->out
.info
);
16947 _mem_save_info_0
= NDR_PULL_GET_MEM_CTX(ndr
);
16948 NDR_PULL_SET_MEM_CTX(ndr
, r
->out
.info
, LIBNDR_FLAG_REF_ALLOC
);
16949 NDR_CHECK(ndr_pull_srvsvc_NetDiskInfo(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->out
.info
));
16950 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_info_0
, LIBNDR_FLAG_REF_ALLOC
);
16951 if (ndr
->flags
& LIBNDR_FLAG_REF_ALLOC
) {
16952 NDR_PULL_ALLOC(ndr
, r
->out
.totalentries
);
16954 _mem_save_totalentries_0
= NDR_PULL_GET_MEM_CTX(ndr
);
16955 NDR_PULL_SET_MEM_CTX(ndr
, r
->out
.totalentries
, LIBNDR_FLAG_REF_ALLOC
);
16956 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, r
->out
.totalentries
));
16957 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_totalentries_0
, LIBNDR_FLAG_REF_ALLOC
);
16958 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_resume_handle
));
16959 if (_ptr_resume_handle
) {
16960 NDR_PULL_ALLOC(ndr
, r
->out
.resume_handle
);
16962 r
->out
.resume_handle
= NULL
;
16964 if (r
->out
.resume_handle
) {
16965 _mem_save_resume_handle_0
= NDR_PULL_GET_MEM_CTX(ndr
);
16966 NDR_PULL_SET_MEM_CTX(ndr
, r
->out
.resume_handle
, 0);
16967 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, r
->out
.resume_handle
));
16968 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_resume_handle_0
, 0);
16970 NDR_CHECK(ndr_pull_WERROR(ndr
, NDR_SCALARS
, &r
->out
.result
));
16972 return NDR_ERR_SUCCESS
;
16975 _PUBLIC_
void ndr_print_srvsvc_NetDiskEnum(struct ndr_print
*ndr
, const char *name
, int flags
, const struct srvsvc_NetDiskEnum
*r
)
16977 ndr_print_struct(ndr
, name
, "srvsvc_NetDiskEnum");
16979 if (flags
& NDR_SET_VALUES
) {
16980 ndr
->flags
|= LIBNDR_PRINT_SET_VALUES
;
16982 if (flags
& NDR_IN
) {
16983 ndr_print_struct(ndr
, "in", "srvsvc_NetDiskEnum");
16985 ndr_print_ptr(ndr
, "server_unc", r
->in
.server_unc
);
16987 if (r
->in
.server_unc
) {
16988 ndr_print_string(ndr
, "server_unc", r
->in
.server_unc
);
16991 ndr_print_uint32(ndr
, "level", r
->in
.level
);
16992 ndr_print_ptr(ndr
, "info", r
->in
.info
);
16994 ndr_print_srvsvc_NetDiskInfo(ndr
, "info", r
->in
.info
);
16996 ndr_print_uint32(ndr
, "maxlen", r
->in
.maxlen
);
16997 ndr_print_ptr(ndr
, "resume_handle", r
->in
.resume_handle
);
16999 if (r
->in
.resume_handle
) {
17000 ndr_print_uint32(ndr
, "resume_handle", *r
->in
.resume_handle
);
17005 if (flags
& NDR_OUT
) {
17006 ndr_print_struct(ndr
, "out", "srvsvc_NetDiskEnum");
17008 ndr_print_ptr(ndr
, "info", r
->out
.info
);
17010 ndr_print_srvsvc_NetDiskInfo(ndr
, "info", r
->out
.info
);
17012 ndr_print_ptr(ndr
, "totalentries", r
->out
.totalentries
);
17014 ndr_print_uint32(ndr
, "totalentries", *r
->out
.totalentries
);
17016 ndr_print_ptr(ndr
, "resume_handle", r
->out
.resume_handle
);
17018 if (r
->out
.resume_handle
) {
17019 ndr_print_uint32(ndr
, "resume_handle", *r
->out
.resume_handle
);
17022 ndr_print_WERROR(ndr
, "result", r
->out
.result
);
17028 static enum ndr_err_code
ndr_push_srvsvc_NetServerStatisticsGet(struct ndr_push
*ndr
, int flags
, const struct srvsvc_NetServerStatisticsGet
*r
)
17030 if (flags
& NDR_IN
) {
17031 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->in
.server_unc
));
17032 if (r
->in
.server_unc
) {
17033 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.server_unc
, CH_UTF16
)));
17034 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
17035 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.server_unc
, CH_UTF16
)));
17036 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
));
17038 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->in
.service
));
17039 if (r
->in
.service
) {
17040 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.service
, CH_UTF16
)));
17041 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
17042 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.service
, CH_UTF16
)));
17043 NDR_CHECK(ndr_push_charset(ndr
, NDR_SCALARS
, r
->in
.service
, ndr_charset_length(r
->in
.service
, CH_UTF16
), sizeof(uint16_t), CH_UTF16
));
17045 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->in
.level
));
17046 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->in
.options
));
17048 if (flags
& NDR_OUT
) {
17049 if (r
->out
.stats
== NULL
) {
17050 return ndr_push_error(ndr
, NDR_ERR_INVALID_POINTER
, "NULL [ref] pointer");
17052 NDR_CHECK(ndr_push_unique_ptr(ndr
, *r
->out
.stats
));
17053 if (*r
->out
.stats
) {
17054 NDR_CHECK(ndr_push_srvsvc_Statistics(ndr
, NDR_SCALARS
, *r
->out
.stats
));
17056 NDR_CHECK(ndr_push_WERROR(ndr
, NDR_SCALARS
, r
->out
.result
));
17058 return NDR_ERR_SUCCESS
;
17061 static enum ndr_err_code
ndr_pull_srvsvc_NetServerStatisticsGet(struct ndr_pull
*ndr
, int flags
, struct srvsvc_NetServerStatisticsGet
*r
)
17063 uint32_t _ptr_server_unc
;
17064 uint32_t size_server_unc_1
= 0;
17065 uint32_t length_server_unc_1
= 0;
17066 uint32_t _ptr_service
;
17067 uint32_t size_service_1
= 0;
17068 uint32_t length_service_1
= 0;
17069 uint32_t _ptr_stats
;
17070 TALLOC_CTX
*_mem_save_server_unc_0
;
17071 TALLOC_CTX
*_mem_save_service_0
;
17072 TALLOC_CTX
*_mem_save_stats_0
;
17073 TALLOC_CTX
*_mem_save_stats_1
;
17074 if (flags
& NDR_IN
) {
17075 ZERO_STRUCT(r
->out
);
17077 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_server_unc
));
17078 if (_ptr_server_unc
) {
17079 NDR_PULL_ALLOC(ndr
, r
->in
.server_unc
);
17081 r
->in
.server_unc
= NULL
;
17083 if (r
->in
.server_unc
) {
17084 _mem_save_server_unc_0
= NDR_PULL_GET_MEM_CTX(ndr
);
17085 NDR_PULL_SET_MEM_CTX(ndr
, r
->in
.server_unc
, 0);
17086 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->in
.server_unc
));
17087 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->in
.server_unc
));
17088 size_server_unc_1
= ndr_get_array_size(ndr
, &r
->in
.server_unc
);
17089 length_server_unc_1
= ndr_get_array_length(ndr
, &r
->in
.server_unc
);
17090 if (length_server_unc_1
> size_server_unc_1
) {
17091 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", size_server_unc_1
, length_server_unc_1
);
17093 NDR_CHECK(ndr_check_string_terminator(ndr
, length_server_unc_1
, sizeof(uint16_t)));
17094 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->in
.server_unc
, length_server_unc_1
, sizeof(uint16_t), CH_UTF16
));
17095 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_server_unc_0
, 0);
17097 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_service
));
17098 if (_ptr_service
) {
17099 NDR_PULL_ALLOC(ndr
, r
->in
.service
);
17101 r
->in
.service
= NULL
;
17103 if (r
->in
.service
) {
17104 _mem_save_service_0
= NDR_PULL_GET_MEM_CTX(ndr
);
17105 NDR_PULL_SET_MEM_CTX(ndr
, r
->in
.service
, 0);
17106 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->in
.service
));
17107 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->in
.service
));
17108 size_service_1
= ndr_get_array_size(ndr
, &r
->in
.service
);
17109 length_service_1
= ndr_get_array_length(ndr
, &r
->in
.service
);
17110 if (length_service_1
> size_service_1
) {
17111 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", size_service_1
, length_service_1
);
17113 NDR_CHECK(ndr_check_string_terminator(ndr
, length_service_1
, sizeof(uint16_t)));
17114 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->in
.service
, length_service_1
, sizeof(uint16_t), CH_UTF16
));
17115 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_service_0
, 0);
17117 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->in
.level
));
17118 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->in
.options
));
17119 NDR_PULL_ALLOC(ndr
, r
->out
.stats
);
17120 ZERO_STRUCTP(r
->out
.stats
);
17122 if (flags
& NDR_OUT
) {
17123 if (ndr
->flags
& LIBNDR_FLAG_REF_ALLOC
) {
17124 NDR_PULL_ALLOC(ndr
, r
->out
.stats
);
17126 _mem_save_stats_0
= NDR_PULL_GET_MEM_CTX(ndr
);
17127 NDR_PULL_SET_MEM_CTX(ndr
, r
->out
.stats
, LIBNDR_FLAG_REF_ALLOC
);
17128 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_stats
));
17130 NDR_PULL_ALLOC(ndr
, *r
->out
.stats
);
17132 *r
->out
.stats
= NULL
;
17134 if (*r
->out
.stats
) {
17135 _mem_save_stats_1
= NDR_PULL_GET_MEM_CTX(ndr
);
17136 NDR_PULL_SET_MEM_CTX(ndr
, *r
->out
.stats
, 0);
17137 NDR_CHECK(ndr_pull_srvsvc_Statistics(ndr
, NDR_SCALARS
, *r
->out
.stats
));
17138 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_stats_1
, 0);
17140 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_stats_0
, LIBNDR_FLAG_REF_ALLOC
);
17141 NDR_CHECK(ndr_pull_WERROR(ndr
, NDR_SCALARS
, &r
->out
.result
));
17143 return NDR_ERR_SUCCESS
;
17146 _PUBLIC_
void ndr_print_srvsvc_NetServerStatisticsGet(struct ndr_print
*ndr
, const char *name
, int flags
, const struct srvsvc_NetServerStatisticsGet
*r
)
17148 ndr_print_struct(ndr
, name
, "srvsvc_NetServerStatisticsGet");
17150 if (flags
& NDR_SET_VALUES
) {
17151 ndr
->flags
|= LIBNDR_PRINT_SET_VALUES
;
17153 if (flags
& NDR_IN
) {
17154 ndr_print_struct(ndr
, "in", "srvsvc_NetServerStatisticsGet");
17156 ndr_print_ptr(ndr
, "server_unc", r
->in
.server_unc
);
17158 if (r
->in
.server_unc
) {
17159 ndr_print_string(ndr
, "server_unc", r
->in
.server_unc
);
17162 ndr_print_ptr(ndr
, "service", r
->in
.service
);
17164 if (r
->in
.service
) {
17165 ndr_print_string(ndr
, "service", r
->in
.service
);
17168 ndr_print_uint32(ndr
, "level", r
->in
.level
);
17169 ndr_print_uint32(ndr
, "options", r
->in
.options
);
17172 if (flags
& NDR_OUT
) {
17173 ndr_print_struct(ndr
, "out", "srvsvc_NetServerStatisticsGet");
17175 ndr_print_ptr(ndr
, "stats", r
->out
.stats
);
17177 ndr_print_ptr(ndr
, "stats", *r
->out
.stats
);
17179 if (*r
->out
.stats
) {
17180 ndr_print_srvsvc_Statistics(ndr
, "stats", *r
->out
.stats
);
17184 ndr_print_WERROR(ndr
, "result", r
->out
.result
);
17190 static enum ndr_err_code
ndr_push_srvsvc_NetTransportAdd(struct ndr_push
*ndr
, int flags
, const struct srvsvc_NetTransportAdd
*r
)
17192 if (flags
& NDR_IN
) {
17193 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->in
.server_unc
));
17194 if (r
->in
.server_unc
) {
17195 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.server_unc
, CH_UTF16
)));
17196 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
17197 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.server_unc
, CH_UTF16
)));
17198 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
));
17200 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->in
.level
));
17201 NDR_CHECK(ndr_push_set_switch_value(ndr
, &r
->in
.info
, r
->in
.level
));
17202 NDR_CHECK(ndr_push_srvsvc_NetTransportInfo(ndr
, NDR_SCALARS
|NDR_BUFFERS
, &r
->in
.info
));
17204 if (flags
& NDR_OUT
) {
17205 NDR_CHECK(ndr_push_WERROR(ndr
, NDR_SCALARS
, r
->out
.result
));
17207 return NDR_ERR_SUCCESS
;
17210 static enum ndr_err_code
ndr_pull_srvsvc_NetTransportAdd(struct ndr_pull
*ndr
, int flags
, struct srvsvc_NetTransportAdd
*r
)
17212 uint32_t _ptr_server_unc
;
17213 uint32_t size_server_unc_1
= 0;
17214 uint32_t length_server_unc_1
= 0;
17215 TALLOC_CTX
*_mem_save_server_unc_0
;
17216 if (flags
& NDR_IN
) {
17217 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_server_unc
));
17218 if (_ptr_server_unc
) {
17219 NDR_PULL_ALLOC(ndr
, r
->in
.server_unc
);
17221 r
->in
.server_unc
= NULL
;
17223 if (r
->in
.server_unc
) {
17224 _mem_save_server_unc_0
= NDR_PULL_GET_MEM_CTX(ndr
);
17225 NDR_PULL_SET_MEM_CTX(ndr
, r
->in
.server_unc
, 0);
17226 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->in
.server_unc
));
17227 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->in
.server_unc
));
17228 size_server_unc_1
= ndr_get_array_size(ndr
, &r
->in
.server_unc
);
17229 length_server_unc_1
= ndr_get_array_length(ndr
, &r
->in
.server_unc
);
17230 if (length_server_unc_1
> size_server_unc_1
) {
17231 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", size_server_unc_1
, length_server_unc_1
);
17233 NDR_CHECK(ndr_check_string_terminator(ndr
, length_server_unc_1
, sizeof(uint16_t)));
17234 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->in
.server_unc
, length_server_unc_1
, sizeof(uint16_t), CH_UTF16
));
17235 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_server_unc_0
, 0);
17237 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->in
.level
));
17238 NDR_CHECK(ndr_pull_set_switch_value(ndr
, &r
->in
.info
, r
->in
.level
));
17239 NDR_CHECK(ndr_pull_srvsvc_NetTransportInfo(ndr
, NDR_SCALARS
|NDR_BUFFERS
, &r
->in
.info
));
17241 if (flags
& NDR_OUT
) {
17242 NDR_CHECK(ndr_pull_WERROR(ndr
, NDR_SCALARS
, &r
->out
.result
));
17244 return NDR_ERR_SUCCESS
;
17247 _PUBLIC_
void ndr_print_srvsvc_NetTransportAdd(struct ndr_print
*ndr
, const char *name
, int flags
, const struct srvsvc_NetTransportAdd
*r
)
17249 ndr_print_struct(ndr
, name
, "srvsvc_NetTransportAdd");
17251 if (flags
& NDR_SET_VALUES
) {
17252 ndr
->flags
|= LIBNDR_PRINT_SET_VALUES
;
17254 if (flags
& NDR_IN
) {
17255 ndr_print_struct(ndr
, "in", "srvsvc_NetTransportAdd");
17257 ndr_print_ptr(ndr
, "server_unc", r
->in
.server_unc
);
17259 if (r
->in
.server_unc
) {
17260 ndr_print_string(ndr
, "server_unc", r
->in
.server_unc
);
17263 ndr_print_uint32(ndr
, "level", r
->in
.level
);
17264 ndr_print_set_switch_value(ndr
, &r
->in
.info
, r
->in
.level
);
17265 ndr_print_srvsvc_NetTransportInfo(ndr
, "info", &r
->in
.info
);
17268 if (flags
& NDR_OUT
) {
17269 ndr_print_struct(ndr
, "out", "srvsvc_NetTransportAdd");
17271 ndr_print_WERROR(ndr
, "result", r
->out
.result
);
17277 static enum ndr_err_code
ndr_push_srvsvc_NetTransportEnum(struct ndr_push
*ndr
, int flags
, const struct srvsvc_NetTransportEnum
*r
)
17279 if (flags
& NDR_IN
) {
17280 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->in
.server_unc
));
17281 if (r
->in
.server_unc
) {
17282 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.server_unc
, CH_UTF16
)));
17283 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
17284 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.server_unc
, CH_UTF16
)));
17285 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
));
17287 if (r
->in
.transports
== NULL
) {
17288 return ndr_push_error(ndr
, NDR_ERR_INVALID_POINTER
, "NULL [ref] pointer");
17290 NDR_CHECK(ndr_push_srvsvc_NetTransportInfoCtr(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->in
.transports
));
17291 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->in
.max_buffer
));
17292 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->in
.resume_handle
));
17293 if (r
->in
.resume_handle
) {
17294 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, *r
->in
.resume_handle
));
17297 if (flags
& NDR_OUT
) {
17298 if (r
->out
.transports
== NULL
) {
17299 return ndr_push_error(ndr
, NDR_ERR_INVALID_POINTER
, "NULL [ref] pointer");
17301 NDR_CHECK(ndr_push_srvsvc_NetTransportInfoCtr(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->out
.transports
));
17302 if (r
->out
.totalentries
== NULL
) {
17303 return ndr_push_error(ndr
, NDR_ERR_INVALID_POINTER
, "NULL [ref] pointer");
17305 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, *r
->out
.totalentries
));
17306 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->out
.resume_handle
));
17307 if (r
->out
.resume_handle
) {
17308 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, *r
->out
.resume_handle
));
17310 NDR_CHECK(ndr_push_WERROR(ndr
, NDR_SCALARS
, r
->out
.result
));
17312 return NDR_ERR_SUCCESS
;
17315 static enum ndr_err_code
ndr_pull_srvsvc_NetTransportEnum(struct ndr_pull
*ndr
, int flags
, struct srvsvc_NetTransportEnum
*r
)
17317 uint32_t _ptr_server_unc
;
17318 uint32_t size_server_unc_1
= 0;
17319 uint32_t length_server_unc_1
= 0;
17320 uint32_t _ptr_resume_handle
;
17321 TALLOC_CTX
*_mem_save_server_unc_0
;
17322 TALLOC_CTX
*_mem_save_transports_0
;
17323 TALLOC_CTX
*_mem_save_totalentries_0
;
17324 TALLOC_CTX
*_mem_save_resume_handle_0
;
17325 if (flags
& NDR_IN
) {
17326 ZERO_STRUCT(r
->out
);
17328 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_server_unc
));
17329 if (_ptr_server_unc
) {
17330 NDR_PULL_ALLOC(ndr
, r
->in
.server_unc
);
17332 r
->in
.server_unc
= NULL
;
17334 if (r
->in
.server_unc
) {
17335 _mem_save_server_unc_0
= NDR_PULL_GET_MEM_CTX(ndr
);
17336 NDR_PULL_SET_MEM_CTX(ndr
, r
->in
.server_unc
, 0);
17337 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->in
.server_unc
));
17338 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->in
.server_unc
));
17339 size_server_unc_1
= ndr_get_array_size(ndr
, &r
->in
.server_unc
);
17340 length_server_unc_1
= ndr_get_array_length(ndr
, &r
->in
.server_unc
);
17341 if (length_server_unc_1
> size_server_unc_1
) {
17342 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", size_server_unc_1
, length_server_unc_1
);
17344 NDR_CHECK(ndr_check_string_terminator(ndr
, length_server_unc_1
, sizeof(uint16_t)));
17345 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->in
.server_unc
, length_server_unc_1
, sizeof(uint16_t), CH_UTF16
));
17346 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_server_unc_0
, 0);
17348 if (ndr
->flags
& LIBNDR_FLAG_REF_ALLOC
) {
17349 NDR_PULL_ALLOC(ndr
, r
->in
.transports
);
17351 _mem_save_transports_0
= NDR_PULL_GET_MEM_CTX(ndr
);
17352 NDR_PULL_SET_MEM_CTX(ndr
, r
->in
.transports
, LIBNDR_FLAG_REF_ALLOC
);
17353 NDR_CHECK(ndr_pull_srvsvc_NetTransportInfoCtr(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->in
.transports
));
17354 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_transports_0
, LIBNDR_FLAG_REF_ALLOC
);
17355 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->in
.max_buffer
));
17356 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_resume_handle
));
17357 if (_ptr_resume_handle
) {
17358 NDR_PULL_ALLOC(ndr
, r
->in
.resume_handle
);
17360 r
->in
.resume_handle
= NULL
;
17362 if (r
->in
.resume_handle
) {
17363 _mem_save_resume_handle_0
= NDR_PULL_GET_MEM_CTX(ndr
);
17364 NDR_PULL_SET_MEM_CTX(ndr
, r
->in
.resume_handle
, 0);
17365 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, r
->in
.resume_handle
));
17366 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_resume_handle_0
, 0);
17368 NDR_PULL_ALLOC(ndr
, r
->out
.transports
);
17369 *r
->out
.transports
= *r
->in
.transports
;
17370 NDR_PULL_ALLOC(ndr
, r
->out
.totalentries
);
17371 ZERO_STRUCTP(r
->out
.totalentries
);
17373 if (flags
& NDR_OUT
) {
17374 if (ndr
->flags
& LIBNDR_FLAG_REF_ALLOC
) {
17375 NDR_PULL_ALLOC(ndr
, r
->out
.transports
);
17377 _mem_save_transports_0
= NDR_PULL_GET_MEM_CTX(ndr
);
17378 NDR_PULL_SET_MEM_CTX(ndr
, r
->out
.transports
, LIBNDR_FLAG_REF_ALLOC
);
17379 NDR_CHECK(ndr_pull_srvsvc_NetTransportInfoCtr(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->out
.transports
));
17380 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_transports_0
, LIBNDR_FLAG_REF_ALLOC
);
17381 if (ndr
->flags
& LIBNDR_FLAG_REF_ALLOC
) {
17382 NDR_PULL_ALLOC(ndr
, r
->out
.totalentries
);
17384 _mem_save_totalentries_0
= NDR_PULL_GET_MEM_CTX(ndr
);
17385 NDR_PULL_SET_MEM_CTX(ndr
, r
->out
.totalentries
, LIBNDR_FLAG_REF_ALLOC
);
17386 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, r
->out
.totalentries
));
17387 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_totalentries_0
, LIBNDR_FLAG_REF_ALLOC
);
17388 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_resume_handle
));
17389 if (_ptr_resume_handle
) {
17390 NDR_PULL_ALLOC(ndr
, r
->out
.resume_handle
);
17392 r
->out
.resume_handle
= NULL
;
17394 if (r
->out
.resume_handle
) {
17395 _mem_save_resume_handle_0
= NDR_PULL_GET_MEM_CTX(ndr
);
17396 NDR_PULL_SET_MEM_CTX(ndr
, r
->out
.resume_handle
, 0);
17397 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, r
->out
.resume_handle
));
17398 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_resume_handle_0
, 0);
17400 NDR_CHECK(ndr_pull_WERROR(ndr
, NDR_SCALARS
, &r
->out
.result
));
17402 return NDR_ERR_SUCCESS
;
17405 _PUBLIC_
void ndr_print_srvsvc_NetTransportEnum(struct ndr_print
*ndr
, const char *name
, int flags
, const struct srvsvc_NetTransportEnum
*r
)
17407 ndr_print_struct(ndr
, name
, "srvsvc_NetTransportEnum");
17409 if (flags
& NDR_SET_VALUES
) {
17410 ndr
->flags
|= LIBNDR_PRINT_SET_VALUES
;
17412 if (flags
& NDR_IN
) {
17413 ndr_print_struct(ndr
, "in", "srvsvc_NetTransportEnum");
17415 ndr_print_ptr(ndr
, "server_unc", r
->in
.server_unc
);
17417 if (r
->in
.server_unc
) {
17418 ndr_print_string(ndr
, "server_unc", r
->in
.server_unc
);
17421 ndr_print_ptr(ndr
, "transports", r
->in
.transports
);
17423 ndr_print_srvsvc_NetTransportInfoCtr(ndr
, "transports", r
->in
.transports
);
17425 ndr_print_uint32(ndr
, "max_buffer", r
->in
.max_buffer
);
17426 ndr_print_ptr(ndr
, "resume_handle", r
->in
.resume_handle
);
17428 if (r
->in
.resume_handle
) {
17429 ndr_print_uint32(ndr
, "resume_handle", *r
->in
.resume_handle
);
17434 if (flags
& NDR_OUT
) {
17435 ndr_print_struct(ndr
, "out", "srvsvc_NetTransportEnum");
17437 ndr_print_ptr(ndr
, "transports", r
->out
.transports
);
17439 ndr_print_srvsvc_NetTransportInfoCtr(ndr
, "transports", r
->out
.transports
);
17441 ndr_print_ptr(ndr
, "totalentries", r
->out
.totalentries
);
17443 ndr_print_uint32(ndr
, "totalentries", *r
->out
.totalentries
);
17445 ndr_print_ptr(ndr
, "resume_handle", r
->out
.resume_handle
);
17447 if (r
->out
.resume_handle
) {
17448 ndr_print_uint32(ndr
, "resume_handle", *r
->out
.resume_handle
);
17451 ndr_print_WERROR(ndr
, "result", r
->out
.result
);
17457 static enum ndr_err_code
ndr_push_srvsvc_NetTransportDel(struct ndr_push
*ndr
, int flags
, const struct srvsvc_NetTransportDel
*r
)
17459 if (flags
& NDR_IN
) {
17460 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->in
.server_unc
));
17461 if (r
->in
.server_unc
) {
17462 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.server_unc
, CH_UTF16
)));
17463 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
17464 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.server_unc
, CH_UTF16
)));
17465 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
));
17467 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->in
.level
));
17468 if (r
->in
.info0
== NULL
) {
17469 return ndr_push_error(ndr
, NDR_ERR_INVALID_POINTER
, "NULL [ref] pointer");
17471 NDR_CHECK(ndr_push_srvsvc_NetTransportInfo0(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->in
.info0
));
17473 if (flags
& NDR_OUT
) {
17474 NDR_CHECK(ndr_push_WERROR(ndr
, NDR_SCALARS
, r
->out
.result
));
17476 return NDR_ERR_SUCCESS
;
17479 static enum ndr_err_code
ndr_pull_srvsvc_NetTransportDel(struct ndr_pull
*ndr
, int flags
, struct srvsvc_NetTransportDel
*r
)
17481 uint32_t _ptr_server_unc
;
17482 uint32_t size_server_unc_1
= 0;
17483 uint32_t length_server_unc_1
= 0;
17484 TALLOC_CTX
*_mem_save_server_unc_0
;
17485 TALLOC_CTX
*_mem_save_info0_0
;
17486 if (flags
& NDR_IN
) {
17487 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_server_unc
));
17488 if (_ptr_server_unc
) {
17489 NDR_PULL_ALLOC(ndr
, r
->in
.server_unc
);
17491 r
->in
.server_unc
= NULL
;
17493 if (r
->in
.server_unc
) {
17494 _mem_save_server_unc_0
= NDR_PULL_GET_MEM_CTX(ndr
);
17495 NDR_PULL_SET_MEM_CTX(ndr
, r
->in
.server_unc
, 0);
17496 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->in
.server_unc
));
17497 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->in
.server_unc
));
17498 size_server_unc_1
= ndr_get_array_size(ndr
, &r
->in
.server_unc
);
17499 length_server_unc_1
= ndr_get_array_length(ndr
, &r
->in
.server_unc
);
17500 if (length_server_unc_1
> size_server_unc_1
) {
17501 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", size_server_unc_1
, length_server_unc_1
);
17503 NDR_CHECK(ndr_check_string_terminator(ndr
, length_server_unc_1
, sizeof(uint16_t)));
17504 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->in
.server_unc
, length_server_unc_1
, sizeof(uint16_t), CH_UTF16
));
17505 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_server_unc_0
, 0);
17507 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->in
.level
));
17508 if (ndr
->flags
& LIBNDR_FLAG_REF_ALLOC
) {
17509 NDR_PULL_ALLOC(ndr
, r
->in
.info0
);
17511 _mem_save_info0_0
= NDR_PULL_GET_MEM_CTX(ndr
);
17512 NDR_PULL_SET_MEM_CTX(ndr
, r
->in
.info0
, LIBNDR_FLAG_REF_ALLOC
);
17513 NDR_CHECK(ndr_pull_srvsvc_NetTransportInfo0(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->in
.info0
));
17514 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_info0_0
, LIBNDR_FLAG_REF_ALLOC
);
17516 if (flags
& NDR_OUT
) {
17517 NDR_CHECK(ndr_pull_WERROR(ndr
, NDR_SCALARS
, &r
->out
.result
));
17519 return NDR_ERR_SUCCESS
;
17522 _PUBLIC_
void ndr_print_srvsvc_NetTransportDel(struct ndr_print
*ndr
, const char *name
, int flags
, const struct srvsvc_NetTransportDel
*r
)
17524 ndr_print_struct(ndr
, name
, "srvsvc_NetTransportDel");
17526 if (flags
& NDR_SET_VALUES
) {
17527 ndr
->flags
|= LIBNDR_PRINT_SET_VALUES
;
17529 if (flags
& NDR_IN
) {
17530 ndr_print_struct(ndr
, "in", "srvsvc_NetTransportDel");
17532 ndr_print_ptr(ndr
, "server_unc", r
->in
.server_unc
);
17534 if (r
->in
.server_unc
) {
17535 ndr_print_string(ndr
, "server_unc", r
->in
.server_unc
);
17538 ndr_print_uint32(ndr
, "level", r
->in
.level
);
17539 ndr_print_ptr(ndr
, "info0", r
->in
.info0
);
17541 ndr_print_srvsvc_NetTransportInfo0(ndr
, "info0", r
->in
.info0
);
17545 if (flags
& NDR_OUT
) {
17546 ndr_print_struct(ndr
, "out", "srvsvc_NetTransportDel");
17548 ndr_print_WERROR(ndr
, "result", r
->out
.result
);
17554 static enum ndr_err_code
ndr_push_srvsvc_NetRemoteTOD(struct ndr_push
*ndr
, int flags
, const struct srvsvc_NetRemoteTOD
*r
)
17556 if (flags
& NDR_IN
) {
17557 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->in
.server_unc
));
17558 if (r
->in
.server_unc
) {
17559 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.server_unc
, CH_UTF16
)));
17560 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
17561 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.server_unc
, CH_UTF16
)));
17562 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
));
17565 if (flags
& NDR_OUT
) {
17566 if (r
->out
.info
== NULL
) {
17567 return ndr_push_error(ndr
, NDR_ERR_INVALID_POINTER
, "NULL [ref] pointer");
17569 NDR_CHECK(ndr_push_unique_ptr(ndr
, *r
->out
.info
));
17570 if (*r
->out
.info
) {
17571 NDR_CHECK(ndr_push_srvsvc_NetRemoteTODInfo(ndr
, NDR_SCALARS
, *r
->out
.info
));
17573 NDR_CHECK(ndr_push_WERROR(ndr
, NDR_SCALARS
, r
->out
.result
));
17575 return NDR_ERR_SUCCESS
;
17578 static enum ndr_err_code
ndr_pull_srvsvc_NetRemoteTOD(struct ndr_pull
*ndr
, int flags
, struct srvsvc_NetRemoteTOD
*r
)
17580 uint32_t _ptr_server_unc
;
17581 uint32_t size_server_unc_1
= 0;
17582 uint32_t length_server_unc_1
= 0;
17583 uint32_t _ptr_info
;
17584 TALLOC_CTX
*_mem_save_server_unc_0
;
17585 TALLOC_CTX
*_mem_save_info_0
;
17586 TALLOC_CTX
*_mem_save_info_1
;
17587 if (flags
& NDR_IN
) {
17588 ZERO_STRUCT(r
->out
);
17590 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_server_unc
));
17591 if (_ptr_server_unc
) {
17592 NDR_PULL_ALLOC(ndr
, r
->in
.server_unc
);
17594 r
->in
.server_unc
= NULL
;
17596 if (r
->in
.server_unc
) {
17597 _mem_save_server_unc_0
= NDR_PULL_GET_MEM_CTX(ndr
);
17598 NDR_PULL_SET_MEM_CTX(ndr
, r
->in
.server_unc
, 0);
17599 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->in
.server_unc
));
17600 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->in
.server_unc
));
17601 size_server_unc_1
= ndr_get_array_size(ndr
, &r
->in
.server_unc
);
17602 length_server_unc_1
= ndr_get_array_length(ndr
, &r
->in
.server_unc
);
17603 if (length_server_unc_1
> size_server_unc_1
) {
17604 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", size_server_unc_1
, length_server_unc_1
);
17606 NDR_CHECK(ndr_check_string_terminator(ndr
, length_server_unc_1
, sizeof(uint16_t)));
17607 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->in
.server_unc
, length_server_unc_1
, sizeof(uint16_t), CH_UTF16
));
17608 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_server_unc_0
, 0);
17610 NDR_PULL_ALLOC(ndr
, r
->out
.info
);
17611 ZERO_STRUCTP(r
->out
.info
);
17613 if (flags
& NDR_OUT
) {
17614 if (ndr
->flags
& LIBNDR_FLAG_REF_ALLOC
) {
17615 NDR_PULL_ALLOC(ndr
, r
->out
.info
);
17617 _mem_save_info_0
= NDR_PULL_GET_MEM_CTX(ndr
);
17618 NDR_PULL_SET_MEM_CTX(ndr
, r
->out
.info
, LIBNDR_FLAG_REF_ALLOC
);
17619 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_info
));
17621 NDR_PULL_ALLOC(ndr
, *r
->out
.info
);
17623 *r
->out
.info
= NULL
;
17625 if (*r
->out
.info
) {
17626 _mem_save_info_1
= NDR_PULL_GET_MEM_CTX(ndr
);
17627 NDR_PULL_SET_MEM_CTX(ndr
, *r
->out
.info
, 0);
17628 NDR_CHECK(ndr_pull_srvsvc_NetRemoteTODInfo(ndr
, NDR_SCALARS
, *r
->out
.info
));
17629 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_info_1
, 0);
17631 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_info_0
, LIBNDR_FLAG_REF_ALLOC
);
17632 NDR_CHECK(ndr_pull_WERROR(ndr
, NDR_SCALARS
, &r
->out
.result
));
17634 return NDR_ERR_SUCCESS
;
17637 _PUBLIC_
void ndr_print_srvsvc_NetRemoteTOD(struct ndr_print
*ndr
, const char *name
, int flags
, const struct srvsvc_NetRemoteTOD
*r
)
17639 ndr_print_struct(ndr
, name
, "srvsvc_NetRemoteTOD");
17641 if (flags
& NDR_SET_VALUES
) {
17642 ndr
->flags
|= LIBNDR_PRINT_SET_VALUES
;
17644 if (flags
& NDR_IN
) {
17645 ndr_print_struct(ndr
, "in", "srvsvc_NetRemoteTOD");
17647 ndr_print_ptr(ndr
, "server_unc", r
->in
.server_unc
);
17649 if (r
->in
.server_unc
) {
17650 ndr_print_string(ndr
, "server_unc", r
->in
.server_unc
);
17655 if (flags
& NDR_OUT
) {
17656 ndr_print_struct(ndr
, "out", "srvsvc_NetRemoteTOD");
17658 ndr_print_ptr(ndr
, "info", r
->out
.info
);
17660 ndr_print_ptr(ndr
, "info", *r
->out
.info
);
17662 if (*r
->out
.info
) {
17663 ndr_print_srvsvc_NetRemoteTODInfo(ndr
, "info", *r
->out
.info
);
17667 ndr_print_WERROR(ndr
, "result", r
->out
.result
);
17673 static enum ndr_err_code
ndr_push_srvsvc_NetSetServiceBits(struct ndr_push
*ndr
, int flags
, const struct srvsvc_NetSetServiceBits
*r
)
17675 if (flags
& NDR_IN
) {
17676 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->in
.server_unc
));
17677 if (r
->in
.server_unc
) {
17678 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.server_unc
, CH_UTF16
)));
17679 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
17680 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.server_unc
, CH_UTF16
)));
17681 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
));
17683 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->in
.transport
));
17684 if (r
->in
.transport
) {
17685 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.transport
, CH_UTF16
)));
17686 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
17687 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.transport
, CH_UTF16
)));
17688 NDR_CHECK(ndr_push_charset(ndr
, NDR_SCALARS
, r
->in
.transport
, ndr_charset_length(r
->in
.transport
, CH_UTF16
), sizeof(uint16_t), CH_UTF16
));
17690 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->in
.servicebits
));
17691 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->in
.updateimmediately
));
17693 if (flags
& NDR_OUT
) {
17694 NDR_CHECK(ndr_push_WERROR(ndr
, NDR_SCALARS
, r
->out
.result
));
17696 return NDR_ERR_SUCCESS
;
17699 static enum ndr_err_code
ndr_pull_srvsvc_NetSetServiceBits(struct ndr_pull
*ndr
, int flags
, struct srvsvc_NetSetServiceBits
*r
)
17701 uint32_t _ptr_server_unc
;
17702 uint32_t size_server_unc_1
= 0;
17703 uint32_t length_server_unc_1
= 0;
17704 uint32_t _ptr_transport
;
17705 uint32_t size_transport_1
= 0;
17706 uint32_t length_transport_1
= 0;
17707 TALLOC_CTX
*_mem_save_server_unc_0
;
17708 TALLOC_CTX
*_mem_save_transport_0
;
17709 if (flags
& NDR_IN
) {
17710 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_server_unc
));
17711 if (_ptr_server_unc
) {
17712 NDR_PULL_ALLOC(ndr
, r
->in
.server_unc
);
17714 r
->in
.server_unc
= NULL
;
17716 if (r
->in
.server_unc
) {
17717 _mem_save_server_unc_0
= NDR_PULL_GET_MEM_CTX(ndr
);
17718 NDR_PULL_SET_MEM_CTX(ndr
, r
->in
.server_unc
, 0);
17719 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->in
.server_unc
));
17720 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->in
.server_unc
));
17721 size_server_unc_1
= ndr_get_array_size(ndr
, &r
->in
.server_unc
);
17722 length_server_unc_1
= ndr_get_array_length(ndr
, &r
->in
.server_unc
);
17723 if (length_server_unc_1
> size_server_unc_1
) {
17724 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", size_server_unc_1
, length_server_unc_1
);
17726 NDR_CHECK(ndr_check_string_terminator(ndr
, length_server_unc_1
, sizeof(uint16_t)));
17727 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->in
.server_unc
, length_server_unc_1
, sizeof(uint16_t), CH_UTF16
));
17728 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_server_unc_0
, 0);
17730 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_transport
));
17731 if (_ptr_transport
) {
17732 NDR_PULL_ALLOC(ndr
, r
->in
.transport
);
17734 r
->in
.transport
= NULL
;
17736 if (r
->in
.transport
) {
17737 _mem_save_transport_0
= NDR_PULL_GET_MEM_CTX(ndr
);
17738 NDR_PULL_SET_MEM_CTX(ndr
, r
->in
.transport
, 0);
17739 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->in
.transport
));
17740 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->in
.transport
));
17741 size_transport_1
= ndr_get_array_size(ndr
, &r
->in
.transport
);
17742 length_transport_1
= ndr_get_array_length(ndr
, &r
->in
.transport
);
17743 if (length_transport_1
> size_transport_1
) {
17744 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", size_transport_1
, length_transport_1
);
17746 NDR_CHECK(ndr_check_string_terminator(ndr
, length_transport_1
, sizeof(uint16_t)));
17747 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->in
.transport
, length_transport_1
, sizeof(uint16_t), CH_UTF16
));
17748 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_transport_0
, 0);
17750 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->in
.servicebits
));
17751 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->in
.updateimmediately
));
17753 if (flags
& NDR_OUT
) {
17754 NDR_CHECK(ndr_pull_WERROR(ndr
, NDR_SCALARS
, &r
->out
.result
));
17756 return NDR_ERR_SUCCESS
;
17759 _PUBLIC_
void ndr_print_srvsvc_NetSetServiceBits(struct ndr_print
*ndr
, const char *name
, int flags
, const struct srvsvc_NetSetServiceBits
*r
)
17761 ndr_print_struct(ndr
, name
, "srvsvc_NetSetServiceBits");
17763 if (flags
& NDR_SET_VALUES
) {
17764 ndr
->flags
|= LIBNDR_PRINT_SET_VALUES
;
17766 if (flags
& NDR_IN
) {
17767 ndr_print_struct(ndr
, "in", "srvsvc_NetSetServiceBits");
17769 ndr_print_ptr(ndr
, "server_unc", r
->in
.server_unc
);
17771 if (r
->in
.server_unc
) {
17772 ndr_print_string(ndr
, "server_unc", r
->in
.server_unc
);
17775 ndr_print_ptr(ndr
, "transport", r
->in
.transport
);
17777 if (r
->in
.transport
) {
17778 ndr_print_string(ndr
, "transport", r
->in
.transport
);
17781 ndr_print_uint32(ndr
, "servicebits", r
->in
.servicebits
);
17782 ndr_print_uint32(ndr
, "updateimmediately", r
->in
.updateimmediately
);
17785 if (flags
& NDR_OUT
) {
17786 ndr_print_struct(ndr
, "out", "srvsvc_NetSetServiceBits");
17788 ndr_print_WERROR(ndr
, "result", r
->out
.result
);
17794 static enum ndr_err_code
ndr_push_srvsvc_NetPathType(struct ndr_push
*ndr
, int flags
, const struct srvsvc_NetPathType
*r
)
17796 if (flags
& NDR_IN
) {
17797 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->in
.server_unc
));
17798 if (r
->in
.server_unc
) {
17799 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.server_unc
, CH_UTF16
)));
17800 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
17801 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.server_unc
, CH_UTF16
)));
17802 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
));
17804 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.path
, CH_UTF16
)));
17805 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
17806 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.path
, CH_UTF16
)));
17807 NDR_CHECK(ndr_push_charset(ndr
, NDR_SCALARS
, r
->in
.path
, ndr_charset_length(r
->in
.path
, CH_UTF16
), sizeof(uint16_t), CH_UTF16
));
17808 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->in
.pathflags
));
17810 if (flags
& NDR_OUT
) {
17811 if (r
->out
.pathtype
== NULL
) {
17812 return ndr_push_error(ndr
, NDR_ERR_INVALID_POINTER
, "NULL [ref] pointer");
17814 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, *r
->out
.pathtype
));
17815 NDR_CHECK(ndr_push_WERROR(ndr
, NDR_SCALARS
, r
->out
.result
));
17817 return NDR_ERR_SUCCESS
;
17820 static enum ndr_err_code
ndr_pull_srvsvc_NetPathType(struct ndr_pull
*ndr
, int flags
, struct srvsvc_NetPathType
*r
)
17822 uint32_t _ptr_server_unc
;
17823 uint32_t size_server_unc_1
= 0;
17824 uint32_t length_server_unc_1
= 0;
17825 uint32_t size_path_0
= 0;
17826 uint32_t length_path_0
= 0;
17827 TALLOC_CTX
*_mem_save_server_unc_0
;
17828 TALLOC_CTX
*_mem_save_pathtype_0
;
17829 if (flags
& NDR_IN
) {
17830 ZERO_STRUCT(r
->out
);
17832 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_server_unc
));
17833 if (_ptr_server_unc
) {
17834 NDR_PULL_ALLOC(ndr
, r
->in
.server_unc
);
17836 r
->in
.server_unc
= NULL
;
17838 if (r
->in
.server_unc
) {
17839 _mem_save_server_unc_0
= NDR_PULL_GET_MEM_CTX(ndr
);
17840 NDR_PULL_SET_MEM_CTX(ndr
, r
->in
.server_unc
, 0);
17841 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->in
.server_unc
));
17842 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->in
.server_unc
));
17843 size_server_unc_1
= ndr_get_array_size(ndr
, &r
->in
.server_unc
);
17844 length_server_unc_1
= ndr_get_array_length(ndr
, &r
->in
.server_unc
);
17845 if (length_server_unc_1
> size_server_unc_1
) {
17846 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", size_server_unc_1
, length_server_unc_1
);
17848 NDR_CHECK(ndr_check_string_terminator(ndr
, length_server_unc_1
, sizeof(uint16_t)));
17849 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->in
.server_unc
, length_server_unc_1
, sizeof(uint16_t), CH_UTF16
));
17850 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_server_unc_0
, 0);
17852 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->in
.path
));
17853 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->in
.path
));
17854 size_path_0
= ndr_get_array_size(ndr
, &r
->in
.path
);
17855 length_path_0
= ndr_get_array_length(ndr
, &r
->in
.path
);
17856 if (length_path_0
> size_path_0
) {
17857 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", size_path_0
, length_path_0
);
17859 NDR_CHECK(ndr_check_string_terminator(ndr
, length_path_0
, sizeof(uint16_t)));
17860 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->in
.path
, length_path_0
, sizeof(uint16_t), CH_UTF16
));
17861 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->in
.pathflags
));
17862 NDR_PULL_ALLOC(ndr
, r
->out
.pathtype
);
17863 ZERO_STRUCTP(r
->out
.pathtype
);
17865 if (flags
& NDR_OUT
) {
17866 if (ndr
->flags
& LIBNDR_FLAG_REF_ALLOC
) {
17867 NDR_PULL_ALLOC(ndr
, r
->out
.pathtype
);
17869 _mem_save_pathtype_0
= NDR_PULL_GET_MEM_CTX(ndr
);
17870 NDR_PULL_SET_MEM_CTX(ndr
, r
->out
.pathtype
, LIBNDR_FLAG_REF_ALLOC
);
17871 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, r
->out
.pathtype
));
17872 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_pathtype_0
, LIBNDR_FLAG_REF_ALLOC
);
17873 NDR_CHECK(ndr_pull_WERROR(ndr
, NDR_SCALARS
, &r
->out
.result
));
17875 return NDR_ERR_SUCCESS
;
17878 _PUBLIC_
void ndr_print_srvsvc_NetPathType(struct ndr_print
*ndr
, const char *name
, int flags
, const struct srvsvc_NetPathType
*r
)
17880 ndr_print_struct(ndr
, name
, "srvsvc_NetPathType");
17882 if (flags
& NDR_SET_VALUES
) {
17883 ndr
->flags
|= LIBNDR_PRINT_SET_VALUES
;
17885 if (flags
& NDR_IN
) {
17886 ndr_print_struct(ndr
, "in", "srvsvc_NetPathType");
17888 ndr_print_ptr(ndr
, "server_unc", r
->in
.server_unc
);
17890 if (r
->in
.server_unc
) {
17891 ndr_print_string(ndr
, "server_unc", r
->in
.server_unc
);
17894 ndr_print_string(ndr
, "path", r
->in
.path
);
17895 ndr_print_uint32(ndr
, "pathflags", r
->in
.pathflags
);
17898 if (flags
& NDR_OUT
) {
17899 ndr_print_struct(ndr
, "out", "srvsvc_NetPathType");
17901 ndr_print_ptr(ndr
, "pathtype", r
->out
.pathtype
);
17903 ndr_print_uint32(ndr
, "pathtype", *r
->out
.pathtype
);
17905 ndr_print_WERROR(ndr
, "result", r
->out
.result
);
17911 static enum ndr_err_code
ndr_push_srvsvc_NetPathCanonicalize(struct ndr_push
*ndr
, int flags
, const struct srvsvc_NetPathCanonicalize
*r
)
17913 if (flags
& NDR_IN
) {
17914 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->in
.server_unc
));
17915 if (r
->in
.server_unc
) {
17916 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.server_unc
, CH_UTF16
)));
17917 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
17918 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.server_unc
, CH_UTF16
)));
17919 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
));
17921 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.path
, CH_UTF16
)));
17922 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
17923 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.path
, CH_UTF16
)));
17924 NDR_CHECK(ndr_push_charset(ndr
, NDR_SCALARS
, r
->in
.path
, ndr_charset_length(r
->in
.path
, CH_UTF16
), sizeof(uint16_t), CH_UTF16
));
17925 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->in
.maxbuf
));
17926 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.prefix
, CH_UTF16
)));
17927 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
17928 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.prefix
, CH_UTF16
)));
17929 NDR_CHECK(ndr_push_charset(ndr
, NDR_SCALARS
, r
->in
.prefix
, ndr_charset_length(r
->in
.prefix
, CH_UTF16
), sizeof(uint16_t), CH_UTF16
));
17930 if (r
->in
.pathtype
== NULL
) {
17931 return ndr_push_error(ndr
, NDR_ERR_INVALID_POINTER
, "NULL [ref] pointer");
17933 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, *r
->in
.pathtype
));
17934 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->in
.pathflags
));
17936 if (flags
& NDR_OUT
) {
17937 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->in
.maxbuf
));
17938 NDR_CHECK(ndr_push_array_uint8(ndr
, NDR_SCALARS
, r
->out
.can_path
, r
->in
.maxbuf
));
17939 if (r
->out
.pathtype
== NULL
) {
17940 return ndr_push_error(ndr
, NDR_ERR_INVALID_POINTER
, "NULL [ref] pointer");
17942 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, *r
->out
.pathtype
));
17943 NDR_CHECK(ndr_push_WERROR(ndr
, NDR_SCALARS
, r
->out
.result
));
17945 return NDR_ERR_SUCCESS
;
17948 static enum ndr_err_code
ndr_pull_srvsvc_NetPathCanonicalize(struct ndr_pull
*ndr
, int flags
, struct srvsvc_NetPathCanonicalize
*r
)
17950 uint32_t _ptr_server_unc
;
17951 uint32_t size_server_unc_1
= 0;
17952 uint32_t length_server_unc_1
= 0;
17953 uint32_t size_path_0
= 0;
17954 uint32_t length_path_0
= 0;
17955 uint32_t size_can_path_0
= 0;
17956 uint32_t size_prefix_0
= 0;
17957 uint32_t length_prefix_0
= 0;
17958 TALLOC_CTX
*_mem_save_server_unc_0
;
17959 TALLOC_CTX
*_mem_save_pathtype_0
;
17960 if (flags
& NDR_IN
) {
17961 ZERO_STRUCT(r
->out
);
17963 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_server_unc
));
17964 if (_ptr_server_unc
) {
17965 NDR_PULL_ALLOC(ndr
, r
->in
.server_unc
);
17967 r
->in
.server_unc
= NULL
;
17969 if (r
->in
.server_unc
) {
17970 _mem_save_server_unc_0
= NDR_PULL_GET_MEM_CTX(ndr
);
17971 NDR_PULL_SET_MEM_CTX(ndr
, r
->in
.server_unc
, 0);
17972 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->in
.server_unc
));
17973 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->in
.server_unc
));
17974 size_server_unc_1
= ndr_get_array_size(ndr
, &r
->in
.server_unc
);
17975 length_server_unc_1
= ndr_get_array_length(ndr
, &r
->in
.server_unc
);
17976 if (length_server_unc_1
> size_server_unc_1
) {
17977 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", size_server_unc_1
, length_server_unc_1
);
17979 NDR_CHECK(ndr_check_string_terminator(ndr
, length_server_unc_1
, sizeof(uint16_t)));
17980 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->in
.server_unc
, length_server_unc_1
, sizeof(uint16_t), CH_UTF16
));
17981 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_server_unc_0
, 0);
17983 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->in
.path
));
17984 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->in
.path
));
17985 size_path_0
= ndr_get_array_size(ndr
, &r
->in
.path
);
17986 length_path_0
= ndr_get_array_length(ndr
, &r
->in
.path
);
17987 if (length_path_0
> size_path_0
) {
17988 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", size_path_0
, length_path_0
);
17990 NDR_CHECK(ndr_check_string_terminator(ndr
, length_path_0
, sizeof(uint16_t)));
17991 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->in
.path
, length_path_0
, sizeof(uint16_t), CH_UTF16
));
17992 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->in
.maxbuf
));
17993 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->in
.prefix
));
17994 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->in
.prefix
));
17995 size_prefix_0
= ndr_get_array_size(ndr
, &r
->in
.prefix
);
17996 length_prefix_0
= ndr_get_array_length(ndr
, &r
->in
.prefix
);
17997 if (length_prefix_0
> size_prefix_0
) {
17998 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", size_prefix_0
, length_prefix_0
);
18000 NDR_CHECK(ndr_check_string_terminator(ndr
, length_prefix_0
, sizeof(uint16_t)));
18001 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->in
.prefix
, length_prefix_0
, sizeof(uint16_t), CH_UTF16
));
18002 if (ndr
->flags
& LIBNDR_FLAG_REF_ALLOC
) {
18003 NDR_PULL_ALLOC(ndr
, r
->in
.pathtype
);
18005 _mem_save_pathtype_0
= NDR_PULL_GET_MEM_CTX(ndr
);
18006 NDR_PULL_SET_MEM_CTX(ndr
, r
->in
.pathtype
, LIBNDR_FLAG_REF_ALLOC
);
18007 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, r
->in
.pathtype
));
18008 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_pathtype_0
, LIBNDR_FLAG_REF_ALLOC
);
18009 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->in
.pathflags
));
18010 NDR_PULL_ALLOC(ndr
, r
->out
.pathtype
);
18011 *r
->out
.pathtype
= *r
->in
.pathtype
;
18013 if (flags
& NDR_OUT
) {
18014 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->out
.can_path
));
18015 size_can_path_0
= ndr_get_array_size(ndr
, &r
->out
.can_path
);
18016 NDR_PULL_ALLOC_N(ndr
, r
->out
.can_path
, size_can_path_0
);
18017 NDR_CHECK(ndr_pull_array_uint8(ndr
, NDR_SCALARS
, r
->out
.can_path
, size_can_path_0
));
18018 if (ndr
->flags
& LIBNDR_FLAG_REF_ALLOC
) {
18019 NDR_PULL_ALLOC(ndr
, r
->out
.pathtype
);
18021 _mem_save_pathtype_0
= NDR_PULL_GET_MEM_CTX(ndr
);
18022 NDR_PULL_SET_MEM_CTX(ndr
, r
->out
.pathtype
, LIBNDR_FLAG_REF_ALLOC
);
18023 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, r
->out
.pathtype
));
18024 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_pathtype_0
, LIBNDR_FLAG_REF_ALLOC
);
18025 NDR_CHECK(ndr_pull_WERROR(ndr
, NDR_SCALARS
, &r
->out
.result
));
18026 if (r
->out
.can_path
) {
18027 NDR_CHECK(ndr_check_array_size(ndr
, (void*)&r
->out
.can_path
, r
->in
.maxbuf
));
18030 return NDR_ERR_SUCCESS
;
18033 _PUBLIC_
void ndr_print_srvsvc_NetPathCanonicalize(struct ndr_print
*ndr
, const char *name
, int flags
, const struct srvsvc_NetPathCanonicalize
*r
)
18035 ndr_print_struct(ndr
, name
, "srvsvc_NetPathCanonicalize");
18037 if (flags
& NDR_SET_VALUES
) {
18038 ndr
->flags
|= LIBNDR_PRINT_SET_VALUES
;
18040 if (flags
& NDR_IN
) {
18041 ndr_print_struct(ndr
, "in", "srvsvc_NetPathCanonicalize");
18043 ndr_print_ptr(ndr
, "server_unc", r
->in
.server_unc
);
18045 if (r
->in
.server_unc
) {
18046 ndr_print_string(ndr
, "server_unc", r
->in
.server_unc
);
18049 ndr_print_string(ndr
, "path", r
->in
.path
);
18050 ndr_print_uint32(ndr
, "maxbuf", r
->in
.maxbuf
);
18051 ndr_print_string(ndr
, "prefix", r
->in
.prefix
);
18052 ndr_print_ptr(ndr
, "pathtype", r
->in
.pathtype
);
18054 ndr_print_uint32(ndr
, "pathtype", *r
->in
.pathtype
);
18056 ndr_print_uint32(ndr
, "pathflags", r
->in
.pathflags
);
18059 if (flags
& NDR_OUT
) {
18060 ndr_print_struct(ndr
, "out", "srvsvc_NetPathCanonicalize");
18062 ndr_print_array_uint8(ndr
, "can_path", r
->out
.can_path
, r
->in
.maxbuf
);
18063 ndr_print_ptr(ndr
, "pathtype", r
->out
.pathtype
);
18065 ndr_print_uint32(ndr
, "pathtype", *r
->out
.pathtype
);
18067 ndr_print_WERROR(ndr
, "result", r
->out
.result
);
18073 static enum ndr_err_code
ndr_push_srvsvc_NetPathCompare(struct ndr_push
*ndr
, int flags
, const struct srvsvc_NetPathCompare
*r
)
18075 if (flags
& NDR_IN
) {
18076 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->in
.server_unc
));
18077 if (r
->in
.server_unc
) {
18078 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.server_unc
, CH_UTF16
)));
18079 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
18080 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.server_unc
, CH_UTF16
)));
18081 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
));
18083 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.path1
, CH_UTF16
)));
18084 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
18085 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.path1
, CH_UTF16
)));
18086 NDR_CHECK(ndr_push_charset(ndr
, NDR_SCALARS
, r
->in
.path1
, ndr_charset_length(r
->in
.path1
, CH_UTF16
), sizeof(uint16_t), CH_UTF16
));
18087 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.path2
, CH_UTF16
)));
18088 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
18089 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.path2
, CH_UTF16
)));
18090 NDR_CHECK(ndr_push_charset(ndr
, NDR_SCALARS
, r
->in
.path2
, ndr_charset_length(r
->in
.path2
, CH_UTF16
), sizeof(uint16_t), CH_UTF16
));
18091 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->in
.pathtype
));
18092 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->in
.pathflags
));
18094 if (flags
& NDR_OUT
) {
18095 NDR_CHECK(ndr_push_WERROR(ndr
, NDR_SCALARS
, r
->out
.result
));
18097 return NDR_ERR_SUCCESS
;
18100 static enum ndr_err_code
ndr_pull_srvsvc_NetPathCompare(struct ndr_pull
*ndr
, int flags
, struct srvsvc_NetPathCompare
*r
)
18102 uint32_t _ptr_server_unc
;
18103 uint32_t size_server_unc_1
= 0;
18104 uint32_t length_server_unc_1
= 0;
18105 uint32_t size_path1_0
= 0;
18106 uint32_t length_path1_0
= 0;
18107 uint32_t size_path2_0
= 0;
18108 uint32_t length_path2_0
= 0;
18109 TALLOC_CTX
*_mem_save_server_unc_0
;
18110 if (flags
& NDR_IN
) {
18111 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_server_unc
));
18112 if (_ptr_server_unc
) {
18113 NDR_PULL_ALLOC(ndr
, r
->in
.server_unc
);
18115 r
->in
.server_unc
= NULL
;
18117 if (r
->in
.server_unc
) {
18118 _mem_save_server_unc_0
= NDR_PULL_GET_MEM_CTX(ndr
);
18119 NDR_PULL_SET_MEM_CTX(ndr
, r
->in
.server_unc
, 0);
18120 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->in
.server_unc
));
18121 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->in
.server_unc
));
18122 size_server_unc_1
= ndr_get_array_size(ndr
, &r
->in
.server_unc
);
18123 length_server_unc_1
= ndr_get_array_length(ndr
, &r
->in
.server_unc
);
18124 if (length_server_unc_1
> size_server_unc_1
) {
18125 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", size_server_unc_1
, length_server_unc_1
);
18127 NDR_CHECK(ndr_check_string_terminator(ndr
, length_server_unc_1
, sizeof(uint16_t)));
18128 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->in
.server_unc
, length_server_unc_1
, sizeof(uint16_t), CH_UTF16
));
18129 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_server_unc_0
, 0);
18131 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->in
.path1
));
18132 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->in
.path1
));
18133 size_path1_0
= ndr_get_array_size(ndr
, &r
->in
.path1
);
18134 length_path1_0
= ndr_get_array_length(ndr
, &r
->in
.path1
);
18135 if (length_path1_0
> size_path1_0
) {
18136 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", size_path1_0
, length_path1_0
);
18138 NDR_CHECK(ndr_check_string_terminator(ndr
, length_path1_0
, sizeof(uint16_t)));
18139 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->in
.path1
, length_path1_0
, sizeof(uint16_t), CH_UTF16
));
18140 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->in
.path2
));
18141 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->in
.path2
));
18142 size_path2_0
= ndr_get_array_size(ndr
, &r
->in
.path2
);
18143 length_path2_0
= ndr_get_array_length(ndr
, &r
->in
.path2
);
18144 if (length_path2_0
> size_path2_0
) {
18145 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", size_path2_0
, length_path2_0
);
18147 NDR_CHECK(ndr_check_string_terminator(ndr
, length_path2_0
, sizeof(uint16_t)));
18148 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->in
.path2
, length_path2_0
, sizeof(uint16_t), CH_UTF16
));
18149 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->in
.pathtype
));
18150 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->in
.pathflags
));
18152 if (flags
& NDR_OUT
) {
18153 NDR_CHECK(ndr_pull_WERROR(ndr
, NDR_SCALARS
, &r
->out
.result
));
18155 return NDR_ERR_SUCCESS
;
18158 _PUBLIC_
void ndr_print_srvsvc_NetPathCompare(struct ndr_print
*ndr
, const char *name
, int flags
, const struct srvsvc_NetPathCompare
*r
)
18160 ndr_print_struct(ndr
, name
, "srvsvc_NetPathCompare");
18162 if (flags
& NDR_SET_VALUES
) {
18163 ndr
->flags
|= LIBNDR_PRINT_SET_VALUES
;
18165 if (flags
& NDR_IN
) {
18166 ndr_print_struct(ndr
, "in", "srvsvc_NetPathCompare");
18168 ndr_print_ptr(ndr
, "server_unc", r
->in
.server_unc
);
18170 if (r
->in
.server_unc
) {
18171 ndr_print_string(ndr
, "server_unc", r
->in
.server_unc
);
18174 ndr_print_string(ndr
, "path1", r
->in
.path1
);
18175 ndr_print_string(ndr
, "path2", r
->in
.path2
);
18176 ndr_print_uint32(ndr
, "pathtype", r
->in
.pathtype
);
18177 ndr_print_uint32(ndr
, "pathflags", r
->in
.pathflags
);
18180 if (flags
& NDR_OUT
) {
18181 ndr_print_struct(ndr
, "out", "srvsvc_NetPathCompare");
18183 ndr_print_WERROR(ndr
, "result", r
->out
.result
);
18189 static enum ndr_err_code
ndr_push_srvsvc_NetNameValidate(struct ndr_push
*ndr
, int flags
, const struct srvsvc_NetNameValidate
*r
)
18191 if (flags
& NDR_IN
) {
18192 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->in
.server_unc
));
18193 if (r
->in
.server_unc
) {
18194 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.server_unc
, CH_UTF16
)));
18195 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
18196 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.server_unc
, CH_UTF16
)));
18197 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
));
18199 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.name
, CH_UTF16
)));
18200 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
18201 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.name
, CH_UTF16
)));
18202 NDR_CHECK(ndr_push_charset(ndr
, NDR_SCALARS
, r
->in
.name
, ndr_charset_length(r
->in
.name
, CH_UTF16
), sizeof(uint16_t), CH_UTF16
));
18203 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->in
.name_type
));
18204 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->in
.flags
));
18206 if (flags
& NDR_OUT
) {
18207 NDR_CHECK(ndr_push_WERROR(ndr
, NDR_SCALARS
, r
->out
.result
));
18209 return NDR_ERR_SUCCESS
;
18212 static enum ndr_err_code
ndr_pull_srvsvc_NetNameValidate(struct ndr_pull
*ndr
, int flags
, struct srvsvc_NetNameValidate
*r
)
18214 uint32_t _ptr_server_unc
;
18215 uint32_t size_server_unc_1
= 0;
18216 uint32_t length_server_unc_1
= 0;
18217 uint32_t size_name_0
= 0;
18218 uint32_t length_name_0
= 0;
18219 TALLOC_CTX
*_mem_save_server_unc_0
;
18220 if (flags
& NDR_IN
) {
18221 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_server_unc
));
18222 if (_ptr_server_unc
) {
18223 NDR_PULL_ALLOC(ndr
, r
->in
.server_unc
);
18225 r
->in
.server_unc
= NULL
;
18227 if (r
->in
.server_unc
) {
18228 _mem_save_server_unc_0
= NDR_PULL_GET_MEM_CTX(ndr
);
18229 NDR_PULL_SET_MEM_CTX(ndr
, r
->in
.server_unc
, 0);
18230 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->in
.server_unc
));
18231 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->in
.server_unc
));
18232 size_server_unc_1
= ndr_get_array_size(ndr
, &r
->in
.server_unc
);
18233 length_server_unc_1
= ndr_get_array_length(ndr
, &r
->in
.server_unc
);
18234 if (length_server_unc_1
> size_server_unc_1
) {
18235 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", size_server_unc_1
, length_server_unc_1
);
18237 NDR_CHECK(ndr_check_string_terminator(ndr
, length_server_unc_1
, sizeof(uint16_t)));
18238 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->in
.server_unc
, length_server_unc_1
, sizeof(uint16_t), CH_UTF16
));
18239 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_server_unc_0
, 0);
18241 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->in
.name
));
18242 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->in
.name
));
18243 size_name_0
= ndr_get_array_size(ndr
, &r
->in
.name
);
18244 length_name_0
= ndr_get_array_length(ndr
, &r
->in
.name
);
18245 if (length_name_0
> size_name_0
) {
18246 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", size_name_0
, length_name_0
);
18248 NDR_CHECK(ndr_check_string_terminator(ndr
, length_name_0
, sizeof(uint16_t)));
18249 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->in
.name
, length_name_0
, sizeof(uint16_t), CH_UTF16
));
18250 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->in
.name_type
));
18251 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->in
.flags
));
18253 if (flags
& NDR_OUT
) {
18254 NDR_CHECK(ndr_pull_WERROR(ndr
, NDR_SCALARS
, &r
->out
.result
));
18256 return NDR_ERR_SUCCESS
;
18259 _PUBLIC_
void ndr_print_srvsvc_NetNameValidate(struct ndr_print
*ndr
, const char *name
, int flags
, const struct srvsvc_NetNameValidate
*r
)
18261 ndr_print_struct(ndr
, name
, "srvsvc_NetNameValidate");
18263 if (flags
& NDR_SET_VALUES
) {
18264 ndr
->flags
|= LIBNDR_PRINT_SET_VALUES
;
18266 if (flags
& NDR_IN
) {
18267 ndr_print_struct(ndr
, "in", "srvsvc_NetNameValidate");
18269 ndr_print_ptr(ndr
, "server_unc", r
->in
.server_unc
);
18271 if (r
->in
.server_unc
) {
18272 ndr_print_string(ndr
, "server_unc", r
->in
.server_unc
);
18275 ndr_print_string(ndr
, "name", r
->in
.name
);
18276 ndr_print_uint32(ndr
, "name_type", r
->in
.name_type
);
18277 ndr_print_uint32(ndr
, "flags", r
->in
.flags
);
18280 if (flags
& NDR_OUT
) {
18281 ndr_print_struct(ndr
, "out", "srvsvc_NetNameValidate");
18283 ndr_print_WERROR(ndr
, "result", r
->out
.result
);
18289 static enum ndr_err_code
ndr_push_srvsvc_NETRPRNAMECANONICALIZE(struct ndr_push
*ndr
, int flags
, const struct srvsvc_NETRPRNAMECANONICALIZE
*r
)
18291 if (flags
& NDR_IN
) {
18293 if (flags
& NDR_OUT
) {
18294 NDR_CHECK(ndr_push_WERROR(ndr
, NDR_SCALARS
, r
->out
.result
));
18296 return NDR_ERR_SUCCESS
;
18299 static enum ndr_err_code
ndr_pull_srvsvc_NETRPRNAMECANONICALIZE(struct ndr_pull
*ndr
, int flags
, struct srvsvc_NETRPRNAMECANONICALIZE
*r
)
18301 if (flags
& NDR_IN
) {
18303 if (flags
& NDR_OUT
) {
18304 NDR_CHECK(ndr_pull_WERROR(ndr
, NDR_SCALARS
, &r
->out
.result
));
18306 return NDR_ERR_SUCCESS
;
18309 _PUBLIC_
void ndr_print_srvsvc_NETRPRNAMECANONICALIZE(struct ndr_print
*ndr
, const char *name
, int flags
, const struct srvsvc_NETRPRNAMECANONICALIZE
*r
)
18311 ndr_print_struct(ndr
, name
, "srvsvc_NETRPRNAMECANONICALIZE");
18313 if (flags
& NDR_SET_VALUES
) {
18314 ndr
->flags
|= LIBNDR_PRINT_SET_VALUES
;
18316 if (flags
& NDR_IN
) {
18317 ndr_print_struct(ndr
, "in", "srvsvc_NETRPRNAMECANONICALIZE");
18321 if (flags
& NDR_OUT
) {
18322 ndr_print_struct(ndr
, "out", "srvsvc_NETRPRNAMECANONICALIZE");
18324 ndr_print_WERROR(ndr
, "result", r
->out
.result
);
18330 static enum ndr_err_code
ndr_push_srvsvc_NetPRNameCompare(struct ndr_push
*ndr
, int flags
, const struct srvsvc_NetPRNameCompare
*r
)
18332 if (flags
& NDR_IN
) {
18333 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->in
.server_unc
));
18334 if (r
->in
.server_unc
) {
18335 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.server_unc
, CH_UTF16
)));
18336 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
18337 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.server_unc
, CH_UTF16
)));
18338 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
));
18340 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.name1
, CH_UTF16
)));
18341 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
18342 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.name1
, CH_UTF16
)));
18343 NDR_CHECK(ndr_push_charset(ndr
, NDR_SCALARS
, r
->in
.name1
, ndr_charset_length(r
->in
.name1
, CH_UTF16
), sizeof(uint16_t), CH_UTF16
));
18344 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.name2
, CH_UTF16
)));
18345 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
18346 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.name2
, CH_UTF16
)));
18347 NDR_CHECK(ndr_push_charset(ndr
, NDR_SCALARS
, r
->in
.name2
, ndr_charset_length(r
->in
.name2
, CH_UTF16
), sizeof(uint16_t), CH_UTF16
));
18348 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->in
.name_type
));
18349 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->in
.flags
));
18351 if (flags
& NDR_OUT
) {
18352 NDR_CHECK(ndr_push_WERROR(ndr
, NDR_SCALARS
, r
->out
.result
));
18354 return NDR_ERR_SUCCESS
;
18357 static enum ndr_err_code
ndr_pull_srvsvc_NetPRNameCompare(struct ndr_pull
*ndr
, int flags
, struct srvsvc_NetPRNameCompare
*r
)
18359 uint32_t _ptr_server_unc
;
18360 uint32_t size_server_unc_1
= 0;
18361 uint32_t length_server_unc_1
= 0;
18362 uint32_t size_name1_0
= 0;
18363 uint32_t length_name1_0
= 0;
18364 uint32_t size_name2_0
= 0;
18365 uint32_t length_name2_0
= 0;
18366 TALLOC_CTX
*_mem_save_server_unc_0
;
18367 if (flags
& NDR_IN
) {
18368 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_server_unc
));
18369 if (_ptr_server_unc
) {
18370 NDR_PULL_ALLOC(ndr
, r
->in
.server_unc
);
18372 r
->in
.server_unc
= NULL
;
18374 if (r
->in
.server_unc
) {
18375 _mem_save_server_unc_0
= NDR_PULL_GET_MEM_CTX(ndr
);
18376 NDR_PULL_SET_MEM_CTX(ndr
, r
->in
.server_unc
, 0);
18377 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->in
.server_unc
));
18378 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->in
.server_unc
));
18379 size_server_unc_1
= ndr_get_array_size(ndr
, &r
->in
.server_unc
);
18380 length_server_unc_1
= ndr_get_array_length(ndr
, &r
->in
.server_unc
);
18381 if (length_server_unc_1
> size_server_unc_1
) {
18382 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", size_server_unc_1
, length_server_unc_1
);
18384 NDR_CHECK(ndr_check_string_terminator(ndr
, length_server_unc_1
, sizeof(uint16_t)));
18385 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->in
.server_unc
, length_server_unc_1
, sizeof(uint16_t), CH_UTF16
));
18386 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_server_unc_0
, 0);
18388 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->in
.name1
));
18389 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->in
.name1
));
18390 size_name1_0
= ndr_get_array_size(ndr
, &r
->in
.name1
);
18391 length_name1_0
= ndr_get_array_length(ndr
, &r
->in
.name1
);
18392 if (length_name1_0
> size_name1_0
) {
18393 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", size_name1_0
, length_name1_0
);
18395 NDR_CHECK(ndr_check_string_terminator(ndr
, length_name1_0
, sizeof(uint16_t)));
18396 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->in
.name1
, length_name1_0
, sizeof(uint16_t), CH_UTF16
));
18397 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->in
.name2
));
18398 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->in
.name2
));
18399 size_name2_0
= ndr_get_array_size(ndr
, &r
->in
.name2
);
18400 length_name2_0
= ndr_get_array_length(ndr
, &r
->in
.name2
);
18401 if (length_name2_0
> size_name2_0
) {
18402 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", size_name2_0
, length_name2_0
);
18404 NDR_CHECK(ndr_check_string_terminator(ndr
, length_name2_0
, sizeof(uint16_t)));
18405 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->in
.name2
, length_name2_0
, sizeof(uint16_t), CH_UTF16
));
18406 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->in
.name_type
));
18407 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->in
.flags
));
18409 if (flags
& NDR_OUT
) {
18410 NDR_CHECK(ndr_pull_WERROR(ndr
, NDR_SCALARS
, &r
->out
.result
));
18412 return NDR_ERR_SUCCESS
;
18415 _PUBLIC_
void ndr_print_srvsvc_NetPRNameCompare(struct ndr_print
*ndr
, const char *name
, int flags
, const struct srvsvc_NetPRNameCompare
*r
)
18417 ndr_print_struct(ndr
, name
, "srvsvc_NetPRNameCompare");
18419 if (flags
& NDR_SET_VALUES
) {
18420 ndr
->flags
|= LIBNDR_PRINT_SET_VALUES
;
18422 if (flags
& NDR_IN
) {
18423 ndr_print_struct(ndr
, "in", "srvsvc_NetPRNameCompare");
18425 ndr_print_ptr(ndr
, "server_unc", r
->in
.server_unc
);
18427 if (r
->in
.server_unc
) {
18428 ndr_print_string(ndr
, "server_unc", r
->in
.server_unc
);
18431 ndr_print_string(ndr
, "name1", r
->in
.name1
);
18432 ndr_print_string(ndr
, "name2", r
->in
.name2
);
18433 ndr_print_uint32(ndr
, "name_type", r
->in
.name_type
);
18434 ndr_print_uint32(ndr
, "flags", r
->in
.flags
);
18437 if (flags
& NDR_OUT
) {
18438 ndr_print_struct(ndr
, "out", "srvsvc_NetPRNameCompare");
18440 ndr_print_WERROR(ndr
, "result", r
->out
.result
);
18446 static enum ndr_err_code
ndr_push_srvsvc_NetShareEnum(struct ndr_push
*ndr
, int flags
, const struct srvsvc_NetShareEnum
*r
)
18448 if (flags
& NDR_IN
) {
18449 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->in
.server_unc
));
18450 if (r
->in
.server_unc
) {
18451 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.server_unc
, CH_UTF16
)));
18452 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
18453 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.server_unc
, CH_UTF16
)));
18454 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
));
18456 if (r
->in
.info_ctr
== NULL
) {
18457 return ndr_push_error(ndr
, NDR_ERR_INVALID_POINTER
, "NULL [ref] pointer");
18459 NDR_CHECK(ndr_push_srvsvc_NetShareInfoCtr(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->in
.info_ctr
));
18460 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->in
.max_buffer
));
18461 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->in
.resume_handle
));
18462 if (r
->in
.resume_handle
) {
18463 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, *r
->in
.resume_handle
));
18466 if (flags
& NDR_OUT
) {
18467 if (r
->out
.info_ctr
== NULL
) {
18468 return ndr_push_error(ndr
, NDR_ERR_INVALID_POINTER
, "NULL [ref] pointer");
18470 NDR_CHECK(ndr_push_srvsvc_NetShareInfoCtr(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->out
.info_ctr
));
18471 if (r
->out
.totalentries
== NULL
) {
18472 return ndr_push_error(ndr
, NDR_ERR_INVALID_POINTER
, "NULL [ref] pointer");
18474 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, *r
->out
.totalentries
));
18475 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->out
.resume_handle
));
18476 if (r
->out
.resume_handle
) {
18477 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, *r
->out
.resume_handle
));
18479 NDR_CHECK(ndr_push_WERROR(ndr
, NDR_SCALARS
, r
->out
.result
));
18481 return NDR_ERR_SUCCESS
;
18484 static enum ndr_err_code
ndr_pull_srvsvc_NetShareEnum(struct ndr_pull
*ndr
, int flags
, struct srvsvc_NetShareEnum
*r
)
18486 uint32_t _ptr_server_unc
;
18487 uint32_t size_server_unc_1
= 0;
18488 uint32_t length_server_unc_1
= 0;
18489 uint32_t _ptr_resume_handle
;
18490 TALLOC_CTX
*_mem_save_server_unc_0
;
18491 TALLOC_CTX
*_mem_save_info_ctr_0
;
18492 TALLOC_CTX
*_mem_save_totalentries_0
;
18493 TALLOC_CTX
*_mem_save_resume_handle_0
;
18494 if (flags
& NDR_IN
) {
18495 ZERO_STRUCT(r
->out
);
18497 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_server_unc
));
18498 if (_ptr_server_unc
) {
18499 NDR_PULL_ALLOC(ndr
, r
->in
.server_unc
);
18501 r
->in
.server_unc
= NULL
;
18503 if (r
->in
.server_unc
) {
18504 _mem_save_server_unc_0
= NDR_PULL_GET_MEM_CTX(ndr
);
18505 NDR_PULL_SET_MEM_CTX(ndr
, r
->in
.server_unc
, 0);
18506 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->in
.server_unc
));
18507 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->in
.server_unc
));
18508 size_server_unc_1
= ndr_get_array_size(ndr
, &r
->in
.server_unc
);
18509 length_server_unc_1
= ndr_get_array_length(ndr
, &r
->in
.server_unc
);
18510 if (length_server_unc_1
> size_server_unc_1
) {
18511 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", size_server_unc_1
, length_server_unc_1
);
18513 NDR_CHECK(ndr_check_string_terminator(ndr
, length_server_unc_1
, sizeof(uint16_t)));
18514 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->in
.server_unc
, length_server_unc_1
, sizeof(uint16_t), CH_UTF16
));
18515 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_server_unc_0
, 0);
18517 if (ndr
->flags
& LIBNDR_FLAG_REF_ALLOC
) {
18518 NDR_PULL_ALLOC(ndr
, r
->in
.info_ctr
);
18520 _mem_save_info_ctr_0
= NDR_PULL_GET_MEM_CTX(ndr
);
18521 NDR_PULL_SET_MEM_CTX(ndr
, r
->in
.info_ctr
, LIBNDR_FLAG_REF_ALLOC
);
18522 NDR_CHECK(ndr_pull_srvsvc_NetShareInfoCtr(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->in
.info_ctr
));
18523 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_info_ctr_0
, LIBNDR_FLAG_REF_ALLOC
);
18524 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->in
.max_buffer
));
18525 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_resume_handle
));
18526 if (_ptr_resume_handle
) {
18527 NDR_PULL_ALLOC(ndr
, r
->in
.resume_handle
);
18529 r
->in
.resume_handle
= NULL
;
18531 if (r
->in
.resume_handle
) {
18532 _mem_save_resume_handle_0
= NDR_PULL_GET_MEM_CTX(ndr
);
18533 NDR_PULL_SET_MEM_CTX(ndr
, r
->in
.resume_handle
, 0);
18534 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, r
->in
.resume_handle
));
18535 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_resume_handle_0
, 0);
18537 NDR_PULL_ALLOC(ndr
, r
->out
.info_ctr
);
18538 *r
->out
.info_ctr
= *r
->in
.info_ctr
;
18539 NDR_PULL_ALLOC(ndr
, r
->out
.totalentries
);
18540 ZERO_STRUCTP(r
->out
.totalentries
);
18542 if (flags
& NDR_OUT
) {
18543 if (ndr
->flags
& LIBNDR_FLAG_REF_ALLOC
) {
18544 NDR_PULL_ALLOC(ndr
, r
->out
.info_ctr
);
18546 _mem_save_info_ctr_0
= NDR_PULL_GET_MEM_CTX(ndr
);
18547 NDR_PULL_SET_MEM_CTX(ndr
, r
->out
.info_ctr
, LIBNDR_FLAG_REF_ALLOC
);
18548 NDR_CHECK(ndr_pull_srvsvc_NetShareInfoCtr(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->out
.info_ctr
));
18549 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_info_ctr_0
, LIBNDR_FLAG_REF_ALLOC
);
18550 if (ndr
->flags
& LIBNDR_FLAG_REF_ALLOC
) {
18551 NDR_PULL_ALLOC(ndr
, r
->out
.totalentries
);
18553 _mem_save_totalentries_0
= NDR_PULL_GET_MEM_CTX(ndr
);
18554 NDR_PULL_SET_MEM_CTX(ndr
, r
->out
.totalentries
, LIBNDR_FLAG_REF_ALLOC
);
18555 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, r
->out
.totalentries
));
18556 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_totalentries_0
, LIBNDR_FLAG_REF_ALLOC
);
18557 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_resume_handle
));
18558 if (_ptr_resume_handle
) {
18559 NDR_PULL_ALLOC(ndr
, r
->out
.resume_handle
);
18561 r
->out
.resume_handle
= NULL
;
18563 if (r
->out
.resume_handle
) {
18564 _mem_save_resume_handle_0
= NDR_PULL_GET_MEM_CTX(ndr
);
18565 NDR_PULL_SET_MEM_CTX(ndr
, r
->out
.resume_handle
, 0);
18566 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, r
->out
.resume_handle
));
18567 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_resume_handle_0
, 0);
18569 NDR_CHECK(ndr_pull_WERROR(ndr
, NDR_SCALARS
, &r
->out
.result
));
18571 return NDR_ERR_SUCCESS
;
18574 _PUBLIC_
void ndr_print_srvsvc_NetShareEnum(struct ndr_print
*ndr
, const char *name
, int flags
, const struct srvsvc_NetShareEnum
*r
)
18576 ndr_print_struct(ndr
, name
, "srvsvc_NetShareEnum");
18578 if (flags
& NDR_SET_VALUES
) {
18579 ndr
->flags
|= LIBNDR_PRINT_SET_VALUES
;
18581 if (flags
& NDR_IN
) {
18582 ndr_print_struct(ndr
, "in", "srvsvc_NetShareEnum");
18584 ndr_print_ptr(ndr
, "server_unc", r
->in
.server_unc
);
18586 if (r
->in
.server_unc
) {
18587 ndr_print_string(ndr
, "server_unc", r
->in
.server_unc
);
18590 ndr_print_ptr(ndr
, "info_ctr", r
->in
.info_ctr
);
18592 ndr_print_srvsvc_NetShareInfoCtr(ndr
, "info_ctr", r
->in
.info_ctr
);
18594 ndr_print_uint32(ndr
, "max_buffer", r
->in
.max_buffer
);
18595 ndr_print_ptr(ndr
, "resume_handle", r
->in
.resume_handle
);
18597 if (r
->in
.resume_handle
) {
18598 ndr_print_uint32(ndr
, "resume_handle", *r
->in
.resume_handle
);
18603 if (flags
& NDR_OUT
) {
18604 ndr_print_struct(ndr
, "out", "srvsvc_NetShareEnum");
18606 ndr_print_ptr(ndr
, "info_ctr", r
->out
.info_ctr
);
18608 ndr_print_srvsvc_NetShareInfoCtr(ndr
, "info_ctr", r
->out
.info_ctr
);
18610 ndr_print_ptr(ndr
, "totalentries", r
->out
.totalentries
);
18612 ndr_print_uint32(ndr
, "totalentries", *r
->out
.totalentries
);
18614 ndr_print_ptr(ndr
, "resume_handle", r
->out
.resume_handle
);
18616 if (r
->out
.resume_handle
) {
18617 ndr_print_uint32(ndr
, "resume_handle", *r
->out
.resume_handle
);
18620 ndr_print_WERROR(ndr
, "result", r
->out
.result
);
18626 static enum ndr_err_code
ndr_push_srvsvc_NetShareDelStart(struct ndr_push
*ndr
, int flags
, const struct srvsvc_NetShareDelStart
*r
)
18628 if (flags
& NDR_IN
) {
18629 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->in
.server_unc
));
18630 if (r
->in
.server_unc
) {
18631 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.server_unc
, CH_UTF16
)));
18632 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
18633 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.server_unc
, CH_UTF16
)));
18634 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
));
18636 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.share
, CH_UTF16
)));
18637 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
18638 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.share
, CH_UTF16
)));
18639 NDR_CHECK(ndr_push_charset(ndr
, NDR_SCALARS
, r
->in
.share
, ndr_charset_length(r
->in
.share
, CH_UTF16
), sizeof(uint16_t), CH_UTF16
));
18640 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->in
.reserved
));
18642 if (flags
& NDR_OUT
) {
18643 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->out
.hnd
));
18645 NDR_CHECK(ndr_push_policy_handle(ndr
, NDR_SCALARS
, r
->out
.hnd
));
18647 NDR_CHECK(ndr_push_WERROR(ndr
, NDR_SCALARS
, r
->out
.result
));
18649 return NDR_ERR_SUCCESS
;
18652 static enum ndr_err_code
ndr_pull_srvsvc_NetShareDelStart(struct ndr_pull
*ndr
, int flags
, struct srvsvc_NetShareDelStart
*r
)
18654 uint32_t _ptr_server_unc
;
18655 uint32_t size_server_unc_1
= 0;
18656 uint32_t length_server_unc_1
= 0;
18657 uint32_t size_share_0
= 0;
18658 uint32_t length_share_0
= 0;
18660 TALLOC_CTX
*_mem_save_server_unc_0
;
18661 TALLOC_CTX
*_mem_save_hnd_0
;
18662 if (flags
& NDR_IN
) {
18663 ZERO_STRUCT(r
->out
);
18665 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_server_unc
));
18666 if (_ptr_server_unc
) {
18667 NDR_PULL_ALLOC(ndr
, r
->in
.server_unc
);
18669 r
->in
.server_unc
= NULL
;
18671 if (r
->in
.server_unc
) {
18672 _mem_save_server_unc_0
= NDR_PULL_GET_MEM_CTX(ndr
);
18673 NDR_PULL_SET_MEM_CTX(ndr
, r
->in
.server_unc
, 0);
18674 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->in
.server_unc
));
18675 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->in
.server_unc
));
18676 size_server_unc_1
= ndr_get_array_size(ndr
, &r
->in
.server_unc
);
18677 length_server_unc_1
= ndr_get_array_length(ndr
, &r
->in
.server_unc
);
18678 if (length_server_unc_1
> size_server_unc_1
) {
18679 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", size_server_unc_1
, length_server_unc_1
);
18681 NDR_CHECK(ndr_check_string_terminator(ndr
, length_server_unc_1
, sizeof(uint16_t)));
18682 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->in
.server_unc
, length_server_unc_1
, sizeof(uint16_t), CH_UTF16
));
18683 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_server_unc_0
, 0);
18685 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->in
.share
));
18686 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->in
.share
));
18687 size_share_0
= ndr_get_array_size(ndr
, &r
->in
.share
);
18688 length_share_0
= ndr_get_array_length(ndr
, &r
->in
.share
);
18689 if (length_share_0
> size_share_0
) {
18690 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", size_share_0
, length_share_0
);
18692 NDR_CHECK(ndr_check_string_terminator(ndr
, length_share_0
, sizeof(uint16_t)));
18693 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->in
.share
, length_share_0
, sizeof(uint16_t), CH_UTF16
));
18694 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->in
.reserved
));
18696 if (flags
& NDR_OUT
) {
18697 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_hnd
));
18699 NDR_PULL_ALLOC(ndr
, r
->out
.hnd
);
18704 _mem_save_hnd_0
= NDR_PULL_GET_MEM_CTX(ndr
);
18705 NDR_PULL_SET_MEM_CTX(ndr
, r
->out
.hnd
, 0);
18706 NDR_CHECK(ndr_pull_policy_handle(ndr
, NDR_SCALARS
, r
->out
.hnd
));
18707 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_hnd_0
, 0);
18709 NDR_CHECK(ndr_pull_WERROR(ndr
, NDR_SCALARS
, &r
->out
.result
));
18711 return NDR_ERR_SUCCESS
;
18714 _PUBLIC_
void ndr_print_srvsvc_NetShareDelStart(struct ndr_print
*ndr
, const char *name
, int flags
, const struct srvsvc_NetShareDelStart
*r
)
18716 ndr_print_struct(ndr
, name
, "srvsvc_NetShareDelStart");
18718 if (flags
& NDR_SET_VALUES
) {
18719 ndr
->flags
|= LIBNDR_PRINT_SET_VALUES
;
18721 if (flags
& NDR_IN
) {
18722 ndr_print_struct(ndr
, "in", "srvsvc_NetShareDelStart");
18724 ndr_print_ptr(ndr
, "server_unc", r
->in
.server_unc
);
18726 if (r
->in
.server_unc
) {
18727 ndr_print_string(ndr
, "server_unc", r
->in
.server_unc
);
18730 ndr_print_string(ndr
, "share", r
->in
.share
);
18731 ndr_print_uint32(ndr
, "reserved", r
->in
.reserved
);
18734 if (flags
& NDR_OUT
) {
18735 ndr_print_struct(ndr
, "out", "srvsvc_NetShareDelStart");
18737 ndr_print_ptr(ndr
, "hnd", r
->out
.hnd
);
18740 ndr_print_policy_handle(ndr
, "hnd", r
->out
.hnd
);
18743 ndr_print_WERROR(ndr
, "result", r
->out
.result
);
18749 static enum ndr_err_code
ndr_push_srvsvc_NetShareDelCommit(struct ndr_push
*ndr
, int flags
, const struct srvsvc_NetShareDelCommit
*r
)
18751 if (flags
& NDR_IN
) {
18752 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->in
.hnd
));
18754 NDR_CHECK(ndr_push_policy_handle(ndr
, NDR_SCALARS
, r
->in
.hnd
));
18757 if (flags
& NDR_OUT
) {
18758 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->out
.hnd
));
18760 NDR_CHECK(ndr_push_policy_handle(ndr
, NDR_SCALARS
, r
->out
.hnd
));
18762 NDR_CHECK(ndr_push_WERROR(ndr
, NDR_SCALARS
, r
->out
.result
));
18764 return NDR_ERR_SUCCESS
;
18767 static enum ndr_err_code
ndr_pull_srvsvc_NetShareDelCommit(struct ndr_pull
*ndr
, int flags
, struct srvsvc_NetShareDelCommit
*r
)
18770 TALLOC_CTX
*_mem_save_hnd_0
;
18771 if (flags
& NDR_IN
) {
18772 ZERO_STRUCT(r
->out
);
18774 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_hnd
));
18776 NDR_PULL_ALLOC(ndr
, r
->in
.hnd
);
18781 _mem_save_hnd_0
= NDR_PULL_GET_MEM_CTX(ndr
);
18782 NDR_PULL_SET_MEM_CTX(ndr
, r
->in
.hnd
, 0);
18783 NDR_CHECK(ndr_pull_policy_handle(ndr
, NDR_SCALARS
, r
->in
.hnd
));
18784 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_hnd_0
, 0);
18787 if (flags
& NDR_OUT
) {
18788 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_hnd
));
18790 NDR_PULL_ALLOC(ndr
, r
->out
.hnd
);
18795 _mem_save_hnd_0
= NDR_PULL_GET_MEM_CTX(ndr
);
18796 NDR_PULL_SET_MEM_CTX(ndr
, r
->out
.hnd
, 0);
18797 NDR_CHECK(ndr_pull_policy_handle(ndr
, NDR_SCALARS
, r
->out
.hnd
));
18798 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_hnd_0
, 0);
18800 NDR_CHECK(ndr_pull_WERROR(ndr
, NDR_SCALARS
, &r
->out
.result
));
18802 return NDR_ERR_SUCCESS
;
18805 _PUBLIC_
void ndr_print_srvsvc_NetShareDelCommit(struct ndr_print
*ndr
, const char *name
, int flags
, const struct srvsvc_NetShareDelCommit
*r
)
18807 ndr_print_struct(ndr
, name
, "srvsvc_NetShareDelCommit");
18809 if (flags
& NDR_SET_VALUES
) {
18810 ndr
->flags
|= LIBNDR_PRINT_SET_VALUES
;
18812 if (flags
& NDR_IN
) {
18813 ndr_print_struct(ndr
, "in", "srvsvc_NetShareDelCommit");
18815 ndr_print_ptr(ndr
, "hnd", r
->in
.hnd
);
18818 ndr_print_policy_handle(ndr
, "hnd", r
->in
.hnd
);
18823 if (flags
& NDR_OUT
) {
18824 ndr_print_struct(ndr
, "out", "srvsvc_NetShareDelCommit");
18826 ndr_print_ptr(ndr
, "hnd", r
->out
.hnd
);
18829 ndr_print_policy_handle(ndr
, "hnd", r
->out
.hnd
);
18832 ndr_print_WERROR(ndr
, "result", r
->out
.result
);
18838 static enum ndr_err_code
ndr_push_srvsvc_NetGetFileSecurity(struct ndr_push
*ndr
, int flags
, const struct srvsvc_NetGetFileSecurity
*r
)
18840 if (flags
& NDR_IN
) {
18841 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->in
.server_unc
));
18842 if (r
->in
.server_unc
) {
18843 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.server_unc
, CH_UTF16
)));
18844 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
18845 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.server_unc
, CH_UTF16
)));
18846 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
));
18848 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->in
.share
));
18850 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.share
, CH_UTF16
)));
18851 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
18852 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.share
, CH_UTF16
)));
18853 NDR_CHECK(ndr_push_charset(ndr
, NDR_SCALARS
, r
->in
.share
, ndr_charset_length(r
->in
.share
, CH_UTF16
), sizeof(uint16_t), CH_UTF16
));
18855 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.file
, CH_UTF16
)));
18856 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
18857 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.file
, CH_UTF16
)));
18858 NDR_CHECK(ndr_push_charset(ndr
, NDR_SCALARS
, r
->in
.file
, ndr_charset_length(r
->in
.file
, CH_UTF16
), sizeof(uint16_t), CH_UTF16
));
18859 NDR_CHECK(ndr_push_security_secinfo(ndr
, NDR_SCALARS
, r
->in
.securityinformation
));
18861 if (flags
& NDR_OUT
) {
18862 if (r
->out
.sd_buf
== NULL
) {
18863 return ndr_push_error(ndr
, NDR_ERR_INVALID_POINTER
, "NULL [ref] pointer");
18865 NDR_CHECK(ndr_push_unique_ptr(ndr
, *r
->out
.sd_buf
));
18866 if (*r
->out
.sd_buf
) {
18867 NDR_CHECK(ndr_push_sec_desc_buf(ndr
, NDR_SCALARS
|NDR_BUFFERS
, *r
->out
.sd_buf
));
18869 NDR_CHECK(ndr_push_WERROR(ndr
, NDR_SCALARS
, r
->out
.result
));
18871 return NDR_ERR_SUCCESS
;
18874 static enum ndr_err_code
ndr_pull_srvsvc_NetGetFileSecurity(struct ndr_pull
*ndr
, int flags
, struct srvsvc_NetGetFileSecurity
*r
)
18876 uint32_t _ptr_server_unc
;
18877 uint32_t size_server_unc_1
= 0;
18878 uint32_t length_server_unc_1
= 0;
18879 uint32_t _ptr_share
;
18880 uint32_t size_share_1
= 0;
18881 uint32_t length_share_1
= 0;
18882 uint32_t size_file_0
= 0;
18883 uint32_t length_file_0
= 0;
18884 uint32_t _ptr_sd_buf
;
18885 TALLOC_CTX
*_mem_save_server_unc_0
;
18886 TALLOC_CTX
*_mem_save_share_0
;
18887 TALLOC_CTX
*_mem_save_sd_buf_0
;
18888 TALLOC_CTX
*_mem_save_sd_buf_1
;
18889 if (flags
& NDR_IN
) {
18890 ZERO_STRUCT(r
->out
);
18892 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_server_unc
));
18893 if (_ptr_server_unc
) {
18894 NDR_PULL_ALLOC(ndr
, r
->in
.server_unc
);
18896 r
->in
.server_unc
= NULL
;
18898 if (r
->in
.server_unc
) {
18899 _mem_save_server_unc_0
= NDR_PULL_GET_MEM_CTX(ndr
);
18900 NDR_PULL_SET_MEM_CTX(ndr
, r
->in
.server_unc
, 0);
18901 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->in
.server_unc
));
18902 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->in
.server_unc
));
18903 size_server_unc_1
= ndr_get_array_size(ndr
, &r
->in
.server_unc
);
18904 length_server_unc_1
= ndr_get_array_length(ndr
, &r
->in
.server_unc
);
18905 if (length_server_unc_1
> size_server_unc_1
) {
18906 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", size_server_unc_1
, length_server_unc_1
);
18908 NDR_CHECK(ndr_check_string_terminator(ndr
, length_server_unc_1
, sizeof(uint16_t)));
18909 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->in
.server_unc
, length_server_unc_1
, sizeof(uint16_t), CH_UTF16
));
18910 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_server_unc_0
, 0);
18912 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_share
));
18914 NDR_PULL_ALLOC(ndr
, r
->in
.share
);
18916 r
->in
.share
= NULL
;
18919 _mem_save_share_0
= NDR_PULL_GET_MEM_CTX(ndr
);
18920 NDR_PULL_SET_MEM_CTX(ndr
, r
->in
.share
, 0);
18921 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->in
.share
));
18922 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->in
.share
));
18923 size_share_1
= ndr_get_array_size(ndr
, &r
->in
.share
);
18924 length_share_1
= ndr_get_array_length(ndr
, &r
->in
.share
);
18925 if (length_share_1
> size_share_1
) {
18926 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", size_share_1
, length_share_1
);
18928 NDR_CHECK(ndr_check_string_terminator(ndr
, length_share_1
, sizeof(uint16_t)));
18929 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->in
.share
, length_share_1
, sizeof(uint16_t), CH_UTF16
));
18930 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_share_0
, 0);
18932 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->in
.file
));
18933 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->in
.file
));
18934 size_file_0
= ndr_get_array_size(ndr
, &r
->in
.file
);
18935 length_file_0
= ndr_get_array_length(ndr
, &r
->in
.file
);
18936 if (length_file_0
> size_file_0
) {
18937 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", size_file_0
, length_file_0
);
18939 NDR_CHECK(ndr_check_string_terminator(ndr
, length_file_0
, sizeof(uint16_t)));
18940 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->in
.file
, length_file_0
, sizeof(uint16_t), CH_UTF16
));
18941 NDR_CHECK(ndr_pull_security_secinfo(ndr
, NDR_SCALARS
, &r
->in
.securityinformation
));
18942 NDR_PULL_ALLOC(ndr
, r
->out
.sd_buf
);
18943 ZERO_STRUCTP(r
->out
.sd_buf
);
18945 if (flags
& NDR_OUT
) {
18946 if (ndr
->flags
& LIBNDR_FLAG_REF_ALLOC
) {
18947 NDR_PULL_ALLOC(ndr
, r
->out
.sd_buf
);
18949 _mem_save_sd_buf_0
= NDR_PULL_GET_MEM_CTX(ndr
);
18950 NDR_PULL_SET_MEM_CTX(ndr
, r
->out
.sd_buf
, LIBNDR_FLAG_REF_ALLOC
);
18951 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_sd_buf
));
18953 NDR_PULL_ALLOC(ndr
, *r
->out
.sd_buf
);
18955 *r
->out
.sd_buf
= NULL
;
18957 if (*r
->out
.sd_buf
) {
18958 _mem_save_sd_buf_1
= NDR_PULL_GET_MEM_CTX(ndr
);
18959 NDR_PULL_SET_MEM_CTX(ndr
, *r
->out
.sd_buf
, 0);
18960 NDR_CHECK(ndr_pull_sec_desc_buf(ndr
, NDR_SCALARS
|NDR_BUFFERS
, *r
->out
.sd_buf
));
18961 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_sd_buf_1
, 0);
18963 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_sd_buf_0
, LIBNDR_FLAG_REF_ALLOC
);
18964 NDR_CHECK(ndr_pull_WERROR(ndr
, NDR_SCALARS
, &r
->out
.result
));
18966 return NDR_ERR_SUCCESS
;
18969 _PUBLIC_
void ndr_print_srvsvc_NetGetFileSecurity(struct ndr_print
*ndr
, const char *name
, int flags
, const struct srvsvc_NetGetFileSecurity
*r
)
18971 ndr_print_struct(ndr
, name
, "srvsvc_NetGetFileSecurity");
18973 if (flags
& NDR_SET_VALUES
) {
18974 ndr
->flags
|= LIBNDR_PRINT_SET_VALUES
;
18976 if (flags
& NDR_IN
) {
18977 ndr_print_struct(ndr
, "in", "srvsvc_NetGetFileSecurity");
18979 ndr_print_ptr(ndr
, "server_unc", r
->in
.server_unc
);
18981 if (r
->in
.server_unc
) {
18982 ndr_print_string(ndr
, "server_unc", r
->in
.server_unc
);
18985 ndr_print_ptr(ndr
, "share", r
->in
.share
);
18988 ndr_print_string(ndr
, "share", r
->in
.share
);
18991 ndr_print_string(ndr
, "file", r
->in
.file
);
18992 ndr_print_security_secinfo(ndr
, "securityinformation", r
->in
.securityinformation
);
18995 if (flags
& NDR_OUT
) {
18996 ndr_print_struct(ndr
, "out", "srvsvc_NetGetFileSecurity");
18998 ndr_print_ptr(ndr
, "sd_buf", r
->out
.sd_buf
);
19000 ndr_print_ptr(ndr
, "sd_buf", *r
->out
.sd_buf
);
19002 if (*r
->out
.sd_buf
) {
19003 ndr_print_sec_desc_buf(ndr
, "sd_buf", *r
->out
.sd_buf
);
19007 ndr_print_WERROR(ndr
, "result", r
->out
.result
);
19013 static enum ndr_err_code
ndr_push_srvsvc_NetSetFileSecurity(struct ndr_push
*ndr
, int flags
, const struct srvsvc_NetSetFileSecurity
*r
)
19015 if (flags
& NDR_IN
) {
19016 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->in
.server_unc
));
19017 if (r
->in
.server_unc
) {
19018 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.server_unc
, CH_UTF16
)));
19019 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
19020 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.server_unc
, CH_UTF16
)));
19021 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
));
19023 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->in
.share
));
19025 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.share
, CH_UTF16
)));
19026 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
19027 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.share
, CH_UTF16
)));
19028 NDR_CHECK(ndr_push_charset(ndr
, NDR_SCALARS
, r
->in
.share
, ndr_charset_length(r
->in
.share
, CH_UTF16
), sizeof(uint16_t), CH_UTF16
));
19030 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.file
, CH_UTF16
)));
19031 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
19032 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.file
, CH_UTF16
)));
19033 NDR_CHECK(ndr_push_charset(ndr
, NDR_SCALARS
, r
->in
.file
, ndr_charset_length(r
->in
.file
, CH_UTF16
), sizeof(uint16_t), CH_UTF16
));
19034 NDR_CHECK(ndr_push_security_secinfo(ndr
, NDR_SCALARS
, r
->in
.securityinformation
));
19035 if (r
->in
.sd_buf
== NULL
) {
19036 return ndr_push_error(ndr
, NDR_ERR_INVALID_POINTER
, "NULL [ref] pointer");
19038 NDR_CHECK(ndr_push_sec_desc_buf(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->in
.sd_buf
));
19040 if (flags
& NDR_OUT
) {
19041 NDR_CHECK(ndr_push_WERROR(ndr
, NDR_SCALARS
, r
->out
.result
));
19043 return NDR_ERR_SUCCESS
;
19046 static enum ndr_err_code
ndr_pull_srvsvc_NetSetFileSecurity(struct ndr_pull
*ndr
, int flags
, struct srvsvc_NetSetFileSecurity
*r
)
19048 uint32_t _ptr_server_unc
;
19049 uint32_t size_server_unc_1
= 0;
19050 uint32_t length_server_unc_1
= 0;
19051 uint32_t _ptr_share
;
19052 uint32_t size_share_1
= 0;
19053 uint32_t length_share_1
= 0;
19054 uint32_t size_file_0
= 0;
19055 uint32_t length_file_0
= 0;
19056 TALLOC_CTX
*_mem_save_server_unc_0
;
19057 TALLOC_CTX
*_mem_save_share_0
;
19058 TALLOC_CTX
*_mem_save_sd_buf_0
;
19059 if (flags
& NDR_IN
) {
19060 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_server_unc
));
19061 if (_ptr_server_unc
) {
19062 NDR_PULL_ALLOC(ndr
, r
->in
.server_unc
);
19064 r
->in
.server_unc
= NULL
;
19066 if (r
->in
.server_unc
) {
19067 _mem_save_server_unc_0
= NDR_PULL_GET_MEM_CTX(ndr
);
19068 NDR_PULL_SET_MEM_CTX(ndr
, r
->in
.server_unc
, 0);
19069 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->in
.server_unc
));
19070 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->in
.server_unc
));
19071 size_server_unc_1
= ndr_get_array_size(ndr
, &r
->in
.server_unc
);
19072 length_server_unc_1
= ndr_get_array_length(ndr
, &r
->in
.server_unc
);
19073 if (length_server_unc_1
> size_server_unc_1
) {
19074 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", size_server_unc_1
, length_server_unc_1
);
19076 NDR_CHECK(ndr_check_string_terminator(ndr
, length_server_unc_1
, sizeof(uint16_t)));
19077 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->in
.server_unc
, length_server_unc_1
, sizeof(uint16_t), CH_UTF16
));
19078 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_server_unc_0
, 0);
19080 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_share
));
19082 NDR_PULL_ALLOC(ndr
, r
->in
.share
);
19084 r
->in
.share
= NULL
;
19087 _mem_save_share_0
= NDR_PULL_GET_MEM_CTX(ndr
);
19088 NDR_PULL_SET_MEM_CTX(ndr
, r
->in
.share
, 0);
19089 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->in
.share
));
19090 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->in
.share
));
19091 size_share_1
= ndr_get_array_size(ndr
, &r
->in
.share
);
19092 length_share_1
= ndr_get_array_length(ndr
, &r
->in
.share
);
19093 if (length_share_1
> size_share_1
) {
19094 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", size_share_1
, length_share_1
);
19096 NDR_CHECK(ndr_check_string_terminator(ndr
, length_share_1
, sizeof(uint16_t)));
19097 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->in
.share
, length_share_1
, sizeof(uint16_t), CH_UTF16
));
19098 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_share_0
, 0);
19100 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->in
.file
));
19101 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->in
.file
));
19102 size_file_0
= ndr_get_array_size(ndr
, &r
->in
.file
);
19103 length_file_0
= ndr_get_array_length(ndr
, &r
->in
.file
);
19104 if (length_file_0
> size_file_0
) {
19105 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", size_file_0
, length_file_0
);
19107 NDR_CHECK(ndr_check_string_terminator(ndr
, length_file_0
, sizeof(uint16_t)));
19108 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->in
.file
, length_file_0
, sizeof(uint16_t), CH_UTF16
));
19109 NDR_CHECK(ndr_pull_security_secinfo(ndr
, NDR_SCALARS
, &r
->in
.securityinformation
));
19110 if (ndr
->flags
& LIBNDR_FLAG_REF_ALLOC
) {
19111 NDR_PULL_ALLOC(ndr
, r
->in
.sd_buf
);
19113 _mem_save_sd_buf_0
= NDR_PULL_GET_MEM_CTX(ndr
);
19114 NDR_PULL_SET_MEM_CTX(ndr
, r
->in
.sd_buf
, LIBNDR_FLAG_REF_ALLOC
);
19115 NDR_CHECK(ndr_pull_sec_desc_buf(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->in
.sd_buf
));
19116 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_sd_buf_0
, LIBNDR_FLAG_REF_ALLOC
);
19118 if (flags
& NDR_OUT
) {
19119 NDR_CHECK(ndr_pull_WERROR(ndr
, NDR_SCALARS
, &r
->out
.result
));
19121 return NDR_ERR_SUCCESS
;
19124 _PUBLIC_
void ndr_print_srvsvc_NetSetFileSecurity(struct ndr_print
*ndr
, const char *name
, int flags
, const struct srvsvc_NetSetFileSecurity
*r
)
19126 ndr_print_struct(ndr
, name
, "srvsvc_NetSetFileSecurity");
19128 if (flags
& NDR_SET_VALUES
) {
19129 ndr
->flags
|= LIBNDR_PRINT_SET_VALUES
;
19131 if (flags
& NDR_IN
) {
19132 ndr_print_struct(ndr
, "in", "srvsvc_NetSetFileSecurity");
19134 ndr_print_ptr(ndr
, "server_unc", r
->in
.server_unc
);
19136 if (r
->in
.server_unc
) {
19137 ndr_print_string(ndr
, "server_unc", r
->in
.server_unc
);
19140 ndr_print_ptr(ndr
, "share", r
->in
.share
);
19143 ndr_print_string(ndr
, "share", r
->in
.share
);
19146 ndr_print_string(ndr
, "file", r
->in
.file
);
19147 ndr_print_security_secinfo(ndr
, "securityinformation", r
->in
.securityinformation
);
19148 ndr_print_ptr(ndr
, "sd_buf", r
->in
.sd_buf
);
19150 ndr_print_sec_desc_buf(ndr
, "sd_buf", r
->in
.sd_buf
);
19154 if (flags
& NDR_OUT
) {
19155 ndr_print_struct(ndr
, "out", "srvsvc_NetSetFileSecurity");
19157 ndr_print_WERROR(ndr
, "result", r
->out
.result
);
19163 static enum ndr_err_code
ndr_push_srvsvc_NetServerTransportAddEx(struct ndr_push
*ndr
, int flags
, const struct srvsvc_NetServerTransportAddEx
*r
)
19165 if (flags
& NDR_IN
) {
19166 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->in
.server_unc
));
19167 if (r
->in
.server_unc
) {
19168 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.server_unc
, CH_UTF16
)));
19169 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
19170 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.server_unc
, CH_UTF16
)));
19171 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
));
19173 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->in
.level
));
19174 NDR_CHECK(ndr_push_set_switch_value(ndr
, &r
->in
.info
, r
->in
.level
));
19175 NDR_CHECK(ndr_push_srvsvc_NetTransportInfo(ndr
, NDR_SCALARS
|NDR_BUFFERS
, &r
->in
.info
));
19177 if (flags
& NDR_OUT
) {
19178 NDR_CHECK(ndr_push_WERROR(ndr
, NDR_SCALARS
, r
->out
.result
));
19180 return NDR_ERR_SUCCESS
;
19183 static enum ndr_err_code
ndr_pull_srvsvc_NetServerTransportAddEx(struct ndr_pull
*ndr
, int flags
, struct srvsvc_NetServerTransportAddEx
*r
)
19185 uint32_t _ptr_server_unc
;
19186 uint32_t size_server_unc_1
= 0;
19187 uint32_t length_server_unc_1
= 0;
19188 TALLOC_CTX
*_mem_save_server_unc_0
;
19189 if (flags
& NDR_IN
) {
19190 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_server_unc
));
19191 if (_ptr_server_unc
) {
19192 NDR_PULL_ALLOC(ndr
, r
->in
.server_unc
);
19194 r
->in
.server_unc
= NULL
;
19196 if (r
->in
.server_unc
) {
19197 _mem_save_server_unc_0
= NDR_PULL_GET_MEM_CTX(ndr
);
19198 NDR_PULL_SET_MEM_CTX(ndr
, r
->in
.server_unc
, 0);
19199 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->in
.server_unc
));
19200 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->in
.server_unc
));
19201 size_server_unc_1
= ndr_get_array_size(ndr
, &r
->in
.server_unc
);
19202 length_server_unc_1
= ndr_get_array_length(ndr
, &r
->in
.server_unc
);
19203 if (length_server_unc_1
> size_server_unc_1
) {
19204 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", size_server_unc_1
, length_server_unc_1
);
19206 NDR_CHECK(ndr_check_string_terminator(ndr
, length_server_unc_1
, sizeof(uint16_t)));
19207 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->in
.server_unc
, length_server_unc_1
, sizeof(uint16_t), CH_UTF16
));
19208 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_server_unc_0
, 0);
19210 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->in
.level
));
19211 NDR_CHECK(ndr_pull_set_switch_value(ndr
, &r
->in
.info
, r
->in
.level
));
19212 NDR_CHECK(ndr_pull_srvsvc_NetTransportInfo(ndr
, NDR_SCALARS
|NDR_BUFFERS
, &r
->in
.info
));
19214 if (flags
& NDR_OUT
) {
19215 NDR_CHECK(ndr_pull_WERROR(ndr
, NDR_SCALARS
, &r
->out
.result
));
19217 return NDR_ERR_SUCCESS
;
19220 _PUBLIC_
void ndr_print_srvsvc_NetServerTransportAddEx(struct ndr_print
*ndr
, const char *name
, int flags
, const struct srvsvc_NetServerTransportAddEx
*r
)
19222 ndr_print_struct(ndr
, name
, "srvsvc_NetServerTransportAddEx");
19224 if (flags
& NDR_SET_VALUES
) {
19225 ndr
->flags
|= LIBNDR_PRINT_SET_VALUES
;
19227 if (flags
& NDR_IN
) {
19228 ndr_print_struct(ndr
, "in", "srvsvc_NetServerTransportAddEx");
19230 ndr_print_ptr(ndr
, "server_unc", r
->in
.server_unc
);
19232 if (r
->in
.server_unc
) {
19233 ndr_print_string(ndr
, "server_unc", r
->in
.server_unc
);
19236 ndr_print_uint32(ndr
, "level", r
->in
.level
);
19237 ndr_print_set_switch_value(ndr
, &r
->in
.info
, r
->in
.level
);
19238 ndr_print_srvsvc_NetTransportInfo(ndr
, "info", &r
->in
.info
);
19241 if (flags
& NDR_OUT
) {
19242 ndr_print_struct(ndr
, "out", "srvsvc_NetServerTransportAddEx");
19244 ndr_print_WERROR(ndr
, "result", r
->out
.result
);
19250 static enum ndr_err_code
ndr_push_srvsvc_NetServerSetServiceBitsEx(struct ndr_push
*ndr
, int flags
, const struct srvsvc_NetServerSetServiceBitsEx
*r
)
19252 if (flags
& NDR_IN
) {
19253 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->in
.server_unc
));
19254 if (r
->in
.server_unc
) {
19255 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.server_unc
, CH_UTF16
)));
19256 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
19257 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.server_unc
, CH_UTF16
)));
19258 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
));
19260 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->in
.emulated_server_unc
));
19261 if (r
->in
.emulated_server_unc
) {
19262 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.emulated_server_unc
, CH_UTF16
)));
19263 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
19264 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.emulated_server_unc
, CH_UTF16
)));
19265 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
));
19267 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->in
.transport
));
19268 if (r
->in
.transport
) {
19269 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.transport
, CH_UTF16
)));
19270 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
19271 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.transport
, CH_UTF16
)));
19272 NDR_CHECK(ndr_push_charset(ndr
, NDR_SCALARS
, r
->in
.transport
, ndr_charset_length(r
->in
.transport
, CH_UTF16
), sizeof(uint16_t), CH_UTF16
));
19274 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->in
.servicebitsofinterest
));
19275 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->in
.servicebits
));
19276 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->in
.updateimmediately
));
19278 if (flags
& NDR_OUT
) {
19279 NDR_CHECK(ndr_push_WERROR(ndr
, NDR_SCALARS
, r
->out
.result
));
19281 return NDR_ERR_SUCCESS
;
19284 static enum ndr_err_code
ndr_pull_srvsvc_NetServerSetServiceBitsEx(struct ndr_pull
*ndr
, int flags
, struct srvsvc_NetServerSetServiceBitsEx
*r
)
19286 uint32_t _ptr_server_unc
;
19287 uint32_t size_server_unc_1
= 0;
19288 uint32_t length_server_unc_1
= 0;
19289 uint32_t _ptr_emulated_server_unc
;
19290 uint32_t size_emulated_server_unc_1
= 0;
19291 uint32_t length_emulated_server_unc_1
= 0;
19292 uint32_t _ptr_transport
;
19293 uint32_t size_transport_1
= 0;
19294 uint32_t length_transport_1
= 0;
19295 TALLOC_CTX
*_mem_save_server_unc_0
;
19296 TALLOC_CTX
*_mem_save_emulated_server_unc_0
;
19297 TALLOC_CTX
*_mem_save_transport_0
;
19298 if (flags
& NDR_IN
) {
19299 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_server_unc
));
19300 if (_ptr_server_unc
) {
19301 NDR_PULL_ALLOC(ndr
, r
->in
.server_unc
);
19303 r
->in
.server_unc
= NULL
;
19305 if (r
->in
.server_unc
) {
19306 _mem_save_server_unc_0
= NDR_PULL_GET_MEM_CTX(ndr
);
19307 NDR_PULL_SET_MEM_CTX(ndr
, r
->in
.server_unc
, 0);
19308 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->in
.server_unc
));
19309 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->in
.server_unc
));
19310 size_server_unc_1
= ndr_get_array_size(ndr
, &r
->in
.server_unc
);
19311 length_server_unc_1
= ndr_get_array_length(ndr
, &r
->in
.server_unc
);
19312 if (length_server_unc_1
> size_server_unc_1
) {
19313 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", size_server_unc_1
, length_server_unc_1
);
19315 NDR_CHECK(ndr_check_string_terminator(ndr
, length_server_unc_1
, sizeof(uint16_t)));
19316 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->in
.server_unc
, length_server_unc_1
, sizeof(uint16_t), CH_UTF16
));
19317 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_server_unc_0
, 0);
19319 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_emulated_server_unc
));
19320 if (_ptr_emulated_server_unc
) {
19321 NDR_PULL_ALLOC(ndr
, r
->in
.emulated_server_unc
);
19323 r
->in
.emulated_server_unc
= NULL
;
19325 if (r
->in
.emulated_server_unc
) {
19326 _mem_save_emulated_server_unc_0
= NDR_PULL_GET_MEM_CTX(ndr
);
19327 NDR_PULL_SET_MEM_CTX(ndr
, r
->in
.emulated_server_unc
, 0);
19328 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->in
.emulated_server_unc
));
19329 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->in
.emulated_server_unc
));
19330 size_emulated_server_unc_1
= ndr_get_array_size(ndr
, &r
->in
.emulated_server_unc
);
19331 length_emulated_server_unc_1
= ndr_get_array_length(ndr
, &r
->in
.emulated_server_unc
);
19332 if (length_emulated_server_unc_1
> size_emulated_server_unc_1
) {
19333 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", size_emulated_server_unc_1
, length_emulated_server_unc_1
);
19335 NDR_CHECK(ndr_check_string_terminator(ndr
, length_emulated_server_unc_1
, sizeof(uint16_t)));
19336 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->in
.emulated_server_unc
, length_emulated_server_unc_1
, sizeof(uint16_t), CH_UTF16
));
19337 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_emulated_server_unc_0
, 0);
19339 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_transport
));
19340 if (_ptr_transport
) {
19341 NDR_PULL_ALLOC(ndr
, r
->in
.transport
);
19343 r
->in
.transport
= NULL
;
19345 if (r
->in
.transport
) {
19346 _mem_save_transport_0
= NDR_PULL_GET_MEM_CTX(ndr
);
19347 NDR_PULL_SET_MEM_CTX(ndr
, r
->in
.transport
, 0);
19348 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->in
.transport
));
19349 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->in
.transport
));
19350 size_transport_1
= ndr_get_array_size(ndr
, &r
->in
.transport
);
19351 length_transport_1
= ndr_get_array_length(ndr
, &r
->in
.transport
);
19352 if (length_transport_1
> size_transport_1
) {
19353 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", size_transport_1
, length_transport_1
);
19355 NDR_CHECK(ndr_check_string_terminator(ndr
, length_transport_1
, sizeof(uint16_t)));
19356 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->in
.transport
, length_transport_1
, sizeof(uint16_t), CH_UTF16
));
19357 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_transport_0
, 0);
19359 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->in
.servicebitsofinterest
));
19360 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->in
.servicebits
));
19361 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->in
.updateimmediately
));
19363 if (flags
& NDR_OUT
) {
19364 NDR_CHECK(ndr_pull_WERROR(ndr
, NDR_SCALARS
, &r
->out
.result
));
19366 return NDR_ERR_SUCCESS
;
19369 _PUBLIC_
void ndr_print_srvsvc_NetServerSetServiceBitsEx(struct ndr_print
*ndr
, const char *name
, int flags
, const struct srvsvc_NetServerSetServiceBitsEx
*r
)
19371 ndr_print_struct(ndr
, name
, "srvsvc_NetServerSetServiceBitsEx");
19373 if (flags
& NDR_SET_VALUES
) {
19374 ndr
->flags
|= LIBNDR_PRINT_SET_VALUES
;
19376 if (flags
& NDR_IN
) {
19377 ndr_print_struct(ndr
, "in", "srvsvc_NetServerSetServiceBitsEx");
19379 ndr_print_ptr(ndr
, "server_unc", r
->in
.server_unc
);
19381 if (r
->in
.server_unc
) {
19382 ndr_print_string(ndr
, "server_unc", r
->in
.server_unc
);
19385 ndr_print_ptr(ndr
, "emulated_server_unc", r
->in
.emulated_server_unc
);
19387 if (r
->in
.emulated_server_unc
) {
19388 ndr_print_string(ndr
, "emulated_server_unc", r
->in
.emulated_server_unc
);
19391 ndr_print_ptr(ndr
, "transport", r
->in
.transport
);
19393 if (r
->in
.transport
) {
19394 ndr_print_string(ndr
, "transport", r
->in
.transport
);
19397 ndr_print_uint32(ndr
, "servicebitsofinterest", r
->in
.servicebitsofinterest
);
19398 ndr_print_uint32(ndr
, "servicebits", r
->in
.servicebits
);
19399 ndr_print_uint32(ndr
, "updateimmediately", r
->in
.updateimmediately
);
19402 if (flags
& NDR_OUT
) {
19403 ndr_print_struct(ndr
, "out", "srvsvc_NetServerSetServiceBitsEx");
19405 ndr_print_WERROR(ndr
, "result", r
->out
.result
);
19411 static enum ndr_err_code
ndr_push_srvsvc_NETRDFSGETVERSION(struct ndr_push
*ndr
, int flags
, const struct srvsvc_NETRDFSGETVERSION
*r
)
19413 if (flags
& NDR_IN
) {
19415 if (flags
& NDR_OUT
) {
19416 NDR_CHECK(ndr_push_WERROR(ndr
, NDR_SCALARS
, r
->out
.result
));
19418 return NDR_ERR_SUCCESS
;
19421 static enum ndr_err_code
ndr_pull_srvsvc_NETRDFSGETVERSION(struct ndr_pull
*ndr
, int flags
, struct srvsvc_NETRDFSGETVERSION
*r
)
19423 if (flags
& NDR_IN
) {
19425 if (flags
& NDR_OUT
) {
19426 NDR_CHECK(ndr_pull_WERROR(ndr
, NDR_SCALARS
, &r
->out
.result
));
19428 return NDR_ERR_SUCCESS
;
19431 _PUBLIC_
void ndr_print_srvsvc_NETRDFSGETVERSION(struct ndr_print
*ndr
, const char *name
, int flags
, const struct srvsvc_NETRDFSGETVERSION
*r
)
19433 ndr_print_struct(ndr
, name
, "srvsvc_NETRDFSGETVERSION");
19435 if (flags
& NDR_SET_VALUES
) {
19436 ndr
->flags
|= LIBNDR_PRINT_SET_VALUES
;
19438 if (flags
& NDR_IN
) {
19439 ndr_print_struct(ndr
, "in", "srvsvc_NETRDFSGETVERSION");
19443 if (flags
& NDR_OUT
) {
19444 ndr_print_struct(ndr
, "out", "srvsvc_NETRDFSGETVERSION");
19446 ndr_print_WERROR(ndr
, "result", r
->out
.result
);
19452 static enum ndr_err_code
ndr_push_srvsvc_NETRDFSCREATELOCALPARTITION(struct ndr_push
*ndr
, int flags
, const struct srvsvc_NETRDFSCREATELOCALPARTITION
*r
)
19454 if (flags
& NDR_IN
) {
19456 if (flags
& NDR_OUT
) {
19457 NDR_CHECK(ndr_push_WERROR(ndr
, NDR_SCALARS
, r
->out
.result
));
19459 return NDR_ERR_SUCCESS
;
19462 static enum ndr_err_code
ndr_pull_srvsvc_NETRDFSCREATELOCALPARTITION(struct ndr_pull
*ndr
, int flags
, struct srvsvc_NETRDFSCREATELOCALPARTITION
*r
)
19464 if (flags
& NDR_IN
) {
19466 if (flags
& NDR_OUT
) {
19467 NDR_CHECK(ndr_pull_WERROR(ndr
, NDR_SCALARS
, &r
->out
.result
));
19469 return NDR_ERR_SUCCESS
;
19472 _PUBLIC_
void ndr_print_srvsvc_NETRDFSCREATELOCALPARTITION(struct ndr_print
*ndr
, const char *name
, int flags
, const struct srvsvc_NETRDFSCREATELOCALPARTITION
*r
)
19474 ndr_print_struct(ndr
, name
, "srvsvc_NETRDFSCREATELOCALPARTITION");
19476 if (flags
& NDR_SET_VALUES
) {
19477 ndr
->flags
|= LIBNDR_PRINT_SET_VALUES
;
19479 if (flags
& NDR_IN
) {
19480 ndr_print_struct(ndr
, "in", "srvsvc_NETRDFSCREATELOCALPARTITION");
19484 if (flags
& NDR_OUT
) {
19485 ndr_print_struct(ndr
, "out", "srvsvc_NETRDFSCREATELOCALPARTITION");
19487 ndr_print_WERROR(ndr
, "result", r
->out
.result
);
19493 static enum ndr_err_code
ndr_push_srvsvc_NETRDFSDELETELOCALPARTITION(struct ndr_push
*ndr
, int flags
, const struct srvsvc_NETRDFSDELETELOCALPARTITION
*r
)
19495 if (flags
& NDR_IN
) {
19497 if (flags
& NDR_OUT
) {
19498 NDR_CHECK(ndr_push_WERROR(ndr
, NDR_SCALARS
, r
->out
.result
));
19500 return NDR_ERR_SUCCESS
;
19503 static enum ndr_err_code
ndr_pull_srvsvc_NETRDFSDELETELOCALPARTITION(struct ndr_pull
*ndr
, int flags
, struct srvsvc_NETRDFSDELETELOCALPARTITION
*r
)
19505 if (flags
& NDR_IN
) {
19507 if (flags
& NDR_OUT
) {
19508 NDR_CHECK(ndr_pull_WERROR(ndr
, NDR_SCALARS
, &r
->out
.result
));
19510 return NDR_ERR_SUCCESS
;
19513 _PUBLIC_
void ndr_print_srvsvc_NETRDFSDELETELOCALPARTITION(struct ndr_print
*ndr
, const char *name
, int flags
, const struct srvsvc_NETRDFSDELETELOCALPARTITION
*r
)
19515 ndr_print_struct(ndr
, name
, "srvsvc_NETRDFSDELETELOCALPARTITION");
19517 if (flags
& NDR_SET_VALUES
) {
19518 ndr
->flags
|= LIBNDR_PRINT_SET_VALUES
;
19520 if (flags
& NDR_IN
) {
19521 ndr_print_struct(ndr
, "in", "srvsvc_NETRDFSDELETELOCALPARTITION");
19525 if (flags
& NDR_OUT
) {
19526 ndr_print_struct(ndr
, "out", "srvsvc_NETRDFSDELETELOCALPARTITION");
19528 ndr_print_WERROR(ndr
, "result", r
->out
.result
);
19534 static enum ndr_err_code
ndr_push_srvsvc_NETRDFSSETLOCALVOLUMESTATE(struct ndr_push
*ndr
, int flags
, const struct srvsvc_NETRDFSSETLOCALVOLUMESTATE
*r
)
19536 if (flags
& NDR_IN
) {
19538 if (flags
& NDR_OUT
) {
19539 NDR_CHECK(ndr_push_WERROR(ndr
, NDR_SCALARS
, r
->out
.result
));
19541 return NDR_ERR_SUCCESS
;
19544 static enum ndr_err_code
ndr_pull_srvsvc_NETRDFSSETLOCALVOLUMESTATE(struct ndr_pull
*ndr
, int flags
, struct srvsvc_NETRDFSSETLOCALVOLUMESTATE
*r
)
19546 if (flags
& NDR_IN
) {
19548 if (flags
& NDR_OUT
) {
19549 NDR_CHECK(ndr_pull_WERROR(ndr
, NDR_SCALARS
, &r
->out
.result
));
19551 return NDR_ERR_SUCCESS
;
19554 _PUBLIC_
void ndr_print_srvsvc_NETRDFSSETLOCALVOLUMESTATE(struct ndr_print
*ndr
, const char *name
, int flags
, const struct srvsvc_NETRDFSSETLOCALVOLUMESTATE
*r
)
19556 ndr_print_struct(ndr
, name
, "srvsvc_NETRDFSSETLOCALVOLUMESTATE");
19558 if (flags
& NDR_SET_VALUES
) {
19559 ndr
->flags
|= LIBNDR_PRINT_SET_VALUES
;
19561 if (flags
& NDR_IN
) {
19562 ndr_print_struct(ndr
, "in", "srvsvc_NETRDFSSETLOCALVOLUMESTATE");
19566 if (flags
& NDR_OUT
) {
19567 ndr_print_struct(ndr
, "out", "srvsvc_NETRDFSSETLOCALVOLUMESTATE");
19569 ndr_print_WERROR(ndr
, "result", r
->out
.result
);
19575 static enum ndr_err_code
ndr_push_srvsvc_NETRDFSSETSERVERINFO(struct ndr_push
*ndr
, int flags
, const struct srvsvc_NETRDFSSETSERVERINFO
*r
)
19577 if (flags
& NDR_IN
) {
19579 if (flags
& NDR_OUT
) {
19580 NDR_CHECK(ndr_push_WERROR(ndr
, NDR_SCALARS
, r
->out
.result
));
19582 return NDR_ERR_SUCCESS
;
19585 static enum ndr_err_code
ndr_pull_srvsvc_NETRDFSSETSERVERINFO(struct ndr_pull
*ndr
, int flags
, struct srvsvc_NETRDFSSETSERVERINFO
*r
)
19587 if (flags
& NDR_IN
) {
19589 if (flags
& NDR_OUT
) {
19590 NDR_CHECK(ndr_pull_WERROR(ndr
, NDR_SCALARS
, &r
->out
.result
));
19592 return NDR_ERR_SUCCESS
;
19595 _PUBLIC_
void ndr_print_srvsvc_NETRDFSSETSERVERINFO(struct ndr_print
*ndr
, const char *name
, int flags
, const struct srvsvc_NETRDFSSETSERVERINFO
*r
)
19597 ndr_print_struct(ndr
, name
, "srvsvc_NETRDFSSETSERVERINFO");
19599 if (flags
& NDR_SET_VALUES
) {
19600 ndr
->flags
|= LIBNDR_PRINT_SET_VALUES
;
19602 if (flags
& NDR_IN
) {
19603 ndr_print_struct(ndr
, "in", "srvsvc_NETRDFSSETSERVERINFO");
19607 if (flags
& NDR_OUT
) {
19608 ndr_print_struct(ndr
, "out", "srvsvc_NETRDFSSETSERVERINFO");
19610 ndr_print_WERROR(ndr
, "result", r
->out
.result
);
19616 static enum ndr_err_code
ndr_push_srvsvc_NETRDFSCREATEEXITPOINT(struct ndr_push
*ndr
, int flags
, const struct srvsvc_NETRDFSCREATEEXITPOINT
*r
)
19618 if (flags
& NDR_IN
) {
19620 if (flags
& NDR_OUT
) {
19621 NDR_CHECK(ndr_push_WERROR(ndr
, NDR_SCALARS
, r
->out
.result
));
19623 return NDR_ERR_SUCCESS
;
19626 static enum ndr_err_code
ndr_pull_srvsvc_NETRDFSCREATEEXITPOINT(struct ndr_pull
*ndr
, int flags
, struct srvsvc_NETRDFSCREATEEXITPOINT
*r
)
19628 if (flags
& NDR_IN
) {
19630 if (flags
& NDR_OUT
) {
19631 NDR_CHECK(ndr_pull_WERROR(ndr
, NDR_SCALARS
, &r
->out
.result
));
19633 return NDR_ERR_SUCCESS
;
19636 _PUBLIC_
void ndr_print_srvsvc_NETRDFSCREATEEXITPOINT(struct ndr_print
*ndr
, const char *name
, int flags
, const struct srvsvc_NETRDFSCREATEEXITPOINT
*r
)
19638 ndr_print_struct(ndr
, name
, "srvsvc_NETRDFSCREATEEXITPOINT");
19640 if (flags
& NDR_SET_VALUES
) {
19641 ndr
->flags
|= LIBNDR_PRINT_SET_VALUES
;
19643 if (flags
& NDR_IN
) {
19644 ndr_print_struct(ndr
, "in", "srvsvc_NETRDFSCREATEEXITPOINT");
19648 if (flags
& NDR_OUT
) {
19649 ndr_print_struct(ndr
, "out", "srvsvc_NETRDFSCREATEEXITPOINT");
19651 ndr_print_WERROR(ndr
, "result", r
->out
.result
);
19657 static enum ndr_err_code
ndr_push_srvsvc_NETRDFSDELETEEXITPOINT(struct ndr_push
*ndr
, int flags
, const struct srvsvc_NETRDFSDELETEEXITPOINT
*r
)
19659 if (flags
& NDR_IN
) {
19661 if (flags
& NDR_OUT
) {
19662 NDR_CHECK(ndr_push_WERROR(ndr
, NDR_SCALARS
, r
->out
.result
));
19664 return NDR_ERR_SUCCESS
;
19667 static enum ndr_err_code
ndr_pull_srvsvc_NETRDFSDELETEEXITPOINT(struct ndr_pull
*ndr
, int flags
, struct srvsvc_NETRDFSDELETEEXITPOINT
*r
)
19669 if (flags
& NDR_IN
) {
19671 if (flags
& NDR_OUT
) {
19672 NDR_CHECK(ndr_pull_WERROR(ndr
, NDR_SCALARS
, &r
->out
.result
));
19674 return NDR_ERR_SUCCESS
;
19677 _PUBLIC_
void ndr_print_srvsvc_NETRDFSDELETEEXITPOINT(struct ndr_print
*ndr
, const char *name
, int flags
, const struct srvsvc_NETRDFSDELETEEXITPOINT
*r
)
19679 ndr_print_struct(ndr
, name
, "srvsvc_NETRDFSDELETEEXITPOINT");
19681 if (flags
& NDR_SET_VALUES
) {
19682 ndr
->flags
|= LIBNDR_PRINT_SET_VALUES
;
19684 if (flags
& NDR_IN
) {
19685 ndr_print_struct(ndr
, "in", "srvsvc_NETRDFSDELETEEXITPOINT");
19689 if (flags
& NDR_OUT
) {
19690 ndr_print_struct(ndr
, "out", "srvsvc_NETRDFSDELETEEXITPOINT");
19692 ndr_print_WERROR(ndr
, "result", r
->out
.result
);
19698 static enum ndr_err_code
ndr_push_srvsvc_NETRDFSMODIFYPREFIX(struct ndr_push
*ndr
, int flags
, const struct srvsvc_NETRDFSMODIFYPREFIX
*r
)
19700 if (flags
& NDR_IN
) {
19702 if (flags
& NDR_OUT
) {
19703 NDR_CHECK(ndr_push_WERROR(ndr
, NDR_SCALARS
, r
->out
.result
));
19705 return NDR_ERR_SUCCESS
;
19708 static enum ndr_err_code
ndr_pull_srvsvc_NETRDFSMODIFYPREFIX(struct ndr_pull
*ndr
, int flags
, struct srvsvc_NETRDFSMODIFYPREFIX
*r
)
19710 if (flags
& NDR_IN
) {
19712 if (flags
& NDR_OUT
) {
19713 NDR_CHECK(ndr_pull_WERROR(ndr
, NDR_SCALARS
, &r
->out
.result
));
19715 return NDR_ERR_SUCCESS
;
19718 _PUBLIC_
void ndr_print_srvsvc_NETRDFSMODIFYPREFIX(struct ndr_print
*ndr
, const char *name
, int flags
, const struct srvsvc_NETRDFSMODIFYPREFIX
*r
)
19720 ndr_print_struct(ndr
, name
, "srvsvc_NETRDFSMODIFYPREFIX");
19722 if (flags
& NDR_SET_VALUES
) {
19723 ndr
->flags
|= LIBNDR_PRINT_SET_VALUES
;
19725 if (flags
& NDR_IN
) {
19726 ndr_print_struct(ndr
, "in", "srvsvc_NETRDFSMODIFYPREFIX");
19730 if (flags
& NDR_OUT
) {
19731 ndr_print_struct(ndr
, "out", "srvsvc_NETRDFSMODIFYPREFIX");
19733 ndr_print_WERROR(ndr
, "result", r
->out
.result
);
19739 static enum ndr_err_code
ndr_push_srvsvc_NETRDFSFIXLOCALVOLUME(struct ndr_push
*ndr
, int flags
, const struct srvsvc_NETRDFSFIXLOCALVOLUME
*r
)
19741 if (flags
& NDR_IN
) {
19743 if (flags
& NDR_OUT
) {
19744 NDR_CHECK(ndr_push_WERROR(ndr
, NDR_SCALARS
, r
->out
.result
));
19746 return NDR_ERR_SUCCESS
;
19749 static enum ndr_err_code
ndr_pull_srvsvc_NETRDFSFIXLOCALVOLUME(struct ndr_pull
*ndr
, int flags
, struct srvsvc_NETRDFSFIXLOCALVOLUME
*r
)
19751 if (flags
& NDR_IN
) {
19753 if (flags
& NDR_OUT
) {
19754 NDR_CHECK(ndr_pull_WERROR(ndr
, NDR_SCALARS
, &r
->out
.result
));
19756 return NDR_ERR_SUCCESS
;
19759 _PUBLIC_
void ndr_print_srvsvc_NETRDFSFIXLOCALVOLUME(struct ndr_print
*ndr
, const char *name
, int flags
, const struct srvsvc_NETRDFSFIXLOCALVOLUME
*r
)
19761 ndr_print_struct(ndr
, name
, "srvsvc_NETRDFSFIXLOCALVOLUME");
19763 if (flags
& NDR_SET_VALUES
) {
19764 ndr
->flags
|= LIBNDR_PRINT_SET_VALUES
;
19766 if (flags
& NDR_IN
) {
19767 ndr_print_struct(ndr
, "in", "srvsvc_NETRDFSFIXLOCALVOLUME");
19771 if (flags
& NDR_OUT
) {
19772 ndr_print_struct(ndr
, "out", "srvsvc_NETRDFSFIXLOCALVOLUME");
19774 ndr_print_WERROR(ndr
, "result", r
->out
.result
);
19780 static enum ndr_err_code
ndr_push_srvsvc_NETRDFSMANAGERREPORTSITEINFO(struct ndr_push
*ndr
, int flags
, const struct srvsvc_NETRDFSMANAGERREPORTSITEINFO
*r
)
19782 if (flags
& NDR_IN
) {
19784 if (flags
& NDR_OUT
) {
19785 NDR_CHECK(ndr_push_WERROR(ndr
, NDR_SCALARS
, r
->out
.result
));
19787 return NDR_ERR_SUCCESS
;
19790 static enum ndr_err_code
ndr_pull_srvsvc_NETRDFSMANAGERREPORTSITEINFO(struct ndr_pull
*ndr
, int flags
, struct srvsvc_NETRDFSMANAGERREPORTSITEINFO
*r
)
19792 if (flags
& NDR_IN
) {
19794 if (flags
& NDR_OUT
) {
19795 NDR_CHECK(ndr_pull_WERROR(ndr
, NDR_SCALARS
, &r
->out
.result
));
19797 return NDR_ERR_SUCCESS
;
19800 _PUBLIC_
void ndr_print_srvsvc_NETRDFSMANAGERREPORTSITEINFO(struct ndr_print
*ndr
, const char *name
, int flags
, const struct srvsvc_NETRDFSMANAGERREPORTSITEINFO
*r
)
19802 ndr_print_struct(ndr
, name
, "srvsvc_NETRDFSMANAGERREPORTSITEINFO");
19804 if (flags
& NDR_SET_VALUES
) {
19805 ndr
->flags
|= LIBNDR_PRINT_SET_VALUES
;
19807 if (flags
& NDR_IN
) {
19808 ndr_print_struct(ndr
, "in", "srvsvc_NETRDFSMANAGERREPORTSITEINFO");
19812 if (flags
& NDR_OUT
) {
19813 ndr_print_struct(ndr
, "out", "srvsvc_NETRDFSMANAGERREPORTSITEINFO");
19815 ndr_print_WERROR(ndr
, "result", r
->out
.result
);
19821 static enum ndr_err_code
ndr_push_srvsvc_NETRSERVERTRANSPORTDELEX(struct ndr_push
*ndr
, int flags
, const struct srvsvc_NETRSERVERTRANSPORTDELEX
*r
)
19823 if (flags
& NDR_IN
) {
19825 if (flags
& NDR_OUT
) {
19826 NDR_CHECK(ndr_push_WERROR(ndr
, NDR_SCALARS
, r
->out
.result
));
19828 return NDR_ERR_SUCCESS
;
19831 static enum ndr_err_code
ndr_pull_srvsvc_NETRSERVERTRANSPORTDELEX(struct ndr_pull
*ndr
, int flags
, struct srvsvc_NETRSERVERTRANSPORTDELEX
*r
)
19833 if (flags
& NDR_IN
) {
19835 if (flags
& NDR_OUT
) {
19836 NDR_CHECK(ndr_pull_WERROR(ndr
, NDR_SCALARS
, &r
->out
.result
));
19838 return NDR_ERR_SUCCESS
;
19841 _PUBLIC_
void ndr_print_srvsvc_NETRSERVERTRANSPORTDELEX(struct ndr_print
*ndr
, const char *name
, int flags
, const struct srvsvc_NETRSERVERTRANSPORTDELEX
*r
)
19843 ndr_print_struct(ndr
, name
, "srvsvc_NETRSERVERTRANSPORTDELEX");
19845 if (flags
& NDR_SET_VALUES
) {
19846 ndr
->flags
|= LIBNDR_PRINT_SET_VALUES
;
19848 if (flags
& NDR_IN
) {
19849 ndr_print_struct(ndr
, "in", "srvsvc_NETRSERVERTRANSPORTDELEX");
19853 if (flags
& NDR_OUT
) {
19854 ndr_print_struct(ndr
, "out", "srvsvc_NETRSERVERTRANSPORTDELEX");
19856 ndr_print_WERROR(ndr
, "result", r
->out
.result
);
19862 static const struct ndr_interface_call srvsvc_calls
[] = {
19864 "srvsvc_NetCharDevEnum",
19865 sizeof(struct srvsvc_NetCharDevEnum
),
19866 (ndr_push_flags_fn_t
) ndr_push_srvsvc_NetCharDevEnum
,
19867 (ndr_pull_flags_fn_t
) ndr_pull_srvsvc_NetCharDevEnum
,
19868 (ndr_print_function_t
) ndr_print_srvsvc_NetCharDevEnum
,
19872 "srvsvc_NetCharDevGetInfo",
19873 sizeof(struct srvsvc_NetCharDevGetInfo
),
19874 (ndr_push_flags_fn_t
) ndr_push_srvsvc_NetCharDevGetInfo
,
19875 (ndr_pull_flags_fn_t
) ndr_pull_srvsvc_NetCharDevGetInfo
,
19876 (ndr_print_function_t
) ndr_print_srvsvc_NetCharDevGetInfo
,
19880 "srvsvc_NetCharDevControl",
19881 sizeof(struct srvsvc_NetCharDevControl
),
19882 (ndr_push_flags_fn_t
) ndr_push_srvsvc_NetCharDevControl
,
19883 (ndr_pull_flags_fn_t
) ndr_pull_srvsvc_NetCharDevControl
,
19884 (ndr_print_function_t
) ndr_print_srvsvc_NetCharDevControl
,
19888 "srvsvc_NetCharDevQEnum",
19889 sizeof(struct srvsvc_NetCharDevQEnum
),
19890 (ndr_push_flags_fn_t
) ndr_push_srvsvc_NetCharDevQEnum
,
19891 (ndr_pull_flags_fn_t
) ndr_pull_srvsvc_NetCharDevQEnum
,
19892 (ndr_print_function_t
) ndr_print_srvsvc_NetCharDevQEnum
,
19896 "srvsvc_NetCharDevQGetInfo",
19897 sizeof(struct srvsvc_NetCharDevQGetInfo
),
19898 (ndr_push_flags_fn_t
) ndr_push_srvsvc_NetCharDevQGetInfo
,
19899 (ndr_pull_flags_fn_t
) ndr_pull_srvsvc_NetCharDevQGetInfo
,
19900 (ndr_print_function_t
) ndr_print_srvsvc_NetCharDevQGetInfo
,
19904 "srvsvc_NetCharDevQSetInfo",
19905 sizeof(struct srvsvc_NetCharDevQSetInfo
),
19906 (ndr_push_flags_fn_t
) ndr_push_srvsvc_NetCharDevQSetInfo
,
19907 (ndr_pull_flags_fn_t
) ndr_pull_srvsvc_NetCharDevQSetInfo
,
19908 (ndr_print_function_t
) ndr_print_srvsvc_NetCharDevQSetInfo
,
19912 "srvsvc_NetCharDevQPurge",
19913 sizeof(struct srvsvc_NetCharDevQPurge
),
19914 (ndr_push_flags_fn_t
) ndr_push_srvsvc_NetCharDevQPurge
,
19915 (ndr_pull_flags_fn_t
) ndr_pull_srvsvc_NetCharDevQPurge
,
19916 (ndr_print_function_t
) ndr_print_srvsvc_NetCharDevQPurge
,
19920 "srvsvc_NetCharDevQPurgeSelf",
19921 sizeof(struct srvsvc_NetCharDevQPurgeSelf
),
19922 (ndr_push_flags_fn_t
) ndr_push_srvsvc_NetCharDevQPurgeSelf
,
19923 (ndr_pull_flags_fn_t
) ndr_pull_srvsvc_NetCharDevQPurgeSelf
,
19924 (ndr_print_function_t
) ndr_print_srvsvc_NetCharDevQPurgeSelf
,
19928 "srvsvc_NetConnEnum",
19929 sizeof(struct srvsvc_NetConnEnum
),
19930 (ndr_push_flags_fn_t
) ndr_push_srvsvc_NetConnEnum
,
19931 (ndr_pull_flags_fn_t
) ndr_pull_srvsvc_NetConnEnum
,
19932 (ndr_print_function_t
) ndr_print_srvsvc_NetConnEnum
,
19936 "srvsvc_NetFileEnum",
19937 sizeof(struct srvsvc_NetFileEnum
),
19938 (ndr_push_flags_fn_t
) ndr_push_srvsvc_NetFileEnum
,
19939 (ndr_pull_flags_fn_t
) ndr_pull_srvsvc_NetFileEnum
,
19940 (ndr_print_function_t
) ndr_print_srvsvc_NetFileEnum
,
19944 "srvsvc_NetFileGetInfo",
19945 sizeof(struct srvsvc_NetFileGetInfo
),
19946 (ndr_push_flags_fn_t
) ndr_push_srvsvc_NetFileGetInfo
,
19947 (ndr_pull_flags_fn_t
) ndr_pull_srvsvc_NetFileGetInfo
,
19948 (ndr_print_function_t
) ndr_print_srvsvc_NetFileGetInfo
,
19952 "srvsvc_NetFileClose",
19953 sizeof(struct srvsvc_NetFileClose
),
19954 (ndr_push_flags_fn_t
) ndr_push_srvsvc_NetFileClose
,
19955 (ndr_pull_flags_fn_t
) ndr_pull_srvsvc_NetFileClose
,
19956 (ndr_print_function_t
) ndr_print_srvsvc_NetFileClose
,
19960 "srvsvc_NetSessEnum",
19961 sizeof(struct srvsvc_NetSessEnum
),
19962 (ndr_push_flags_fn_t
) ndr_push_srvsvc_NetSessEnum
,
19963 (ndr_pull_flags_fn_t
) ndr_pull_srvsvc_NetSessEnum
,
19964 (ndr_print_function_t
) ndr_print_srvsvc_NetSessEnum
,
19968 "srvsvc_NetSessDel",
19969 sizeof(struct srvsvc_NetSessDel
),
19970 (ndr_push_flags_fn_t
) ndr_push_srvsvc_NetSessDel
,
19971 (ndr_pull_flags_fn_t
) ndr_pull_srvsvc_NetSessDel
,
19972 (ndr_print_function_t
) ndr_print_srvsvc_NetSessDel
,
19976 "srvsvc_NetShareAdd",
19977 sizeof(struct srvsvc_NetShareAdd
),
19978 (ndr_push_flags_fn_t
) ndr_push_srvsvc_NetShareAdd
,
19979 (ndr_pull_flags_fn_t
) ndr_pull_srvsvc_NetShareAdd
,
19980 (ndr_print_function_t
) ndr_print_srvsvc_NetShareAdd
,
19984 "srvsvc_NetShareEnumAll",
19985 sizeof(struct srvsvc_NetShareEnumAll
),
19986 (ndr_push_flags_fn_t
) ndr_push_srvsvc_NetShareEnumAll
,
19987 (ndr_pull_flags_fn_t
) ndr_pull_srvsvc_NetShareEnumAll
,
19988 (ndr_print_function_t
) ndr_print_srvsvc_NetShareEnumAll
,
19992 "srvsvc_NetShareGetInfo",
19993 sizeof(struct srvsvc_NetShareGetInfo
),
19994 (ndr_push_flags_fn_t
) ndr_push_srvsvc_NetShareGetInfo
,
19995 (ndr_pull_flags_fn_t
) ndr_pull_srvsvc_NetShareGetInfo
,
19996 (ndr_print_function_t
) ndr_print_srvsvc_NetShareGetInfo
,
20000 "srvsvc_NetShareSetInfo",
20001 sizeof(struct srvsvc_NetShareSetInfo
),
20002 (ndr_push_flags_fn_t
) ndr_push_srvsvc_NetShareSetInfo
,
20003 (ndr_pull_flags_fn_t
) ndr_pull_srvsvc_NetShareSetInfo
,
20004 (ndr_print_function_t
) ndr_print_srvsvc_NetShareSetInfo
,
20008 "srvsvc_NetShareDel",
20009 sizeof(struct srvsvc_NetShareDel
),
20010 (ndr_push_flags_fn_t
) ndr_push_srvsvc_NetShareDel
,
20011 (ndr_pull_flags_fn_t
) ndr_pull_srvsvc_NetShareDel
,
20012 (ndr_print_function_t
) ndr_print_srvsvc_NetShareDel
,
20016 "srvsvc_NetShareDelSticky",
20017 sizeof(struct srvsvc_NetShareDelSticky
),
20018 (ndr_push_flags_fn_t
) ndr_push_srvsvc_NetShareDelSticky
,
20019 (ndr_pull_flags_fn_t
) ndr_pull_srvsvc_NetShareDelSticky
,
20020 (ndr_print_function_t
) ndr_print_srvsvc_NetShareDelSticky
,
20024 "srvsvc_NetShareCheck",
20025 sizeof(struct srvsvc_NetShareCheck
),
20026 (ndr_push_flags_fn_t
) ndr_push_srvsvc_NetShareCheck
,
20027 (ndr_pull_flags_fn_t
) ndr_pull_srvsvc_NetShareCheck
,
20028 (ndr_print_function_t
) ndr_print_srvsvc_NetShareCheck
,
20032 "srvsvc_NetSrvGetInfo",
20033 sizeof(struct srvsvc_NetSrvGetInfo
),
20034 (ndr_push_flags_fn_t
) ndr_push_srvsvc_NetSrvGetInfo
,
20035 (ndr_pull_flags_fn_t
) ndr_pull_srvsvc_NetSrvGetInfo
,
20036 (ndr_print_function_t
) ndr_print_srvsvc_NetSrvGetInfo
,
20040 "srvsvc_NetSrvSetInfo",
20041 sizeof(struct srvsvc_NetSrvSetInfo
),
20042 (ndr_push_flags_fn_t
) ndr_push_srvsvc_NetSrvSetInfo
,
20043 (ndr_pull_flags_fn_t
) ndr_pull_srvsvc_NetSrvSetInfo
,
20044 (ndr_print_function_t
) ndr_print_srvsvc_NetSrvSetInfo
,
20048 "srvsvc_NetDiskEnum",
20049 sizeof(struct srvsvc_NetDiskEnum
),
20050 (ndr_push_flags_fn_t
) ndr_push_srvsvc_NetDiskEnum
,
20051 (ndr_pull_flags_fn_t
) ndr_pull_srvsvc_NetDiskEnum
,
20052 (ndr_print_function_t
) ndr_print_srvsvc_NetDiskEnum
,
20056 "srvsvc_NetServerStatisticsGet",
20057 sizeof(struct srvsvc_NetServerStatisticsGet
),
20058 (ndr_push_flags_fn_t
) ndr_push_srvsvc_NetServerStatisticsGet
,
20059 (ndr_pull_flags_fn_t
) ndr_pull_srvsvc_NetServerStatisticsGet
,
20060 (ndr_print_function_t
) ndr_print_srvsvc_NetServerStatisticsGet
,
20064 "srvsvc_NetTransportAdd",
20065 sizeof(struct srvsvc_NetTransportAdd
),
20066 (ndr_push_flags_fn_t
) ndr_push_srvsvc_NetTransportAdd
,
20067 (ndr_pull_flags_fn_t
) ndr_pull_srvsvc_NetTransportAdd
,
20068 (ndr_print_function_t
) ndr_print_srvsvc_NetTransportAdd
,
20072 "srvsvc_NetTransportEnum",
20073 sizeof(struct srvsvc_NetTransportEnum
),
20074 (ndr_push_flags_fn_t
) ndr_push_srvsvc_NetTransportEnum
,
20075 (ndr_pull_flags_fn_t
) ndr_pull_srvsvc_NetTransportEnum
,
20076 (ndr_print_function_t
) ndr_print_srvsvc_NetTransportEnum
,
20080 "srvsvc_NetTransportDel",
20081 sizeof(struct srvsvc_NetTransportDel
),
20082 (ndr_push_flags_fn_t
) ndr_push_srvsvc_NetTransportDel
,
20083 (ndr_pull_flags_fn_t
) ndr_pull_srvsvc_NetTransportDel
,
20084 (ndr_print_function_t
) ndr_print_srvsvc_NetTransportDel
,
20088 "srvsvc_NetRemoteTOD",
20089 sizeof(struct srvsvc_NetRemoteTOD
),
20090 (ndr_push_flags_fn_t
) ndr_push_srvsvc_NetRemoteTOD
,
20091 (ndr_pull_flags_fn_t
) ndr_pull_srvsvc_NetRemoteTOD
,
20092 (ndr_print_function_t
) ndr_print_srvsvc_NetRemoteTOD
,
20096 "srvsvc_NetSetServiceBits",
20097 sizeof(struct srvsvc_NetSetServiceBits
),
20098 (ndr_push_flags_fn_t
) ndr_push_srvsvc_NetSetServiceBits
,
20099 (ndr_pull_flags_fn_t
) ndr_pull_srvsvc_NetSetServiceBits
,
20100 (ndr_print_function_t
) ndr_print_srvsvc_NetSetServiceBits
,
20104 "srvsvc_NetPathType",
20105 sizeof(struct srvsvc_NetPathType
),
20106 (ndr_push_flags_fn_t
) ndr_push_srvsvc_NetPathType
,
20107 (ndr_pull_flags_fn_t
) ndr_pull_srvsvc_NetPathType
,
20108 (ndr_print_function_t
) ndr_print_srvsvc_NetPathType
,
20112 "srvsvc_NetPathCanonicalize",
20113 sizeof(struct srvsvc_NetPathCanonicalize
),
20114 (ndr_push_flags_fn_t
) ndr_push_srvsvc_NetPathCanonicalize
,
20115 (ndr_pull_flags_fn_t
) ndr_pull_srvsvc_NetPathCanonicalize
,
20116 (ndr_print_function_t
) ndr_print_srvsvc_NetPathCanonicalize
,
20120 "srvsvc_NetPathCompare",
20121 sizeof(struct srvsvc_NetPathCompare
),
20122 (ndr_push_flags_fn_t
) ndr_push_srvsvc_NetPathCompare
,
20123 (ndr_pull_flags_fn_t
) ndr_pull_srvsvc_NetPathCompare
,
20124 (ndr_print_function_t
) ndr_print_srvsvc_NetPathCompare
,
20128 "srvsvc_NetNameValidate",
20129 sizeof(struct srvsvc_NetNameValidate
),
20130 (ndr_push_flags_fn_t
) ndr_push_srvsvc_NetNameValidate
,
20131 (ndr_pull_flags_fn_t
) ndr_pull_srvsvc_NetNameValidate
,
20132 (ndr_print_function_t
) ndr_print_srvsvc_NetNameValidate
,
20136 "srvsvc_NETRPRNAMECANONICALIZE",
20137 sizeof(struct srvsvc_NETRPRNAMECANONICALIZE
),
20138 (ndr_push_flags_fn_t
) ndr_push_srvsvc_NETRPRNAMECANONICALIZE
,
20139 (ndr_pull_flags_fn_t
) ndr_pull_srvsvc_NETRPRNAMECANONICALIZE
,
20140 (ndr_print_function_t
) ndr_print_srvsvc_NETRPRNAMECANONICALIZE
,
20144 "srvsvc_NetPRNameCompare",
20145 sizeof(struct srvsvc_NetPRNameCompare
),
20146 (ndr_push_flags_fn_t
) ndr_push_srvsvc_NetPRNameCompare
,
20147 (ndr_pull_flags_fn_t
) ndr_pull_srvsvc_NetPRNameCompare
,
20148 (ndr_print_function_t
) ndr_print_srvsvc_NetPRNameCompare
,
20152 "srvsvc_NetShareEnum",
20153 sizeof(struct srvsvc_NetShareEnum
),
20154 (ndr_push_flags_fn_t
) ndr_push_srvsvc_NetShareEnum
,
20155 (ndr_pull_flags_fn_t
) ndr_pull_srvsvc_NetShareEnum
,
20156 (ndr_print_function_t
) ndr_print_srvsvc_NetShareEnum
,
20160 "srvsvc_NetShareDelStart",
20161 sizeof(struct srvsvc_NetShareDelStart
),
20162 (ndr_push_flags_fn_t
) ndr_push_srvsvc_NetShareDelStart
,
20163 (ndr_pull_flags_fn_t
) ndr_pull_srvsvc_NetShareDelStart
,
20164 (ndr_print_function_t
) ndr_print_srvsvc_NetShareDelStart
,
20168 "srvsvc_NetShareDelCommit",
20169 sizeof(struct srvsvc_NetShareDelCommit
),
20170 (ndr_push_flags_fn_t
) ndr_push_srvsvc_NetShareDelCommit
,
20171 (ndr_pull_flags_fn_t
) ndr_pull_srvsvc_NetShareDelCommit
,
20172 (ndr_print_function_t
) ndr_print_srvsvc_NetShareDelCommit
,
20176 "srvsvc_NetGetFileSecurity",
20177 sizeof(struct srvsvc_NetGetFileSecurity
),
20178 (ndr_push_flags_fn_t
) ndr_push_srvsvc_NetGetFileSecurity
,
20179 (ndr_pull_flags_fn_t
) ndr_pull_srvsvc_NetGetFileSecurity
,
20180 (ndr_print_function_t
) ndr_print_srvsvc_NetGetFileSecurity
,
20184 "srvsvc_NetSetFileSecurity",
20185 sizeof(struct srvsvc_NetSetFileSecurity
),
20186 (ndr_push_flags_fn_t
) ndr_push_srvsvc_NetSetFileSecurity
,
20187 (ndr_pull_flags_fn_t
) ndr_pull_srvsvc_NetSetFileSecurity
,
20188 (ndr_print_function_t
) ndr_print_srvsvc_NetSetFileSecurity
,
20192 "srvsvc_NetServerTransportAddEx",
20193 sizeof(struct srvsvc_NetServerTransportAddEx
),
20194 (ndr_push_flags_fn_t
) ndr_push_srvsvc_NetServerTransportAddEx
,
20195 (ndr_pull_flags_fn_t
) ndr_pull_srvsvc_NetServerTransportAddEx
,
20196 (ndr_print_function_t
) ndr_print_srvsvc_NetServerTransportAddEx
,
20200 "srvsvc_NetServerSetServiceBitsEx",
20201 sizeof(struct srvsvc_NetServerSetServiceBitsEx
),
20202 (ndr_push_flags_fn_t
) ndr_push_srvsvc_NetServerSetServiceBitsEx
,
20203 (ndr_pull_flags_fn_t
) ndr_pull_srvsvc_NetServerSetServiceBitsEx
,
20204 (ndr_print_function_t
) ndr_print_srvsvc_NetServerSetServiceBitsEx
,
20208 "srvsvc_NETRDFSGETVERSION",
20209 sizeof(struct srvsvc_NETRDFSGETVERSION
),
20210 (ndr_push_flags_fn_t
) ndr_push_srvsvc_NETRDFSGETVERSION
,
20211 (ndr_pull_flags_fn_t
) ndr_pull_srvsvc_NETRDFSGETVERSION
,
20212 (ndr_print_function_t
) ndr_print_srvsvc_NETRDFSGETVERSION
,
20216 "srvsvc_NETRDFSCREATELOCALPARTITION",
20217 sizeof(struct srvsvc_NETRDFSCREATELOCALPARTITION
),
20218 (ndr_push_flags_fn_t
) ndr_push_srvsvc_NETRDFSCREATELOCALPARTITION
,
20219 (ndr_pull_flags_fn_t
) ndr_pull_srvsvc_NETRDFSCREATELOCALPARTITION
,
20220 (ndr_print_function_t
) ndr_print_srvsvc_NETRDFSCREATELOCALPARTITION
,
20224 "srvsvc_NETRDFSDELETELOCALPARTITION",
20225 sizeof(struct srvsvc_NETRDFSDELETELOCALPARTITION
),
20226 (ndr_push_flags_fn_t
) ndr_push_srvsvc_NETRDFSDELETELOCALPARTITION
,
20227 (ndr_pull_flags_fn_t
) ndr_pull_srvsvc_NETRDFSDELETELOCALPARTITION
,
20228 (ndr_print_function_t
) ndr_print_srvsvc_NETRDFSDELETELOCALPARTITION
,
20232 "srvsvc_NETRDFSSETLOCALVOLUMESTATE",
20233 sizeof(struct srvsvc_NETRDFSSETLOCALVOLUMESTATE
),
20234 (ndr_push_flags_fn_t
) ndr_push_srvsvc_NETRDFSSETLOCALVOLUMESTATE
,
20235 (ndr_pull_flags_fn_t
) ndr_pull_srvsvc_NETRDFSSETLOCALVOLUMESTATE
,
20236 (ndr_print_function_t
) ndr_print_srvsvc_NETRDFSSETLOCALVOLUMESTATE
,
20240 "srvsvc_NETRDFSSETSERVERINFO",
20241 sizeof(struct srvsvc_NETRDFSSETSERVERINFO
),
20242 (ndr_push_flags_fn_t
) ndr_push_srvsvc_NETRDFSSETSERVERINFO
,
20243 (ndr_pull_flags_fn_t
) ndr_pull_srvsvc_NETRDFSSETSERVERINFO
,
20244 (ndr_print_function_t
) ndr_print_srvsvc_NETRDFSSETSERVERINFO
,
20248 "srvsvc_NETRDFSCREATEEXITPOINT",
20249 sizeof(struct srvsvc_NETRDFSCREATEEXITPOINT
),
20250 (ndr_push_flags_fn_t
) ndr_push_srvsvc_NETRDFSCREATEEXITPOINT
,
20251 (ndr_pull_flags_fn_t
) ndr_pull_srvsvc_NETRDFSCREATEEXITPOINT
,
20252 (ndr_print_function_t
) ndr_print_srvsvc_NETRDFSCREATEEXITPOINT
,
20256 "srvsvc_NETRDFSDELETEEXITPOINT",
20257 sizeof(struct srvsvc_NETRDFSDELETEEXITPOINT
),
20258 (ndr_push_flags_fn_t
) ndr_push_srvsvc_NETRDFSDELETEEXITPOINT
,
20259 (ndr_pull_flags_fn_t
) ndr_pull_srvsvc_NETRDFSDELETEEXITPOINT
,
20260 (ndr_print_function_t
) ndr_print_srvsvc_NETRDFSDELETEEXITPOINT
,
20264 "srvsvc_NETRDFSMODIFYPREFIX",
20265 sizeof(struct srvsvc_NETRDFSMODIFYPREFIX
),
20266 (ndr_push_flags_fn_t
) ndr_push_srvsvc_NETRDFSMODIFYPREFIX
,
20267 (ndr_pull_flags_fn_t
) ndr_pull_srvsvc_NETRDFSMODIFYPREFIX
,
20268 (ndr_print_function_t
) ndr_print_srvsvc_NETRDFSMODIFYPREFIX
,
20272 "srvsvc_NETRDFSFIXLOCALVOLUME",
20273 sizeof(struct srvsvc_NETRDFSFIXLOCALVOLUME
),
20274 (ndr_push_flags_fn_t
) ndr_push_srvsvc_NETRDFSFIXLOCALVOLUME
,
20275 (ndr_pull_flags_fn_t
) ndr_pull_srvsvc_NETRDFSFIXLOCALVOLUME
,
20276 (ndr_print_function_t
) ndr_print_srvsvc_NETRDFSFIXLOCALVOLUME
,
20280 "srvsvc_NETRDFSMANAGERREPORTSITEINFO",
20281 sizeof(struct srvsvc_NETRDFSMANAGERREPORTSITEINFO
),
20282 (ndr_push_flags_fn_t
) ndr_push_srvsvc_NETRDFSMANAGERREPORTSITEINFO
,
20283 (ndr_pull_flags_fn_t
) ndr_pull_srvsvc_NETRDFSMANAGERREPORTSITEINFO
,
20284 (ndr_print_function_t
) ndr_print_srvsvc_NETRDFSMANAGERREPORTSITEINFO
,
20288 "srvsvc_NETRSERVERTRANSPORTDELEX",
20289 sizeof(struct srvsvc_NETRSERVERTRANSPORTDELEX
),
20290 (ndr_push_flags_fn_t
) ndr_push_srvsvc_NETRSERVERTRANSPORTDELEX
,
20291 (ndr_pull_flags_fn_t
) ndr_pull_srvsvc_NETRSERVERTRANSPORTDELEX
,
20292 (ndr_print_function_t
) ndr_print_srvsvc_NETRSERVERTRANSPORTDELEX
,
20295 { NULL
, 0, NULL
, NULL
, NULL
, false }
20298 static const char * const srvsvc_endpoint_strings
[] = {
20299 "ncacn_np:[\\pipe\\srvsvc]",
20304 static const struct ndr_interface_string_array srvsvc_endpoints
= {
20306 .names
= srvsvc_endpoint_strings
20309 static const char * const srvsvc_authservice_strings
[] = {
20313 static const struct ndr_interface_string_array srvsvc_authservices
= {
20315 .names
= srvsvc_authservice_strings
20319 const struct ndr_interface_table ndr_table_srvsvc
= {
20322 {0x4b324fc8,0x1670,0x01d3,{0x12,0x78},{0x5a,0x47,0xbf,0x6e,0xe1,0x88}},
20325 .helpstring
= NDR_SRVSVC_HELPSTRING
,
20327 .calls
= srvsvc_calls
,
20328 .endpoints
= &srvsvc_endpoints
,
20329 .authservices
= &srvsvc_authservices