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 TALLOC_CTX
*_mem_save_device_0
;
29 if (ndr_flags
& NDR_SCALARS
) {
30 NDR_CHECK(ndr_pull_align(ndr
, 4));
31 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_device
));
33 NDR_PULL_ALLOC(ndr
, r
->device
);
38 if (ndr_flags
& NDR_BUFFERS
) {
40 _mem_save_device_0
= NDR_PULL_GET_MEM_CTX(ndr
);
41 NDR_PULL_SET_MEM_CTX(ndr
, r
->device
, 0);
42 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->device
));
43 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->device
));
44 if (ndr_get_array_length(ndr
, &r
->device
) > ndr_get_array_size(ndr
, &r
->device
)) {
45 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", ndr_get_array_size(ndr
, &r
->device
), ndr_get_array_length(ndr
, &r
->device
));
47 NDR_CHECK(ndr_check_string_terminator(ndr
, ndr_get_array_length(ndr
, &r
->device
), sizeof(uint16_t)));
48 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->device
, ndr_get_array_length(ndr
, &r
->device
), sizeof(uint16_t), CH_UTF16
));
49 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_device_0
, 0);
52 return NDR_ERR_SUCCESS
;
55 _PUBLIC_
void ndr_print_srvsvc_NetCharDevInfo0(struct ndr_print
*ndr
, const char *name
, const struct srvsvc_NetCharDevInfo0
*r
)
57 ndr_print_struct(ndr
, name
, "srvsvc_NetCharDevInfo0");
59 ndr_print_ptr(ndr
, "device", r
->device
);
62 ndr_print_string(ndr
, "device", r
->device
);
68 static enum ndr_err_code
ndr_push_srvsvc_NetCharDevCtr0(struct ndr_push
*ndr
, int ndr_flags
, const struct srvsvc_NetCharDevCtr0
*r
)
70 uint32_t cntr_array_1
;
71 if (ndr_flags
& NDR_SCALARS
) {
72 NDR_CHECK(ndr_push_align(ndr
, 4));
73 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->count
));
74 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->array
));
76 if (ndr_flags
& NDR_BUFFERS
) {
78 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->count
));
79 for (cntr_array_1
= 0; cntr_array_1
< r
->count
; cntr_array_1
++) {
80 NDR_CHECK(ndr_push_srvsvc_NetCharDevInfo0(ndr
, NDR_SCALARS
, &r
->array
[cntr_array_1
]));
82 for (cntr_array_1
= 0; cntr_array_1
< r
->count
; cntr_array_1
++) {
83 NDR_CHECK(ndr_push_srvsvc_NetCharDevInfo0(ndr
, NDR_BUFFERS
, &r
->array
[cntr_array_1
]));
87 return NDR_ERR_SUCCESS
;
90 static enum ndr_err_code
ndr_pull_srvsvc_NetCharDevCtr0(struct ndr_pull
*ndr
, int ndr_flags
, struct srvsvc_NetCharDevCtr0
*r
)
93 uint32_t cntr_array_1
;
94 TALLOC_CTX
*_mem_save_array_0
;
95 TALLOC_CTX
*_mem_save_array_1
;
96 if (ndr_flags
& NDR_SCALARS
) {
97 NDR_CHECK(ndr_pull_align(ndr
, 4));
98 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->count
));
99 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_array
));
101 NDR_PULL_ALLOC(ndr
, r
->array
);
106 if (ndr_flags
& NDR_BUFFERS
) {
108 _mem_save_array_0
= NDR_PULL_GET_MEM_CTX(ndr
);
109 NDR_PULL_SET_MEM_CTX(ndr
, r
->array
, 0);
110 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->array
));
111 NDR_PULL_ALLOC_N(ndr
, r
->array
, ndr_get_array_size(ndr
, &r
->array
));
112 _mem_save_array_1
= NDR_PULL_GET_MEM_CTX(ndr
);
113 NDR_PULL_SET_MEM_CTX(ndr
, r
->array
, 0);
114 for (cntr_array_1
= 0; cntr_array_1
< r
->count
; cntr_array_1
++) {
115 NDR_CHECK(ndr_pull_srvsvc_NetCharDevInfo0(ndr
, NDR_SCALARS
, &r
->array
[cntr_array_1
]));
117 for (cntr_array_1
= 0; cntr_array_1
< r
->count
; cntr_array_1
++) {
118 NDR_CHECK(ndr_pull_srvsvc_NetCharDevInfo0(ndr
, NDR_BUFFERS
, &r
->array
[cntr_array_1
]));
120 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_array_1
, 0);
121 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_array_0
, 0);
124 NDR_CHECK(ndr_check_array_size(ndr
, (void*)&r
->array
, r
->count
));
127 return NDR_ERR_SUCCESS
;
130 _PUBLIC_
void ndr_print_srvsvc_NetCharDevCtr0(struct ndr_print
*ndr
, const char *name
, const struct srvsvc_NetCharDevCtr0
*r
)
132 uint32_t cntr_array_1
;
133 ndr_print_struct(ndr
, name
, "srvsvc_NetCharDevCtr0");
135 ndr_print_uint32(ndr
, "count", r
->count
);
136 ndr_print_ptr(ndr
, "array", r
->array
);
139 ndr
->print(ndr
, "%s: ARRAY(%d)", "array", (int)r
->count
);
141 for (cntr_array_1
=0;cntr_array_1
<r
->count
;cntr_array_1
++) {
143 if (asprintf(&idx_1
, "[%d]", cntr_array_1
) != -1) {
144 ndr_print_srvsvc_NetCharDevInfo0(ndr
, "array", &r
->array
[cntr_array_1
]);
154 static enum ndr_err_code
ndr_push_srvsvc_NetCharDevInfo1(struct ndr_push
*ndr
, int ndr_flags
, const struct srvsvc_NetCharDevInfo1
*r
)
156 if (ndr_flags
& NDR_SCALARS
) {
157 NDR_CHECK(ndr_push_align(ndr
, 4));
158 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->device
));
159 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->status
));
160 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->user
));
161 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->time
));
163 if (ndr_flags
& NDR_BUFFERS
) {
165 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->device
, CH_UTF16
)));
166 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
167 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->device
, CH_UTF16
)));
168 NDR_CHECK(ndr_push_charset(ndr
, NDR_SCALARS
, r
->device
, ndr_charset_length(r
->device
, CH_UTF16
), sizeof(uint16_t), CH_UTF16
));
171 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->user
, 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
->user
, CH_UTF16
)));
174 NDR_CHECK(ndr_push_charset(ndr
, NDR_SCALARS
, r
->user
, ndr_charset_length(r
->user
, CH_UTF16
), sizeof(uint16_t), CH_UTF16
));
177 return NDR_ERR_SUCCESS
;
180 static enum ndr_err_code
ndr_pull_srvsvc_NetCharDevInfo1(struct ndr_pull
*ndr
, int ndr_flags
, struct srvsvc_NetCharDevInfo1
*r
)
182 uint32_t _ptr_device
;
183 TALLOC_CTX
*_mem_save_device_0
;
185 TALLOC_CTX
*_mem_save_user_0
;
186 if (ndr_flags
& NDR_SCALARS
) {
187 NDR_CHECK(ndr_pull_align(ndr
, 4));
188 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_device
));
190 NDR_PULL_ALLOC(ndr
, r
->device
);
194 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->status
));
195 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_user
));
197 NDR_PULL_ALLOC(ndr
, r
->user
);
201 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->time
));
203 if (ndr_flags
& NDR_BUFFERS
) {
205 _mem_save_device_0
= NDR_PULL_GET_MEM_CTX(ndr
);
206 NDR_PULL_SET_MEM_CTX(ndr
, r
->device
, 0);
207 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->device
));
208 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->device
));
209 if (ndr_get_array_length(ndr
, &r
->device
) > ndr_get_array_size(ndr
, &r
->device
)) {
210 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", ndr_get_array_size(ndr
, &r
->device
), ndr_get_array_length(ndr
, &r
->device
));
212 NDR_CHECK(ndr_check_string_terminator(ndr
, ndr_get_array_length(ndr
, &r
->device
), sizeof(uint16_t)));
213 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->device
, ndr_get_array_length(ndr
, &r
->device
), sizeof(uint16_t), CH_UTF16
));
214 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_device_0
, 0);
217 _mem_save_user_0
= NDR_PULL_GET_MEM_CTX(ndr
);
218 NDR_PULL_SET_MEM_CTX(ndr
, r
->user
, 0);
219 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->user
));
220 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->user
));
221 if (ndr_get_array_length(ndr
, &r
->user
) > ndr_get_array_size(ndr
, &r
->user
)) {
222 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", ndr_get_array_size(ndr
, &r
->user
), ndr_get_array_length(ndr
, &r
->user
));
224 NDR_CHECK(ndr_check_string_terminator(ndr
, ndr_get_array_length(ndr
, &r
->user
), sizeof(uint16_t)));
225 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->user
, ndr_get_array_length(ndr
, &r
->user
), sizeof(uint16_t), CH_UTF16
));
226 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_user_0
, 0);
229 return NDR_ERR_SUCCESS
;
232 _PUBLIC_
void ndr_print_srvsvc_NetCharDevInfo1(struct ndr_print
*ndr
, const char *name
, const struct srvsvc_NetCharDevInfo1
*r
)
234 ndr_print_struct(ndr
, name
, "srvsvc_NetCharDevInfo1");
236 ndr_print_ptr(ndr
, "device", r
->device
);
239 ndr_print_string(ndr
, "device", r
->device
);
242 ndr_print_uint32(ndr
, "status", r
->status
);
243 ndr_print_ptr(ndr
, "user", r
->user
);
246 ndr_print_string(ndr
, "user", r
->user
);
249 ndr_print_uint32(ndr
, "time", r
->time
);
253 static enum ndr_err_code
ndr_push_srvsvc_NetCharDevCtr1(struct ndr_push
*ndr
, int ndr_flags
, const struct srvsvc_NetCharDevCtr1
*r
)
255 uint32_t cntr_array_1
;
256 if (ndr_flags
& NDR_SCALARS
) {
257 NDR_CHECK(ndr_push_align(ndr
, 4));
258 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->count
));
259 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->array
));
261 if (ndr_flags
& NDR_BUFFERS
) {
263 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->count
));
264 for (cntr_array_1
= 0; cntr_array_1
< r
->count
; cntr_array_1
++) {
265 NDR_CHECK(ndr_push_srvsvc_NetCharDevInfo1(ndr
, NDR_SCALARS
, &r
->array
[cntr_array_1
]));
267 for (cntr_array_1
= 0; cntr_array_1
< r
->count
; cntr_array_1
++) {
268 NDR_CHECK(ndr_push_srvsvc_NetCharDevInfo1(ndr
, NDR_BUFFERS
, &r
->array
[cntr_array_1
]));
272 return NDR_ERR_SUCCESS
;
275 static enum ndr_err_code
ndr_pull_srvsvc_NetCharDevCtr1(struct ndr_pull
*ndr
, int ndr_flags
, struct srvsvc_NetCharDevCtr1
*r
)
278 uint32_t cntr_array_1
;
279 TALLOC_CTX
*_mem_save_array_0
;
280 TALLOC_CTX
*_mem_save_array_1
;
281 if (ndr_flags
& NDR_SCALARS
) {
282 NDR_CHECK(ndr_pull_align(ndr
, 4));
283 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->count
));
284 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_array
));
286 NDR_PULL_ALLOC(ndr
, r
->array
);
291 if (ndr_flags
& NDR_BUFFERS
) {
293 _mem_save_array_0
= NDR_PULL_GET_MEM_CTX(ndr
);
294 NDR_PULL_SET_MEM_CTX(ndr
, r
->array
, 0);
295 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->array
));
296 NDR_PULL_ALLOC_N(ndr
, r
->array
, ndr_get_array_size(ndr
, &r
->array
));
297 _mem_save_array_1
= NDR_PULL_GET_MEM_CTX(ndr
);
298 NDR_PULL_SET_MEM_CTX(ndr
, r
->array
, 0);
299 for (cntr_array_1
= 0; cntr_array_1
< r
->count
; cntr_array_1
++) {
300 NDR_CHECK(ndr_pull_srvsvc_NetCharDevInfo1(ndr
, NDR_SCALARS
, &r
->array
[cntr_array_1
]));
302 for (cntr_array_1
= 0; cntr_array_1
< r
->count
; cntr_array_1
++) {
303 NDR_CHECK(ndr_pull_srvsvc_NetCharDevInfo1(ndr
, NDR_BUFFERS
, &r
->array
[cntr_array_1
]));
305 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_array_1
, 0);
306 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_array_0
, 0);
309 NDR_CHECK(ndr_check_array_size(ndr
, (void*)&r
->array
, r
->count
));
312 return NDR_ERR_SUCCESS
;
315 _PUBLIC_
void ndr_print_srvsvc_NetCharDevCtr1(struct ndr_print
*ndr
, const char *name
, const struct srvsvc_NetCharDevCtr1
*r
)
317 uint32_t cntr_array_1
;
318 ndr_print_struct(ndr
, name
, "srvsvc_NetCharDevCtr1");
320 ndr_print_uint32(ndr
, "count", r
->count
);
321 ndr_print_ptr(ndr
, "array", r
->array
);
324 ndr
->print(ndr
, "%s: ARRAY(%d)", "array", (int)r
->count
);
326 for (cntr_array_1
=0;cntr_array_1
<r
->count
;cntr_array_1
++) {
328 if (asprintf(&idx_1
, "[%d]", cntr_array_1
) != -1) {
329 ndr_print_srvsvc_NetCharDevInfo1(ndr
, "array", &r
->array
[cntr_array_1
]);
339 static enum ndr_err_code
ndr_push_srvsvc_NetCharDevInfo(struct ndr_push
*ndr
, int ndr_flags
, const union srvsvc_NetCharDevInfo
*r
)
341 if (ndr_flags
& NDR_SCALARS
) {
342 int level
= ndr_push_get_switch_value(ndr
, r
);
343 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, level
));
346 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->info0
));
350 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->info1
));
358 if (ndr_flags
& NDR_BUFFERS
) {
359 int level
= ndr_push_get_switch_value(ndr
, r
);
363 NDR_CHECK(ndr_push_srvsvc_NetCharDevInfo0(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->info0
));
369 NDR_CHECK(ndr_push_srvsvc_NetCharDevInfo1(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->info1
));
378 return NDR_ERR_SUCCESS
;
381 static enum ndr_err_code
ndr_pull_srvsvc_NetCharDevInfo(struct ndr_pull
*ndr
, int ndr_flags
, union srvsvc_NetCharDevInfo
*r
)
385 TALLOC_CTX
*_mem_save_info0_0
;
386 TALLOC_CTX
*_mem_save_info1_0
;
387 level
= ndr_pull_get_switch_value(ndr
, r
);
388 if (ndr_flags
& NDR_SCALARS
) {
389 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &_level
));
390 if (_level
!= level
) {
391 return ndr_pull_error(ndr
, NDR_ERR_BAD_SWITCH
, "Bad switch value %u for r", _level
);
396 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_info0
));
398 NDR_PULL_ALLOC(ndr
, r
->info0
);
406 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_info1
));
408 NDR_PULL_ALLOC(ndr
, r
->info1
);
419 if (ndr_flags
& NDR_BUFFERS
) {
423 _mem_save_info0_0
= NDR_PULL_GET_MEM_CTX(ndr
);
424 NDR_PULL_SET_MEM_CTX(ndr
, r
->info0
, 0);
425 NDR_CHECK(ndr_pull_srvsvc_NetCharDevInfo0(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->info0
));
426 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_info0_0
, 0);
432 _mem_save_info1_0
= NDR_PULL_GET_MEM_CTX(ndr
);
433 NDR_PULL_SET_MEM_CTX(ndr
, r
->info1
, 0);
434 NDR_CHECK(ndr_pull_srvsvc_NetCharDevInfo1(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->info1
));
435 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_info1_0
, 0);
444 return NDR_ERR_SUCCESS
;
447 _PUBLIC_
void ndr_print_srvsvc_NetCharDevInfo(struct ndr_print
*ndr
, const char *name
, const union srvsvc_NetCharDevInfo
*r
)
450 level
= ndr_print_get_switch_value(ndr
, r
);
451 ndr_print_union(ndr
, name
, level
, "srvsvc_NetCharDevInfo");
454 ndr_print_ptr(ndr
, "info0", r
->info0
);
457 ndr_print_srvsvc_NetCharDevInfo0(ndr
, "info0", r
->info0
);
463 ndr_print_ptr(ndr
, "info1", r
->info1
);
466 ndr_print_srvsvc_NetCharDevInfo1(ndr
, "info1", r
->info1
);
477 static enum ndr_err_code
ndr_push_srvsvc_NetCharDevCtr(struct ndr_push
*ndr
, int ndr_flags
, const union srvsvc_NetCharDevCtr
*r
)
479 if (ndr_flags
& NDR_SCALARS
) {
480 int level
= ndr_push_get_switch_value(ndr
, r
);
481 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, level
));
484 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->ctr0
));
488 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->ctr1
));
496 if (ndr_flags
& NDR_BUFFERS
) {
497 int level
= ndr_push_get_switch_value(ndr
, r
);
501 NDR_CHECK(ndr_push_srvsvc_NetCharDevCtr0(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->ctr0
));
507 NDR_CHECK(ndr_push_srvsvc_NetCharDevCtr1(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->ctr1
));
516 return NDR_ERR_SUCCESS
;
519 static enum ndr_err_code
ndr_pull_srvsvc_NetCharDevCtr(struct ndr_pull
*ndr
, int ndr_flags
, union srvsvc_NetCharDevCtr
*r
)
523 TALLOC_CTX
*_mem_save_ctr0_0
;
524 TALLOC_CTX
*_mem_save_ctr1_0
;
525 level
= ndr_pull_get_switch_value(ndr
, r
);
526 if (ndr_flags
& NDR_SCALARS
) {
527 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &_level
));
528 if (_level
!= level
) {
529 return ndr_pull_error(ndr
, NDR_ERR_BAD_SWITCH
, "Bad switch value %u for r", _level
);
534 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_ctr0
));
536 NDR_PULL_ALLOC(ndr
, r
->ctr0
);
544 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_ctr1
));
546 NDR_PULL_ALLOC(ndr
, r
->ctr1
);
557 if (ndr_flags
& NDR_BUFFERS
) {
561 _mem_save_ctr0_0
= NDR_PULL_GET_MEM_CTX(ndr
);
562 NDR_PULL_SET_MEM_CTX(ndr
, r
->ctr0
, 0);
563 NDR_CHECK(ndr_pull_srvsvc_NetCharDevCtr0(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->ctr0
));
564 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_ctr0_0
, 0);
570 _mem_save_ctr1_0
= NDR_PULL_GET_MEM_CTX(ndr
);
571 NDR_PULL_SET_MEM_CTX(ndr
, r
->ctr1
, 0);
572 NDR_CHECK(ndr_pull_srvsvc_NetCharDevCtr1(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->ctr1
));
573 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_ctr1_0
, 0);
582 return NDR_ERR_SUCCESS
;
585 _PUBLIC_
void ndr_print_srvsvc_NetCharDevCtr(struct ndr_print
*ndr
, const char *name
, const union srvsvc_NetCharDevCtr
*r
)
588 level
= ndr_print_get_switch_value(ndr
, r
);
589 ndr_print_union(ndr
, name
, level
, "srvsvc_NetCharDevCtr");
592 ndr_print_ptr(ndr
, "ctr0", r
->ctr0
);
595 ndr_print_srvsvc_NetCharDevCtr0(ndr
, "ctr0", r
->ctr0
);
601 ndr_print_ptr(ndr
, "ctr1", r
->ctr1
);
604 ndr_print_srvsvc_NetCharDevCtr1(ndr
, "ctr1", r
->ctr1
);
615 static enum ndr_err_code
ndr_push_srvsvc_NetCharDevQInfo0(struct ndr_push
*ndr
, int ndr_flags
, const struct srvsvc_NetCharDevQInfo0
*r
)
617 if (ndr_flags
& NDR_SCALARS
) {
618 NDR_CHECK(ndr_push_align(ndr
, 4));
619 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->device
));
621 if (ndr_flags
& NDR_BUFFERS
) {
623 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->device
, CH_UTF16
)));
624 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
625 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->device
, CH_UTF16
)));
626 NDR_CHECK(ndr_push_charset(ndr
, NDR_SCALARS
, r
->device
, ndr_charset_length(r
->device
, CH_UTF16
), sizeof(uint16_t), CH_UTF16
));
629 return NDR_ERR_SUCCESS
;
632 static enum ndr_err_code
ndr_pull_srvsvc_NetCharDevQInfo0(struct ndr_pull
*ndr
, int ndr_flags
, struct srvsvc_NetCharDevQInfo0
*r
)
634 uint32_t _ptr_device
;
635 TALLOC_CTX
*_mem_save_device_0
;
636 if (ndr_flags
& NDR_SCALARS
) {
637 NDR_CHECK(ndr_pull_align(ndr
, 4));
638 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_device
));
640 NDR_PULL_ALLOC(ndr
, r
->device
);
645 if (ndr_flags
& NDR_BUFFERS
) {
647 _mem_save_device_0
= NDR_PULL_GET_MEM_CTX(ndr
);
648 NDR_PULL_SET_MEM_CTX(ndr
, r
->device
, 0);
649 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->device
));
650 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->device
));
651 if (ndr_get_array_length(ndr
, &r
->device
) > ndr_get_array_size(ndr
, &r
->device
)) {
652 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", ndr_get_array_size(ndr
, &r
->device
), ndr_get_array_length(ndr
, &r
->device
));
654 NDR_CHECK(ndr_check_string_terminator(ndr
, ndr_get_array_length(ndr
, &r
->device
), sizeof(uint16_t)));
655 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->device
, ndr_get_array_length(ndr
, &r
->device
), sizeof(uint16_t), CH_UTF16
));
656 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_device_0
, 0);
659 return NDR_ERR_SUCCESS
;
662 _PUBLIC_
void ndr_print_srvsvc_NetCharDevQInfo0(struct ndr_print
*ndr
, const char *name
, const struct srvsvc_NetCharDevQInfo0
*r
)
664 ndr_print_struct(ndr
, name
, "srvsvc_NetCharDevQInfo0");
666 ndr_print_ptr(ndr
, "device", r
->device
);
669 ndr_print_string(ndr
, "device", r
->device
);
675 static enum ndr_err_code
ndr_push_srvsvc_NetCharDevQCtr0(struct ndr_push
*ndr
, int ndr_flags
, const struct srvsvc_NetCharDevQCtr0
*r
)
677 uint32_t cntr_array_1
;
678 if (ndr_flags
& NDR_SCALARS
) {
679 NDR_CHECK(ndr_push_align(ndr
, 4));
680 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->count
));
681 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->array
));
683 if (ndr_flags
& NDR_BUFFERS
) {
685 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->count
));
686 for (cntr_array_1
= 0; cntr_array_1
< r
->count
; cntr_array_1
++) {
687 NDR_CHECK(ndr_push_srvsvc_NetCharDevQInfo0(ndr
, NDR_SCALARS
, &r
->array
[cntr_array_1
]));
689 for (cntr_array_1
= 0; cntr_array_1
< r
->count
; cntr_array_1
++) {
690 NDR_CHECK(ndr_push_srvsvc_NetCharDevQInfo0(ndr
, NDR_BUFFERS
, &r
->array
[cntr_array_1
]));
694 return NDR_ERR_SUCCESS
;
697 static enum ndr_err_code
ndr_pull_srvsvc_NetCharDevQCtr0(struct ndr_pull
*ndr
, int ndr_flags
, struct srvsvc_NetCharDevQCtr0
*r
)
700 uint32_t cntr_array_1
;
701 TALLOC_CTX
*_mem_save_array_0
;
702 TALLOC_CTX
*_mem_save_array_1
;
703 if (ndr_flags
& NDR_SCALARS
) {
704 NDR_CHECK(ndr_pull_align(ndr
, 4));
705 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->count
));
706 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_array
));
708 NDR_PULL_ALLOC(ndr
, r
->array
);
713 if (ndr_flags
& NDR_BUFFERS
) {
715 _mem_save_array_0
= NDR_PULL_GET_MEM_CTX(ndr
);
716 NDR_PULL_SET_MEM_CTX(ndr
, r
->array
, 0);
717 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->array
));
718 NDR_PULL_ALLOC_N(ndr
, r
->array
, ndr_get_array_size(ndr
, &r
->array
));
719 _mem_save_array_1
= NDR_PULL_GET_MEM_CTX(ndr
);
720 NDR_PULL_SET_MEM_CTX(ndr
, r
->array
, 0);
721 for (cntr_array_1
= 0; cntr_array_1
< r
->count
; cntr_array_1
++) {
722 NDR_CHECK(ndr_pull_srvsvc_NetCharDevQInfo0(ndr
, NDR_SCALARS
, &r
->array
[cntr_array_1
]));
724 for (cntr_array_1
= 0; cntr_array_1
< r
->count
; cntr_array_1
++) {
725 NDR_CHECK(ndr_pull_srvsvc_NetCharDevQInfo0(ndr
, NDR_BUFFERS
, &r
->array
[cntr_array_1
]));
727 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_array_1
, 0);
728 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_array_0
, 0);
731 NDR_CHECK(ndr_check_array_size(ndr
, (void*)&r
->array
, r
->count
));
734 return NDR_ERR_SUCCESS
;
737 _PUBLIC_
void ndr_print_srvsvc_NetCharDevQCtr0(struct ndr_print
*ndr
, const char *name
, const struct srvsvc_NetCharDevQCtr0
*r
)
739 uint32_t cntr_array_1
;
740 ndr_print_struct(ndr
, name
, "srvsvc_NetCharDevQCtr0");
742 ndr_print_uint32(ndr
, "count", r
->count
);
743 ndr_print_ptr(ndr
, "array", r
->array
);
746 ndr
->print(ndr
, "%s: ARRAY(%d)", "array", (int)r
->count
);
748 for (cntr_array_1
=0;cntr_array_1
<r
->count
;cntr_array_1
++) {
750 if (asprintf(&idx_1
, "[%d]", cntr_array_1
) != -1) {
751 ndr_print_srvsvc_NetCharDevQInfo0(ndr
, "array", &r
->array
[cntr_array_1
]);
761 static enum ndr_err_code
ndr_push_srvsvc_NetCharDevQInfo1(struct ndr_push
*ndr
, int ndr_flags
, const struct srvsvc_NetCharDevQInfo1
*r
)
763 if (ndr_flags
& NDR_SCALARS
) {
764 NDR_CHECK(ndr_push_align(ndr
, 4));
765 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->device
));
766 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->priority
));
767 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->devices
));
768 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->users
));
769 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->num_ahead
));
771 if (ndr_flags
& NDR_BUFFERS
) {
773 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->device
, CH_UTF16
)));
774 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
775 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->device
, CH_UTF16
)));
776 NDR_CHECK(ndr_push_charset(ndr
, NDR_SCALARS
, r
->device
, ndr_charset_length(r
->device
, CH_UTF16
), sizeof(uint16_t), CH_UTF16
));
779 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->devices
, CH_UTF16
)));
780 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
781 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->devices
, CH_UTF16
)));
782 NDR_CHECK(ndr_push_charset(ndr
, NDR_SCALARS
, r
->devices
, ndr_charset_length(r
->devices
, CH_UTF16
), sizeof(uint16_t), CH_UTF16
));
785 return NDR_ERR_SUCCESS
;
788 static enum ndr_err_code
ndr_pull_srvsvc_NetCharDevQInfo1(struct ndr_pull
*ndr
, int ndr_flags
, struct srvsvc_NetCharDevQInfo1
*r
)
790 uint32_t _ptr_device
;
791 TALLOC_CTX
*_mem_save_device_0
;
792 uint32_t _ptr_devices
;
793 TALLOC_CTX
*_mem_save_devices_0
;
794 if (ndr_flags
& NDR_SCALARS
) {
795 NDR_CHECK(ndr_pull_align(ndr
, 4));
796 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_device
));
798 NDR_PULL_ALLOC(ndr
, r
->device
);
802 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->priority
));
803 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_devices
));
805 NDR_PULL_ALLOC(ndr
, r
->devices
);
809 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->users
));
810 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->num_ahead
));
812 if (ndr_flags
& NDR_BUFFERS
) {
814 _mem_save_device_0
= NDR_PULL_GET_MEM_CTX(ndr
);
815 NDR_PULL_SET_MEM_CTX(ndr
, r
->device
, 0);
816 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->device
));
817 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->device
));
818 if (ndr_get_array_length(ndr
, &r
->device
) > ndr_get_array_size(ndr
, &r
->device
)) {
819 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", ndr_get_array_size(ndr
, &r
->device
), ndr_get_array_length(ndr
, &r
->device
));
821 NDR_CHECK(ndr_check_string_terminator(ndr
, ndr_get_array_length(ndr
, &r
->device
), sizeof(uint16_t)));
822 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->device
, ndr_get_array_length(ndr
, &r
->device
), sizeof(uint16_t), CH_UTF16
));
823 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_device_0
, 0);
826 _mem_save_devices_0
= NDR_PULL_GET_MEM_CTX(ndr
);
827 NDR_PULL_SET_MEM_CTX(ndr
, r
->devices
, 0);
828 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->devices
));
829 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->devices
));
830 if (ndr_get_array_length(ndr
, &r
->devices
) > ndr_get_array_size(ndr
, &r
->devices
)) {
831 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", ndr_get_array_size(ndr
, &r
->devices
), ndr_get_array_length(ndr
, &r
->devices
));
833 NDR_CHECK(ndr_check_string_terminator(ndr
, ndr_get_array_length(ndr
, &r
->devices
), sizeof(uint16_t)));
834 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->devices
, ndr_get_array_length(ndr
, &r
->devices
), sizeof(uint16_t), CH_UTF16
));
835 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_devices_0
, 0);
838 return NDR_ERR_SUCCESS
;
841 _PUBLIC_
void ndr_print_srvsvc_NetCharDevQInfo1(struct ndr_print
*ndr
, const char *name
, const struct srvsvc_NetCharDevQInfo1
*r
)
843 ndr_print_struct(ndr
, name
, "srvsvc_NetCharDevQInfo1");
845 ndr_print_ptr(ndr
, "device", r
->device
);
848 ndr_print_string(ndr
, "device", r
->device
);
851 ndr_print_uint32(ndr
, "priority", r
->priority
);
852 ndr_print_ptr(ndr
, "devices", r
->devices
);
855 ndr_print_string(ndr
, "devices", r
->devices
);
858 ndr_print_uint32(ndr
, "users", r
->users
);
859 ndr_print_uint32(ndr
, "num_ahead", r
->num_ahead
);
863 static enum ndr_err_code
ndr_push_srvsvc_NetCharDevQCtr1(struct ndr_push
*ndr
, int ndr_flags
, const struct srvsvc_NetCharDevQCtr1
*r
)
865 uint32_t cntr_array_1
;
866 if (ndr_flags
& NDR_SCALARS
) {
867 NDR_CHECK(ndr_push_align(ndr
, 4));
868 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->count
));
869 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->array
));
871 if (ndr_flags
& NDR_BUFFERS
) {
873 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->count
));
874 for (cntr_array_1
= 0; cntr_array_1
< r
->count
; cntr_array_1
++) {
875 NDR_CHECK(ndr_push_srvsvc_NetCharDevQInfo1(ndr
, NDR_SCALARS
, &r
->array
[cntr_array_1
]));
877 for (cntr_array_1
= 0; cntr_array_1
< r
->count
; cntr_array_1
++) {
878 NDR_CHECK(ndr_push_srvsvc_NetCharDevQInfo1(ndr
, NDR_BUFFERS
, &r
->array
[cntr_array_1
]));
882 return NDR_ERR_SUCCESS
;
885 static enum ndr_err_code
ndr_pull_srvsvc_NetCharDevQCtr1(struct ndr_pull
*ndr
, int ndr_flags
, struct srvsvc_NetCharDevQCtr1
*r
)
888 uint32_t cntr_array_1
;
889 TALLOC_CTX
*_mem_save_array_0
;
890 TALLOC_CTX
*_mem_save_array_1
;
891 if (ndr_flags
& NDR_SCALARS
) {
892 NDR_CHECK(ndr_pull_align(ndr
, 4));
893 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->count
));
894 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_array
));
896 NDR_PULL_ALLOC(ndr
, r
->array
);
901 if (ndr_flags
& NDR_BUFFERS
) {
903 _mem_save_array_0
= NDR_PULL_GET_MEM_CTX(ndr
);
904 NDR_PULL_SET_MEM_CTX(ndr
, r
->array
, 0);
905 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->array
));
906 NDR_PULL_ALLOC_N(ndr
, r
->array
, ndr_get_array_size(ndr
, &r
->array
));
907 _mem_save_array_1
= NDR_PULL_GET_MEM_CTX(ndr
);
908 NDR_PULL_SET_MEM_CTX(ndr
, r
->array
, 0);
909 for (cntr_array_1
= 0; cntr_array_1
< r
->count
; cntr_array_1
++) {
910 NDR_CHECK(ndr_pull_srvsvc_NetCharDevQInfo1(ndr
, NDR_SCALARS
, &r
->array
[cntr_array_1
]));
912 for (cntr_array_1
= 0; cntr_array_1
< r
->count
; cntr_array_1
++) {
913 NDR_CHECK(ndr_pull_srvsvc_NetCharDevQInfo1(ndr
, NDR_BUFFERS
, &r
->array
[cntr_array_1
]));
915 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_array_1
, 0);
916 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_array_0
, 0);
919 NDR_CHECK(ndr_check_array_size(ndr
, (void*)&r
->array
, r
->count
));
922 return NDR_ERR_SUCCESS
;
925 _PUBLIC_
void ndr_print_srvsvc_NetCharDevQCtr1(struct ndr_print
*ndr
, const char *name
, const struct srvsvc_NetCharDevQCtr1
*r
)
927 uint32_t cntr_array_1
;
928 ndr_print_struct(ndr
, name
, "srvsvc_NetCharDevQCtr1");
930 ndr_print_uint32(ndr
, "count", r
->count
);
931 ndr_print_ptr(ndr
, "array", r
->array
);
934 ndr
->print(ndr
, "%s: ARRAY(%d)", "array", (int)r
->count
);
936 for (cntr_array_1
=0;cntr_array_1
<r
->count
;cntr_array_1
++) {
938 if (asprintf(&idx_1
, "[%d]", cntr_array_1
) != -1) {
939 ndr_print_srvsvc_NetCharDevQInfo1(ndr
, "array", &r
->array
[cntr_array_1
]);
949 static enum ndr_err_code
ndr_push_srvsvc_NetCharDevQInfo(struct ndr_push
*ndr
, int ndr_flags
, const union srvsvc_NetCharDevQInfo
*r
)
951 if (ndr_flags
& NDR_SCALARS
) {
952 int level
= ndr_push_get_switch_value(ndr
, r
);
953 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, level
));
956 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->info0
));
960 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->info1
));
968 if (ndr_flags
& NDR_BUFFERS
) {
969 int level
= ndr_push_get_switch_value(ndr
, r
);
973 NDR_CHECK(ndr_push_srvsvc_NetCharDevQInfo0(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->info0
));
979 NDR_CHECK(ndr_push_srvsvc_NetCharDevQInfo1(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->info1
));
988 return NDR_ERR_SUCCESS
;
991 static enum ndr_err_code
ndr_pull_srvsvc_NetCharDevQInfo(struct ndr_pull
*ndr
, int ndr_flags
, union srvsvc_NetCharDevQInfo
*r
)
995 TALLOC_CTX
*_mem_save_info0_0
;
996 TALLOC_CTX
*_mem_save_info1_0
;
997 level
= ndr_pull_get_switch_value(ndr
, r
);
998 if (ndr_flags
& NDR_SCALARS
) {
999 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &_level
));
1000 if (_level
!= level
) {
1001 return ndr_pull_error(ndr
, NDR_ERR_BAD_SWITCH
, "Bad switch value %u for r", _level
);
1005 uint32_t _ptr_info0
;
1006 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_info0
));
1008 NDR_PULL_ALLOC(ndr
, r
->info0
);
1015 uint32_t _ptr_info1
;
1016 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_info1
));
1018 NDR_PULL_ALLOC(ndr
, r
->info1
);
1029 if (ndr_flags
& NDR_BUFFERS
) {
1033 _mem_save_info0_0
= NDR_PULL_GET_MEM_CTX(ndr
);
1034 NDR_PULL_SET_MEM_CTX(ndr
, r
->info0
, 0);
1035 NDR_CHECK(ndr_pull_srvsvc_NetCharDevQInfo0(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->info0
));
1036 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_info0_0
, 0);
1042 _mem_save_info1_0
= NDR_PULL_GET_MEM_CTX(ndr
);
1043 NDR_PULL_SET_MEM_CTX(ndr
, r
->info1
, 0);
1044 NDR_CHECK(ndr_pull_srvsvc_NetCharDevQInfo1(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->info1
));
1045 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_info1_0
, 0);
1054 return NDR_ERR_SUCCESS
;
1057 _PUBLIC_
void ndr_print_srvsvc_NetCharDevQInfo(struct ndr_print
*ndr
, const char *name
, const union srvsvc_NetCharDevQInfo
*r
)
1060 level
= ndr_print_get_switch_value(ndr
, r
);
1061 ndr_print_union(ndr
, name
, level
, "srvsvc_NetCharDevQInfo");
1064 ndr_print_ptr(ndr
, "info0", r
->info0
);
1067 ndr_print_srvsvc_NetCharDevQInfo0(ndr
, "info0", r
->info0
);
1073 ndr_print_ptr(ndr
, "info1", r
->info1
);
1076 ndr_print_srvsvc_NetCharDevQInfo1(ndr
, "info1", r
->info1
);
1087 static enum ndr_err_code
ndr_push_srvsvc_NetCharDevQCtr(struct ndr_push
*ndr
, int ndr_flags
, const union srvsvc_NetCharDevQCtr
*r
)
1089 if (ndr_flags
& NDR_SCALARS
) {
1090 int level
= ndr_push_get_switch_value(ndr
, r
);
1091 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, level
));
1094 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->ctr0
));
1098 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->ctr1
));
1106 if (ndr_flags
& NDR_BUFFERS
) {
1107 int level
= ndr_push_get_switch_value(ndr
, r
);
1111 NDR_CHECK(ndr_push_srvsvc_NetCharDevQCtr0(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->ctr0
));
1117 NDR_CHECK(ndr_push_srvsvc_NetCharDevQCtr1(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->ctr1
));
1126 return NDR_ERR_SUCCESS
;
1129 static enum ndr_err_code
ndr_pull_srvsvc_NetCharDevQCtr(struct ndr_pull
*ndr
, int ndr_flags
, union srvsvc_NetCharDevQCtr
*r
)
1133 TALLOC_CTX
*_mem_save_ctr0_0
;
1134 TALLOC_CTX
*_mem_save_ctr1_0
;
1135 level
= ndr_pull_get_switch_value(ndr
, r
);
1136 if (ndr_flags
& NDR_SCALARS
) {
1137 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &_level
));
1138 if (_level
!= level
) {
1139 return ndr_pull_error(ndr
, NDR_ERR_BAD_SWITCH
, "Bad switch value %u for r", _level
);
1144 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_ctr0
));
1146 NDR_PULL_ALLOC(ndr
, r
->ctr0
);
1154 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_ctr1
));
1156 NDR_PULL_ALLOC(ndr
, r
->ctr1
);
1167 if (ndr_flags
& NDR_BUFFERS
) {
1171 _mem_save_ctr0_0
= NDR_PULL_GET_MEM_CTX(ndr
);
1172 NDR_PULL_SET_MEM_CTX(ndr
, r
->ctr0
, 0);
1173 NDR_CHECK(ndr_pull_srvsvc_NetCharDevQCtr0(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->ctr0
));
1174 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_ctr0_0
, 0);
1180 _mem_save_ctr1_0
= NDR_PULL_GET_MEM_CTX(ndr
);
1181 NDR_PULL_SET_MEM_CTX(ndr
, r
->ctr1
, 0);
1182 NDR_CHECK(ndr_pull_srvsvc_NetCharDevQCtr1(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->ctr1
));
1183 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_ctr1_0
, 0);
1192 return NDR_ERR_SUCCESS
;
1195 _PUBLIC_
void ndr_print_srvsvc_NetCharDevQCtr(struct ndr_print
*ndr
, const char *name
, const union srvsvc_NetCharDevQCtr
*r
)
1198 level
= ndr_print_get_switch_value(ndr
, r
);
1199 ndr_print_union(ndr
, name
, level
, "srvsvc_NetCharDevQCtr");
1202 ndr_print_ptr(ndr
, "ctr0", r
->ctr0
);
1205 ndr_print_srvsvc_NetCharDevQCtr0(ndr
, "ctr0", r
->ctr0
);
1211 ndr_print_ptr(ndr
, "ctr1", r
->ctr1
);
1214 ndr_print_srvsvc_NetCharDevQCtr1(ndr
, "ctr1", r
->ctr1
);
1225 static enum ndr_err_code
ndr_push_srvsvc_NetConnInfo0(struct ndr_push
*ndr
, int ndr_flags
, const struct srvsvc_NetConnInfo0
*r
)
1227 if (ndr_flags
& NDR_SCALARS
) {
1228 NDR_CHECK(ndr_push_align(ndr
, 4));
1229 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->conn_id
));
1231 if (ndr_flags
& NDR_BUFFERS
) {
1233 return NDR_ERR_SUCCESS
;
1236 static enum ndr_err_code
ndr_pull_srvsvc_NetConnInfo0(struct ndr_pull
*ndr
, int ndr_flags
, struct srvsvc_NetConnInfo0
*r
)
1238 if (ndr_flags
& NDR_SCALARS
) {
1239 NDR_CHECK(ndr_pull_align(ndr
, 4));
1240 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->conn_id
));
1242 if (ndr_flags
& NDR_BUFFERS
) {
1244 return NDR_ERR_SUCCESS
;
1247 _PUBLIC_
void ndr_print_srvsvc_NetConnInfo0(struct ndr_print
*ndr
, const char *name
, const struct srvsvc_NetConnInfo0
*r
)
1249 ndr_print_struct(ndr
, name
, "srvsvc_NetConnInfo0");
1251 ndr_print_uint32(ndr
, "conn_id", r
->conn_id
);
1255 static enum ndr_err_code
ndr_push_srvsvc_NetConnCtr0(struct ndr_push
*ndr
, int ndr_flags
, const struct srvsvc_NetConnCtr0
*r
)
1257 uint32_t cntr_array_1
;
1258 if (ndr_flags
& NDR_SCALARS
) {
1259 NDR_CHECK(ndr_push_align(ndr
, 4));
1260 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->count
));
1261 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->array
));
1263 if (ndr_flags
& NDR_BUFFERS
) {
1265 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->count
));
1266 for (cntr_array_1
= 0; cntr_array_1
< r
->count
; cntr_array_1
++) {
1267 NDR_CHECK(ndr_push_srvsvc_NetConnInfo0(ndr
, NDR_SCALARS
, &r
->array
[cntr_array_1
]));
1271 return NDR_ERR_SUCCESS
;
1274 static enum ndr_err_code
ndr_pull_srvsvc_NetConnCtr0(struct ndr_pull
*ndr
, int ndr_flags
, struct srvsvc_NetConnCtr0
*r
)
1276 uint32_t _ptr_array
;
1277 uint32_t cntr_array_1
;
1278 TALLOC_CTX
*_mem_save_array_0
;
1279 TALLOC_CTX
*_mem_save_array_1
;
1280 if (ndr_flags
& NDR_SCALARS
) {
1281 NDR_CHECK(ndr_pull_align(ndr
, 4));
1282 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->count
));
1283 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_array
));
1285 NDR_PULL_ALLOC(ndr
, r
->array
);
1290 if (ndr_flags
& NDR_BUFFERS
) {
1292 _mem_save_array_0
= NDR_PULL_GET_MEM_CTX(ndr
);
1293 NDR_PULL_SET_MEM_CTX(ndr
, r
->array
, 0);
1294 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->array
));
1295 NDR_PULL_ALLOC_N(ndr
, r
->array
, ndr_get_array_size(ndr
, &r
->array
));
1296 _mem_save_array_1
= NDR_PULL_GET_MEM_CTX(ndr
);
1297 NDR_PULL_SET_MEM_CTX(ndr
, r
->array
, 0);
1298 for (cntr_array_1
= 0; cntr_array_1
< r
->count
; cntr_array_1
++) {
1299 NDR_CHECK(ndr_pull_srvsvc_NetConnInfo0(ndr
, NDR_SCALARS
, &r
->array
[cntr_array_1
]));
1301 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_array_1
, 0);
1302 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_array_0
, 0);
1305 NDR_CHECK(ndr_check_array_size(ndr
, (void*)&r
->array
, r
->count
));
1308 return NDR_ERR_SUCCESS
;
1311 _PUBLIC_
void ndr_print_srvsvc_NetConnCtr0(struct ndr_print
*ndr
, const char *name
, const struct srvsvc_NetConnCtr0
*r
)
1313 uint32_t cntr_array_1
;
1314 ndr_print_struct(ndr
, name
, "srvsvc_NetConnCtr0");
1316 ndr_print_uint32(ndr
, "count", r
->count
);
1317 ndr_print_ptr(ndr
, "array", r
->array
);
1320 ndr
->print(ndr
, "%s: ARRAY(%d)", "array", (int)r
->count
);
1322 for (cntr_array_1
=0;cntr_array_1
<r
->count
;cntr_array_1
++) {
1324 if (asprintf(&idx_1
, "[%d]", cntr_array_1
) != -1) {
1325 ndr_print_srvsvc_NetConnInfo0(ndr
, "array", &r
->array
[cntr_array_1
]);
1335 static enum ndr_err_code
ndr_push_srvsvc_NetConnInfo1(struct ndr_push
*ndr
, int ndr_flags
, const struct srvsvc_NetConnInfo1
*r
)
1337 if (ndr_flags
& NDR_SCALARS
) {
1338 NDR_CHECK(ndr_push_align(ndr
, 4));
1339 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->conn_id
));
1340 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->conn_type
));
1341 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->num_open
));
1342 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->num_users
));
1343 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->conn_time
));
1344 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->user
));
1345 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->share
));
1347 if (ndr_flags
& NDR_BUFFERS
) {
1349 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->user
, CH_UTF16
)));
1350 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
1351 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->user
, CH_UTF16
)));
1352 NDR_CHECK(ndr_push_charset(ndr
, NDR_SCALARS
, r
->user
, ndr_charset_length(r
->user
, CH_UTF16
), sizeof(uint16_t), CH_UTF16
));
1355 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->share
, CH_UTF16
)));
1356 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
1357 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->share
, CH_UTF16
)));
1358 NDR_CHECK(ndr_push_charset(ndr
, NDR_SCALARS
, r
->share
, ndr_charset_length(r
->share
, CH_UTF16
), sizeof(uint16_t), CH_UTF16
));
1361 return NDR_ERR_SUCCESS
;
1364 static enum ndr_err_code
ndr_pull_srvsvc_NetConnInfo1(struct ndr_pull
*ndr
, int ndr_flags
, struct srvsvc_NetConnInfo1
*r
)
1367 TALLOC_CTX
*_mem_save_user_0
;
1368 uint32_t _ptr_share
;
1369 TALLOC_CTX
*_mem_save_share_0
;
1370 if (ndr_flags
& NDR_SCALARS
) {
1371 NDR_CHECK(ndr_pull_align(ndr
, 4));
1372 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->conn_id
));
1373 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->conn_type
));
1374 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->num_open
));
1375 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->num_users
));
1376 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->conn_time
));
1377 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_user
));
1379 NDR_PULL_ALLOC(ndr
, r
->user
);
1383 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_share
));
1385 NDR_PULL_ALLOC(ndr
, r
->share
);
1390 if (ndr_flags
& NDR_BUFFERS
) {
1392 _mem_save_user_0
= NDR_PULL_GET_MEM_CTX(ndr
);
1393 NDR_PULL_SET_MEM_CTX(ndr
, r
->user
, 0);
1394 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->user
));
1395 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->user
));
1396 if (ndr_get_array_length(ndr
, &r
->user
) > ndr_get_array_size(ndr
, &r
->user
)) {
1397 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", ndr_get_array_size(ndr
, &r
->user
), ndr_get_array_length(ndr
, &r
->user
));
1399 NDR_CHECK(ndr_check_string_terminator(ndr
, ndr_get_array_length(ndr
, &r
->user
), sizeof(uint16_t)));
1400 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->user
, ndr_get_array_length(ndr
, &r
->user
), sizeof(uint16_t), CH_UTF16
));
1401 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_user_0
, 0);
1404 _mem_save_share_0
= NDR_PULL_GET_MEM_CTX(ndr
);
1405 NDR_PULL_SET_MEM_CTX(ndr
, r
->share
, 0);
1406 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->share
));
1407 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->share
));
1408 if (ndr_get_array_length(ndr
, &r
->share
) > ndr_get_array_size(ndr
, &r
->share
)) {
1409 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", ndr_get_array_size(ndr
, &r
->share
), ndr_get_array_length(ndr
, &r
->share
));
1411 NDR_CHECK(ndr_check_string_terminator(ndr
, ndr_get_array_length(ndr
, &r
->share
), sizeof(uint16_t)));
1412 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->share
, ndr_get_array_length(ndr
, &r
->share
), sizeof(uint16_t), CH_UTF16
));
1413 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_share_0
, 0);
1416 return NDR_ERR_SUCCESS
;
1419 _PUBLIC_
void ndr_print_srvsvc_NetConnInfo1(struct ndr_print
*ndr
, const char *name
, const struct srvsvc_NetConnInfo1
*r
)
1421 ndr_print_struct(ndr
, name
, "srvsvc_NetConnInfo1");
1423 ndr_print_uint32(ndr
, "conn_id", r
->conn_id
);
1424 ndr_print_uint32(ndr
, "conn_type", r
->conn_type
);
1425 ndr_print_uint32(ndr
, "num_open", r
->num_open
);
1426 ndr_print_uint32(ndr
, "num_users", r
->num_users
);
1427 ndr_print_uint32(ndr
, "conn_time", r
->conn_time
);
1428 ndr_print_ptr(ndr
, "user", r
->user
);
1431 ndr_print_string(ndr
, "user", r
->user
);
1434 ndr_print_ptr(ndr
, "share", r
->share
);
1437 ndr_print_string(ndr
, "share", r
->share
);
1443 static enum ndr_err_code
ndr_push_srvsvc_NetConnCtr1(struct ndr_push
*ndr
, int ndr_flags
, const struct srvsvc_NetConnCtr1
*r
)
1445 uint32_t cntr_array_1
;
1446 if (ndr_flags
& NDR_SCALARS
) {
1447 NDR_CHECK(ndr_push_align(ndr
, 4));
1448 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->count
));
1449 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->array
));
1451 if (ndr_flags
& NDR_BUFFERS
) {
1453 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->count
));
1454 for (cntr_array_1
= 0; cntr_array_1
< r
->count
; cntr_array_1
++) {
1455 NDR_CHECK(ndr_push_srvsvc_NetConnInfo1(ndr
, NDR_SCALARS
, &r
->array
[cntr_array_1
]));
1457 for (cntr_array_1
= 0; cntr_array_1
< r
->count
; cntr_array_1
++) {
1458 NDR_CHECK(ndr_push_srvsvc_NetConnInfo1(ndr
, NDR_BUFFERS
, &r
->array
[cntr_array_1
]));
1462 return NDR_ERR_SUCCESS
;
1465 static enum ndr_err_code
ndr_pull_srvsvc_NetConnCtr1(struct ndr_pull
*ndr
, int ndr_flags
, struct srvsvc_NetConnCtr1
*r
)
1467 uint32_t _ptr_array
;
1468 uint32_t cntr_array_1
;
1469 TALLOC_CTX
*_mem_save_array_0
;
1470 TALLOC_CTX
*_mem_save_array_1
;
1471 if (ndr_flags
& NDR_SCALARS
) {
1472 NDR_CHECK(ndr_pull_align(ndr
, 4));
1473 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->count
));
1474 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_array
));
1476 NDR_PULL_ALLOC(ndr
, r
->array
);
1481 if (ndr_flags
& NDR_BUFFERS
) {
1483 _mem_save_array_0
= NDR_PULL_GET_MEM_CTX(ndr
);
1484 NDR_PULL_SET_MEM_CTX(ndr
, r
->array
, 0);
1485 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->array
));
1486 NDR_PULL_ALLOC_N(ndr
, r
->array
, ndr_get_array_size(ndr
, &r
->array
));
1487 _mem_save_array_1
= NDR_PULL_GET_MEM_CTX(ndr
);
1488 NDR_PULL_SET_MEM_CTX(ndr
, r
->array
, 0);
1489 for (cntr_array_1
= 0; cntr_array_1
< r
->count
; cntr_array_1
++) {
1490 NDR_CHECK(ndr_pull_srvsvc_NetConnInfo1(ndr
, NDR_SCALARS
, &r
->array
[cntr_array_1
]));
1492 for (cntr_array_1
= 0; cntr_array_1
< r
->count
; cntr_array_1
++) {
1493 NDR_CHECK(ndr_pull_srvsvc_NetConnInfo1(ndr
, NDR_BUFFERS
, &r
->array
[cntr_array_1
]));
1495 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_array_1
, 0);
1496 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_array_0
, 0);
1499 NDR_CHECK(ndr_check_array_size(ndr
, (void*)&r
->array
, r
->count
));
1502 return NDR_ERR_SUCCESS
;
1505 _PUBLIC_
void ndr_print_srvsvc_NetConnCtr1(struct ndr_print
*ndr
, const char *name
, const struct srvsvc_NetConnCtr1
*r
)
1507 uint32_t cntr_array_1
;
1508 ndr_print_struct(ndr
, name
, "srvsvc_NetConnCtr1");
1510 ndr_print_uint32(ndr
, "count", r
->count
);
1511 ndr_print_ptr(ndr
, "array", r
->array
);
1514 ndr
->print(ndr
, "%s: ARRAY(%d)", "array", (int)r
->count
);
1516 for (cntr_array_1
=0;cntr_array_1
<r
->count
;cntr_array_1
++) {
1518 if (asprintf(&idx_1
, "[%d]", cntr_array_1
) != -1) {
1519 ndr_print_srvsvc_NetConnInfo1(ndr
, "array", &r
->array
[cntr_array_1
]);
1529 static enum ndr_err_code
ndr_push_srvsvc_NetConnCtr(struct ndr_push
*ndr
, int ndr_flags
, const union srvsvc_NetConnCtr
*r
)
1531 if (ndr_flags
& NDR_SCALARS
) {
1532 int level
= ndr_push_get_switch_value(ndr
, r
);
1533 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, level
));
1536 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->ctr0
));
1540 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->ctr1
));
1548 if (ndr_flags
& NDR_BUFFERS
) {
1549 int level
= ndr_push_get_switch_value(ndr
, r
);
1553 NDR_CHECK(ndr_push_srvsvc_NetConnCtr0(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->ctr0
));
1559 NDR_CHECK(ndr_push_srvsvc_NetConnCtr1(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->ctr1
));
1568 return NDR_ERR_SUCCESS
;
1571 static enum ndr_err_code
ndr_pull_srvsvc_NetConnCtr(struct ndr_pull
*ndr
, int ndr_flags
, union srvsvc_NetConnCtr
*r
)
1575 TALLOC_CTX
*_mem_save_ctr0_0
;
1576 TALLOC_CTX
*_mem_save_ctr1_0
;
1577 level
= ndr_pull_get_switch_value(ndr
, r
);
1578 if (ndr_flags
& NDR_SCALARS
) {
1579 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &_level
));
1580 if (_level
!= level
) {
1581 return ndr_pull_error(ndr
, NDR_ERR_BAD_SWITCH
, "Bad switch value %u for r", _level
);
1586 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_ctr0
));
1588 NDR_PULL_ALLOC(ndr
, r
->ctr0
);
1596 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_ctr1
));
1598 NDR_PULL_ALLOC(ndr
, r
->ctr1
);
1609 if (ndr_flags
& NDR_BUFFERS
) {
1613 _mem_save_ctr0_0
= NDR_PULL_GET_MEM_CTX(ndr
);
1614 NDR_PULL_SET_MEM_CTX(ndr
, r
->ctr0
, 0);
1615 NDR_CHECK(ndr_pull_srvsvc_NetConnCtr0(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->ctr0
));
1616 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_ctr0_0
, 0);
1622 _mem_save_ctr1_0
= NDR_PULL_GET_MEM_CTX(ndr
);
1623 NDR_PULL_SET_MEM_CTX(ndr
, r
->ctr1
, 0);
1624 NDR_CHECK(ndr_pull_srvsvc_NetConnCtr1(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->ctr1
));
1625 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_ctr1_0
, 0);
1634 return NDR_ERR_SUCCESS
;
1637 _PUBLIC_
void ndr_print_srvsvc_NetConnCtr(struct ndr_print
*ndr
, const char *name
, const union srvsvc_NetConnCtr
*r
)
1640 level
= ndr_print_get_switch_value(ndr
, r
);
1641 ndr_print_union(ndr
, name
, level
, "srvsvc_NetConnCtr");
1644 ndr_print_ptr(ndr
, "ctr0", r
->ctr0
);
1647 ndr_print_srvsvc_NetConnCtr0(ndr
, "ctr0", r
->ctr0
);
1653 ndr_print_ptr(ndr
, "ctr1", r
->ctr1
);
1656 ndr_print_srvsvc_NetConnCtr1(ndr
, "ctr1", r
->ctr1
);
1667 static enum ndr_err_code
ndr_push_srvsvc_NetConnInfoCtr(struct ndr_push
*ndr
, int ndr_flags
, const struct srvsvc_NetConnInfoCtr
*r
)
1669 if (ndr_flags
& NDR_SCALARS
) {
1670 NDR_CHECK(ndr_push_align(ndr
, 4));
1671 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->level
));
1672 NDR_CHECK(ndr_push_set_switch_value(ndr
, &r
->ctr
, r
->level
));
1673 NDR_CHECK(ndr_push_srvsvc_NetConnCtr(ndr
, NDR_SCALARS
, &r
->ctr
));
1675 if (ndr_flags
& NDR_BUFFERS
) {
1676 NDR_CHECK(ndr_push_srvsvc_NetConnCtr(ndr
, NDR_BUFFERS
, &r
->ctr
));
1678 return NDR_ERR_SUCCESS
;
1681 static enum ndr_err_code
ndr_pull_srvsvc_NetConnInfoCtr(struct ndr_pull
*ndr
, int ndr_flags
, struct srvsvc_NetConnInfoCtr
*r
)
1683 if (ndr_flags
& NDR_SCALARS
) {
1684 NDR_CHECK(ndr_pull_align(ndr
, 4));
1685 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->level
));
1686 NDR_CHECK(ndr_pull_set_switch_value(ndr
, &r
->ctr
, r
->level
));
1687 NDR_CHECK(ndr_pull_srvsvc_NetConnCtr(ndr
, NDR_SCALARS
, &r
->ctr
));
1689 if (ndr_flags
& NDR_BUFFERS
) {
1690 NDR_CHECK(ndr_pull_srvsvc_NetConnCtr(ndr
, NDR_BUFFERS
, &r
->ctr
));
1692 return NDR_ERR_SUCCESS
;
1695 _PUBLIC_
void ndr_print_srvsvc_NetConnInfoCtr(struct ndr_print
*ndr
, const char *name
, const struct srvsvc_NetConnInfoCtr
*r
)
1697 ndr_print_struct(ndr
, name
, "srvsvc_NetConnInfoCtr");
1699 ndr_print_uint32(ndr
, "level", r
->level
);
1700 ndr_print_set_switch_value(ndr
, &r
->ctr
, r
->level
);
1701 ndr_print_srvsvc_NetConnCtr(ndr
, "ctr", &r
->ctr
);
1705 static enum ndr_err_code
ndr_push_srvsvc_NetFileInfo2(struct ndr_push
*ndr
, int ndr_flags
, const struct srvsvc_NetFileInfo2
*r
)
1707 if (ndr_flags
& NDR_SCALARS
) {
1708 NDR_CHECK(ndr_push_align(ndr
, 4));
1709 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->fid
));
1711 if (ndr_flags
& NDR_BUFFERS
) {
1713 return NDR_ERR_SUCCESS
;
1716 static enum ndr_err_code
ndr_pull_srvsvc_NetFileInfo2(struct ndr_pull
*ndr
, int ndr_flags
, struct srvsvc_NetFileInfo2
*r
)
1718 if (ndr_flags
& NDR_SCALARS
) {
1719 NDR_CHECK(ndr_pull_align(ndr
, 4));
1720 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->fid
));
1722 if (ndr_flags
& NDR_BUFFERS
) {
1724 return NDR_ERR_SUCCESS
;
1727 _PUBLIC_
void ndr_print_srvsvc_NetFileInfo2(struct ndr_print
*ndr
, const char *name
, const struct srvsvc_NetFileInfo2
*r
)
1729 ndr_print_struct(ndr
, name
, "srvsvc_NetFileInfo2");
1731 ndr_print_uint32(ndr
, "fid", r
->fid
);
1735 static enum ndr_err_code
ndr_push_srvsvc_NetFileCtr2(struct ndr_push
*ndr
, int ndr_flags
, const struct srvsvc_NetFileCtr2
*r
)
1737 uint32_t cntr_array_1
;
1738 if (ndr_flags
& NDR_SCALARS
) {
1739 NDR_CHECK(ndr_push_align(ndr
, 4));
1740 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->count
));
1741 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->array
));
1743 if (ndr_flags
& NDR_BUFFERS
) {
1745 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->count
));
1746 for (cntr_array_1
= 0; cntr_array_1
< r
->count
; cntr_array_1
++) {
1747 NDR_CHECK(ndr_push_srvsvc_NetFileInfo2(ndr
, NDR_SCALARS
, &r
->array
[cntr_array_1
]));
1751 return NDR_ERR_SUCCESS
;
1754 static enum ndr_err_code
ndr_pull_srvsvc_NetFileCtr2(struct ndr_pull
*ndr
, int ndr_flags
, struct srvsvc_NetFileCtr2
*r
)
1756 uint32_t _ptr_array
;
1757 uint32_t cntr_array_1
;
1758 TALLOC_CTX
*_mem_save_array_0
;
1759 TALLOC_CTX
*_mem_save_array_1
;
1760 if (ndr_flags
& NDR_SCALARS
) {
1761 NDR_CHECK(ndr_pull_align(ndr
, 4));
1762 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->count
));
1763 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_array
));
1765 NDR_PULL_ALLOC(ndr
, r
->array
);
1770 if (ndr_flags
& NDR_BUFFERS
) {
1772 _mem_save_array_0
= NDR_PULL_GET_MEM_CTX(ndr
);
1773 NDR_PULL_SET_MEM_CTX(ndr
, r
->array
, 0);
1774 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->array
));
1775 NDR_PULL_ALLOC_N(ndr
, r
->array
, ndr_get_array_size(ndr
, &r
->array
));
1776 _mem_save_array_1
= NDR_PULL_GET_MEM_CTX(ndr
);
1777 NDR_PULL_SET_MEM_CTX(ndr
, r
->array
, 0);
1778 for (cntr_array_1
= 0; cntr_array_1
< r
->count
; cntr_array_1
++) {
1779 NDR_CHECK(ndr_pull_srvsvc_NetFileInfo2(ndr
, NDR_SCALARS
, &r
->array
[cntr_array_1
]));
1781 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_array_1
, 0);
1782 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_array_0
, 0);
1785 NDR_CHECK(ndr_check_array_size(ndr
, (void*)&r
->array
, r
->count
));
1788 return NDR_ERR_SUCCESS
;
1791 _PUBLIC_
void ndr_print_srvsvc_NetFileCtr2(struct ndr_print
*ndr
, const char *name
, const struct srvsvc_NetFileCtr2
*r
)
1793 uint32_t cntr_array_1
;
1794 ndr_print_struct(ndr
, name
, "srvsvc_NetFileCtr2");
1796 ndr_print_uint32(ndr
, "count", r
->count
);
1797 ndr_print_ptr(ndr
, "array", r
->array
);
1800 ndr
->print(ndr
, "%s: ARRAY(%d)", "array", (int)r
->count
);
1802 for (cntr_array_1
=0;cntr_array_1
<r
->count
;cntr_array_1
++) {
1804 if (asprintf(&idx_1
, "[%d]", cntr_array_1
) != -1) {
1805 ndr_print_srvsvc_NetFileInfo2(ndr
, "array", &r
->array
[cntr_array_1
]);
1815 static enum ndr_err_code
ndr_push_srvsvc_NetFileInfo3(struct ndr_push
*ndr
, int ndr_flags
, const struct srvsvc_NetFileInfo3
*r
)
1817 if (ndr_flags
& NDR_SCALARS
) {
1818 NDR_CHECK(ndr_push_align(ndr
, 4));
1819 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->fid
));
1820 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->permissions
));
1821 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->num_locks
));
1822 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->path
));
1823 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->user
));
1825 if (ndr_flags
& NDR_BUFFERS
) {
1827 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->path
, CH_UTF16
)));
1828 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
1829 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->path
, CH_UTF16
)));
1830 NDR_CHECK(ndr_push_charset(ndr
, NDR_SCALARS
, r
->path
, ndr_charset_length(r
->path
, CH_UTF16
), sizeof(uint16_t), CH_UTF16
));
1833 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->user
, CH_UTF16
)));
1834 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
1835 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->user
, CH_UTF16
)));
1836 NDR_CHECK(ndr_push_charset(ndr
, NDR_SCALARS
, r
->user
, ndr_charset_length(r
->user
, CH_UTF16
), sizeof(uint16_t), CH_UTF16
));
1839 return NDR_ERR_SUCCESS
;
1842 static enum ndr_err_code
ndr_pull_srvsvc_NetFileInfo3(struct ndr_pull
*ndr
, int ndr_flags
, struct srvsvc_NetFileInfo3
*r
)
1845 TALLOC_CTX
*_mem_save_path_0
;
1847 TALLOC_CTX
*_mem_save_user_0
;
1848 if (ndr_flags
& NDR_SCALARS
) {
1849 NDR_CHECK(ndr_pull_align(ndr
, 4));
1850 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->fid
));
1851 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->permissions
));
1852 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->num_locks
));
1853 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_path
));
1855 NDR_PULL_ALLOC(ndr
, r
->path
);
1859 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_user
));
1861 NDR_PULL_ALLOC(ndr
, r
->user
);
1866 if (ndr_flags
& NDR_BUFFERS
) {
1868 _mem_save_path_0
= NDR_PULL_GET_MEM_CTX(ndr
);
1869 NDR_PULL_SET_MEM_CTX(ndr
, r
->path
, 0);
1870 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->path
));
1871 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->path
));
1872 if (ndr_get_array_length(ndr
, &r
->path
) > ndr_get_array_size(ndr
, &r
->path
)) {
1873 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", ndr_get_array_size(ndr
, &r
->path
), ndr_get_array_length(ndr
, &r
->path
));
1875 NDR_CHECK(ndr_check_string_terminator(ndr
, ndr_get_array_length(ndr
, &r
->path
), sizeof(uint16_t)));
1876 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->path
, ndr_get_array_length(ndr
, &r
->path
), sizeof(uint16_t), CH_UTF16
));
1877 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_path_0
, 0);
1880 _mem_save_user_0
= NDR_PULL_GET_MEM_CTX(ndr
);
1881 NDR_PULL_SET_MEM_CTX(ndr
, r
->user
, 0);
1882 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->user
));
1883 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->user
));
1884 if (ndr_get_array_length(ndr
, &r
->user
) > ndr_get_array_size(ndr
, &r
->user
)) {
1885 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", ndr_get_array_size(ndr
, &r
->user
), ndr_get_array_length(ndr
, &r
->user
));
1887 NDR_CHECK(ndr_check_string_terminator(ndr
, ndr_get_array_length(ndr
, &r
->user
), sizeof(uint16_t)));
1888 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->user
, ndr_get_array_length(ndr
, &r
->user
), sizeof(uint16_t), CH_UTF16
));
1889 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_user_0
, 0);
1892 return NDR_ERR_SUCCESS
;
1895 _PUBLIC_
void ndr_print_srvsvc_NetFileInfo3(struct ndr_print
*ndr
, const char *name
, const struct srvsvc_NetFileInfo3
*r
)
1897 ndr_print_struct(ndr
, name
, "srvsvc_NetFileInfo3");
1899 ndr_print_uint32(ndr
, "fid", r
->fid
);
1900 ndr_print_uint32(ndr
, "permissions", r
->permissions
);
1901 ndr_print_uint32(ndr
, "num_locks", r
->num_locks
);
1902 ndr_print_ptr(ndr
, "path", r
->path
);
1905 ndr_print_string(ndr
, "path", r
->path
);
1908 ndr_print_ptr(ndr
, "user", r
->user
);
1911 ndr_print_string(ndr
, "user", r
->user
);
1917 static enum ndr_err_code
ndr_push_srvsvc_NetFileCtr3(struct ndr_push
*ndr
, int ndr_flags
, const struct srvsvc_NetFileCtr3
*r
)
1919 uint32_t cntr_array_1
;
1920 if (ndr_flags
& NDR_SCALARS
) {
1921 NDR_CHECK(ndr_push_align(ndr
, 4));
1922 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->count
));
1923 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->array
));
1925 if (ndr_flags
& NDR_BUFFERS
) {
1927 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->count
));
1928 for (cntr_array_1
= 0; cntr_array_1
< r
->count
; cntr_array_1
++) {
1929 NDR_CHECK(ndr_push_srvsvc_NetFileInfo3(ndr
, NDR_SCALARS
, &r
->array
[cntr_array_1
]));
1931 for (cntr_array_1
= 0; cntr_array_1
< r
->count
; cntr_array_1
++) {
1932 NDR_CHECK(ndr_push_srvsvc_NetFileInfo3(ndr
, NDR_BUFFERS
, &r
->array
[cntr_array_1
]));
1936 return NDR_ERR_SUCCESS
;
1939 static enum ndr_err_code
ndr_pull_srvsvc_NetFileCtr3(struct ndr_pull
*ndr
, int ndr_flags
, struct srvsvc_NetFileCtr3
*r
)
1941 uint32_t _ptr_array
;
1942 uint32_t cntr_array_1
;
1943 TALLOC_CTX
*_mem_save_array_0
;
1944 TALLOC_CTX
*_mem_save_array_1
;
1945 if (ndr_flags
& NDR_SCALARS
) {
1946 NDR_CHECK(ndr_pull_align(ndr
, 4));
1947 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->count
));
1948 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_array
));
1950 NDR_PULL_ALLOC(ndr
, r
->array
);
1955 if (ndr_flags
& NDR_BUFFERS
) {
1957 _mem_save_array_0
= NDR_PULL_GET_MEM_CTX(ndr
);
1958 NDR_PULL_SET_MEM_CTX(ndr
, r
->array
, 0);
1959 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->array
));
1960 NDR_PULL_ALLOC_N(ndr
, r
->array
, ndr_get_array_size(ndr
, &r
->array
));
1961 _mem_save_array_1
= NDR_PULL_GET_MEM_CTX(ndr
);
1962 NDR_PULL_SET_MEM_CTX(ndr
, r
->array
, 0);
1963 for (cntr_array_1
= 0; cntr_array_1
< r
->count
; cntr_array_1
++) {
1964 NDR_CHECK(ndr_pull_srvsvc_NetFileInfo3(ndr
, NDR_SCALARS
, &r
->array
[cntr_array_1
]));
1966 for (cntr_array_1
= 0; cntr_array_1
< r
->count
; cntr_array_1
++) {
1967 NDR_CHECK(ndr_pull_srvsvc_NetFileInfo3(ndr
, NDR_BUFFERS
, &r
->array
[cntr_array_1
]));
1969 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_array_1
, 0);
1970 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_array_0
, 0);
1973 NDR_CHECK(ndr_check_array_size(ndr
, (void*)&r
->array
, r
->count
));
1976 return NDR_ERR_SUCCESS
;
1979 _PUBLIC_
void ndr_print_srvsvc_NetFileCtr3(struct ndr_print
*ndr
, const char *name
, const struct srvsvc_NetFileCtr3
*r
)
1981 uint32_t cntr_array_1
;
1982 ndr_print_struct(ndr
, name
, "srvsvc_NetFileCtr3");
1984 ndr_print_uint32(ndr
, "count", r
->count
);
1985 ndr_print_ptr(ndr
, "array", r
->array
);
1988 ndr
->print(ndr
, "%s: ARRAY(%d)", "array", (int)r
->count
);
1990 for (cntr_array_1
=0;cntr_array_1
<r
->count
;cntr_array_1
++) {
1992 if (asprintf(&idx_1
, "[%d]", cntr_array_1
) != -1) {
1993 ndr_print_srvsvc_NetFileInfo3(ndr
, "array", &r
->array
[cntr_array_1
]);
2003 static enum ndr_err_code
ndr_push_srvsvc_NetFileInfo(struct ndr_push
*ndr
, int ndr_flags
, const union srvsvc_NetFileInfo
*r
)
2005 if (ndr_flags
& NDR_SCALARS
) {
2006 int level
= ndr_push_get_switch_value(ndr
, r
);
2007 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, level
));
2010 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->info2
));
2014 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->info3
));
2022 if (ndr_flags
& NDR_BUFFERS
) {
2023 int level
= ndr_push_get_switch_value(ndr
, r
);
2027 NDR_CHECK(ndr_push_srvsvc_NetFileInfo2(ndr
, NDR_SCALARS
, r
->info2
));
2033 NDR_CHECK(ndr_push_srvsvc_NetFileInfo3(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->info3
));
2042 return NDR_ERR_SUCCESS
;
2045 static enum ndr_err_code
ndr_pull_srvsvc_NetFileInfo(struct ndr_pull
*ndr
, int ndr_flags
, union srvsvc_NetFileInfo
*r
)
2049 TALLOC_CTX
*_mem_save_info2_0
;
2050 TALLOC_CTX
*_mem_save_info3_0
;
2051 level
= ndr_pull_get_switch_value(ndr
, r
);
2052 if (ndr_flags
& NDR_SCALARS
) {
2053 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &_level
));
2054 if (_level
!= level
) {
2055 return ndr_pull_error(ndr
, NDR_ERR_BAD_SWITCH
, "Bad switch value %u for r", _level
);
2059 uint32_t _ptr_info2
;
2060 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_info2
));
2062 NDR_PULL_ALLOC(ndr
, r
->info2
);
2069 uint32_t _ptr_info3
;
2070 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_info3
));
2072 NDR_PULL_ALLOC(ndr
, r
->info3
);
2083 if (ndr_flags
& NDR_BUFFERS
) {
2087 _mem_save_info2_0
= NDR_PULL_GET_MEM_CTX(ndr
);
2088 NDR_PULL_SET_MEM_CTX(ndr
, r
->info2
, 0);
2089 NDR_CHECK(ndr_pull_srvsvc_NetFileInfo2(ndr
, NDR_SCALARS
, r
->info2
));
2090 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_info2_0
, 0);
2096 _mem_save_info3_0
= NDR_PULL_GET_MEM_CTX(ndr
);
2097 NDR_PULL_SET_MEM_CTX(ndr
, r
->info3
, 0);
2098 NDR_CHECK(ndr_pull_srvsvc_NetFileInfo3(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->info3
));
2099 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_info3_0
, 0);
2108 return NDR_ERR_SUCCESS
;
2111 _PUBLIC_
void ndr_print_srvsvc_NetFileInfo(struct ndr_print
*ndr
, const char *name
, const union srvsvc_NetFileInfo
*r
)
2114 level
= ndr_print_get_switch_value(ndr
, r
);
2115 ndr_print_union(ndr
, name
, level
, "srvsvc_NetFileInfo");
2118 ndr_print_ptr(ndr
, "info2", r
->info2
);
2121 ndr_print_srvsvc_NetFileInfo2(ndr
, "info2", r
->info2
);
2127 ndr_print_ptr(ndr
, "info3", r
->info3
);
2130 ndr_print_srvsvc_NetFileInfo3(ndr
, "info3", r
->info3
);
2141 static enum ndr_err_code
ndr_push_srvsvc_NetFileCtr(struct ndr_push
*ndr
, int ndr_flags
, const union srvsvc_NetFileCtr
*r
)
2143 if (ndr_flags
& NDR_SCALARS
) {
2144 int level
= ndr_push_get_switch_value(ndr
, r
);
2145 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, level
));
2148 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->ctr2
));
2152 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->ctr3
));
2160 if (ndr_flags
& NDR_BUFFERS
) {
2161 int level
= ndr_push_get_switch_value(ndr
, r
);
2165 NDR_CHECK(ndr_push_srvsvc_NetFileCtr2(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->ctr2
));
2171 NDR_CHECK(ndr_push_srvsvc_NetFileCtr3(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->ctr3
));
2180 return NDR_ERR_SUCCESS
;
2183 static enum ndr_err_code
ndr_pull_srvsvc_NetFileCtr(struct ndr_pull
*ndr
, int ndr_flags
, union srvsvc_NetFileCtr
*r
)
2187 TALLOC_CTX
*_mem_save_ctr2_0
;
2188 TALLOC_CTX
*_mem_save_ctr3_0
;
2189 level
= ndr_pull_get_switch_value(ndr
, r
);
2190 if (ndr_flags
& NDR_SCALARS
) {
2191 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &_level
));
2192 if (_level
!= level
) {
2193 return ndr_pull_error(ndr
, NDR_ERR_BAD_SWITCH
, "Bad switch value %u for r", _level
);
2198 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_ctr2
));
2200 NDR_PULL_ALLOC(ndr
, r
->ctr2
);
2208 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_ctr3
));
2210 NDR_PULL_ALLOC(ndr
, r
->ctr3
);
2221 if (ndr_flags
& NDR_BUFFERS
) {
2225 _mem_save_ctr2_0
= NDR_PULL_GET_MEM_CTX(ndr
);
2226 NDR_PULL_SET_MEM_CTX(ndr
, r
->ctr2
, 0);
2227 NDR_CHECK(ndr_pull_srvsvc_NetFileCtr2(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->ctr2
));
2228 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_ctr2_0
, 0);
2234 _mem_save_ctr3_0
= NDR_PULL_GET_MEM_CTX(ndr
);
2235 NDR_PULL_SET_MEM_CTX(ndr
, r
->ctr3
, 0);
2236 NDR_CHECK(ndr_pull_srvsvc_NetFileCtr3(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->ctr3
));
2237 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_ctr3_0
, 0);
2246 return NDR_ERR_SUCCESS
;
2249 _PUBLIC_
void ndr_print_srvsvc_NetFileCtr(struct ndr_print
*ndr
, const char *name
, const union srvsvc_NetFileCtr
*r
)
2252 level
= ndr_print_get_switch_value(ndr
, r
);
2253 ndr_print_union(ndr
, name
, level
, "srvsvc_NetFileCtr");
2256 ndr_print_ptr(ndr
, "ctr2", r
->ctr2
);
2259 ndr_print_srvsvc_NetFileCtr2(ndr
, "ctr2", r
->ctr2
);
2265 ndr_print_ptr(ndr
, "ctr3", r
->ctr3
);
2268 ndr_print_srvsvc_NetFileCtr3(ndr
, "ctr3", r
->ctr3
);
2279 static enum ndr_err_code
ndr_push_srvsvc_NetFileInfoCtr(struct ndr_push
*ndr
, int ndr_flags
, const struct srvsvc_NetFileInfoCtr
*r
)
2281 if (ndr_flags
& NDR_SCALARS
) {
2282 NDR_CHECK(ndr_push_align(ndr
, 4));
2283 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->level
));
2284 NDR_CHECK(ndr_push_set_switch_value(ndr
, &r
->ctr
, r
->level
));
2285 NDR_CHECK(ndr_push_srvsvc_NetFileCtr(ndr
, NDR_SCALARS
, &r
->ctr
));
2287 if (ndr_flags
& NDR_BUFFERS
) {
2288 NDR_CHECK(ndr_push_srvsvc_NetFileCtr(ndr
, NDR_BUFFERS
, &r
->ctr
));
2290 return NDR_ERR_SUCCESS
;
2293 static enum ndr_err_code
ndr_pull_srvsvc_NetFileInfoCtr(struct ndr_pull
*ndr
, int ndr_flags
, struct srvsvc_NetFileInfoCtr
*r
)
2295 if (ndr_flags
& NDR_SCALARS
) {
2296 NDR_CHECK(ndr_pull_align(ndr
, 4));
2297 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->level
));
2298 NDR_CHECK(ndr_pull_set_switch_value(ndr
, &r
->ctr
, r
->level
));
2299 NDR_CHECK(ndr_pull_srvsvc_NetFileCtr(ndr
, NDR_SCALARS
, &r
->ctr
));
2301 if (ndr_flags
& NDR_BUFFERS
) {
2302 NDR_CHECK(ndr_pull_srvsvc_NetFileCtr(ndr
, NDR_BUFFERS
, &r
->ctr
));
2304 return NDR_ERR_SUCCESS
;
2307 _PUBLIC_
void ndr_print_srvsvc_NetFileInfoCtr(struct ndr_print
*ndr
, const char *name
, const struct srvsvc_NetFileInfoCtr
*r
)
2309 ndr_print_struct(ndr
, name
, "srvsvc_NetFileInfoCtr");
2311 ndr_print_uint32(ndr
, "level", r
->level
);
2312 ndr_print_set_switch_value(ndr
, &r
->ctr
, r
->level
);
2313 ndr_print_srvsvc_NetFileCtr(ndr
, "ctr", &r
->ctr
);
2317 static enum ndr_err_code
ndr_push_srvsvc_NetSessInfo0(struct ndr_push
*ndr
, int ndr_flags
, const struct srvsvc_NetSessInfo0
*r
)
2319 if (ndr_flags
& NDR_SCALARS
) {
2320 NDR_CHECK(ndr_push_align(ndr
, 4));
2321 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->client
));
2323 if (ndr_flags
& NDR_BUFFERS
) {
2325 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->client
, CH_UTF16
)));
2326 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
2327 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->client
, CH_UTF16
)));
2328 NDR_CHECK(ndr_push_charset(ndr
, NDR_SCALARS
, r
->client
, ndr_charset_length(r
->client
, CH_UTF16
), sizeof(uint16_t), CH_UTF16
));
2331 return NDR_ERR_SUCCESS
;
2334 static enum ndr_err_code
ndr_pull_srvsvc_NetSessInfo0(struct ndr_pull
*ndr
, int ndr_flags
, struct srvsvc_NetSessInfo0
*r
)
2336 uint32_t _ptr_client
;
2337 TALLOC_CTX
*_mem_save_client_0
;
2338 if (ndr_flags
& NDR_SCALARS
) {
2339 NDR_CHECK(ndr_pull_align(ndr
, 4));
2340 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_client
));
2342 NDR_PULL_ALLOC(ndr
, r
->client
);
2347 if (ndr_flags
& NDR_BUFFERS
) {
2349 _mem_save_client_0
= NDR_PULL_GET_MEM_CTX(ndr
);
2350 NDR_PULL_SET_MEM_CTX(ndr
, r
->client
, 0);
2351 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->client
));
2352 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->client
));
2353 if (ndr_get_array_length(ndr
, &r
->client
) > ndr_get_array_size(ndr
, &r
->client
)) {
2354 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", ndr_get_array_size(ndr
, &r
->client
), ndr_get_array_length(ndr
, &r
->client
));
2356 NDR_CHECK(ndr_check_string_terminator(ndr
, ndr_get_array_length(ndr
, &r
->client
), sizeof(uint16_t)));
2357 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->client
, ndr_get_array_length(ndr
, &r
->client
), sizeof(uint16_t), CH_UTF16
));
2358 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_client_0
, 0);
2361 return NDR_ERR_SUCCESS
;
2364 _PUBLIC_
void ndr_print_srvsvc_NetSessInfo0(struct ndr_print
*ndr
, const char *name
, const struct srvsvc_NetSessInfo0
*r
)
2366 ndr_print_struct(ndr
, name
, "srvsvc_NetSessInfo0");
2368 ndr_print_ptr(ndr
, "client", r
->client
);
2371 ndr_print_string(ndr
, "client", r
->client
);
2377 static enum ndr_err_code
ndr_push_srvsvc_NetSessCtr0(struct ndr_push
*ndr
, int ndr_flags
, const struct srvsvc_NetSessCtr0
*r
)
2379 uint32_t cntr_array_1
;
2380 if (ndr_flags
& NDR_SCALARS
) {
2381 NDR_CHECK(ndr_push_align(ndr
, 4));
2382 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->count
));
2383 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->array
));
2385 if (ndr_flags
& NDR_BUFFERS
) {
2387 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->count
));
2388 for (cntr_array_1
= 0; cntr_array_1
< r
->count
; cntr_array_1
++) {
2389 NDR_CHECK(ndr_push_srvsvc_NetSessInfo0(ndr
, NDR_SCALARS
, &r
->array
[cntr_array_1
]));
2391 for (cntr_array_1
= 0; cntr_array_1
< r
->count
; cntr_array_1
++) {
2392 NDR_CHECK(ndr_push_srvsvc_NetSessInfo0(ndr
, NDR_BUFFERS
, &r
->array
[cntr_array_1
]));
2396 return NDR_ERR_SUCCESS
;
2399 static enum ndr_err_code
ndr_pull_srvsvc_NetSessCtr0(struct ndr_pull
*ndr
, int ndr_flags
, struct srvsvc_NetSessCtr0
*r
)
2401 uint32_t _ptr_array
;
2402 uint32_t cntr_array_1
;
2403 TALLOC_CTX
*_mem_save_array_0
;
2404 TALLOC_CTX
*_mem_save_array_1
;
2405 if (ndr_flags
& NDR_SCALARS
) {
2406 NDR_CHECK(ndr_pull_align(ndr
, 4));
2407 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->count
));
2408 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_array
));
2410 NDR_PULL_ALLOC(ndr
, r
->array
);
2415 if (ndr_flags
& NDR_BUFFERS
) {
2417 _mem_save_array_0
= NDR_PULL_GET_MEM_CTX(ndr
);
2418 NDR_PULL_SET_MEM_CTX(ndr
, r
->array
, 0);
2419 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->array
));
2420 NDR_PULL_ALLOC_N(ndr
, r
->array
, ndr_get_array_size(ndr
, &r
->array
));
2421 _mem_save_array_1
= NDR_PULL_GET_MEM_CTX(ndr
);
2422 NDR_PULL_SET_MEM_CTX(ndr
, r
->array
, 0);
2423 for (cntr_array_1
= 0; cntr_array_1
< r
->count
; cntr_array_1
++) {
2424 NDR_CHECK(ndr_pull_srvsvc_NetSessInfo0(ndr
, NDR_SCALARS
, &r
->array
[cntr_array_1
]));
2426 for (cntr_array_1
= 0; cntr_array_1
< r
->count
; cntr_array_1
++) {
2427 NDR_CHECK(ndr_pull_srvsvc_NetSessInfo0(ndr
, NDR_BUFFERS
, &r
->array
[cntr_array_1
]));
2429 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_array_1
, 0);
2430 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_array_0
, 0);
2433 NDR_CHECK(ndr_check_array_size(ndr
, (void*)&r
->array
, r
->count
));
2436 return NDR_ERR_SUCCESS
;
2439 _PUBLIC_
void ndr_print_srvsvc_NetSessCtr0(struct ndr_print
*ndr
, const char *name
, const struct srvsvc_NetSessCtr0
*r
)
2441 uint32_t cntr_array_1
;
2442 ndr_print_struct(ndr
, name
, "srvsvc_NetSessCtr0");
2444 ndr_print_uint32(ndr
, "count", r
->count
);
2445 ndr_print_ptr(ndr
, "array", r
->array
);
2448 ndr
->print(ndr
, "%s: ARRAY(%d)", "array", (int)r
->count
);
2450 for (cntr_array_1
=0;cntr_array_1
<r
->count
;cntr_array_1
++) {
2452 if (asprintf(&idx_1
, "[%d]", cntr_array_1
) != -1) {
2453 ndr_print_srvsvc_NetSessInfo0(ndr
, "array", &r
->array
[cntr_array_1
]);
2463 static enum ndr_err_code
ndr_push_srvsvc_NetSessInfo1(struct ndr_push
*ndr
, int ndr_flags
, const struct srvsvc_NetSessInfo1
*r
)
2465 if (ndr_flags
& NDR_SCALARS
) {
2466 NDR_CHECK(ndr_push_align(ndr
, 4));
2467 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->client
));
2468 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->user
));
2469 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->num_open
));
2470 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->time
));
2471 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->idle_time
));
2472 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->user_flags
));
2474 if (ndr_flags
& NDR_BUFFERS
) {
2476 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->client
, CH_UTF16
)));
2477 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
2478 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->client
, CH_UTF16
)));
2479 NDR_CHECK(ndr_push_charset(ndr
, NDR_SCALARS
, r
->client
, ndr_charset_length(r
->client
, CH_UTF16
), sizeof(uint16_t), CH_UTF16
));
2482 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->user
, CH_UTF16
)));
2483 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
2484 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->user
, CH_UTF16
)));
2485 NDR_CHECK(ndr_push_charset(ndr
, NDR_SCALARS
, r
->user
, ndr_charset_length(r
->user
, CH_UTF16
), sizeof(uint16_t), CH_UTF16
));
2488 return NDR_ERR_SUCCESS
;
2491 static enum ndr_err_code
ndr_pull_srvsvc_NetSessInfo1(struct ndr_pull
*ndr
, int ndr_flags
, struct srvsvc_NetSessInfo1
*r
)
2493 uint32_t _ptr_client
;
2494 TALLOC_CTX
*_mem_save_client_0
;
2496 TALLOC_CTX
*_mem_save_user_0
;
2497 if (ndr_flags
& NDR_SCALARS
) {
2498 NDR_CHECK(ndr_pull_align(ndr
, 4));
2499 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_client
));
2501 NDR_PULL_ALLOC(ndr
, r
->client
);
2505 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_user
));
2507 NDR_PULL_ALLOC(ndr
, r
->user
);
2511 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->num_open
));
2512 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->time
));
2513 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->idle_time
));
2514 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->user_flags
));
2516 if (ndr_flags
& NDR_BUFFERS
) {
2518 _mem_save_client_0
= NDR_PULL_GET_MEM_CTX(ndr
);
2519 NDR_PULL_SET_MEM_CTX(ndr
, r
->client
, 0);
2520 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->client
));
2521 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->client
));
2522 if (ndr_get_array_length(ndr
, &r
->client
) > ndr_get_array_size(ndr
, &r
->client
)) {
2523 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", ndr_get_array_size(ndr
, &r
->client
), ndr_get_array_length(ndr
, &r
->client
));
2525 NDR_CHECK(ndr_check_string_terminator(ndr
, ndr_get_array_length(ndr
, &r
->client
), sizeof(uint16_t)));
2526 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->client
, ndr_get_array_length(ndr
, &r
->client
), sizeof(uint16_t), CH_UTF16
));
2527 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_client_0
, 0);
2530 _mem_save_user_0
= NDR_PULL_GET_MEM_CTX(ndr
);
2531 NDR_PULL_SET_MEM_CTX(ndr
, r
->user
, 0);
2532 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->user
));
2533 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->user
));
2534 if (ndr_get_array_length(ndr
, &r
->user
) > ndr_get_array_size(ndr
, &r
->user
)) {
2535 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", ndr_get_array_size(ndr
, &r
->user
), ndr_get_array_length(ndr
, &r
->user
));
2537 NDR_CHECK(ndr_check_string_terminator(ndr
, ndr_get_array_length(ndr
, &r
->user
), sizeof(uint16_t)));
2538 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->user
, ndr_get_array_length(ndr
, &r
->user
), sizeof(uint16_t), CH_UTF16
));
2539 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_user_0
, 0);
2542 return NDR_ERR_SUCCESS
;
2545 _PUBLIC_
void ndr_print_srvsvc_NetSessInfo1(struct ndr_print
*ndr
, const char *name
, const struct srvsvc_NetSessInfo1
*r
)
2547 ndr_print_struct(ndr
, name
, "srvsvc_NetSessInfo1");
2549 ndr_print_ptr(ndr
, "client", r
->client
);
2552 ndr_print_string(ndr
, "client", r
->client
);
2555 ndr_print_ptr(ndr
, "user", r
->user
);
2558 ndr_print_string(ndr
, "user", r
->user
);
2561 ndr_print_uint32(ndr
, "num_open", r
->num_open
);
2562 ndr_print_uint32(ndr
, "time", r
->time
);
2563 ndr_print_uint32(ndr
, "idle_time", r
->idle_time
);
2564 ndr_print_uint32(ndr
, "user_flags", r
->user_flags
);
2568 static enum ndr_err_code
ndr_push_srvsvc_NetSessCtr1(struct ndr_push
*ndr
, int ndr_flags
, const struct srvsvc_NetSessCtr1
*r
)
2570 uint32_t cntr_array_1
;
2571 if (ndr_flags
& NDR_SCALARS
) {
2572 NDR_CHECK(ndr_push_align(ndr
, 4));
2573 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->count
));
2574 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->array
));
2576 if (ndr_flags
& NDR_BUFFERS
) {
2578 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->count
));
2579 for (cntr_array_1
= 0; cntr_array_1
< r
->count
; cntr_array_1
++) {
2580 NDR_CHECK(ndr_push_srvsvc_NetSessInfo1(ndr
, NDR_SCALARS
, &r
->array
[cntr_array_1
]));
2582 for (cntr_array_1
= 0; cntr_array_1
< r
->count
; cntr_array_1
++) {
2583 NDR_CHECK(ndr_push_srvsvc_NetSessInfo1(ndr
, NDR_BUFFERS
, &r
->array
[cntr_array_1
]));
2587 return NDR_ERR_SUCCESS
;
2590 static enum ndr_err_code
ndr_pull_srvsvc_NetSessCtr1(struct ndr_pull
*ndr
, int ndr_flags
, struct srvsvc_NetSessCtr1
*r
)
2592 uint32_t _ptr_array
;
2593 uint32_t cntr_array_1
;
2594 TALLOC_CTX
*_mem_save_array_0
;
2595 TALLOC_CTX
*_mem_save_array_1
;
2596 if (ndr_flags
& NDR_SCALARS
) {
2597 NDR_CHECK(ndr_pull_align(ndr
, 4));
2598 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->count
));
2599 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_array
));
2601 NDR_PULL_ALLOC(ndr
, r
->array
);
2606 if (ndr_flags
& NDR_BUFFERS
) {
2608 _mem_save_array_0
= NDR_PULL_GET_MEM_CTX(ndr
);
2609 NDR_PULL_SET_MEM_CTX(ndr
, r
->array
, 0);
2610 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->array
));
2611 NDR_PULL_ALLOC_N(ndr
, r
->array
, ndr_get_array_size(ndr
, &r
->array
));
2612 _mem_save_array_1
= NDR_PULL_GET_MEM_CTX(ndr
);
2613 NDR_PULL_SET_MEM_CTX(ndr
, r
->array
, 0);
2614 for (cntr_array_1
= 0; cntr_array_1
< r
->count
; cntr_array_1
++) {
2615 NDR_CHECK(ndr_pull_srvsvc_NetSessInfo1(ndr
, NDR_SCALARS
, &r
->array
[cntr_array_1
]));
2617 for (cntr_array_1
= 0; cntr_array_1
< r
->count
; cntr_array_1
++) {
2618 NDR_CHECK(ndr_pull_srvsvc_NetSessInfo1(ndr
, NDR_BUFFERS
, &r
->array
[cntr_array_1
]));
2620 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_array_1
, 0);
2621 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_array_0
, 0);
2624 NDR_CHECK(ndr_check_array_size(ndr
, (void*)&r
->array
, r
->count
));
2627 return NDR_ERR_SUCCESS
;
2630 _PUBLIC_
void ndr_print_srvsvc_NetSessCtr1(struct ndr_print
*ndr
, const char *name
, const struct srvsvc_NetSessCtr1
*r
)
2632 uint32_t cntr_array_1
;
2633 ndr_print_struct(ndr
, name
, "srvsvc_NetSessCtr1");
2635 ndr_print_uint32(ndr
, "count", r
->count
);
2636 ndr_print_ptr(ndr
, "array", r
->array
);
2639 ndr
->print(ndr
, "%s: ARRAY(%d)", "array", (int)r
->count
);
2641 for (cntr_array_1
=0;cntr_array_1
<r
->count
;cntr_array_1
++) {
2643 if (asprintf(&idx_1
, "[%d]", cntr_array_1
) != -1) {
2644 ndr_print_srvsvc_NetSessInfo1(ndr
, "array", &r
->array
[cntr_array_1
]);
2654 static enum ndr_err_code
ndr_push_srvsvc_NetSessInfo2(struct ndr_push
*ndr
, int ndr_flags
, const struct srvsvc_NetSessInfo2
*r
)
2656 if (ndr_flags
& NDR_SCALARS
) {
2657 NDR_CHECK(ndr_push_align(ndr
, 4));
2658 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->client
));
2659 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->user
));
2660 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->num_open
));
2661 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->time
));
2662 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->idle_time
));
2663 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->user_flags
));
2664 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->client_type
));
2666 if (ndr_flags
& NDR_BUFFERS
) {
2668 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->client
, CH_UTF16
)));
2669 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
2670 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->client
, CH_UTF16
)));
2671 NDR_CHECK(ndr_push_charset(ndr
, NDR_SCALARS
, r
->client
, ndr_charset_length(r
->client
, CH_UTF16
), sizeof(uint16_t), CH_UTF16
));
2674 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->user
, CH_UTF16
)));
2675 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
2676 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->user
, CH_UTF16
)));
2677 NDR_CHECK(ndr_push_charset(ndr
, NDR_SCALARS
, r
->user
, ndr_charset_length(r
->user
, CH_UTF16
), sizeof(uint16_t), CH_UTF16
));
2679 if (r
->client_type
) {
2680 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->client_type
, CH_UTF16
)));
2681 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
2682 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->client_type
, CH_UTF16
)));
2683 NDR_CHECK(ndr_push_charset(ndr
, NDR_SCALARS
, r
->client_type
, ndr_charset_length(r
->client_type
, CH_UTF16
), sizeof(uint16_t), CH_UTF16
));
2686 return NDR_ERR_SUCCESS
;
2689 static enum ndr_err_code
ndr_pull_srvsvc_NetSessInfo2(struct ndr_pull
*ndr
, int ndr_flags
, struct srvsvc_NetSessInfo2
*r
)
2691 uint32_t _ptr_client
;
2692 TALLOC_CTX
*_mem_save_client_0
;
2694 TALLOC_CTX
*_mem_save_user_0
;
2695 uint32_t _ptr_client_type
;
2696 TALLOC_CTX
*_mem_save_client_type_0
;
2697 if (ndr_flags
& NDR_SCALARS
) {
2698 NDR_CHECK(ndr_pull_align(ndr
, 4));
2699 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_client
));
2701 NDR_PULL_ALLOC(ndr
, r
->client
);
2705 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_user
));
2707 NDR_PULL_ALLOC(ndr
, r
->user
);
2711 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->num_open
));
2712 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->time
));
2713 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->idle_time
));
2714 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->user_flags
));
2715 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_client_type
));
2716 if (_ptr_client_type
) {
2717 NDR_PULL_ALLOC(ndr
, r
->client_type
);
2719 r
->client_type
= NULL
;
2722 if (ndr_flags
& NDR_BUFFERS
) {
2724 _mem_save_client_0
= NDR_PULL_GET_MEM_CTX(ndr
);
2725 NDR_PULL_SET_MEM_CTX(ndr
, r
->client
, 0);
2726 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->client
));
2727 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->client
));
2728 if (ndr_get_array_length(ndr
, &r
->client
) > ndr_get_array_size(ndr
, &r
->client
)) {
2729 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", ndr_get_array_size(ndr
, &r
->client
), ndr_get_array_length(ndr
, &r
->client
));
2731 NDR_CHECK(ndr_check_string_terminator(ndr
, ndr_get_array_length(ndr
, &r
->client
), sizeof(uint16_t)));
2732 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->client
, ndr_get_array_length(ndr
, &r
->client
), sizeof(uint16_t), CH_UTF16
));
2733 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_client_0
, 0);
2736 _mem_save_user_0
= NDR_PULL_GET_MEM_CTX(ndr
);
2737 NDR_PULL_SET_MEM_CTX(ndr
, r
->user
, 0);
2738 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->user
));
2739 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->user
));
2740 if (ndr_get_array_length(ndr
, &r
->user
) > ndr_get_array_size(ndr
, &r
->user
)) {
2741 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", ndr_get_array_size(ndr
, &r
->user
), ndr_get_array_length(ndr
, &r
->user
));
2743 NDR_CHECK(ndr_check_string_terminator(ndr
, ndr_get_array_length(ndr
, &r
->user
), sizeof(uint16_t)));
2744 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->user
, ndr_get_array_length(ndr
, &r
->user
), sizeof(uint16_t), CH_UTF16
));
2745 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_user_0
, 0);
2747 if (r
->client_type
) {
2748 _mem_save_client_type_0
= NDR_PULL_GET_MEM_CTX(ndr
);
2749 NDR_PULL_SET_MEM_CTX(ndr
, r
->client_type
, 0);
2750 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->client_type
));
2751 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->client_type
));
2752 if (ndr_get_array_length(ndr
, &r
->client_type
) > ndr_get_array_size(ndr
, &r
->client_type
)) {
2753 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", ndr_get_array_size(ndr
, &r
->client_type
), ndr_get_array_length(ndr
, &r
->client_type
));
2755 NDR_CHECK(ndr_check_string_terminator(ndr
, ndr_get_array_length(ndr
, &r
->client_type
), sizeof(uint16_t)));
2756 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->client_type
, ndr_get_array_length(ndr
, &r
->client_type
), sizeof(uint16_t), CH_UTF16
));
2757 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_client_type_0
, 0);
2760 return NDR_ERR_SUCCESS
;
2763 _PUBLIC_
void ndr_print_srvsvc_NetSessInfo2(struct ndr_print
*ndr
, const char *name
, const struct srvsvc_NetSessInfo2
*r
)
2765 ndr_print_struct(ndr
, name
, "srvsvc_NetSessInfo2");
2767 ndr_print_ptr(ndr
, "client", r
->client
);
2770 ndr_print_string(ndr
, "client", r
->client
);
2773 ndr_print_ptr(ndr
, "user", r
->user
);
2776 ndr_print_string(ndr
, "user", r
->user
);
2779 ndr_print_uint32(ndr
, "num_open", r
->num_open
);
2780 ndr_print_uint32(ndr
, "time", r
->time
);
2781 ndr_print_uint32(ndr
, "idle_time", r
->idle_time
);
2782 ndr_print_uint32(ndr
, "user_flags", r
->user_flags
);
2783 ndr_print_ptr(ndr
, "client_type", r
->client_type
);
2785 if (r
->client_type
) {
2786 ndr_print_string(ndr
, "client_type", r
->client_type
);
2792 static enum ndr_err_code
ndr_push_srvsvc_NetSessCtr2(struct ndr_push
*ndr
, int ndr_flags
, const struct srvsvc_NetSessCtr2
*r
)
2794 uint32_t cntr_array_1
;
2795 if (ndr_flags
& NDR_SCALARS
) {
2796 NDR_CHECK(ndr_push_align(ndr
, 4));
2797 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->count
));
2798 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->array
));
2800 if (ndr_flags
& NDR_BUFFERS
) {
2802 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->count
));
2803 for (cntr_array_1
= 0; cntr_array_1
< r
->count
; cntr_array_1
++) {
2804 NDR_CHECK(ndr_push_srvsvc_NetSessInfo2(ndr
, NDR_SCALARS
, &r
->array
[cntr_array_1
]));
2806 for (cntr_array_1
= 0; cntr_array_1
< r
->count
; cntr_array_1
++) {
2807 NDR_CHECK(ndr_push_srvsvc_NetSessInfo2(ndr
, NDR_BUFFERS
, &r
->array
[cntr_array_1
]));
2811 return NDR_ERR_SUCCESS
;
2814 static enum ndr_err_code
ndr_pull_srvsvc_NetSessCtr2(struct ndr_pull
*ndr
, int ndr_flags
, struct srvsvc_NetSessCtr2
*r
)
2816 uint32_t _ptr_array
;
2817 uint32_t cntr_array_1
;
2818 TALLOC_CTX
*_mem_save_array_0
;
2819 TALLOC_CTX
*_mem_save_array_1
;
2820 if (ndr_flags
& NDR_SCALARS
) {
2821 NDR_CHECK(ndr_pull_align(ndr
, 4));
2822 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->count
));
2823 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_array
));
2825 NDR_PULL_ALLOC(ndr
, r
->array
);
2830 if (ndr_flags
& NDR_BUFFERS
) {
2832 _mem_save_array_0
= NDR_PULL_GET_MEM_CTX(ndr
);
2833 NDR_PULL_SET_MEM_CTX(ndr
, r
->array
, 0);
2834 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->array
));
2835 NDR_PULL_ALLOC_N(ndr
, r
->array
, ndr_get_array_size(ndr
, &r
->array
));
2836 _mem_save_array_1
= NDR_PULL_GET_MEM_CTX(ndr
);
2837 NDR_PULL_SET_MEM_CTX(ndr
, r
->array
, 0);
2838 for (cntr_array_1
= 0; cntr_array_1
< r
->count
; cntr_array_1
++) {
2839 NDR_CHECK(ndr_pull_srvsvc_NetSessInfo2(ndr
, NDR_SCALARS
, &r
->array
[cntr_array_1
]));
2841 for (cntr_array_1
= 0; cntr_array_1
< r
->count
; cntr_array_1
++) {
2842 NDR_CHECK(ndr_pull_srvsvc_NetSessInfo2(ndr
, NDR_BUFFERS
, &r
->array
[cntr_array_1
]));
2844 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_array_1
, 0);
2845 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_array_0
, 0);
2848 NDR_CHECK(ndr_check_array_size(ndr
, (void*)&r
->array
, r
->count
));
2851 return NDR_ERR_SUCCESS
;
2854 _PUBLIC_
void ndr_print_srvsvc_NetSessCtr2(struct ndr_print
*ndr
, const char *name
, const struct srvsvc_NetSessCtr2
*r
)
2856 uint32_t cntr_array_1
;
2857 ndr_print_struct(ndr
, name
, "srvsvc_NetSessCtr2");
2859 ndr_print_uint32(ndr
, "count", r
->count
);
2860 ndr_print_ptr(ndr
, "array", r
->array
);
2863 ndr
->print(ndr
, "%s: ARRAY(%d)", "array", (int)r
->count
);
2865 for (cntr_array_1
=0;cntr_array_1
<r
->count
;cntr_array_1
++) {
2867 if (asprintf(&idx_1
, "[%d]", cntr_array_1
) != -1) {
2868 ndr_print_srvsvc_NetSessInfo2(ndr
, "array", &r
->array
[cntr_array_1
]);
2878 static enum ndr_err_code
ndr_push_srvsvc_NetSessInfo10(struct ndr_push
*ndr
, int ndr_flags
, const struct srvsvc_NetSessInfo10
*r
)
2880 if (ndr_flags
& NDR_SCALARS
) {
2881 NDR_CHECK(ndr_push_align(ndr
, 4));
2882 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->client
));
2883 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->user
));
2884 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->time
));
2885 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->idle_time
));
2887 if (ndr_flags
& NDR_BUFFERS
) {
2889 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->client
, CH_UTF16
)));
2890 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
2891 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->client
, CH_UTF16
)));
2892 NDR_CHECK(ndr_push_charset(ndr
, NDR_SCALARS
, r
->client
, ndr_charset_length(r
->client
, CH_UTF16
), sizeof(uint16_t), CH_UTF16
));
2895 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->user
, CH_UTF16
)));
2896 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
2897 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->user
, CH_UTF16
)));
2898 NDR_CHECK(ndr_push_charset(ndr
, NDR_SCALARS
, r
->user
, ndr_charset_length(r
->user
, CH_UTF16
), sizeof(uint16_t), CH_UTF16
));
2901 return NDR_ERR_SUCCESS
;
2904 static enum ndr_err_code
ndr_pull_srvsvc_NetSessInfo10(struct ndr_pull
*ndr
, int ndr_flags
, struct srvsvc_NetSessInfo10
*r
)
2906 uint32_t _ptr_client
;
2907 TALLOC_CTX
*_mem_save_client_0
;
2909 TALLOC_CTX
*_mem_save_user_0
;
2910 if (ndr_flags
& NDR_SCALARS
) {
2911 NDR_CHECK(ndr_pull_align(ndr
, 4));
2912 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_client
));
2914 NDR_PULL_ALLOC(ndr
, r
->client
);
2918 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_user
));
2920 NDR_PULL_ALLOC(ndr
, r
->user
);
2924 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->time
));
2925 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->idle_time
));
2927 if (ndr_flags
& NDR_BUFFERS
) {
2929 _mem_save_client_0
= NDR_PULL_GET_MEM_CTX(ndr
);
2930 NDR_PULL_SET_MEM_CTX(ndr
, r
->client
, 0);
2931 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->client
));
2932 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->client
));
2933 if (ndr_get_array_length(ndr
, &r
->client
) > ndr_get_array_size(ndr
, &r
->client
)) {
2934 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", ndr_get_array_size(ndr
, &r
->client
), ndr_get_array_length(ndr
, &r
->client
));
2936 NDR_CHECK(ndr_check_string_terminator(ndr
, ndr_get_array_length(ndr
, &r
->client
), sizeof(uint16_t)));
2937 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->client
, ndr_get_array_length(ndr
, &r
->client
), sizeof(uint16_t), CH_UTF16
));
2938 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_client_0
, 0);
2941 _mem_save_user_0
= NDR_PULL_GET_MEM_CTX(ndr
);
2942 NDR_PULL_SET_MEM_CTX(ndr
, r
->user
, 0);
2943 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->user
));
2944 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->user
));
2945 if (ndr_get_array_length(ndr
, &r
->user
) > ndr_get_array_size(ndr
, &r
->user
)) {
2946 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", ndr_get_array_size(ndr
, &r
->user
), ndr_get_array_length(ndr
, &r
->user
));
2948 NDR_CHECK(ndr_check_string_terminator(ndr
, ndr_get_array_length(ndr
, &r
->user
), sizeof(uint16_t)));
2949 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->user
, ndr_get_array_length(ndr
, &r
->user
), sizeof(uint16_t), CH_UTF16
));
2950 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_user_0
, 0);
2953 return NDR_ERR_SUCCESS
;
2956 _PUBLIC_
void ndr_print_srvsvc_NetSessInfo10(struct ndr_print
*ndr
, const char *name
, const struct srvsvc_NetSessInfo10
*r
)
2958 ndr_print_struct(ndr
, name
, "srvsvc_NetSessInfo10");
2960 ndr_print_ptr(ndr
, "client", r
->client
);
2963 ndr_print_string(ndr
, "client", r
->client
);
2966 ndr_print_ptr(ndr
, "user", r
->user
);
2969 ndr_print_string(ndr
, "user", r
->user
);
2972 ndr_print_uint32(ndr
, "time", r
->time
);
2973 ndr_print_uint32(ndr
, "idle_time", r
->idle_time
);
2977 static enum ndr_err_code
ndr_push_srvsvc_NetSessCtr10(struct ndr_push
*ndr
, int ndr_flags
, const struct srvsvc_NetSessCtr10
*r
)
2979 uint32_t cntr_array_1
;
2980 if (ndr_flags
& NDR_SCALARS
) {
2981 NDR_CHECK(ndr_push_align(ndr
, 4));
2982 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->count
));
2983 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->array
));
2985 if (ndr_flags
& NDR_BUFFERS
) {
2987 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->count
));
2988 for (cntr_array_1
= 0; cntr_array_1
< r
->count
; cntr_array_1
++) {
2989 NDR_CHECK(ndr_push_srvsvc_NetSessInfo10(ndr
, NDR_SCALARS
, &r
->array
[cntr_array_1
]));
2991 for (cntr_array_1
= 0; cntr_array_1
< r
->count
; cntr_array_1
++) {
2992 NDR_CHECK(ndr_push_srvsvc_NetSessInfo10(ndr
, NDR_BUFFERS
, &r
->array
[cntr_array_1
]));
2996 return NDR_ERR_SUCCESS
;
2999 static enum ndr_err_code
ndr_pull_srvsvc_NetSessCtr10(struct ndr_pull
*ndr
, int ndr_flags
, struct srvsvc_NetSessCtr10
*r
)
3001 uint32_t _ptr_array
;
3002 uint32_t cntr_array_1
;
3003 TALLOC_CTX
*_mem_save_array_0
;
3004 TALLOC_CTX
*_mem_save_array_1
;
3005 if (ndr_flags
& NDR_SCALARS
) {
3006 NDR_CHECK(ndr_pull_align(ndr
, 4));
3007 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->count
));
3008 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_array
));
3010 NDR_PULL_ALLOC(ndr
, r
->array
);
3015 if (ndr_flags
& NDR_BUFFERS
) {
3017 _mem_save_array_0
= NDR_PULL_GET_MEM_CTX(ndr
);
3018 NDR_PULL_SET_MEM_CTX(ndr
, r
->array
, 0);
3019 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->array
));
3020 NDR_PULL_ALLOC_N(ndr
, r
->array
, ndr_get_array_size(ndr
, &r
->array
));
3021 _mem_save_array_1
= NDR_PULL_GET_MEM_CTX(ndr
);
3022 NDR_PULL_SET_MEM_CTX(ndr
, r
->array
, 0);
3023 for (cntr_array_1
= 0; cntr_array_1
< r
->count
; cntr_array_1
++) {
3024 NDR_CHECK(ndr_pull_srvsvc_NetSessInfo10(ndr
, NDR_SCALARS
, &r
->array
[cntr_array_1
]));
3026 for (cntr_array_1
= 0; cntr_array_1
< r
->count
; cntr_array_1
++) {
3027 NDR_CHECK(ndr_pull_srvsvc_NetSessInfo10(ndr
, NDR_BUFFERS
, &r
->array
[cntr_array_1
]));
3029 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_array_1
, 0);
3030 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_array_0
, 0);
3033 NDR_CHECK(ndr_check_array_size(ndr
, (void*)&r
->array
, r
->count
));
3036 return NDR_ERR_SUCCESS
;
3039 _PUBLIC_
void ndr_print_srvsvc_NetSessCtr10(struct ndr_print
*ndr
, const char *name
, const struct srvsvc_NetSessCtr10
*r
)
3041 uint32_t cntr_array_1
;
3042 ndr_print_struct(ndr
, name
, "srvsvc_NetSessCtr10");
3044 ndr_print_uint32(ndr
, "count", r
->count
);
3045 ndr_print_ptr(ndr
, "array", r
->array
);
3048 ndr
->print(ndr
, "%s: ARRAY(%d)", "array", (int)r
->count
);
3050 for (cntr_array_1
=0;cntr_array_1
<r
->count
;cntr_array_1
++) {
3052 if (asprintf(&idx_1
, "[%d]", cntr_array_1
) != -1) {
3053 ndr_print_srvsvc_NetSessInfo10(ndr
, "array", &r
->array
[cntr_array_1
]);
3063 static enum ndr_err_code
ndr_push_srvsvc_NetSessInfo502(struct ndr_push
*ndr
, int ndr_flags
, const struct srvsvc_NetSessInfo502
*r
)
3065 if (ndr_flags
& NDR_SCALARS
) {
3066 NDR_CHECK(ndr_push_align(ndr
, 4));
3067 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->client
));
3068 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->user
));
3069 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->num_open
));
3070 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->time
));
3071 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->idle_time
));
3072 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->user_flags
));
3073 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->client_type
));
3074 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->transport
));
3076 if (ndr_flags
& NDR_BUFFERS
) {
3078 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->client
, CH_UTF16
)));
3079 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
3080 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->client
, CH_UTF16
)));
3081 NDR_CHECK(ndr_push_charset(ndr
, NDR_SCALARS
, r
->client
, ndr_charset_length(r
->client
, CH_UTF16
), sizeof(uint16_t), CH_UTF16
));
3084 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->user
, CH_UTF16
)));
3085 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
3086 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->user
, CH_UTF16
)));
3087 NDR_CHECK(ndr_push_charset(ndr
, NDR_SCALARS
, r
->user
, ndr_charset_length(r
->user
, CH_UTF16
), sizeof(uint16_t), CH_UTF16
));
3089 if (r
->client_type
) {
3090 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->client_type
, CH_UTF16
)));
3091 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
3092 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->client_type
, CH_UTF16
)));
3093 NDR_CHECK(ndr_push_charset(ndr
, NDR_SCALARS
, r
->client_type
, ndr_charset_length(r
->client_type
, CH_UTF16
), sizeof(uint16_t), CH_UTF16
));
3096 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->transport
, CH_UTF16
)));
3097 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
3098 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->transport
, CH_UTF16
)));
3099 NDR_CHECK(ndr_push_charset(ndr
, NDR_SCALARS
, r
->transport
, ndr_charset_length(r
->transport
, CH_UTF16
), sizeof(uint16_t), CH_UTF16
));
3102 return NDR_ERR_SUCCESS
;
3105 static enum ndr_err_code
ndr_pull_srvsvc_NetSessInfo502(struct ndr_pull
*ndr
, int ndr_flags
, struct srvsvc_NetSessInfo502
*r
)
3107 uint32_t _ptr_client
;
3108 TALLOC_CTX
*_mem_save_client_0
;
3110 TALLOC_CTX
*_mem_save_user_0
;
3111 uint32_t _ptr_client_type
;
3112 TALLOC_CTX
*_mem_save_client_type_0
;
3113 uint32_t _ptr_transport
;
3114 TALLOC_CTX
*_mem_save_transport_0
;
3115 if (ndr_flags
& NDR_SCALARS
) {
3116 NDR_CHECK(ndr_pull_align(ndr
, 4));
3117 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_client
));
3119 NDR_PULL_ALLOC(ndr
, r
->client
);
3123 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_user
));
3125 NDR_PULL_ALLOC(ndr
, r
->user
);
3129 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->num_open
));
3130 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->time
));
3131 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->idle_time
));
3132 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->user_flags
));
3133 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_client_type
));
3134 if (_ptr_client_type
) {
3135 NDR_PULL_ALLOC(ndr
, r
->client_type
);
3137 r
->client_type
= NULL
;
3139 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_transport
));
3140 if (_ptr_transport
) {
3141 NDR_PULL_ALLOC(ndr
, r
->transport
);
3143 r
->transport
= NULL
;
3146 if (ndr_flags
& NDR_BUFFERS
) {
3148 _mem_save_client_0
= NDR_PULL_GET_MEM_CTX(ndr
);
3149 NDR_PULL_SET_MEM_CTX(ndr
, r
->client
, 0);
3150 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->client
));
3151 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->client
));
3152 if (ndr_get_array_length(ndr
, &r
->client
) > ndr_get_array_size(ndr
, &r
->client
)) {
3153 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", ndr_get_array_size(ndr
, &r
->client
), ndr_get_array_length(ndr
, &r
->client
));
3155 NDR_CHECK(ndr_check_string_terminator(ndr
, ndr_get_array_length(ndr
, &r
->client
), sizeof(uint16_t)));
3156 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->client
, ndr_get_array_length(ndr
, &r
->client
), sizeof(uint16_t), CH_UTF16
));
3157 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_client_0
, 0);
3160 _mem_save_user_0
= NDR_PULL_GET_MEM_CTX(ndr
);
3161 NDR_PULL_SET_MEM_CTX(ndr
, r
->user
, 0);
3162 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->user
));
3163 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->user
));
3164 if (ndr_get_array_length(ndr
, &r
->user
) > ndr_get_array_size(ndr
, &r
->user
)) {
3165 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", ndr_get_array_size(ndr
, &r
->user
), ndr_get_array_length(ndr
, &r
->user
));
3167 NDR_CHECK(ndr_check_string_terminator(ndr
, ndr_get_array_length(ndr
, &r
->user
), sizeof(uint16_t)));
3168 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->user
, ndr_get_array_length(ndr
, &r
->user
), sizeof(uint16_t), CH_UTF16
));
3169 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_user_0
, 0);
3171 if (r
->client_type
) {
3172 _mem_save_client_type_0
= NDR_PULL_GET_MEM_CTX(ndr
);
3173 NDR_PULL_SET_MEM_CTX(ndr
, r
->client_type
, 0);
3174 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->client_type
));
3175 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->client_type
));
3176 if (ndr_get_array_length(ndr
, &r
->client_type
) > ndr_get_array_size(ndr
, &r
->client_type
)) {
3177 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", ndr_get_array_size(ndr
, &r
->client_type
), ndr_get_array_length(ndr
, &r
->client_type
));
3179 NDR_CHECK(ndr_check_string_terminator(ndr
, ndr_get_array_length(ndr
, &r
->client_type
), sizeof(uint16_t)));
3180 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->client_type
, ndr_get_array_length(ndr
, &r
->client_type
), sizeof(uint16_t), CH_UTF16
));
3181 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_client_type_0
, 0);
3184 _mem_save_transport_0
= NDR_PULL_GET_MEM_CTX(ndr
);
3185 NDR_PULL_SET_MEM_CTX(ndr
, r
->transport
, 0);
3186 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->transport
));
3187 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->transport
));
3188 if (ndr_get_array_length(ndr
, &r
->transport
) > ndr_get_array_size(ndr
, &r
->transport
)) {
3189 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", ndr_get_array_size(ndr
, &r
->transport
), ndr_get_array_length(ndr
, &r
->transport
));
3191 NDR_CHECK(ndr_check_string_terminator(ndr
, ndr_get_array_length(ndr
, &r
->transport
), sizeof(uint16_t)));
3192 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->transport
, ndr_get_array_length(ndr
, &r
->transport
), sizeof(uint16_t), CH_UTF16
));
3193 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_transport_0
, 0);
3196 return NDR_ERR_SUCCESS
;
3199 _PUBLIC_
void ndr_print_srvsvc_NetSessInfo502(struct ndr_print
*ndr
, const char *name
, const struct srvsvc_NetSessInfo502
*r
)
3201 ndr_print_struct(ndr
, name
, "srvsvc_NetSessInfo502");
3203 ndr_print_ptr(ndr
, "client", r
->client
);
3206 ndr_print_string(ndr
, "client", r
->client
);
3209 ndr_print_ptr(ndr
, "user", r
->user
);
3212 ndr_print_string(ndr
, "user", r
->user
);
3215 ndr_print_uint32(ndr
, "num_open", r
->num_open
);
3216 ndr_print_uint32(ndr
, "time", r
->time
);
3217 ndr_print_uint32(ndr
, "idle_time", r
->idle_time
);
3218 ndr_print_uint32(ndr
, "user_flags", r
->user_flags
);
3219 ndr_print_ptr(ndr
, "client_type", r
->client_type
);
3221 if (r
->client_type
) {
3222 ndr_print_string(ndr
, "client_type", r
->client_type
);
3225 ndr_print_ptr(ndr
, "transport", r
->transport
);
3228 ndr_print_string(ndr
, "transport", r
->transport
);
3234 static enum ndr_err_code
ndr_push_srvsvc_NetSessCtr502(struct ndr_push
*ndr
, int ndr_flags
, const struct srvsvc_NetSessCtr502
*r
)
3236 uint32_t cntr_array_1
;
3237 if (ndr_flags
& NDR_SCALARS
) {
3238 NDR_CHECK(ndr_push_align(ndr
, 4));
3239 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->count
));
3240 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->array
));
3242 if (ndr_flags
& NDR_BUFFERS
) {
3244 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->count
));
3245 for (cntr_array_1
= 0; cntr_array_1
< r
->count
; cntr_array_1
++) {
3246 NDR_CHECK(ndr_push_srvsvc_NetSessInfo502(ndr
, NDR_SCALARS
, &r
->array
[cntr_array_1
]));
3248 for (cntr_array_1
= 0; cntr_array_1
< r
->count
; cntr_array_1
++) {
3249 NDR_CHECK(ndr_push_srvsvc_NetSessInfo502(ndr
, NDR_BUFFERS
, &r
->array
[cntr_array_1
]));
3253 return NDR_ERR_SUCCESS
;
3256 static enum ndr_err_code
ndr_pull_srvsvc_NetSessCtr502(struct ndr_pull
*ndr
, int ndr_flags
, struct srvsvc_NetSessCtr502
*r
)
3258 uint32_t _ptr_array
;
3259 uint32_t cntr_array_1
;
3260 TALLOC_CTX
*_mem_save_array_0
;
3261 TALLOC_CTX
*_mem_save_array_1
;
3262 if (ndr_flags
& NDR_SCALARS
) {
3263 NDR_CHECK(ndr_pull_align(ndr
, 4));
3264 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->count
));
3265 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_array
));
3267 NDR_PULL_ALLOC(ndr
, r
->array
);
3272 if (ndr_flags
& NDR_BUFFERS
) {
3274 _mem_save_array_0
= NDR_PULL_GET_MEM_CTX(ndr
);
3275 NDR_PULL_SET_MEM_CTX(ndr
, r
->array
, 0);
3276 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->array
));
3277 NDR_PULL_ALLOC_N(ndr
, r
->array
, ndr_get_array_size(ndr
, &r
->array
));
3278 _mem_save_array_1
= NDR_PULL_GET_MEM_CTX(ndr
);
3279 NDR_PULL_SET_MEM_CTX(ndr
, r
->array
, 0);
3280 for (cntr_array_1
= 0; cntr_array_1
< r
->count
; cntr_array_1
++) {
3281 NDR_CHECK(ndr_pull_srvsvc_NetSessInfo502(ndr
, NDR_SCALARS
, &r
->array
[cntr_array_1
]));
3283 for (cntr_array_1
= 0; cntr_array_1
< r
->count
; cntr_array_1
++) {
3284 NDR_CHECK(ndr_pull_srvsvc_NetSessInfo502(ndr
, NDR_BUFFERS
, &r
->array
[cntr_array_1
]));
3286 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_array_1
, 0);
3287 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_array_0
, 0);
3290 NDR_CHECK(ndr_check_array_size(ndr
, (void*)&r
->array
, r
->count
));
3293 return NDR_ERR_SUCCESS
;
3296 _PUBLIC_
void ndr_print_srvsvc_NetSessCtr502(struct ndr_print
*ndr
, const char *name
, const struct srvsvc_NetSessCtr502
*r
)
3298 uint32_t cntr_array_1
;
3299 ndr_print_struct(ndr
, name
, "srvsvc_NetSessCtr502");
3301 ndr_print_uint32(ndr
, "count", r
->count
);
3302 ndr_print_ptr(ndr
, "array", r
->array
);
3305 ndr
->print(ndr
, "%s: ARRAY(%d)", "array", (int)r
->count
);
3307 for (cntr_array_1
=0;cntr_array_1
<r
->count
;cntr_array_1
++) {
3309 if (asprintf(&idx_1
, "[%d]", cntr_array_1
) != -1) {
3310 ndr_print_srvsvc_NetSessInfo502(ndr
, "array", &r
->array
[cntr_array_1
]);
3320 static enum ndr_err_code
ndr_push_srvsvc_NetSessCtr(struct ndr_push
*ndr
, int ndr_flags
, const union srvsvc_NetSessCtr
*r
)
3322 if (ndr_flags
& NDR_SCALARS
) {
3323 int level
= ndr_push_get_switch_value(ndr
, r
);
3324 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, level
));
3327 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->ctr0
));
3331 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->ctr1
));
3335 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->ctr2
));
3339 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->ctr10
));
3343 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->ctr502
));
3351 if (ndr_flags
& NDR_BUFFERS
) {
3352 int level
= ndr_push_get_switch_value(ndr
, r
);
3356 NDR_CHECK(ndr_push_srvsvc_NetSessCtr0(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->ctr0
));
3362 NDR_CHECK(ndr_push_srvsvc_NetSessCtr1(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->ctr1
));
3368 NDR_CHECK(ndr_push_srvsvc_NetSessCtr2(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->ctr2
));
3374 NDR_CHECK(ndr_push_srvsvc_NetSessCtr10(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->ctr10
));
3380 NDR_CHECK(ndr_push_srvsvc_NetSessCtr502(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->ctr502
));
3389 return NDR_ERR_SUCCESS
;
3392 static enum ndr_err_code
ndr_pull_srvsvc_NetSessCtr(struct ndr_pull
*ndr
, int ndr_flags
, union srvsvc_NetSessCtr
*r
)
3396 TALLOC_CTX
*_mem_save_ctr0_0
;
3397 TALLOC_CTX
*_mem_save_ctr1_0
;
3398 TALLOC_CTX
*_mem_save_ctr2_0
;
3399 TALLOC_CTX
*_mem_save_ctr10_0
;
3400 TALLOC_CTX
*_mem_save_ctr502_0
;
3401 level
= ndr_pull_get_switch_value(ndr
, r
);
3402 if (ndr_flags
& NDR_SCALARS
) {
3403 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &_level
));
3404 if (_level
!= level
) {
3405 return ndr_pull_error(ndr
, NDR_ERR_BAD_SWITCH
, "Bad switch value %u for r", _level
);
3410 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_ctr0
));
3412 NDR_PULL_ALLOC(ndr
, r
->ctr0
);
3420 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_ctr1
));
3422 NDR_PULL_ALLOC(ndr
, r
->ctr1
);
3430 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_ctr2
));
3432 NDR_PULL_ALLOC(ndr
, r
->ctr2
);
3439 uint32_t _ptr_ctr10
;
3440 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_ctr10
));
3442 NDR_PULL_ALLOC(ndr
, r
->ctr10
);
3449 uint32_t _ptr_ctr502
;
3450 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_ctr502
));
3452 NDR_PULL_ALLOC(ndr
, r
->ctr502
);
3463 if (ndr_flags
& NDR_BUFFERS
) {
3467 _mem_save_ctr0_0
= NDR_PULL_GET_MEM_CTX(ndr
);
3468 NDR_PULL_SET_MEM_CTX(ndr
, r
->ctr0
, 0);
3469 NDR_CHECK(ndr_pull_srvsvc_NetSessCtr0(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->ctr0
));
3470 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_ctr0_0
, 0);
3476 _mem_save_ctr1_0
= NDR_PULL_GET_MEM_CTX(ndr
);
3477 NDR_PULL_SET_MEM_CTX(ndr
, r
->ctr1
, 0);
3478 NDR_CHECK(ndr_pull_srvsvc_NetSessCtr1(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->ctr1
));
3479 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_ctr1_0
, 0);
3485 _mem_save_ctr2_0
= NDR_PULL_GET_MEM_CTX(ndr
);
3486 NDR_PULL_SET_MEM_CTX(ndr
, r
->ctr2
, 0);
3487 NDR_CHECK(ndr_pull_srvsvc_NetSessCtr2(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->ctr2
));
3488 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_ctr2_0
, 0);
3494 _mem_save_ctr10_0
= NDR_PULL_GET_MEM_CTX(ndr
);
3495 NDR_PULL_SET_MEM_CTX(ndr
, r
->ctr10
, 0);
3496 NDR_CHECK(ndr_pull_srvsvc_NetSessCtr10(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->ctr10
));
3497 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_ctr10_0
, 0);
3503 _mem_save_ctr502_0
= NDR_PULL_GET_MEM_CTX(ndr
);
3504 NDR_PULL_SET_MEM_CTX(ndr
, r
->ctr502
, 0);
3505 NDR_CHECK(ndr_pull_srvsvc_NetSessCtr502(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->ctr502
));
3506 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_ctr502_0
, 0);
3515 return NDR_ERR_SUCCESS
;
3518 _PUBLIC_
void ndr_print_srvsvc_NetSessCtr(struct ndr_print
*ndr
, const char *name
, const union srvsvc_NetSessCtr
*r
)
3521 level
= ndr_print_get_switch_value(ndr
, r
);
3522 ndr_print_union(ndr
, name
, level
, "srvsvc_NetSessCtr");
3525 ndr_print_ptr(ndr
, "ctr0", r
->ctr0
);
3528 ndr_print_srvsvc_NetSessCtr0(ndr
, "ctr0", r
->ctr0
);
3534 ndr_print_ptr(ndr
, "ctr1", r
->ctr1
);
3537 ndr_print_srvsvc_NetSessCtr1(ndr
, "ctr1", r
->ctr1
);
3543 ndr_print_ptr(ndr
, "ctr2", r
->ctr2
);
3546 ndr_print_srvsvc_NetSessCtr2(ndr
, "ctr2", r
->ctr2
);
3552 ndr_print_ptr(ndr
, "ctr10", r
->ctr10
);
3555 ndr_print_srvsvc_NetSessCtr10(ndr
, "ctr10", r
->ctr10
);
3561 ndr_print_ptr(ndr
, "ctr502", r
->ctr502
);
3564 ndr_print_srvsvc_NetSessCtr502(ndr
, "ctr502", r
->ctr502
);
3575 static enum ndr_err_code
ndr_push_srvsvc_NetSessInfoCtr(struct ndr_push
*ndr
, int ndr_flags
, const struct srvsvc_NetSessInfoCtr
*r
)
3577 if (ndr_flags
& NDR_SCALARS
) {
3578 NDR_CHECK(ndr_push_align(ndr
, 4));
3579 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->level
));
3580 NDR_CHECK(ndr_push_set_switch_value(ndr
, &r
->ctr
, r
->level
));
3581 NDR_CHECK(ndr_push_srvsvc_NetSessCtr(ndr
, NDR_SCALARS
, &r
->ctr
));
3583 if (ndr_flags
& NDR_BUFFERS
) {
3584 NDR_CHECK(ndr_push_srvsvc_NetSessCtr(ndr
, NDR_BUFFERS
, &r
->ctr
));
3586 return NDR_ERR_SUCCESS
;
3589 static enum ndr_err_code
ndr_pull_srvsvc_NetSessInfoCtr(struct ndr_pull
*ndr
, int ndr_flags
, struct srvsvc_NetSessInfoCtr
*r
)
3591 if (ndr_flags
& NDR_SCALARS
) {
3592 NDR_CHECK(ndr_pull_align(ndr
, 4));
3593 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->level
));
3594 NDR_CHECK(ndr_pull_set_switch_value(ndr
, &r
->ctr
, r
->level
));
3595 NDR_CHECK(ndr_pull_srvsvc_NetSessCtr(ndr
, NDR_SCALARS
, &r
->ctr
));
3597 if (ndr_flags
& NDR_BUFFERS
) {
3598 NDR_CHECK(ndr_pull_srvsvc_NetSessCtr(ndr
, NDR_BUFFERS
, &r
->ctr
));
3600 return NDR_ERR_SUCCESS
;
3603 _PUBLIC_
void ndr_print_srvsvc_NetSessInfoCtr(struct ndr_print
*ndr
, const char *name
, const struct srvsvc_NetSessInfoCtr
*r
)
3605 ndr_print_struct(ndr
, name
, "srvsvc_NetSessInfoCtr");
3607 ndr_print_uint32(ndr
, "level", r
->level
);
3608 ndr_print_set_switch_value(ndr
, &r
->ctr
, r
->level
);
3609 ndr_print_srvsvc_NetSessCtr(ndr
, "ctr", &r
->ctr
);
3613 static enum ndr_err_code
ndr_push_srvsvc_ShareType(struct ndr_push
*ndr
, int ndr_flags
, enum srvsvc_ShareType r
)
3616 uint32_t _flags_save_ENUM
= ndr
->flags
;
3617 ndr_set_flags(&ndr
->flags
, LIBNDR_PRINT_ARRAY_HEX
);
3618 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
));
3619 ndr
->flags
= _flags_save_ENUM
;
3621 return NDR_ERR_SUCCESS
;
3624 static enum ndr_err_code
ndr_pull_srvsvc_ShareType(struct ndr_pull
*ndr
, int ndr_flags
, enum srvsvc_ShareType
*r
)
3628 uint32_t _flags_save_ENUM
= ndr
->flags
;
3629 ndr_set_flags(&ndr
->flags
, LIBNDR_PRINT_ARRAY_HEX
);
3630 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &v
));
3632 ndr
->flags
= _flags_save_ENUM
;
3634 return NDR_ERR_SUCCESS
;
3637 _PUBLIC_
void ndr_print_srvsvc_ShareType(struct ndr_print
*ndr
, const char *name
, enum srvsvc_ShareType r
)
3639 const char *val
= NULL
;
3642 uint32_t _flags_save_ENUM
= ndr
->flags
;
3643 ndr_set_flags(&ndr
->flags
, LIBNDR_PRINT_ARRAY_HEX
);
3645 case STYPE_DISKTREE
: val
= "STYPE_DISKTREE"; break;
3646 case STYPE_DISKTREE_TEMPORARY
: val
= "STYPE_DISKTREE_TEMPORARY"; break;
3647 case STYPE_DISKTREE_HIDDEN
: val
= "STYPE_DISKTREE_HIDDEN"; break;
3648 case STYPE_PRINTQ
: val
= "STYPE_PRINTQ"; break;
3649 case STYPE_PRINTQ_TEMPORARY
: val
= "STYPE_PRINTQ_TEMPORARY"; break;
3650 case STYPE_PRINTQ_HIDDEN
: val
= "STYPE_PRINTQ_HIDDEN"; break;
3651 case STYPE_DEVICE
: val
= "STYPE_DEVICE"; break;
3652 case STYPE_DEVICE_TEMPORARY
: val
= "STYPE_DEVICE_TEMPORARY"; break;
3653 case STYPE_DEVICE_HIDDEN
: val
= "STYPE_DEVICE_HIDDEN"; break;
3654 case STYPE_IPC
: val
= "STYPE_IPC"; break;
3655 case STYPE_IPC_TEMPORARY
: val
= "STYPE_IPC_TEMPORARY"; break;
3656 case STYPE_IPC_HIDDEN
: val
= "STYPE_IPC_HIDDEN"; break;
3658 ndr_print_enum(ndr
, name
, "ENUM", val
, r
);
3659 ndr
->flags
= _flags_save_ENUM
;
3663 static enum ndr_err_code
ndr_push_srvsvc_NetShareInfo0(struct ndr_push
*ndr
, int ndr_flags
, const struct srvsvc_NetShareInfo0
*r
)
3665 if (ndr_flags
& NDR_SCALARS
) {
3666 NDR_CHECK(ndr_push_align(ndr
, 4));
3667 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->name
));
3669 if (ndr_flags
& NDR_BUFFERS
) {
3671 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->name
, CH_UTF16
)));
3672 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
3673 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->name
, CH_UTF16
)));
3674 NDR_CHECK(ndr_push_charset(ndr
, NDR_SCALARS
, r
->name
, ndr_charset_length(r
->name
, CH_UTF16
), sizeof(uint16_t), CH_UTF16
));
3677 return NDR_ERR_SUCCESS
;
3680 static enum ndr_err_code
ndr_pull_srvsvc_NetShareInfo0(struct ndr_pull
*ndr
, int ndr_flags
, struct srvsvc_NetShareInfo0
*r
)
3683 TALLOC_CTX
*_mem_save_name_0
;
3684 if (ndr_flags
& NDR_SCALARS
) {
3685 NDR_CHECK(ndr_pull_align(ndr
, 4));
3686 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_name
));
3688 NDR_PULL_ALLOC(ndr
, r
->name
);
3693 if (ndr_flags
& NDR_BUFFERS
) {
3695 _mem_save_name_0
= NDR_PULL_GET_MEM_CTX(ndr
);
3696 NDR_PULL_SET_MEM_CTX(ndr
, r
->name
, 0);
3697 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->name
));
3698 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->name
));
3699 if (ndr_get_array_length(ndr
, &r
->name
) > ndr_get_array_size(ndr
, &r
->name
)) {
3700 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", ndr_get_array_size(ndr
, &r
->name
), ndr_get_array_length(ndr
, &r
->name
));
3702 NDR_CHECK(ndr_check_string_terminator(ndr
, ndr_get_array_length(ndr
, &r
->name
), sizeof(uint16_t)));
3703 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->name
, ndr_get_array_length(ndr
, &r
->name
), sizeof(uint16_t), CH_UTF16
));
3704 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_name_0
, 0);
3707 return NDR_ERR_SUCCESS
;
3710 _PUBLIC_
void ndr_print_srvsvc_NetShareInfo0(struct ndr_print
*ndr
, const char *name
, const struct srvsvc_NetShareInfo0
*r
)
3712 ndr_print_struct(ndr
, name
, "srvsvc_NetShareInfo0");
3714 ndr_print_ptr(ndr
, "name", r
->name
);
3717 ndr_print_string(ndr
, "name", r
->name
);
3723 static enum ndr_err_code
ndr_push_srvsvc_NetShareCtr0(struct ndr_push
*ndr
, int ndr_flags
, const struct srvsvc_NetShareCtr0
*r
)
3725 uint32_t cntr_array_1
;
3726 if (ndr_flags
& NDR_SCALARS
) {
3727 NDR_CHECK(ndr_push_align(ndr
, 4));
3728 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->count
));
3729 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->array
));
3731 if (ndr_flags
& NDR_BUFFERS
) {
3733 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->count
));
3734 for (cntr_array_1
= 0; cntr_array_1
< r
->count
; cntr_array_1
++) {
3735 NDR_CHECK(ndr_push_srvsvc_NetShareInfo0(ndr
, NDR_SCALARS
, &r
->array
[cntr_array_1
]));
3737 for (cntr_array_1
= 0; cntr_array_1
< r
->count
; cntr_array_1
++) {
3738 NDR_CHECK(ndr_push_srvsvc_NetShareInfo0(ndr
, NDR_BUFFERS
, &r
->array
[cntr_array_1
]));
3742 return NDR_ERR_SUCCESS
;
3745 static enum ndr_err_code
ndr_pull_srvsvc_NetShareCtr0(struct ndr_pull
*ndr
, int ndr_flags
, struct srvsvc_NetShareCtr0
*r
)
3747 uint32_t _ptr_array
;
3748 uint32_t cntr_array_1
;
3749 TALLOC_CTX
*_mem_save_array_0
;
3750 TALLOC_CTX
*_mem_save_array_1
;
3751 if (ndr_flags
& NDR_SCALARS
) {
3752 NDR_CHECK(ndr_pull_align(ndr
, 4));
3753 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->count
));
3754 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_array
));
3756 NDR_PULL_ALLOC(ndr
, r
->array
);
3761 if (ndr_flags
& NDR_BUFFERS
) {
3763 _mem_save_array_0
= NDR_PULL_GET_MEM_CTX(ndr
);
3764 NDR_PULL_SET_MEM_CTX(ndr
, r
->array
, 0);
3765 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->array
));
3766 NDR_PULL_ALLOC_N(ndr
, r
->array
, ndr_get_array_size(ndr
, &r
->array
));
3767 _mem_save_array_1
= NDR_PULL_GET_MEM_CTX(ndr
);
3768 NDR_PULL_SET_MEM_CTX(ndr
, r
->array
, 0);
3769 for (cntr_array_1
= 0; cntr_array_1
< r
->count
; cntr_array_1
++) {
3770 NDR_CHECK(ndr_pull_srvsvc_NetShareInfo0(ndr
, NDR_SCALARS
, &r
->array
[cntr_array_1
]));
3772 for (cntr_array_1
= 0; cntr_array_1
< r
->count
; cntr_array_1
++) {
3773 NDR_CHECK(ndr_pull_srvsvc_NetShareInfo0(ndr
, NDR_BUFFERS
, &r
->array
[cntr_array_1
]));
3775 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_array_1
, 0);
3776 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_array_0
, 0);
3779 NDR_CHECK(ndr_check_array_size(ndr
, (void*)&r
->array
, r
->count
));
3782 return NDR_ERR_SUCCESS
;
3785 _PUBLIC_
void ndr_print_srvsvc_NetShareCtr0(struct ndr_print
*ndr
, const char *name
, const struct srvsvc_NetShareCtr0
*r
)
3787 uint32_t cntr_array_1
;
3788 ndr_print_struct(ndr
, name
, "srvsvc_NetShareCtr0");
3790 ndr_print_uint32(ndr
, "count", r
->count
);
3791 ndr_print_ptr(ndr
, "array", r
->array
);
3794 ndr
->print(ndr
, "%s: ARRAY(%d)", "array", (int)r
->count
);
3796 for (cntr_array_1
=0;cntr_array_1
<r
->count
;cntr_array_1
++) {
3798 if (asprintf(&idx_1
, "[%d]", cntr_array_1
) != -1) {
3799 ndr_print_srvsvc_NetShareInfo0(ndr
, "array", &r
->array
[cntr_array_1
]);
3809 static enum ndr_err_code
ndr_push_srvsvc_NetShareInfo1(struct ndr_push
*ndr
, int ndr_flags
, const struct srvsvc_NetShareInfo1
*r
)
3811 if (ndr_flags
& NDR_SCALARS
) {
3812 NDR_CHECK(ndr_push_align(ndr
, 4));
3813 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->name
));
3814 NDR_CHECK(ndr_push_srvsvc_ShareType(ndr
, NDR_SCALARS
, r
->type
));
3815 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->comment
));
3817 if (ndr_flags
& NDR_BUFFERS
) {
3819 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->name
, CH_UTF16
)));
3820 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
3821 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->name
, CH_UTF16
)));
3822 NDR_CHECK(ndr_push_charset(ndr
, NDR_SCALARS
, r
->name
, ndr_charset_length(r
->name
, CH_UTF16
), sizeof(uint16_t), CH_UTF16
));
3825 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->comment
, CH_UTF16
)));
3826 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
3827 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->comment
, CH_UTF16
)));
3828 NDR_CHECK(ndr_push_charset(ndr
, NDR_SCALARS
, r
->comment
, ndr_charset_length(r
->comment
, CH_UTF16
), sizeof(uint16_t), CH_UTF16
));
3831 return NDR_ERR_SUCCESS
;
3834 static enum ndr_err_code
ndr_pull_srvsvc_NetShareInfo1(struct ndr_pull
*ndr
, int ndr_flags
, struct srvsvc_NetShareInfo1
*r
)
3837 TALLOC_CTX
*_mem_save_name_0
;
3838 uint32_t _ptr_comment
;
3839 TALLOC_CTX
*_mem_save_comment_0
;
3840 if (ndr_flags
& NDR_SCALARS
) {
3841 NDR_CHECK(ndr_pull_align(ndr
, 4));
3842 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_name
));
3844 NDR_PULL_ALLOC(ndr
, r
->name
);
3848 NDR_CHECK(ndr_pull_srvsvc_ShareType(ndr
, NDR_SCALARS
, &r
->type
));
3849 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_comment
));
3851 NDR_PULL_ALLOC(ndr
, r
->comment
);
3856 if (ndr_flags
& NDR_BUFFERS
) {
3858 _mem_save_name_0
= NDR_PULL_GET_MEM_CTX(ndr
);
3859 NDR_PULL_SET_MEM_CTX(ndr
, r
->name
, 0);
3860 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->name
));
3861 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->name
));
3862 if (ndr_get_array_length(ndr
, &r
->name
) > ndr_get_array_size(ndr
, &r
->name
)) {
3863 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", ndr_get_array_size(ndr
, &r
->name
), ndr_get_array_length(ndr
, &r
->name
));
3865 NDR_CHECK(ndr_check_string_terminator(ndr
, ndr_get_array_length(ndr
, &r
->name
), sizeof(uint16_t)));
3866 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->name
, ndr_get_array_length(ndr
, &r
->name
), sizeof(uint16_t), CH_UTF16
));
3867 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_name_0
, 0);
3870 _mem_save_comment_0
= NDR_PULL_GET_MEM_CTX(ndr
);
3871 NDR_PULL_SET_MEM_CTX(ndr
, r
->comment
, 0);
3872 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->comment
));
3873 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->comment
));
3874 if (ndr_get_array_length(ndr
, &r
->comment
) > ndr_get_array_size(ndr
, &r
->comment
)) {
3875 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", ndr_get_array_size(ndr
, &r
->comment
), ndr_get_array_length(ndr
, &r
->comment
));
3877 NDR_CHECK(ndr_check_string_terminator(ndr
, ndr_get_array_length(ndr
, &r
->comment
), sizeof(uint16_t)));
3878 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->comment
, ndr_get_array_length(ndr
, &r
->comment
), sizeof(uint16_t), CH_UTF16
));
3879 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_comment_0
, 0);
3882 return NDR_ERR_SUCCESS
;
3885 _PUBLIC_
void ndr_print_srvsvc_NetShareInfo1(struct ndr_print
*ndr
, const char *name
, const struct srvsvc_NetShareInfo1
*r
)
3887 ndr_print_struct(ndr
, name
, "srvsvc_NetShareInfo1");
3889 ndr_print_ptr(ndr
, "name", r
->name
);
3892 ndr_print_string(ndr
, "name", r
->name
);
3895 ndr_print_srvsvc_ShareType(ndr
, "type", r
->type
);
3896 ndr_print_ptr(ndr
, "comment", r
->comment
);
3899 ndr_print_string(ndr
, "comment", r
->comment
);
3905 static enum ndr_err_code
ndr_push_srvsvc_NetShareCtr1(struct ndr_push
*ndr
, int ndr_flags
, const struct srvsvc_NetShareCtr1
*r
)
3907 uint32_t cntr_array_1
;
3908 if (ndr_flags
& NDR_SCALARS
) {
3909 NDR_CHECK(ndr_push_align(ndr
, 4));
3910 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->count
));
3911 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->array
));
3913 if (ndr_flags
& NDR_BUFFERS
) {
3915 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->count
));
3916 for (cntr_array_1
= 0; cntr_array_1
< r
->count
; cntr_array_1
++) {
3917 NDR_CHECK(ndr_push_srvsvc_NetShareInfo1(ndr
, NDR_SCALARS
, &r
->array
[cntr_array_1
]));
3919 for (cntr_array_1
= 0; cntr_array_1
< r
->count
; cntr_array_1
++) {
3920 NDR_CHECK(ndr_push_srvsvc_NetShareInfo1(ndr
, NDR_BUFFERS
, &r
->array
[cntr_array_1
]));
3924 return NDR_ERR_SUCCESS
;
3927 static enum ndr_err_code
ndr_pull_srvsvc_NetShareCtr1(struct ndr_pull
*ndr
, int ndr_flags
, struct srvsvc_NetShareCtr1
*r
)
3929 uint32_t _ptr_array
;
3930 uint32_t cntr_array_1
;
3931 TALLOC_CTX
*_mem_save_array_0
;
3932 TALLOC_CTX
*_mem_save_array_1
;
3933 if (ndr_flags
& NDR_SCALARS
) {
3934 NDR_CHECK(ndr_pull_align(ndr
, 4));
3935 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->count
));
3936 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_array
));
3938 NDR_PULL_ALLOC(ndr
, r
->array
);
3943 if (ndr_flags
& NDR_BUFFERS
) {
3945 _mem_save_array_0
= NDR_PULL_GET_MEM_CTX(ndr
);
3946 NDR_PULL_SET_MEM_CTX(ndr
, r
->array
, 0);
3947 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->array
));
3948 NDR_PULL_ALLOC_N(ndr
, r
->array
, ndr_get_array_size(ndr
, &r
->array
));
3949 _mem_save_array_1
= NDR_PULL_GET_MEM_CTX(ndr
);
3950 NDR_PULL_SET_MEM_CTX(ndr
, r
->array
, 0);
3951 for (cntr_array_1
= 0; cntr_array_1
< r
->count
; cntr_array_1
++) {
3952 NDR_CHECK(ndr_pull_srvsvc_NetShareInfo1(ndr
, NDR_SCALARS
, &r
->array
[cntr_array_1
]));
3954 for (cntr_array_1
= 0; cntr_array_1
< r
->count
; cntr_array_1
++) {
3955 NDR_CHECK(ndr_pull_srvsvc_NetShareInfo1(ndr
, NDR_BUFFERS
, &r
->array
[cntr_array_1
]));
3957 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_array_1
, 0);
3958 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_array_0
, 0);
3961 NDR_CHECK(ndr_check_array_size(ndr
, (void*)&r
->array
, r
->count
));
3964 return NDR_ERR_SUCCESS
;
3967 _PUBLIC_
void ndr_print_srvsvc_NetShareCtr1(struct ndr_print
*ndr
, const char *name
, const struct srvsvc_NetShareCtr1
*r
)
3969 uint32_t cntr_array_1
;
3970 ndr_print_struct(ndr
, name
, "srvsvc_NetShareCtr1");
3972 ndr_print_uint32(ndr
, "count", r
->count
);
3973 ndr_print_ptr(ndr
, "array", r
->array
);
3976 ndr
->print(ndr
, "%s: ARRAY(%d)", "array", (int)r
->count
);
3978 for (cntr_array_1
=0;cntr_array_1
<r
->count
;cntr_array_1
++) {
3980 if (asprintf(&idx_1
, "[%d]", cntr_array_1
) != -1) {
3981 ndr_print_srvsvc_NetShareInfo1(ndr
, "array", &r
->array
[cntr_array_1
]);
3991 static enum ndr_err_code
ndr_push_srvsvc_NetShareInfo2(struct ndr_push
*ndr
, int ndr_flags
, const struct srvsvc_NetShareInfo2
*r
)
3993 if (ndr_flags
& NDR_SCALARS
) {
3994 NDR_CHECK(ndr_push_align(ndr
, 4));
3995 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->name
));
3996 NDR_CHECK(ndr_push_srvsvc_ShareType(ndr
, NDR_SCALARS
, r
->type
));
3997 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->comment
));
3998 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->permissions
));
3999 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->max_users
));
4000 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->current_users
));
4001 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->path
));
4002 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->password
));
4004 if (ndr_flags
& NDR_BUFFERS
) {
4006 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->name
, CH_UTF16
)));
4007 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
4008 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->name
, CH_UTF16
)));
4009 NDR_CHECK(ndr_push_charset(ndr
, NDR_SCALARS
, r
->name
, ndr_charset_length(r
->name
, CH_UTF16
), sizeof(uint16_t), CH_UTF16
));
4012 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->comment
, CH_UTF16
)));
4013 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
4014 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->comment
, CH_UTF16
)));
4015 NDR_CHECK(ndr_push_charset(ndr
, NDR_SCALARS
, r
->comment
, ndr_charset_length(r
->comment
, CH_UTF16
), sizeof(uint16_t), CH_UTF16
));
4018 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->path
, CH_UTF16
)));
4019 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
4020 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->path
, CH_UTF16
)));
4021 NDR_CHECK(ndr_push_charset(ndr
, NDR_SCALARS
, r
->path
, ndr_charset_length(r
->path
, CH_UTF16
), sizeof(uint16_t), CH_UTF16
));
4024 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->password
, CH_UTF16
)));
4025 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
4026 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->password
, CH_UTF16
)));
4027 NDR_CHECK(ndr_push_charset(ndr
, NDR_SCALARS
, r
->password
, ndr_charset_length(r
->password
, CH_UTF16
), sizeof(uint16_t), CH_UTF16
));
4030 return NDR_ERR_SUCCESS
;
4033 static enum ndr_err_code
ndr_pull_srvsvc_NetShareInfo2(struct ndr_pull
*ndr
, int ndr_flags
, struct srvsvc_NetShareInfo2
*r
)
4036 TALLOC_CTX
*_mem_save_name_0
;
4037 uint32_t _ptr_comment
;
4038 TALLOC_CTX
*_mem_save_comment_0
;
4040 TALLOC_CTX
*_mem_save_path_0
;
4041 uint32_t _ptr_password
;
4042 TALLOC_CTX
*_mem_save_password_0
;
4043 if (ndr_flags
& NDR_SCALARS
) {
4044 NDR_CHECK(ndr_pull_align(ndr
, 4));
4045 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_name
));
4047 NDR_PULL_ALLOC(ndr
, r
->name
);
4051 NDR_CHECK(ndr_pull_srvsvc_ShareType(ndr
, NDR_SCALARS
, &r
->type
));
4052 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_comment
));
4054 NDR_PULL_ALLOC(ndr
, r
->comment
);
4058 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->permissions
));
4059 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->max_users
));
4060 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->current_users
));
4061 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_path
));
4063 NDR_PULL_ALLOC(ndr
, r
->path
);
4067 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_password
));
4068 if (_ptr_password
) {
4069 NDR_PULL_ALLOC(ndr
, r
->password
);
4074 if (ndr_flags
& NDR_BUFFERS
) {
4076 _mem_save_name_0
= NDR_PULL_GET_MEM_CTX(ndr
);
4077 NDR_PULL_SET_MEM_CTX(ndr
, r
->name
, 0);
4078 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->name
));
4079 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->name
));
4080 if (ndr_get_array_length(ndr
, &r
->name
) > ndr_get_array_size(ndr
, &r
->name
)) {
4081 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", ndr_get_array_size(ndr
, &r
->name
), ndr_get_array_length(ndr
, &r
->name
));
4083 NDR_CHECK(ndr_check_string_terminator(ndr
, ndr_get_array_length(ndr
, &r
->name
), sizeof(uint16_t)));
4084 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->name
, ndr_get_array_length(ndr
, &r
->name
), sizeof(uint16_t), CH_UTF16
));
4085 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_name_0
, 0);
4088 _mem_save_comment_0
= NDR_PULL_GET_MEM_CTX(ndr
);
4089 NDR_PULL_SET_MEM_CTX(ndr
, r
->comment
, 0);
4090 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->comment
));
4091 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->comment
));
4092 if (ndr_get_array_length(ndr
, &r
->comment
) > ndr_get_array_size(ndr
, &r
->comment
)) {
4093 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", ndr_get_array_size(ndr
, &r
->comment
), ndr_get_array_length(ndr
, &r
->comment
));
4095 NDR_CHECK(ndr_check_string_terminator(ndr
, ndr_get_array_length(ndr
, &r
->comment
), sizeof(uint16_t)));
4096 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->comment
, ndr_get_array_length(ndr
, &r
->comment
), sizeof(uint16_t), CH_UTF16
));
4097 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_comment_0
, 0);
4100 _mem_save_path_0
= NDR_PULL_GET_MEM_CTX(ndr
);
4101 NDR_PULL_SET_MEM_CTX(ndr
, r
->path
, 0);
4102 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->path
));
4103 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->path
));
4104 if (ndr_get_array_length(ndr
, &r
->path
) > ndr_get_array_size(ndr
, &r
->path
)) {
4105 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", ndr_get_array_size(ndr
, &r
->path
), ndr_get_array_length(ndr
, &r
->path
));
4107 NDR_CHECK(ndr_check_string_terminator(ndr
, ndr_get_array_length(ndr
, &r
->path
), sizeof(uint16_t)));
4108 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->path
, ndr_get_array_length(ndr
, &r
->path
), sizeof(uint16_t), CH_UTF16
));
4109 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_path_0
, 0);
4112 _mem_save_password_0
= NDR_PULL_GET_MEM_CTX(ndr
);
4113 NDR_PULL_SET_MEM_CTX(ndr
, r
->password
, 0);
4114 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->password
));
4115 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->password
));
4116 if (ndr_get_array_length(ndr
, &r
->password
) > ndr_get_array_size(ndr
, &r
->password
)) {
4117 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", ndr_get_array_size(ndr
, &r
->password
), ndr_get_array_length(ndr
, &r
->password
));
4119 NDR_CHECK(ndr_check_string_terminator(ndr
, ndr_get_array_length(ndr
, &r
->password
), sizeof(uint16_t)));
4120 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->password
, ndr_get_array_length(ndr
, &r
->password
), sizeof(uint16_t), CH_UTF16
));
4121 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_password_0
, 0);
4124 return NDR_ERR_SUCCESS
;
4127 _PUBLIC_
void ndr_print_srvsvc_NetShareInfo2(struct ndr_print
*ndr
, const char *name
, const struct srvsvc_NetShareInfo2
*r
)
4129 ndr_print_struct(ndr
, name
, "srvsvc_NetShareInfo2");
4131 ndr_print_ptr(ndr
, "name", r
->name
);
4134 ndr_print_string(ndr
, "name", r
->name
);
4137 ndr_print_srvsvc_ShareType(ndr
, "type", r
->type
);
4138 ndr_print_ptr(ndr
, "comment", r
->comment
);
4141 ndr_print_string(ndr
, "comment", r
->comment
);
4144 ndr_print_uint32(ndr
, "permissions", r
->permissions
);
4145 ndr_print_uint32(ndr
, "max_users", r
->max_users
);
4146 ndr_print_uint32(ndr
, "current_users", r
->current_users
);
4147 ndr_print_ptr(ndr
, "path", r
->path
);
4150 ndr_print_string(ndr
, "path", r
->path
);
4153 ndr_print_ptr(ndr
, "password", r
->password
);
4156 ndr_print_string(ndr
, "password", r
->password
);
4162 static enum ndr_err_code
ndr_push_srvsvc_NetShareCtr2(struct ndr_push
*ndr
, int ndr_flags
, const struct srvsvc_NetShareCtr2
*r
)
4164 uint32_t cntr_array_1
;
4165 if (ndr_flags
& NDR_SCALARS
) {
4166 NDR_CHECK(ndr_push_align(ndr
, 4));
4167 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->count
));
4168 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->array
));
4170 if (ndr_flags
& NDR_BUFFERS
) {
4172 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->count
));
4173 for (cntr_array_1
= 0; cntr_array_1
< r
->count
; cntr_array_1
++) {
4174 NDR_CHECK(ndr_push_srvsvc_NetShareInfo2(ndr
, NDR_SCALARS
, &r
->array
[cntr_array_1
]));
4176 for (cntr_array_1
= 0; cntr_array_1
< r
->count
; cntr_array_1
++) {
4177 NDR_CHECK(ndr_push_srvsvc_NetShareInfo2(ndr
, NDR_BUFFERS
, &r
->array
[cntr_array_1
]));
4181 return NDR_ERR_SUCCESS
;
4184 static enum ndr_err_code
ndr_pull_srvsvc_NetShareCtr2(struct ndr_pull
*ndr
, int ndr_flags
, struct srvsvc_NetShareCtr2
*r
)
4186 uint32_t _ptr_array
;
4187 uint32_t cntr_array_1
;
4188 TALLOC_CTX
*_mem_save_array_0
;
4189 TALLOC_CTX
*_mem_save_array_1
;
4190 if (ndr_flags
& NDR_SCALARS
) {
4191 NDR_CHECK(ndr_pull_align(ndr
, 4));
4192 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->count
));
4193 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_array
));
4195 NDR_PULL_ALLOC(ndr
, r
->array
);
4200 if (ndr_flags
& NDR_BUFFERS
) {
4202 _mem_save_array_0
= NDR_PULL_GET_MEM_CTX(ndr
);
4203 NDR_PULL_SET_MEM_CTX(ndr
, r
->array
, 0);
4204 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->array
));
4205 NDR_PULL_ALLOC_N(ndr
, r
->array
, ndr_get_array_size(ndr
, &r
->array
));
4206 _mem_save_array_1
= NDR_PULL_GET_MEM_CTX(ndr
);
4207 NDR_PULL_SET_MEM_CTX(ndr
, r
->array
, 0);
4208 for (cntr_array_1
= 0; cntr_array_1
< r
->count
; cntr_array_1
++) {
4209 NDR_CHECK(ndr_pull_srvsvc_NetShareInfo2(ndr
, NDR_SCALARS
, &r
->array
[cntr_array_1
]));
4211 for (cntr_array_1
= 0; cntr_array_1
< r
->count
; cntr_array_1
++) {
4212 NDR_CHECK(ndr_pull_srvsvc_NetShareInfo2(ndr
, NDR_BUFFERS
, &r
->array
[cntr_array_1
]));
4214 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_array_1
, 0);
4215 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_array_0
, 0);
4218 NDR_CHECK(ndr_check_array_size(ndr
, (void*)&r
->array
, r
->count
));
4221 return NDR_ERR_SUCCESS
;
4224 _PUBLIC_
void ndr_print_srvsvc_NetShareCtr2(struct ndr_print
*ndr
, const char *name
, const struct srvsvc_NetShareCtr2
*r
)
4226 uint32_t cntr_array_1
;
4227 ndr_print_struct(ndr
, name
, "srvsvc_NetShareCtr2");
4229 ndr_print_uint32(ndr
, "count", r
->count
);
4230 ndr_print_ptr(ndr
, "array", r
->array
);
4233 ndr
->print(ndr
, "%s: ARRAY(%d)", "array", (int)r
->count
);
4235 for (cntr_array_1
=0;cntr_array_1
<r
->count
;cntr_array_1
++) {
4237 if (asprintf(&idx_1
, "[%d]", cntr_array_1
) != -1) {
4238 ndr_print_srvsvc_NetShareInfo2(ndr
, "array", &r
->array
[cntr_array_1
]);
4248 static enum ndr_err_code
ndr_push_srvsvc_NetShareInfo501(struct ndr_push
*ndr
, int ndr_flags
, const struct srvsvc_NetShareInfo501
*r
)
4250 if (ndr_flags
& NDR_SCALARS
) {
4251 NDR_CHECK(ndr_push_align(ndr
, 4));
4252 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->name
));
4253 NDR_CHECK(ndr_push_srvsvc_ShareType(ndr
, NDR_SCALARS
, r
->type
));
4254 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->comment
));
4255 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->csc_policy
));
4257 if (ndr_flags
& NDR_BUFFERS
) {
4259 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->name
, CH_UTF16
)));
4260 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
4261 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->name
, CH_UTF16
)));
4262 NDR_CHECK(ndr_push_charset(ndr
, NDR_SCALARS
, r
->name
, ndr_charset_length(r
->name
, CH_UTF16
), sizeof(uint16_t), CH_UTF16
));
4265 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->comment
, CH_UTF16
)));
4266 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
4267 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->comment
, CH_UTF16
)));
4268 NDR_CHECK(ndr_push_charset(ndr
, NDR_SCALARS
, r
->comment
, ndr_charset_length(r
->comment
, CH_UTF16
), sizeof(uint16_t), CH_UTF16
));
4271 return NDR_ERR_SUCCESS
;
4274 static enum ndr_err_code
ndr_pull_srvsvc_NetShareInfo501(struct ndr_pull
*ndr
, int ndr_flags
, struct srvsvc_NetShareInfo501
*r
)
4277 TALLOC_CTX
*_mem_save_name_0
;
4278 uint32_t _ptr_comment
;
4279 TALLOC_CTX
*_mem_save_comment_0
;
4280 if (ndr_flags
& NDR_SCALARS
) {
4281 NDR_CHECK(ndr_pull_align(ndr
, 4));
4282 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_name
));
4284 NDR_PULL_ALLOC(ndr
, r
->name
);
4288 NDR_CHECK(ndr_pull_srvsvc_ShareType(ndr
, NDR_SCALARS
, &r
->type
));
4289 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_comment
));
4291 NDR_PULL_ALLOC(ndr
, r
->comment
);
4295 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->csc_policy
));
4297 if (ndr_flags
& NDR_BUFFERS
) {
4299 _mem_save_name_0
= NDR_PULL_GET_MEM_CTX(ndr
);
4300 NDR_PULL_SET_MEM_CTX(ndr
, r
->name
, 0);
4301 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->name
));
4302 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->name
));
4303 if (ndr_get_array_length(ndr
, &r
->name
) > ndr_get_array_size(ndr
, &r
->name
)) {
4304 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", ndr_get_array_size(ndr
, &r
->name
), ndr_get_array_length(ndr
, &r
->name
));
4306 NDR_CHECK(ndr_check_string_terminator(ndr
, ndr_get_array_length(ndr
, &r
->name
), sizeof(uint16_t)));
4307 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->name
, ndr_get_array_length(ndr
, &r
->name
), sizeof(uint16_t), CH_UTF16
));
4308 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_name_0
, 0);
4311 _mem_save_comment_0
= NDR_PULL_GET_MEM_CTX(ndr
);
4312 NDR_PULL_SET_MEM_CTX(ndr
, r
->comment
, 0);
4313 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->comment
));
4314 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->comment
));
4315 if (ndr_get_array_length(ndr
, &r
->comment
) > ndr_get_array_size(ndr
, &r
->comment
)) {
4316 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", ndr_get_array_size(ndr
, &r
->comment
), ndr_get_array_length(ndr
, &r
->comment
));
4318 NDR_CHECK(ndr_check_string_terminator(ndr
, ndr_get_array_length(ndr
, &r
->comment
), sizeof(uint16_t)));
4319 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->comment
, ndr_get_array_length(ndr
, &r
->comment
), sizeof(uint16_t), CH_UTF16
));
4320 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_comment_0
, 0);
4323 return NDR_ERR_SUCCESS
;
4326 _PUBLIC_
void ndr_print_srvsvc_NetShareInfo501(struct ndr_print
*ndr
, const char *name
, const struct srvsvc_NetShareInfo501
*r
)
4328 ndr_print_struct(ndr
, name
, "srvsvc_NetShareInfo501");
4330 ndr_print_ptr(ndr
, "name", r
->name
);
4333 ndr_print_string(ndr
, "name", r
->name
);
4336 ndr_print_srvsvc_ShareType(ndr
, "type", r
->type
);
4337 ndr_print_ptr(ndr
, "comment", r
->comment
);
4340 ndr_print_string(ndr
, "comment", r
->comment
);
4343 ndr_print_uint32(ndr
, "csc_policy", r
->csc_policy
);
4347 static enum ndr_err_code
ndr_push_srvsvc_NetShareCtr501(struct ndr_push
*ndr
, int ndr_flags
, const struct srvsvc_NetShareCtr501
*r
)
4349 uint32_t cntr_array_1
;
4350 if (ndr_flags
& NDR_SCALARS
) {
4351 NDR_CHECK(ndr_push_align(ndr
, 4));
4352 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->count
));
4353 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->array
));
4355 if (ndr_flags
& NDR_BUFFERS
) {
4357 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->count
));
4358 for (cntr_array_1
= 0; cntr_array_1
< r
->count
; cntr_array_1
++) {
4359 NDR_CHECK(ndr_push_srvsvc_NetShareInfo501(ndr
, NDR_SCALARS
, &r
->array
[cntr_array_1
]));
4361 for (cntr_array_1
= 0; cntr_array_1
< r
->count
; cntr_array_1
++) {
4362 NDR_CHECK(ndr_push_srvsvc_NetShareInfo501(ndr
, NDR_BUFFERS
, &r
->array
[cntr_array_1
]));
4366 return NDR_ERR_SUCCESS
;
4369 static enum ndr_err_code
ndr_pull_srvsvc_NetShareCtr501(struct ndr_pull
*ndr
, int ndr_flags
, struct srvsvc_NetShareCtr501
*r
)
4371 uint32_t _ptr_array
;
4372 uint32_t cntr_array_1
;
4373 TALLOC_CTX
*_mem_save_array_0
;
4374 TALLOC_CTX
*_mem_save_array_1
;
4375 if (ndr_flags
& NDR_SCALARS
) {
4376 NDR_CHECK(ndr_pull_align(ndr
, 4));
4377 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->count
));
4378 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_array
));
4380 NDR_PULL_ALLOC(ndr
, r
->array
);
4385 if (ndr_flags
& NDR_BUFFERS
) {
4387 _mem_save_array_0
= NDR_PULL_GET_MEM_CTX(ndr
);
4388 NDR_PULL_SET_MEM_CTX(ndr
, r
->array
, 0);
4389 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->array
));
4390 NDR_PULL_ALLOC_N(ndr
, r
->array
, ndr_get_array_size(ndr
, &r
->array
));
4391 _mem_save_array_1
= NDR_PULL_GET_MEM_CTX(ndr
);
4392 NDR_PULL_SET_MEM_CTX(ndr
, r
->array
, 0);
4393 for (cntr_array_1
= 0; cntr_array_1
< r
->count
; cntr_array_1
++) {
4394 NDR_CHECK(ndr_pull_srvsvc_NetShareInfo501(ndr
, NDR_SCALARS
, &r
->array
[cntr_array_1
]));
4396 for (cntr_array_1
= 0; cntr_array_1
< r
->count
; cntr_array_1
++) {
4397 NDR_CHECK(ndr_pull_srvsvc_NetShareInfo501(ndr
, NDR_BUFFERS
, &r
->array
[cntr_array_1
]));
4399 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_array_1
, 0);
4400 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_array_0
, 0);
4403 NDR_CHECK(ndr_check_array_size(ndr
, (void*)&r
->array
, r
->count
));
4406 return NDR_ERR_SUCCESS
;
4409 _PUBLIC_
void ndr_print_srvsvc_NetShareCtr501(struct ndr_print
*ndr
, const char *name
, const struct srvsvc_NetShareCtr501
*r
)
4411 uint32_t cntr_array_1
;
4412 ndr_print_struct(ndr
, name
, "srvsvc_NetShareCtr501");
4414 ndr_print_uint32(ndr
, "count", r
->count
);
4415 ndr_print_ptr(ndr
, "array", r
->array
);
4418 ndr
->print(ndr
, "%s: ARRAY(%d)", "array", (int)r
->count
);
4420 for (cntr_array_1
=0;cntr_array_1
<r
->count
;cntr_array_1
++) {
4422 if (asprintf(&idx_1
, "[%d]", cntr_array_1
) != -1) {
4423 ndr_print_srvsvc_NetShareInfo501(ndr
, "array", &r
->array
[cntr_array_1
]);
4433 static enum ndr_err_code
ndr_push_srvsvc_NetShareInfo502(struct ndr_push
*ndr
, int ndr_flags
, const struct srvsvc_NetShareInfo502
*r
)
4435 if (ndr_flags
& NDR_SCALARS
) {
4436 NDR_CHECK(ndr_push_align(ndr
, 4));
4437 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->name
));
4438 NDR_CHECK(ndr_push_srvsvc_ShareType(ndr
, NDR_SCALARS
, r
->type
));
4439 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->comment
));
4440 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->permissions
));
4441 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->max_users
));
4442 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->current_users
));
4443 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->path
));
4444 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->password
));
4445 NDR_CHECK(ndr_push_sec_desc_buf(ndr
, NDR_SCALARS
, &r
->sd_buf
));
4447 if (ndr_flags
& NDR_BUFFERS
) {
4449 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->name
, CH_UTF16
)));
4450 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
4451 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->name
, CH_UTF16
)));
4452 NDR_CHECK(ndr_push_charset(ndr
, NDR_SCALARS
, r
->name
, ndr_charset_length(r
->name
, CH_UTF16
), sizeof(uint16_t), CH_UTF16
));
4455 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->comment
, CH_UTF16
)));
4456 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
4457 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->comment
, CH_UTF16
)));
4458 NDR_CHECK(ndr_push_charset(ndr
, NDR_SCALARS
, r
->comment
, ndr_charset_length(r
->comment
, CH_UTF16
), sizeof(uint16_t), CH_UTF16
));
4461 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->path
, CH_UTF16
)));
4462 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
4463 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->path
, CH_UTF16
)));
4464 NDR_CHECK(ndr_push_charset(ndr
, NDR_SCALARS
, r
->path
, ndr_charset_length(r
->path
, CH_UTF16
), sizeof(uint16_t), CH_UTF16
));
4467 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->password
, CH_UTF16
)));
4468 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
4469 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->password
, CH_UTF16
)));
4470 NDR_CHECK(ndr_push_charset(ndr
, NDR_SCALARS
, r
->password
, ndr_charset_length(r
->password
, CH_UTF16
), sizeof(uint16_t), CH_UTF16
));
4472 NDR_CHECK(ndr_push_sec_desc_buf(ndr
, NDR_BUFFERS
, &r
->sd_buf
));
4474 return NDR_ERR_SUCCESS
;
4477 static enum ndr_err_code
ndr_pull_srvsvc_NetShareInfo502(struct ndr_pull
*ndr
, int ndr_flags
, struct srvsvc_NetShareInfo502
*r
)
4480 TALLOC_CTX
*_mem_save_name_0
;
4481 uint32_t _ptr_comment
;
4482 TALLOC_CTX
*_mem_save_comment_0
;
4484 TALLOC_CTX
*_mem_save_path_0
;
4485 uint32_t _ptr_password
;
4486 TALLOC_CTX
*_mem_save_password_0
;
4487 if (ndr_flags
& NDR_SCALARS
) {
4488 NDR_CHECK(ndr_pull_align(ndr
, 4));
4489 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_name
));
4491 NDR_PULL_ALLOC(ndr
, r
->name
);
4495 NDR_CHECK(ndr_pull_srvsvc_ShareType(ndr
, NDR_SCALARS
, &r
->type
));
4496 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_comment
));
4498 NDR_PULL_ALLOC(ndr
, r
->comment
);
4502 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->permissions
));
4503 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->max_users
));
4504 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->current_users
));
4505 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_path
));
4507 NDR_PULL_ALLOC(ndr
, r
->path
);
4511 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_password
));
4512 if (_ptr_password
) {
4513 NDR_PULL_ALLOC(ndr
, r
->password
);
4517 NDR_CHECK(ndr_pull_sec_desc_buf(ndr
, NDR_SCALARS
, &r
->sd_buf
));
4519 if (ndr_flags
& NDR_BUFFERS
) {
4521 _mem_save_name_0
= NDR_PULL_GET_MEM_CTX(ndr
);
4522 NDR_PULL_SET_MEM_CTX(ndr
, r
->name
, 0);
4523 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->name
));
4524 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->name
));
4525 if (ndr_get_array_length(ndr
, &r
->name
) > ndr_get_array_size(ndr
, &r
->name
)) {
4526 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", ndr_get_array_size(ndr
, &r
->name
), ndr_get_array_length(ndr
, &r
->name
));
4528 NDR_CHECK(ndr_check_string_terminator(ndr
, ndr_get_array_length(ndr
, &r
->name
), sizeof(uint16_t)));
4529 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->name
, ndr_get_array_length(ndr
, &r
->name
), sizeof(uint16_t), CH_UTF16
));
4530 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_name_0
, 0);
4533 _mem_save_comment_0
= NDR_PULL_GET_MEM_CTX(ndr
);
4534 NDR_PULL_SET_MEM_CTX(ndr
, r
->comment
, 0);
4535 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->comment
));
4536 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->comment
));
4537 if (ndr_get_array_length(ndr
, &r
->comment
) > ndr_get_array_size(ndr
, &r
->comment
)) {
4538 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", ndr_get_array_size(ndr
, &r
->comment
), ndr_get_array_length(ndr
, &r
->comment
));
4540 NDR_CHECK(ndr_check_string_terminator(ndr
, ndr_get_array_length(ndr
, &r
->comment
), sizeof(uint16_t)));
4541 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->comment
, ndr_get_array_length(ndr
, &r
->comment
), sizeof(uint16_t), CH_UTF16
));
4542 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_comment_0
, 0);
4545 _mem_save_path_0
= NDR_PULL_GET_MEM_CTX(ndr
);
4546 NDR_PULL_SET_MEM_CTX(ndr
, r
->path
, 0);
4547 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->path
));
4548 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->path
));
4549 if (ndr_get_array_length(ndr
, &r
->path
) > ndr_get_array_size(ndr
, &r
->path
)) {
4550 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", ndr_get_array_size(ndr
, &r
->path
), ndr_get_array_length(ndr
, &r
->path
));
4552 NDR_CHECK(ndr_check_string_terminator(ndr
, ndr_get_array_length(ndr
, &r
->path
), sizeof(uint16_t)));
4553 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->path
, ndr_get_array_length(ndr
, &r
->path
), sizeof(uint16_t), CH_UTF16
));
4554 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_path_0
, 0);
4557 _mem_save_password_0
= NDR_PULL_GET_MEM_CTX(ndr
);
4558 NDR_PULL_SET_MEM_CTX(ndr
, r
->password
, 0);
4559 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->password
));
4560 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->password
));
4561 if (ndr_get_array_length(ndr
, &r
->password
) > ndr_get_array_size(ndr
, &r
->password
)) {
4562 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", ndr_get_array_size(ndr
, &r
->password
), ndr_get_array_length(ndr
, &r
->password
));
4564 NDR_CHECK(ndr_check_string_terminator(ndr
, ndr_get_array_length(ndr
, &r
->password
), sizeof(uint16_t)));
4565 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->password
, ndr_get_array_length(ndr
, &r
->password
), sizeof(uint16_t), CH_UTF16
));
4566 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_password_0
, 0);
4568 NDR_CHECK(ndr_pull_sec_desc_buf(ndr
, NDR_BUFFERS
, &r
->sd_buf
));
4570 return NDR_ERR_SUCCESS
;
4573 _PUBLIC_
void ndr_print_srvsvc_NetShareInfo502(struct ndr_print
*ndr
, const char *name
, const struct srvsvc_NetShareInfo502
*r
)
4575 ndr_print_struct(ndr
, name
, "srvsvc_NetShareInfo502");
4577 ndr_print_ptr(ndr
, "name", r
->name
);
4580 ndr_print_string(ndr
, "name", r
->name
);
4583 ndr_print_srvsvc_ShareType(ndr
, "type", r
->type
);
4584 ndr_print_ptr(ndr
, "comment", r
->comment
);
4587 ndr_print_string(ndr
, "comment", r
->comment
);
4590 ndr_print_uint32(ndr
, "permissions", r
->permissions
);
4591 ndr_print_uint32(ndr
, "max_users", r
->max_users
);
4592 ndr_print_uint32(ndr
, "current_users", r
->current_users
);
4593 ndr_print_ptr(ndr
, "path", r
->path
);
4596 ndr_print_string(ndr
, "path", r
->path
);
4599 ndr_print_ptr(ndr
, "password", r
->password
);
4602 ndr_print_string(ndr
, "password", r
->password
);
4605 ndr_print_sec_desc_buf(ndr
, "sd_buf", &r
->sd_buf
);
4609 static enum ndr_err_code
ndr_push_srvsvc_NetShareCtr502(struct ndr_push
*ndr
, int ndr_flags
, const struct srvsvc_NetShareCtr502
*r
)
4611 uint32_t cntr_array_1
;
4612 if (ndr_flags
& NDR_SCALARS
) {
4613 NDR_CHECK(ndr_push_align(ndr
, 4));
4614 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->count
));
4615 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->array
));
4617 if (ndr_flags
& NDR_BUFFERS
) {
4619 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->count
));
4620 for (cntr_array_1
= 0; cntr_array_1
< r
->count
; cntr_array_1
++) {
4621 NDR_CHECK(ndr_push_srvsvc_NetShareInfo502(ndr
, NDR_SCALARS
, &r
->array
[cntr_array_1
]));
4623 for (cntr_array_1
= 0; cntr_array_1
< r
->count
; cntr_array_1
++) {
4624 NDR_CHECK(ndr_push_srvsvc_NetShareInfo502(ndr
, NDR_BUFFERS
, &r
->array
[cntr_array_1
]));
4628 return NDR_ERR_SUCCESS
;
4631 static enum ndr_err_code
ndr_pull_srvsvc_NetShareCtr502(struct ndr_pull
*ndr
, int ndr_flags
, struct srvsvc_NetShareCtr502
*r
)
4633 uint32_t _ptr_array
;
4634 uint32_t cntr_array_1
;
4635 TALLOC_CTX
*_mem_save_array_0
;
4636 TALLOC_CTX
*_mem_save_array_1
;
4637 if (ndr_flags
& NDR_SCALARS
) {
4638 NDR_CHECK(ndr_pull_align(ndr
, 4));
4639 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->count
));
4640 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_array
));
4642 NDR_PULL_ALLOC(ndr
, r
->array
);
4647 if (ndr_flags
& NDR_BUFFERS
) {
4649 _mem_save_array_0
= NDR_PULL_GET_MEM_CTX(ndr
);
4650 NDR_PULL_SET_MEM_CTX(ndr
, r
->array
, 0);
4651 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->array
));
4652 NDR_PULL_ALLOC_N(ndr
, r
->array
, ndr_get_array_size(ndr
, &r
->array
));
4653 _mem_save_array_1
= NDR_PULL_GET_MEM_CTX(ndr
);
4654 NDR_PULL_SET_MEM_CTX(ndr
, r
->array
, 0);
4655 for (cntr_array_1
= 0; cntr_array_1
< r
->count
; cntr_array_1
++) {
4656 NDR_CHECK(ndr_pull_srvsvc_NetShareInfo502(ndr
, NDR_SCALARS
, &r
->array
[cntr_array_1
]));
4658 for (cntr_array_1
= 0; cntr_array_1
< r
->count
; cntr_array_1
++) {
4659 NDR_CHECK(ndr_pull_srvsvc_NetShareInfo502(ndr
, NDR_BUFFERS
, &r
->array
[cntr_array_1
]));
4661 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_array_1
, 0);
4662 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_array_0
, 0);
4665 NDR_CHECK(ndr_check_array_size(ndr
, (void*)&r
->array
, r
->count
));
4668 return NDR_ERR_SUCCESS
;
4671 _PUBLIC_
void ndr_print_srvsvc_NetShareCtr502(struct ndr_print
*ndr
, const char *name
, const struct srvsvc_NetShareCtr502
*r
)
4673 uint32_t cntr_array_1
;
4674 ndr_print_struct(ndr
, name
, "srvsvc_NetShareCtr502");
4676 ndr_print_uint32(ndr
, "count", r
->count
);
4677 ndr_print_ptr(ndr
, "array", r
->array
);
4680 ndr
->print(ndr
, "%s: ARRAY(%d)", "array", (int)r
->count
);
4682 for (cntr_array_1
=0;cntr_array_1
<r
->count
;cntr_array_1
++) {
4684 if (asprintf(&idx_1
, "[%d]", cntr_array_1
) != -1) {
4685 ndr_print_srvsvc_NetShareInfo502(ndr
, "array", &r
->array
[cntr_array_1
]);
4695 static enum ndr_err_code
ndr_push_srvsvc_NetShareInfo1004(struct ndr_push
*ndr
, int ndr_flags
, const struct srvsvc_NetShareInfo1004
*r
)
4697 if (ndr_flags
& NDR_SCALARS
) {
4698 NDR_CHECK(ndr_push_align(ndr
, 4));
4699 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->comment
));
4701 if (ndr_flags
& NDR_BUFFERS
) {
4703 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->comment
, CH_UTF16
)));
4704 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
4705 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->comment
, CH_UTF16
)));
4706 NDR_CHECK(ndr_push_charset(ndr
, NDR_SCALARS
, r
->comment
, ndr_charset_length(r
->comment
, CH_UTF16
), sizeof(uint16_t), CH_UTF16
));
4709 return NDR_ERR_SUCCESS
;
4712 static enum ndr_err_code
ndr_pull_srvsvc_NetShareInfo1004(struct ndr_pull
*ndr
, int ndr_flags
, struct srvsvc_NetShareInfo1004
*r
)
4714 uint32_t _ptr_comment
;
4715 TALLOC_CTX
*_mem_save_comment_0
;
4716 if (ndr_flags
& NDR_SCALARS
) {
4717 NDR_CHECK(ndr_pull_align(ndr
, 4));
4718 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_comment
));
4720 NDR_PULL_ALLOC(ndr
, r
->comment
);
4725 if (ndr_flags
& NDR_BUFFERS
) {
4727 _mem_save_comment_0
= NDR_PULL_GET_MEM_CTX(ndr
);
4728 NDR_PULL_SET_MEM_CTX(ndr
, r
->comment
, 0);
4729 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->comment
));
4730 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->comment
));
4731 if (ndr_get_array_length(ndr
, &r
->comment
) > ndr_get_array_size(ndr
, &r
->comment
)) {
4732 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", ndr_get_array_size(ndr
, &r
->comment
), ndr_get_array_length(ndr
, &r
->comment
));
4734 NDR_CHECK(ndr_check_string_terminator(ndr
, ndr_get_array_length(ndr
, &r
->comment
), sizeof(uint16_t)));
4735 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->comment
, ndr_get_array_length(ndr
, &r
->comment
), sizeof(uint16_t), CH_UTF16
));
4736 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_comment_0
, 0);
4739 return NDR_ERR_SUCCESS
;
4742 _PUBLIC_
void ndr_print_srvsvc_NetShareInfo1004(struct ndr_print
*ndr
, const char *name
, const struct srvsvc_NetShareInfo1004
*r
)
4744 ndr_print_struct(ndr
, name
, "srvsvc_NetShareInfo1004");
4746 ndr_print_ptr(ndr
, "comment", r
->comment
);
4749 ndr_print_string(ndr
, "comment", r
->comment
);
4755 static enum ndr_err_code
ndr_push_srvsvc_NetShareCtr1004(struct ndr_push
*ndr
, int ndr_flags
, const struct srvsvc_NetShareCtr1004
*r
)
4757 uint32_t cntr_array_1
;
4758 if (ndr_flags
& NDR_SCALARS
) {
4759 NDR_CHECK(ndr_push_align(ndr
, 4));
4760 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->count
));
4761 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->array
));
4763 if (ndr_flags
& NDR_BUFFERS
) {
4765 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->count
));
4766 for (cntr_array_1
= 0; cntr_array_1
< r
->count
; cntr_array_1
++) {
4767 NDR_CHECK(ndr_push_srvsvc_NetShareInfo1004(ndr
, NDR_SCALARS
, &r
->array
[cntr_array_1
]));
4769 for (cntr_array_1
= 0; cntr_array_1
< r
->count
; cntr_array_1
++) {
4770 NDR_CHECK(ndr_push_srvsvc_NetShareInfo1004(ndr
, NDR_BUFFERS
, &r
->array
[cntr_array_1
]));
4774 return NDR_ERR_SUCCESS
;
4777 static enum ndr_err_code
ndr_pull_srvsvc_NetShareCtr1004(struct ndr_pull
*ndr
, int ndr_flags
, struct srvsvc_NetShareCtr1004
*r
)
4779 uint32_t _ptr_array
;
4780 uint32_t cntr_array_1
;
4781 TALLOC_CTX
*_mem_save_array_0
;
4782 TALLOC_CTX
*_mem_save_array_1
;
4783 if (ndr_flags
& NDR_SCALARS
) {
4784 NDR_CHECK(ndr_pull_align(ndr
, 4));
4785 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->count
));
4786 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_array
));
4788 NDR_PULL_ALLOC(ndr
, r
->array
);
4793 if (ndr_flags
& NDR_BUFFERS
) {
4795 _mem_save_array_0
= NDR_PULL_GET_MEM_CTX(ndr
);
4796 NDR_PULL_SET_MEM_CTX(ndr
, r
->array
, 0);
4797 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->array
));
4798 NDR_PULL_ALLOC_N(ndr
, r
->array
, ndr_get_array_size(ndr
, &r
->array
));
4799 _mem_save_array_1
= NDR_PULL_GET_MEM_CTX(ndr
);
4800 NDR_PULL_SET_MEM_CTX(ndr
, r
->array
, 0);
4801 for (cntr_array_1
= 0; cntr_array_1
< r
->count
; cntr_array_1
++) {
4802 NDR_CHECK(ndr_pull_srvsvc_NetShareInfo1004(ndr
, NDR_SCALARS
, &r
->array
[cntr_array_1
]));
4804 for (cntr_array_1
= 0; cntr_array_1
< r
->count
; cntr_array_1
++) {
4805 NDR_CHECK(ndr_pull_srvsvc_NetShareInfo1004(ndr
, NDR_BUFFERS
, &r
->array
[cntr_array_1
]));
4807 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_array_1
, 0);
4808 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_array_0
, 0);
4811 NDR_CHECK(ndr_check_array_size(ndr
, (void*)&r
->array
, r
->count
));
4814 return NDR_ERR_SUCCESS
;
4817 _PUBLIC_
void ndr_print_srvsvc_NetShareCtr1004(struct ndr_print
*ndr
, const char *name
, const struct srvsvc_NetShareCtr1004
*r
)
4819 uint32_t cntr_array_1
;
4820 ndr_print_struct(ndr
, name
, "srvsvc_NetShareCtr1004");
4822 ndr_print_uint32(ndr
, "count", r
->count
);
4823 ndr_print_ptr(ndr
, "array", r
->array
);
4826 ndr
->print(ndr
, "%s: ARRAY(%d)", "array", (int)r
->count
);
4828 for (cntr_array_1
=0;cntr_array_1
<r
->count
;cntr_array_1
++) {
4830 if (asprintf(&idx_1
, "[%d]", cntr_array_1
) != -1) {
4831 ndr_print_srvsvc_NetShareInfo1004(ndr
, "array", &r
->array
[cntr_array_1
]);
4841 static enum ndr_err_code
ndr_push_NetShareInfo1005Flags(struct ndr_push
*ndr
, int ndr_flags
, uint32_t r
)
4843 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
));
4844 return NDR_ERR_SUCCESS
;
4847 static enum ndr_err_code
ndr_pull_NetShareInfo1005Flags(struct ndr_pull
*ndr
, int ndr_flags
, uint32_t *r
)
4850 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &v
));
4852 return NDR_ERR_SUCCESS
;
4855 _PUBLIC_
void ndr_print_NetShareInfo1005Flags(struct ndr_print
*ndr
, const char *name
, uint32_t r
)
4857 ndr_print_uint32(ndr
, name
, r
);
4859 ndr_print_bitmap_flag(ndr
, sizeof(uint32_t), "SHARE_1005_IN_DFS", SHARE_1005_IN_DFS
, r
);
4860 ndr_print_bitmap_flag(ndr
, sizeof(uint32_t), "SHARE_1005_DFS_ROOT", SHARE_1005_DFS_ROOT
, r
);
4864 static enum ndr_err_code
ndr_push_srvsvc_NetShareInfo1005(struct ndr_push
*ndr
, int ndr_flags
, const struct srvsvc_NetShareInfo1005
*r
)
4866 if (ndr_flags
& NDR_SCALARS
) {
4867 NDR_CHECK(ndr_push_align(ndr
, 4));
4868 NDR_CHECK(ndr_push_NetShareInfo1005Flags(ndr
, NDR_SCALARS
, r
->dfs_flags
));
4870 if (ndr_flags
& NDR_BUFFERS
) {
4872 return NDR_ERR_SUCCESS
;
4875 static enum ndr_err_code
ndr_pull_srvsvc_NetShareInfo1005(struct ndr_pull
*ndr
, int ndr_flags
, struct srvsvc_NetShareInfo1005
*r
)
4877 if (ndr_flags
& NDR_SCALARS
) {
4878 NDR_CHECK(ndr_pull_align(ndr
, 4));
4879 NDR_CHECK(ndr_pull_NetShareInfo1005Flags(ndr
, NDR_SCALARS
, &r
->dfs_flags
));
4881 if (ndr_flags
& NDR_BUFFERS
) {
4883 return NDR_ERR_SUCCESS
;
4886 _PUBLIC_
void ndr_print_srvsvc_NetShareInfo1005(struct ndr_print
*ndr
, const char *name
, const struct srvsvc_NetShareInfo1005
*r
)
4888 ndr_print_struct(ndr
, name
, "srvsvc_NetShareInfo1005");
4890 ndr_print_NetShareInfo1005Flags(ndr
, "dfs_flags", r
->dfs_flags
);
4894 static enum ndr_err_code
ndr_push_srvsvc_NetShareCtr1005(struct ndr_push
*ndr
, int ndr_flags
, const struct srvsvc_NetShareCtr1005
*r
)
4896 uint32_t cntr_array_1
;
4897 if (ndr_flags
& NDR_SCALARS
) {
4898 NDR_CHECK(ndr_push_align(ndr
, 4));
4899 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->count
));
4900 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->array
));
4902 if (ndr_flags
& NDR_BUFFERS
) {
4904 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->count
));
4905 for (cntr_array_1
= 0; cntr_array_1
< r
->count
; cntr_array_1
++) {
4906 NDR_CHECK(ndr_push_srvsvc_NetShareInfo1005(ndr
, NDR_SCALARS
, &r
->array
[cntr_array_1
]));
4910 return NDR_ERR_SUCCESS
;
4913 static enum ndr_err_code
ndr_pull_srvsvc_NetShareCtr1005(struct ndr_pull
*ndr
, int ndr_flags
, struct srvsvc_NetShareCtr1005
*r
)
4915 uint32_t _ptr_array
;
4916 uint32_t cntr_array_1
;
4917 TALLOC_CTX
*_mem_save_array_0
;
4918 TALLOC_CTX
*_mem_save_array_1
;
4919 if (ndr_flags
& NDR_SCALARS
) {
4920 NDR_CHECK(ndr_pull_align(ndr
, 4));
4921 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->count
));
4922 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_array
));
4924 NDR_PULL_ALLOC(ndr
, r
->array
);
4929 if (ndr_flags
& NDR_BUFFERS
) {
4931 _mem_save_array_0
= NDR_PULL_GET_MEM_CTX(ndr
);
4932 NDR_PULL_SET_MEM_CTX(ndr
, r
->array
, 0);
4933 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->array
));
4934 NDR_PULL_ALLOC_N(ndr
, r
->array
, ndr_get_array_size(ndr
, &r
->array
));
4935 _mem_save_array_1
= NDR_PULL_GET_MEM_CTX(ndr
);
4936 NDR_PULL_SET_MEM_CTX(ndr
, r
->array
, 0);
4937 for (cntr_array_1
= 0; cntr_array_1
< r
->count
; cntr_array_1
++) {
4938 NDR_CHECK(ndr_pull_srvsvc_NetShareInfo1005(ndr
, NDR_SCALARS
, &r
->array
[cntr_array_1
]));
4940 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_array_1
, 0);
4941 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_array_0
, 0);
4944 NDR_CHECK(ndr_check_array_size(ndr
, (void*)&r
->array
, r
->count
));
4947 return NDR_ERR_SUCCESS
;
4950 _PUBLIC_
void ndr_print_srvsvc_NetShareCtr1005(struct ndr_print
*ndr
, const char *name
, const struct srvsvc_NetShareCtr1005
*r
)
4952 uint32_t cntr_array_1
;
4953 ndr_print_struct(ndr
, name
, "srvsvc_NetShareCtr1005");
4955 ndr_print_uint32(ndr
, "count", r
->count
);
4956 ndr_print_ptr(ndr
, "array", r
->array
);
4959 ndr
->print(ndr
, "%s: ARRAY(%d)", "array", (int)r
->count
);
4961 for (cntr_array_1
=0;cntr_array_1
<r
->count
;cntr_array_1
++) {
4963 if (asprintf(&idx_1
, "[%d]", cntr_array_1
) != -1) {
4964 ndr_print_srvsvc_NetShareInfo1005(ndr
, "array", &r
->array
[cntr_array_1
]);
4974 static enum ndr_err_code
ndr_push_srvsvc_NetShareInfo1006(struct ndr_push
*ndr
, int ndr_flags
, const struct srvsvc_NetShareInfo1006
*r
)
4976 if (ndr_flags
& NDR_SCALARS
) {
4977 NDR_CHECK(ndr_push_align(ndr
, 4));
4978 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->max_users
));
4980 if (ndr_flags
& NDR_BUFFERS
) {
4982 return NDR_ERR_SUCCESS
;
4985 static enum ndr_err_code
ndr_pull_srvsvc_NetShareInfo1006(struct ndr_pull
*ndr
, int ndr_flags
, struct srvsvc_NetShareInfo1006
*r
)
4987 if (ndr_flags
& NDR_SCALARS
) {
4988 NDR_CHECK(ndr_pull_align(ndr
, 4));
4989 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->max_users
));
4991 if (ndr_flags
& NDR_BUFFERS
) {
4993 return NDR_ERR_SUCCESS
;
4996 _PUBLIC_
void ndr_print_srvsvc_NetShareInfo1006(struct ndr_print
*ndr
, const char *name
, const struct srvsvc_NetShareInfo1006
*r
)
4998 ndr_print_struct(ndr
, name
, "srvsvc_NetShareInfo1006");
5000 ndr_print_uint32(ndr
, "max_users", r
->max_users
);
5004 static enum ndr_err_code
ndr_push_srvsvc_NetShareCtr1006(struct ndr_push
*ndr
, int ndr_flags
, const struct srvsvc_NetShareCtr1006
*r
)
5006 uint32_t cntr_array_1
;
5007 if (ndr_flags
& NDR_SCALARS
) {
5008 NDR_CHECK(ndr_push_align(ndr
, 4));
5009 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->count
));
5010 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->array
));
5012 if (ndr_flags
& NDR_BUFFERS
) {
5014 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->count
));
5015 for (cntr_array_1
= 0; cntr_array_1
< r
->count
; cntr_array_1
++) {
5016 NDR_CHECK(ndr_push_srvsvc_NetShareInfo1006(ndr
, NDR_SCALARS
, &r
->array
[cntr_array_1
]));
5020 return NDR_ERR_SUCCESS
;
5023 static enum ndr_err_code
ndr_pull_srvsvc_NetShareCtr1006(struct ndr_pull
*ndr
, int ndr_flags
, struct srvsvc_NetShareCtr1006
*r
)
5025 uint32_t _ptr_array
;
5026 uint32_t cntr_array_1
;
5027 TALLOC_CTX
*_mem_save_array_0
;
5028 TALLOC_CTX
*_mem_save_array_1
;
5029 if (ndr_flags
& NDR_SCALARS
) {
5030 NDR_CHECK(ndr_pull_align(ndr
, 4));
5031 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->count
));
5032 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_array
));
5034 NDR_PULL_ALLOC(ndr
, r
->array
);
5039 if (ndr_flags
& NDR_BUFFERS
) {
5041 _mem_save_array_0
= NDR_PULL_GET_MEM_CTX(ndr
);
5042 NDR_PULL_SET_MEM_CTX(ndr
, r
->array
, 0);
5043 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->array
));
5044 NDR_PULL_ALLOC_N(ndr
, r
->array
, ndr_get_array_size(ndr
, &r
->array
));
5045 _mem_save_array_1
= NDR_PULL_GET_MEM_CTX(ndr
);
5046 NDR_PULL_SET_MEM_CTX(ndr
, r
->array
, 0);
5047 for (cntr_array_1
= 0; cntr_array_1
< r
->count
; cntr_array_1
++) {
5048 NDR_CHECK(ndr_pull_srvsvc_NetShareInfo1006(ndr
, NDR_SCALARS
, &r
->array
[cntr_array_1
]));
5050 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_array_1
, 0);
5051 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_array_0
, 0);
5054 NDR_CHECK(ndr_check_array_size(ndr
, (void*)&r
->array
, r
->count
));
5057 return NDR_ERR_SUCCESS
;
5060 _PUBLIC_
void ndr_print_srvsvc_NetShareCtr1006(struct ndr_print
*ndr
, const char *name
, const struct srvsvc_NetShareCtr1006
*r
)
5062 uint32_t cntr_array_1
;
5063 ndr_print_struct(ndr
, name
, "srvsvc_NetShareCtr1006");
5065 ndr_print_uint32(ndr
, "count", r
->count
);
5066 ndr_print_ptr(ndr
, "array", r
->array
);
5069 ndr
->print(ndr
, "%s: ARRAY(%d)", "array", (int)r
->count
);
5071 for (cntr_array_1
=0;cntr_array_1
<r
->count
;cntr_array_1
++) {
5073 if (asprintf(&idx_1
, "[%d]", cntr_array_1
) != -1) {
5074 ndr_print_srvsvc_NetShareInfo1006(ndr
, "array", &r
->array
[cntr_array_1
]);
5084 static enum ndr_err_code
ndr_push_srvsvc_NetShareInfo1007(struct ndr_push
*ndr
, int ndr_flags
, const struct srvsvc_NetShareInfo1007
*r
)
5086 if (ndr_flags
& NDR_SCALARS
) {
5087 NDR_CHECK(ndr_push_align(ndr
, 4));
5088 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->flags
));
5089 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->alternate_directory_name
));
5091 if (ndr_flags
& NDR_BUFFERS
) {
5092 if (r
->alternate_directory_name
) {
5093 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->alternate_directory_name
, CH_UTF16
)));
5094 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
5095 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->alternate_directory_name
, CH_UTF16
)));
5096 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
));
5099 return NDR_ERR_SUCCESS
;
5102 static enum ndr_err_code
ndr_pull_srvsvc_NetShareInfo1007(struct ndr_pull
*ndr
, int ndr_flags
, struct srvsvc_NetShareInfo1007
*r
)
5104 uint32_t _ptr_alternate_directory_name
;
5105 TALLOC_CTX
*_mem_save_alternate_directory_name_0
;
5106 if (ndr_flags
& NDR_SCALARS
) {
5107 NDR_CHECK(ndr_pull_align(ndr
, 4));
5108 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->flags
));
5109 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_alternate_directory_name
));
5110 if (_ptr_alternate_directory_name
) {
5111 NDR_PULL_ALLOC(ndr
, r
->alternate_directory_name
);
5113 r
->alternate_directory_name
= NULL
;
5116 if (ndr_flags
& NDR_BUFFERS
) {
5117 if (r
->alternate_directory_name
) {
5118 _mem_save_alternate_directory_name_0
= NDR_PULL_GET_MEM_CTX(ndr
);
5119 NDR_PULL_SET_MEM_CTX(ndr
, r
->alternate_directory_name
, 0);
5120 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->alternate_directory_name
));
5121 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->alternate_directory_name
));
5122 if (ndr_get_array_length(ndr
, &r
->alternate_directory_name
) > ndr_get_array_size(ndr
, &r
->alternate_directory_name
)) {
5123 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", ndr_get_array_size(ndr
, &r
->alternate_directory_name
), ndr_get_array_length(ndr
, &r
->alternate_directory_name
));
5125 NDR_CHECK(ndr_check_string_terminator(ndr
, ndr_get_array_length(ndr
, &r
->alternate_directory_name
), sizeof(uint16_t)));
5126 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->alternate_directory_name
, ndr_get_array_length(ndr
, &r
->alternate_directory_name
), sizeof(uint16_t), CH_UTF16
));
5127 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_alternate_directory_name_0
, 0);
5130 return NDR_ERR_SUCCESS
;
5133 _PUBLIC_
void ndr_print_srvsvc_NetShareInfo1007(struct ndr_print
*ndr
, const char *name
, const struct srvsvc_NetShareInfo1007
*r
)
5135 ndr_print_struct(ndr
, name
, "srvsvc_NetShareInfo1007");
5137 ndr_print_uint32(ndr
, "flags", r
->flags
);
5138 ndr_print_ptr(ndr
, "alternate_directory_name", r
->alternate_directory_name
);
5140 if (r
->alternate_directory_name
) {
5141 ndr_print_string(ndr
, "alternate_directory_name", r
->alternate_directory_name
);
5147 static enum ndr_err_code
ndr_push_srvsvc_NetShareCtr1007(struct ndr_push
*ndr
, int ndr_flags
, const struct srvsvc_NetShareCtr1007
*r
)
5149 uint32_t cntr_array_1
;
5150 if (ndr_flags
& NDR_SCALARS
) {
5151 NDR_CHECK(ndr_push_align(ndr
, 4));
5152 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->count
));
5153 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->array
));
5155 if (ndr_flags
& NDR_BUFFERS
) {
5157 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->count
));
5158 for (cntr_array_1
= 0; cntr_array_1
< r
->count
; cntr_array_1
++) {
5159 NDR_CHECK(ndr_push_srvsvc_NetShareInfo1007(ndr
, NDR_SCALARS
, &r
->array
[cntr_array_1
]));
5161 for (cntr_array_1
= 0; cntr_array_1
< r
->count
; cntr_array_1
++) {
5162 NDR_CHECK(ndr_push_srvsvc_NetShareInfo1007(ndr
, NDR_BUFFERS
, &r
->array
[cntr_array_1
]));
5166 return NDR_ERR_SUCCESS
;
5169 static enum ndr_err_code
ndr_pull_srvsvc_NetShareCtr1007(struct ndr_pull
*ndr
, int ndr_flags
, struct srvsvc_NetShareCtr1007
*r
)
5171 uint32_t _ptr_array
;
5172 uint32_t cntr_array_1
;
5173 TALLOC_CTX
*_mem_save_array_0
;
5174 TALLOC_CTX
*_mem_save_array_1
;
5175 if (ndr_flags
& NDR_SCALARS
) {
5176 NDR_CHECK(ndr_pull_align(ndr
, 4));
5177 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->count
));
5178 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_array
));
5180 NDR_PULL_ALLOC(ndr
, r
->array
);
5185 if (ndr_flags
& NDR_BUFFERS
) {
5187 _mem_save_array_0
= NDR_PULL_GET_MEM_CTX(ndr
);
5188 NDR_PULL_SET_MEM_CTX(ndr
, r
->array
, 0);
5189 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->array
));
5190 NDR_PULL_ALLOC_N(ndr
, r
->array
, ndr_get_array_size(ndr
, &r
->array
));
5191 _mem_save_array_1
= NDR_PULL_GET_MEM_CTX(ndr
);
5192 NDR_PULL_SET_MEM_CTX(ndr
, r
->array
, 0);
5193 for (cntr_array_1
= 0; cntr_array_1
< r
->count
; cntr_array_1
++) {
5194 NDR_CHECK(ndr_pull_srvsvc_NetShareInfo1007(ndr
, NDR_SCALARS
, &r
->array
[cntr_array_1
]));
5196 for (cntr_array_1
= 0; cntr_array_1
< r
->count
; cntr_array_1
++) {
5197 NDR_CHECK(ndr_pull_srvsvc_NetShareInfo1007(ndr
, NDR_BUFFERS
, &r
->array
[cntr_array_1
]));
5199 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_array_1
, 0);
5200 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_array_0
, 0);
5203 NDR_CHECK(ndr_check_array_size(ndr
, (void*)&r
->array
, r
->count
));
5206 return NDR_ERR_SUCCESS
;
5209 _PUBLIC_
void ndr_print_srvsvc_NetShareCtr1007(struct ndr_print
*ndr
, const char *name
, const struct srvsvc_NetShareCtr1007
*r
)
5211 uint32_t cntr_array_1
;
5212 ndr_print_struct(ndr
, name
, "srvsvc_NetShareCtr1007");
5214 ndr_print_uint32(ndr
, "count", r
->count
);
5215 ndr_print_ptr(ndr
, "array", r
->array
);
5218 ndr
->print(ndr
, "%s: ARRAY(%d)", "array", (int)r
->count
);
5220 for (cntr_array_1
=0;cntr_array_1
<r
->count
;cntr_array_1
++) {
5222 if (asprintf(&idx_1
, "[%d]", cntr_array_1
) != -1) {
5223 ndr_print_srvsvc_NetShareInfo1007(ndr
, "array", &r
->array
[cntr_array_1
]);
5233 static enum ndr_err_code
ndr_push_srvsvc_NetShareCtr1501(struct ndr_push
*ndr
, int ndr_flags
, const struct srvsvc_NetShareCtr1501
*r
)
5235 uint32_t cntr_array_1
;
5236 if (ndr_flags
& NDR_SCALARS
) {
5237 NDR_CHECK(ndr_push_align(ndr
, 4));
5238 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->count
));
5239 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->array
));
5241 if (ndr_flags
& NDR_BUFFERS
) {
5243 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->count
));
5244 for (cntr_array_1
= 0; cntr_array_1
< r
->count
; cntr_array_1
++) {
5245 NDR_CHECK(ndr_push_sec_desc_buf(ndr
, NDR_SCALARS
, &r
->array
[cntr_array_1
]));
5247 for (cntr_array_1
= 0; cntr_array_1
< r
->count
; cntr_array_1
++) {
5248 NDR_CHECK(ndr_push_sec_desc_buf(ndr
, NDR_BUFFERS
, &r
->array
[cntr_array_1
]));
5252 return NDR_ERR_SUCCESS
;
5255 static enum ndr_err_code
ndr_pull_srvsvc_NetShareCtr1501(struct ndr_pull
*ndr
, int ndr_flags
, struct srvsvc_NetShareCtr1501
*r
)
5257 uint32_t _ptr_array
;
5258 uint32_t cntr_array_1
;
5259 TALLOC_CTX
*_mem_save_array_0
;
5260 TALLOC_CTX
*_mem_save_array_1
;
5261 if (ndr_flags
& NDR_SCALARS
) {
5262 NDR_CHECK(ndr_pull_align(ndr
, 4));
5263 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->count
));
5264 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_array
));
5266 NDR_PULL_ALLOC(ndr
, r
->array
);
5271 if (ndr_flags
& NDR_BUFFERS
) {
5273 _mem_save_array_0
= NDR_PULL_GET_MEM_CTX(ndr
);
5274 NDR_PULL_SET_MEM_CTX(ndr
, r
->array
, 0);
5275 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->array
));
5276 NDR_PULL_ALLOC_N(ndr
, r
->array
, ndr_get_array_size(ndr
, &r
->array
));
5277 _mem_save_array_1
= NDR_PULL_GET_MEM_CTX(ndr
);
5278 NDR_PULL_SET_MEM_CTX(ndr
, r
->array
, 0);
5279 for (cntr_array_1
= 0; cntr_array_1
< r
->count
; cntr_array_1
++) {
5280 NDR_CHECK(ndr_pull_sec_desc_buf(ndr
, NDR_SCALARS
, &r
->array
[cntr_array_1
]));
5282 for (cntr_array_1
= 0; cntr_array_1
< r
->count
; cntr_array_1
++) {
5283 NDR_CHECK(ndr_pull_sec_desc_buf(ndr
, NDR_BUFFERS
, &r
->array
[cntr_array_1
]));
5285 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_array_1
, 0);
5286 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_array_0
, 0);
5289 NDR_CHECK(ndr_check_array_size(ndr
, (void*)&r
->array
, r
->count
));
5292 return NDR_ERR_SUCCESS
;
5295 _PUBLIC_
void ndr_print_srvsvc_NetShareCtr1501(struct ndr_print
*ndr
, const char *name
, const struct srvsvc_NetShareCtr1501
*r
)
5297 uint32_t cntr_array_1
;
5298 ndr_print_struct(ndr
, name
, "srvsvc_NetShareCtr1501");
5300 ndr_print_uint32(ndr
, "count", r
->count
);
5301 ndr_print_ptr(ndr
, "array", r
->array
);
5304 ndr
->print(ndr
, "%s: ARRAY(%d)", "array", (int)r
->count
);
5306 for (cntr_array_1
=0;cntr_array_1
<r
->count
;cntr_array_1
++) {
5308 if (asprintf(&idx_1
, "[%d]", cntr_array_1
) != -1) {
5309 ndr_print_sec_desc_buf(ndr
, "array", &r
->array
[cntr_array_1
]);
5319 static enum ndr_err_code
ndr_push_srvsvc_NetShareInfo(struct ndr_push
*ndr
, int ndr_flags
, const union srvsvc_NetShareInfo
*r
)
5321 if (ndr_flags
& NDR_SCALARS
) {
5322 int level
= ndr_push_get_switch_value(ndr
, r
);
5323 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, level
));
5326 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->info0
));
5330 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->info1
));
5334 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->info2
));
5338 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->info501
));
5342 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->info502
));
5346 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->info1004
));
5350 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->info1005
));
5354 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->info1006
));
5358 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->info1007
));
5362 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->info1501
));
5370 if (ndr_flags
& NDR_BUFFERS
) {
5371 int level
= ndr_push_get_switch_value(ndr
, r
);
5375 NDR_CHECK(ndr_push_srvsvc_NetShareInfo0(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->info0
));
5381 NDR_CHECK(ndr_push_srvsvc_NetShareInfo1(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->info1
));
5387 NDR_CHECK(ndr_push_srvsvc_NetShareInfo2(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->info2
));
5393 NDR_CHECK(ndr_push_srvsvc_NetShareInfo501(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->info501
));
5399 NDR_CHECK(ndr_push_srvsvc_NetShareInfo502(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->info502
));
5405 NDR_CHECK(ndr_push_srvsvc_NetShareInfo1004(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->info1004
));
5411 NDR_CHECK(ndr_push_srvsvc_NetShareInfo1005(ndr
, NDR_SCALARS
, r
->info1005
));
5417 NDR_CHECK(ndr_push_srvsvc_NetShareInfo1006(ndr
, NDR_SCALARS
, r
->info1006
));
5423 NDR_CHECK(ndr_push_srvsvc_NetShareInfo1007(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->info1007
));
5429 NDR_CHECK(ndr_push_sec_desc_buf(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->info1501
));
5438 return NDR_ERR_SUCCESS
;
5441 static enum ndr_err_code
ndr_pull_srvsvc_NetShareInfo(struct ndr_pull
*ndr
, int ndr_flags
, union srvsvc_NetShareInfo
*r
)
5445 TALLOC_CTX
*_mem_save_info0_0
;
5446 TALLOC_CTX
*_mem_save_info1_0
;
5447 TALLOC_CTX
*_mem_save_info2_0
;
5448 TALLOC_CTX
*_mem_save_info501_0
;
5449 TALLOC_CTX
*_mem_save_info502_0
;
5450 TALLOC_CTX
*_mem_save_info1004_0
;
5451 TALLOC_CTX
*_mem_save_info1005_0
;
5452 TALLOC_CTX
*_mem_save_info1006_0
;
5453 TALLOC_CTX
*_mem_save_info1007_0
;
5454 TALLOC_CTX
*_mem_save_info1501_0
;
5455 level
= ndr_pull_get_switch_value(ndr
, r
);
5456 if (ndr_flags
& NDR_SCALARS
) {
5457 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &_level
));
5458 if (_level
!= level
) {
5459 return ndr_pull_error(ndr
, NDR_ERR_BAD_SWITCH
, "Bad switch value %u for r", _level
);
5463 uint32_t _ptr_info0
;
5464 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_info0
));
5466 NDR_PULL_ALLOC(ndr
, r
->info0
);
5473 uint32_t _ptr_info1
;
5474 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_info1
));
5476 NDR_PULL_ALLOC(ndr
, r
->info1
);
5483 uint32_t _ptr_info2
;
5484 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_info2
));
5486 NDR_PULL_ALLOC(ndr
, r
->info2
);
5493 uint32_t _ptr_info501
;
5494 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_info501
));
5496 NDR_PULL_ALLOC(ndr
, r
->info501
);
5503 uint32_t _ptr_info502
;
5504 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_info502
));
5506 NDR_PULL_ALLOC(ndr
, r
->info502
);
5513 uint32_t _ptr_info1004
;
5514 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_info1004
));
5515 if (_ptr_info1004
) {
5516 NDR_PULL_ALLOC(ndr
, r
->info1004
);
5523 uint32_t _ptr_info1005
;
5524 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_info1005
));
5525 if (_ptr_info1005
) {
5526 NDR_PULL_ALLOC(ndr
, r
->info1005
);
5533 uint32_t _ptr_info1006
;
5534 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_info1006
));
5535 if (_ptr_info1006
) {
5536 NDR_PULL_ALLOC(ndr
, r
->info1006
);
5543 uint32_t _ptr_info1007
;
5544 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_info1007
));
5545 if (_ptr_info1007
) {
5546 NDR_PULL_ALLOC(ndr
, r
->info1007
);
5553 uint32_t _ptr_info1501
;
5554 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_info1501
));
5555 if (_ptr_info1501
) {
5556 NDR_PULL_ALLOC(ndr
, r
->info1501
);
5567 if (ndr_flags
& NDR_BUFFERS
) {
5571 _mem_save_info0_0
= NDR_PULL_GET_MEM_CTX(ndr
);
5572 NDR_PULL_SET_MEM_CTX(ndr
, r
->info0
, 0);
5573 NDR_CHECK(ndr_pull_srvsvc_NetShareInfo0(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->info0
));
5574 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_info0_0
, 0);
5580 _mem_save_info1_0
= NDR_PULL_GET_MEM_CTX(ndr
);
5581 NDR_PULL_SET_MEM_CTX(ndr
, r
->info1
, 0);
5582 NDR_CHECK(ndr_pull_srvsvc_NetShareInfo1(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->info1
));
5583 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_info1_0
, 0);
5589 _mem_save_info2_0
= NDR_PULL_GET_MEM_CTX(ndr
);
5590 NDR_PULL_SET_MEM_CTX(ndr
, r
->info2
, 0);
5591 NDR_CHECK(ndr_pull_srvsvc_NetShareInfo2(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->info2
));
5592 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_info2_0
, 0);
5598 _mem_save_info501_0
= NDR_PULL_GET_MEM_CTX(ndr
);
5599 NDR_PULL_SET_MEM_CTX(ndr
, r
->info501
, 0);
5600 NDR_CHECK(ndr_pull_srvsvc_NetShareInfo501(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->info501
));
5601 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_info501_0
, 0);
5607 _mem_save_info502_0
= NDR_PULL_GET_MEM_CTX(ndr
);
5608 NDR_PULL_SET_MEM_CTX(ndr
, r
->info502
, 0);
5609 NDR_CHECK(ndr_pull_srvsvc_NetShareInfo502(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->info502
));
5610 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_info502_0
, 0);
5616 _mem_save_info1004_0
= NDR_PULL_GET_MEM_CTX(ndr
);
5617 NDR_PULL_SET_MEM_CTX(ndr
, r
->info1004
, 0);
5618 NDR_CHECK(ndr_pull_srvsvc_NetShareInfo1004(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->info1004
));
5619 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_info1004_0
, 0);
5625 _mem_save_info1005_0
= NDR_PULL_GET_MEM_CTX(ndr
);
5626 NDR_PULL_SET_MEM_CTX(ndr
, r
->info1005
, 0);
5627 NDR_CHECK(ndr_pull_srvsvc_NetShareInfo1005(ndr
, NDR_SCALARS
, r
->info1005
));
5628 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_info1005_0
, 0);
5634 _mem_save_info1006_0
= NDR_PULL_GET_MEM_CTX(ndr
);
5635 NDR_PULL_SET_MEM_CTX(ndr
, r
->info1006
, 0);
5636 NDR_CHECK(ndr_pull_srvsvc_NetShareInfo1006(ndr
, NDR_SCALARS
, r
->info1006
));
5637 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_info1006_0
, 0);
5643 _mem_save_info1007_0
= NDR_PULL_GET_MEM_CTX(ndr
);
5644 NDR_PULL_SET_MEM_CTX(ndr
, r
->info1007
, 0);
5645 NDR_CHECK(ndr_pull_srvsvc_NetShareInfo1007(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->info1007
));
5646 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_info1007_0
, 0);
5652 _mem_save_info1501_0
= NDR_PULL_GET_MEM_CTX(ndr
);
5653 NDR_PULL_SET_MEM_CTX(ndr
, r
->info1501
, 0);
5654 NDR_CHECK(ndr_pull_sec_desc_buf(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->info1501
));
5655 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_info1501_0
, 0);
5664 return NDR_ERR_SUCCESS
;
5667 _PUBLIC_
void ndr_print_srvsvc_NetShareInfo(struct ndr_print
*ndr
, const char *name
, const union srvsvc_NetShareInfo
*r
)
5670 level
= ndr_print_get_switch_value(ndr
, r
);
5671 ndr_print_union(ndr
, name
, level
, "srvsvc_NetShareInfo");
5674 ndr_print_ptr(ndr
, "info0", r
->info0
);
5677 ndr_print_srvsvc_NetShareInfo0(ndr
, "info0", r
->info0
);
5683 ndr_print_ptr(ndr
, "info1", r
->info1
);
5686 ndr_print_srvsvc_NetShareInfo1(ndr
, "info1", r
->info1
);
5692 ndr_print_ptr(ndr
, "info2", r
->info2
);
5695 ndr_print_srvsvc_NetShareInfo2(ndr
, "info2", r
->info2
);
5701 ndr_print_ptr(ndr
, "info501", r
->info501
);
5704 ndr_print_srvsvc_NetShareInfo501(ndr
, "info501", r
->info501
);
5710 ndr_print_ptr(ndr
, "info502", r
->info502
);
5713 ndr_print_srvsvc_NetShareInfo502(ndr
, "info502", r
->info502
);
5719 ndr_print_ptr(ndr
, "info1004", r
->info1004
);
5722 ndr_print_srvsvc_NetShareInfo1004(ndr
, "info1004", r
->info1004
);
5728 ndr_print_ptr(ndr
, "info1005", r
->info1005
);
5731 ndr_print_srvsvc_NetShareInfo1005(ndr
, "info1005", r
->info1005
);
5737 ndr_print_ptr(ndr
, "info1006", r
->info1006
);
5740 ndr_print_srvsvc_NetShareInfo1006(ndr
, "info1006", r
->info1006
);
5746 ndr_print_ptr(ndr
, "info1007", r
->info1007
);
5749 ndr_print_srvsvc_NetShareInfo1007(ndr
, "info1007", r
->info1007
);
5755 ndr_print_ptr(ndr
, "info1501", r
->info1501
);
5758 ndr_print_sec_desc_buf(ndr
, "info1501", r
->info1501
);
5769 static enum ndr_err_code
ndr_push_srvsvc_NetShareCtr(struct ndr_push
*ndr
, int ndr_flags
, const union srvsvc_NetShareCtr
*r
)
5771 if (ndr_flags
& NDR_SCALARS
) {
5772 int level
= ndr_push_get_switch_value(ndr
, r
);
5773 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, level
));
5776 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->ctr0
));
5780 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->ctr1
));
5784 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->ctr2
));
5788 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->ctr501
));
5792 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->ctr502
));
5796 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->ctr1004
));
5800 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->ctr1005
));
5804 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->ctr1006
));
5808 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->ctr1007
));
5812 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->ctr1501
));
5820 if (ndr_flags
& NDR_BUFFERS
) {
5821 int level
= ndr_push_get_switch_value(ndr
, r
);
5825 NDR_CHECK(ndr_push_srvsvc_NetShareCtr0(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->ctr0
));
5831 NDR_CHECK(ndr_push_srvsvc_NetShareCtr1(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->ctr1
));
5837 NDR_CHECK(ndr_push_srvsvc_NetShareCtr2(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->ctr2
));
5843 NDR_CHECK(ndr_push_srvsvc_NetShareCtr501(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->ctr501
));
5849 NDR_CHECK(ndr_push_srvsvc_NetShareCtr502(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->ctr502
));
5855 NDR_CHECK(ndr_push_srvsvc_NetShareCtr1004(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->ctr1004
));
5861 NDR_CHECK(ndr_push_srvsvc_NetShareCtr1005(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->ctr1005
));
5867 NDR_CHECK(ndr_push_srvsvc_NetShareCtr1006(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->ctr1006
));
5873 NDR_CHECK(ndr_push_srvsvc_NetShareCtr1007(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->ctr1007
));
5879 NDR_CHECK(ndr_push_srvsvc_NetShareCtr1501(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->ctr1501
));
5888 return NDR_ERR_SUCCESS
;
5891 static enum ndr_err_code
ndr_pull_srvsvc_NetShareCtr(struct ndr_pull
*ndr
, int ndr_flags
, union srvsvc_NetShareCtr
*r
)
5895 TALLOC_CTX
*_mem_save_ctr0_0
;
5896 TALLOC_CTX
*_mem_save_ctr1_0
;
5897 TALLOC_CTX
*_mem_save_ctr2_0
;
5898 TALLOC_CTX
*_mem_save_ctr501_0
;
5899 TALLOC_CTX
*_mem_save_ctr502_0
;
5900 TALLOC_CTX
*_mem_save_ctr1004_0
;
5901 TALLOC_CTX
*_mem_save_ctr1005_0
;
5902 TALLOC_CTX
*_mem_save_ctr1006_0
;
5903 TALLOC_CTX
*_mem_save_ctr1007_0
;
5904 TALLOC_CTX
*_mem_save_ctr1501_0
;
5905 level
= ndr_pull_get_switch_value(ndr
, r
);
5906 if (ndr_flags
& NDR_SCALARS
) {
5907 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &_level
));
5908 if (_level
!= level
) {
5909 return ndr_pull_error(ndr
, NDR_ERR_BAD_SWITCH
, "Bad switch value %u for r", _level
);
5914 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_ctr0
));
5916 NDR_PULL_ALLOC(ndr
, r
->ctr0
);
5924 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_ctr1
));
5926 NDR_PULL_ALLOC(ndr
, r
->ctr1
);
5934 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_ctr2
));
5936 NDR_PULL_ALLOC(ndr
, r
->ctr2
);
5943 uint32_t _ptr_ctr501
;
5944 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_ctr501
));
5946 NDR_PULL_ALLOC(ndr
, r
->ctr501
);
5953 uint32_t _ptr_ctr502
;
5954 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_ctr502
));
5956 NDR_PULL_ALLOC(ndr
, r
->ctr502
);
5963 uint32_t _ptr_ctr1004
;
5964 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_ctr1004
));
5966 NDR_PULL_ALLOC(ndr
, r
->ctr1004
);
5973 uint32_t _ptr_ctr1005
;
5974 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_ctr1005
));
5976 NDR_PULL_ALLOC(ndr
, r
->ctr1005
);
5983 uint32_t _ptr_ctr1006
;
5984 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_ctr1006
));
5986 NDR_PULL_ALLOC(ndr
, r
->ctr1006
);
5993 uint32_t _ptr_ctr1007
;
5994 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_ctr1007
));
5996 NDR_PULL_ALLOC(ndr
, r
->ctr1007
);
6003 uint32_t _ptr_ctr1501
;
6004 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_ctr1501
));
6006 NDR_PULL_ALLOC(ndr
, r
->ctr1501
);
6017 if (ndr_flags
& NDR_BUFFERS
) {
6021 _mem_save_ctr0_0
= NDR_PULL_GET_MEM_CTX(ndr
);
6022 NDR_PULL_SET_MEM_CTX(ndr
, r
->ctr0
, 0);
6023 NDR_CHECK(ndr_pull_srvsvc_NetShareCtr0(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->ctr0
));
6024 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_ctr0_0
, 0);
6030 _mem_save_ctr1_0
= NDR_PULL_GET_MEM_CTX(ndr
);
6031 NDR_PULL_SET_MEM_CTX(ndr
, r
->ctr1
, 0);
6032 NDR_CHECK(ndr_pull_srvsvc_NetShareCtr1(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->ctr1
));
6033 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_ctr1_0
, 0);
6039 _mem_save_ctr2_0
= NDR_PULL_GET_MEM_CTX(ndr
);
6040 NDR_PULL_SET_MEM_CTX(ndr
, r
->ctr2
, 0);
6041 NDR_CHECK(ndr_pull_srvsvc_NetShareCtr2(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->ctr2
));
6042 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_ctr2_0
, 0);
6048 _mem_save_ctr501_0
= NDR_PULL_GET_MEM_CTX(ndr
);
6049 NDR_PULL_SET_MEM_CTX(ndr
, r
->ctr501
, 0);
6050 NDR_CHECK(ndr_pull_srvsvc_NetShareCtr501(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->ctr501
));
6051 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_ctr501_0
, 0);
6057 _mem_save_ctr502_0
= NDR_PULL_GET_MEM_CTX(ndr
);
6058 NDR_PULL_SET_MEM_CTX(ndr
, r
->ctr502
, 0);
6059 NDR_CHECK(ndr_pull_srvsvc_NetShareCtr502(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->ctr502
));
6060 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_ctr502_0
, 0);
6066 _mem_save_ctr1004_0
= NDR_PULL_GET_MEM_CTX(ndr
);
6067 NDR_PULL_SET_MEM_CTX(ndr
, r
->ctr1004
, 0);
6068 NDR_CHECK(ndr_pull_srvsvc_NetShareCtr1004(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->ctr1004
));
6069 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_ctr1004_0
, 0);
6075 _mem_save_ctr1005_0
= NDR_PULL_GET_MEM_CTX(ndr
);
6076 NDR_PULL_SET_MEM_CTX(ndr
, r
->ctr1005
, 0);
6077 NDR_CHECK(ndr_pull_srvsvc_NetShareCtr1005(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->ctr1005
));
6078 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_ctr1005_0
, 0);
6084 _mem_save_ctr1006_0
= NDR_PULL_GET_MEM_CTX(ndr
);
6085 NDR_PULL_SET_MEM_CTX(ndr
, r
->ctr1006
, 0);
6086 NDR_CHECK(ndr_pull_srvsvc_NetShareCtr1006(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->ctr1006
));
6087 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_ctr1006_0
, 0);
6093 _mem_save_ctr1007_0
= NDR_PULL_GET_MEM_CTX(ndr
);
6094 NDR_PULL_SET_MEM_CTX(ndr
, r
->ctr1007
, 0);
6095 NDR_CHECK(ndr_pull_srvsvc_NetShareCtr1007(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->ctr1007
));
6096 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_ctr1007_0
, 0);
6102 _mem_save_ctr1501_0
= NDR_PULL_GET_MEM_CTX(ndr
);
6103 NDR_PULL_SET_MEM_CTX(ndr
, r
->ctr1501
, 0);
6104 NDR_CHECK(ndr_pull_srvsvc_NetShareCtr1501(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->ctr1501
));
6105 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_ctr1501_0
, 0);
6114 return NDR_ERR_SUCCESS
;
6117 _PUBLIC_
void ndr_print_srvsvc_NetShareCtr(struct ndr_print
*ndr
, const char *name
, const union srvsvc_NetShareCtr
*r
)
6120 level
= ndr_print_get_switch_value(ndr
, r
);
6121 ndr_print_union(ndr
, name
, level
, "srvsvc_NetShareCtr");
6124 ndr_print_ptr(ndr
, "ctr0", r
->ctr0
);
6127 ndr_print_srvsvc_NetShareCtr0(ndr
, "ctr0", r
->ctr0
);
6133 ndr_print_ptr(ndr
, "ctr1", r
->ctr1
);
6136 ndr_print_srvsvc_NetShareCtr1(ndr
, "ctr1", r
->ctr1
);
6142 ndr_print_ptr(ndr
, "ctr2", r
->ctr2
);
6145 ndr_print_srvsvc_NetShareCtr2(ndr
, "ctr2", r
->ctr2
);
6151 ndr_print_ptr(ndr
, "ctr501", r
->ctr501
);
6154 ndr_print_srvsvc_NetShareCtr501(ndr
, "ctr501", r
->ctr501
);
6160 ndr_print_ptr(ndr
, "ctr502", r
->ctr502
);
6163 ndr_print_srvsvc_NetShareCtr502(ndr
, "ctr502", r
->ctr502
);
6169 ndr_print_ptr(ndr
, "ctr1004", r
->ctr1004
);
6172 ndr_print_srvsvc_NetShareCtr1004(ndr
, "ctr1004", r
->ctr1004
);
6178 ndr_print_ptr(ndr
, "ctr1005", r
->ctr1005
);
6181 ndr_print_srvsvc_NetShareCtr1005(ndr
, "ctr1005", r
->ctr1005
);
6187 ndr_print_ptr(ndr
, "ctr1006", r
->ctr1006
);
6190 ndr_print_srvsvc_NetShareCtr1006(ndr
, "ctr1006", r
->ctr1006
);
6196 ndr_print_ptr(ndr
, "ctr1007", r
->ctr1007
);
6199 ndr_print_srvsvc_NetShareCtr1007(ndr
, "ctr1007", r
->ctr1007
);
6205 ndr_print_ptr(ndr
, "ctr1501", r
->ctr1501
);
6208 ndr_print_srvsvc_NetShareCtr1501(ndr
, "ctr1501", r
->ctr1501
);
6219 static enum ndr_err_code
ndr_push_srvsvc_NetShareInfoCtr(struct ndr_push
*ndr
, int ndr_flags
, const struct srvsvc_NetShareInfoCtr
*r
)
6221 if (ndr_flags
& NDR_SCALARS
) {
6222 NDR_CHECK(ndr_push_align(ndr
, 4));
6223 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->level
));
6224 NDR_CHECK(ndr_push_set_switch_value(ndr
, &r
->ctr
, r
->level
));
6225 NDR_CHECK(ndr_push_srvsvc_NetShareCtr(ndr
, NDR_SCALARS
, &r
->ctr
));
6227 if (ndr_flags
& NDR_BUFFERS
) {
6228 NDR_CHECK(ndr_push_srvsvc_NetShareCtr(ndr
, NDR_BUFFERS
, &r
->ctr
));
6230 return NDR_ERR_SUCCESS
;
6233 static enum ndr_err_code
ndr_pull_srvsvc_NetShareInfoCtr(struct ndr_pull
*ndr
, int ndr_flags
, struct srvsvc_NetShareInfoCtr
*r
)
6235 if (ndr_flags
& NDR_SCALARS
) {
6236 NDR_CHECK(ndr_pull_align(ndr
, 4));
6237 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->level
));
6238 NDR_CHECK(ndr_pull_set_switch_value(ndr
, &r
->ctr
, r
->level
));
6239 NDR_CHECK(ndr_pull_srvsvc_NetShareCtr(ndr
, NDR_SCALARS
, &r
->ctr
));
6241 if (ndr_flags
& NDR_BUFFERS
) {
6242 NDR_CHECK(ndr_pull_srvsvc_NetShareCtr(ndr
, NDR_BUFFERS
, &r
->ctr
));
6244 return NDR_ERR_SUCCESS
;
6247 _PUBLIC_
void ndr_print_srvsvc_NetShareInfoCtr(struct ndr_print
*ndr
, const char *name
, const struct srvsvc_NetShareInfoCtr
*r
)
6249 ndr_print_struct(ndr
, name
, "srvsvc_NetShareInfoCtr");
6251 ndr_print_uint32(ndr
, "level", r
->level
);
6252 ndr_print_set_switch_value(ndr
, &r
->ctr
, r
->level
);
6253 ndr_print_srvsvc_NetShareCtr(ndr
, "ctr", &r
->ctr
);
6257 _PUBLIC_
enum ndr_err_code
ndr_push_srvsvc_PlatformId(struct ndr_push
*ndr
, int ndr_flags
, enum srvsvc_PlatformId r
)
6259 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
));
6260 return NDR_ERR_SUCCESS
;
6263 _PUBLIC_
enum ndr_err_code
ndr_pull_srvsvc_PlatformId(struct ndr_pull
*ndr
, int ndr_flags
, enum srvsvc_PlatformId
*r
)
6266 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &v
));
6268 return NDR_ERR_SUCCESS
;
6271 _PUBLIC_
void ndr_print_srvsvc_PlatformId(struct ndr_print
*ndr
, const char *name
, enum srvsvc_PlatformId r
)
6273 const char *val
= NULL
;
6276 case PLATFORM_ID_DOS
: val
= "PLATFORM_ID_DOS"; break;
6277 case PLATFORM_ID_OS2
: val
= "PLATFORM_ID_OS2"; break;
6278 case PLATFORM_ID_NT
: val
= "PLATFORM_ID_NT"; break;
6279 case PLATFORM_ID_OSF
: val
= "PLATFORM_ID_OSF"; break;
6280 case PLATFORM_ID_VMS
: val
= "PLATFORM_ID_VMS"; break;
6282 ndr_print_enum(ndr
, name
, "ENUM", val
, r
);
6285 static enum ndr_err_code
ndr_push_srvsvc_NetSrvInfo100(struct ndr_push
*ndr
, int ndr_flags
, const struct srvsvc_NetSrvInfo100
*r
)
6287 if (ndr_flags
& NDR_SCALARS
) {
6288 NDR_CHECK(ndr_push_align(ndr
, 4));
6289 NDR_CHECK(ndr_push_srvsvc_PlatformId(ndr
, NDR_SCALARS
, r
->platform_id
));
6290 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->server_name
));
6292 if (ndr_flags
& NDR_BUFFERS
) {
6293 if (r
->server_name
) {
6294 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->server_name
, CH_UTF16
)));
6295 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
6296 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->server_name
, CH_UTF16
)));
6297 NDR_CHECK(ndr_push_charset(ndr
, NDR_SCALARS
, r
->server_name
, ndr_charset_length(r
->server_name
, CH_UTF16
), sizeof(uint16_t), CH_UTF16
));
6300 return NDR_ERR_SUCCESS
;
6303 static enum ndr_err_code
ndr_pull_srvsvc_NetSrvInfo100(struct ndr_pull
*ndr
, int ndr_flags
, struct srvsvc_NetSrvInfo100
*r
)
6305 uint32_t _ptr_server_name
;
6306 TALLOC_CTX
*_mem_save_server_name_0
;
6307 if (ndr_flags
& NDR_SCALARS
) {
6308 NDR_CHECK(ndr_pull_align(ndr
, 4));
6309 NDR_CHECK(ndr_pull_srvsvc_PlatformId(ndr
, NDR_SCALARS
, &r
->platform_id
));
6310 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_server_name
));
6311 if (_ptr_server_name
) {
6312 NDR_PULL_ALLOC(ndr
, r
->server_name
);
6314 r
->server_name
= NULL
;
6317 if (ndr_flags
& NDR_BUFFERS
) {
6318 if (r
->server_name
) {
6319 _mem_save_server_name_0
= NDR_PULL_GET_MEM_CTX(ndr
);
6320 NDR_PULL_SET_MEM_CTX(ndr
, r
->server_name
, 0);
6321 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->server_name
));
6322 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->server_name
));
6323 if (ndr_get_array_length(ndr
, &r
->server_name
) > ndr_get_array_size(ndr
, &r
->server_name
)) {
6324 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", ndr_get_array_size(ndr
, &r
->server_name
), ndr_get_array_length(ndr
, &r
->server_name
));
6326 NDR_CHECK(ndr_check_string_terminator(ndr
, ndr_get_array_length(ndr
, &r
->server_name
), sizeof(uint16_t)));
6327 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->server_name
, ndr_get_array_length(ndr
, &r
->server_name
), sizeof(uint16_t), CH_UTF16
));
6328 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_server_name_0
, 0);
6331 return NDR_ERR_SUCCESS
;
6334 _PUBLIC_
void ndr_print_srvsvc_NetSrvInfo100(struct ndr_print
*ndr
, const char *name
, const struct srvsvc_NetSrvInfo100
*r
)
6336 ndr_print_struct(ndr
, name
, "srvsvc_NetSrvInfo100");
6338 ndr_print_srvsvc_PlatformId(ndr
, "platform_id", r
->platform_id
);
6339 ndr_print_ptr(ndr
, "server_name", r
->server_name
);
6341 if (r
->server_name
) {
6342 ndr_print_string(ndr
, "server_name", r
->server_name
);
6348 static enum ndr_err_code
ndr_push_srvsvc_NetSrvInfo101(struct ndr_push
*ndr
, int ndr_flags
, const struct srvsvc_NetSrvInfo101
*r
)
6350 if (ndr_flags
& NDR_SCALARS
) {
6351 NDR_CHECK(ndr_push_align(ndr
, 4));
6352 NDR_CHECK(ndr_push_srvsvc_PlatformId(ndr
, NDR_SCALARS
, r
->platform_id
));
6353 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->server_name
));
6354 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->version_major
));
6355 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->version_minor
));
6356 NDR_CHECK(ndr_push_svcctl_ServerType(ndr
, NDR_SCALARS
, r
->server_type
));
6357 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->comment
));
6359 if (ndr_flags
& NDR_BUFFERS
) {
6360 if (r
->server_name
) {
6361 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->server_name
, CH_UTF16
)));
6362 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
6363 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->server_name
, CH_UTF16
)));
6364 NDR_CHECK(ndr_push_charset(ndr
, NDR_SCALARS
, r
->server_name
, ndr_charset_length(r
->server_name
, CH_UTF16
), sizeof(uint16_t), CH_UTF16
));
6367 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->comment
, CH_UTF16
)));
6368 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
6369 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->comment
, CH_UTF16
)));
6370 NDR_CHECK(ndr_push_charset(ndr
, NDR_SCALARS
, r
->comment
, ndr_charset_length(r
->comment
, CH_UTF16
), sizeof(uint16_t), CH_UTF16
));
6373 return NDR_ERR_SUCCESS
;
6376 static enum ndr_err_code
ndr_pull_srvsvc_NetSrvInfo101(struct ndr_pull
*ndr
, int ndr_flags
, struct srvsvc_NetSrvInfo101
*r
)
6378 uint32_t _ptr_server_name
;
6379 TALLOC_CTX
*_mem_save_server_name_0
;
6380 uint32_t _ptr_comment
;
6381 TALLOC_CTX
*_mem_save_comment_0
;
6382 if (ndr_flags
& NDR_SCALARS
) {
6383 NDR_CHECK(ndr_pull_align(ndr
, 4));
6384 NDR_CHECK(ndr_pull_srvsvc_PlatformId(ndr
, NDR_SCALARS
, &r
->platform_id
));
6385 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_server_name
));
6386 if (_ptr_server_name
) {
6387 NDR_PULL_ALLOC(ndr
, r
->server_name
);
6389 r
->server_name
= NULL
;
6391 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->version_major
));
6392 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->version_minor
));
6393 NDR_CHECK(ndr_pull_svcctl_ServerType(ndr
, NDR_SCALARS
, &r
->server_type
));
6394 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_comment
));
6396 NDR_PULL_ALLOC(ndr
, r
->comment
);
6401 if (ndr_flags
& NDR_BUFFERS
) {
6402 if (r
->server_name
) {
6403 _mem_save_server_name_0
= NDR_PULL_GET_MEM_CTX(ndr
);
6404 NDR_PULL_SET_MEM_CTX(ndr
, r
->server_name
, 0);
6405 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->server_name
));
6406 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->server_name
));
6407 if (ndr_get_array_length(ndr
, &r
->server_name
) > ndr_get_array_size(ndr
, &r
->server_name
)) {
6408 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", ndr_get_array_size(ndr
, &r
->server_name
), ndr_get_array_length(ndr
, &r
->server_name
));
6410 NDR_CHECK(ndr_check_string_terminator(ndr
, ndr_get_array_length(ndr
, &r
->server_name
), sizeof(uint16_t)));
6411 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->server_name
, ndr_get_array_length(ndr
, &r
->server_name
), sizeof(uint16_t), CH_UTF16
));
6412 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_server_name_0
, 0);
6415 _mem_save_comment_0
= NDR_PULL_GET_MEM_CTX(ndr
);
6416 NDR_PULL_SET_MEM_CTX(ndr
, r
->comment
, 0);
6417 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->comment
));
6418 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->comment
));
6419 if (ndr_get_array_length(ndr
, &r
->comment
) > ndr_get_array_size(ndr
, &r
->comment
)) {
6420 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", ndr_get_array_size(ndr
, &r
->comment
), ndr_get_array_length(ndr
, &r
->comment
));
6422 NDR_CHECK(ndr_check_string_terminator(ndr
, ndr_get_array_length(ndr
, &r
->comment
), sizeof(uint16_t)));
6423 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->comment
, ndr_get_array_length(ndr
, &r
->comment
), sizeof(uint16_t), CH_UTF16
));
6424 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_comment_0
, 0);
6427 return NDR_ERR_SUCCESS
;
6430 _PUBLIC_
void ndr_print_srvsvc_NetSrvInfo101(struct ndr_print
*ndr
, const char *name
, const struct srvsvc_NetSrvInfo101
*r
)
6432 ndr_print_struct(ndr
, name
, "srvsvc_NetSrvInfo101");
6434 ndr_print_srvsvc_PlatformId(ndr
, "platform_id", r
->platform_id
);
6435 ndr_print_ptr(ndr
, "server_name", r
->server_name
);
6437 if (r
->server_name
) {
6438 ndr_print_string(ndr
, "server_name", r
->server_name
);
6441 ndr_print_uint32(ndr
, "version_major", r
->version_major
);
6442 ndr_print_uint32(ndr
, "version_minor", r
->version_minor
);
6443 ndr_print_svcctl_ServerType(ndr
, "server_type", r
->server_type
);
6444 ndr_print_ptr(ndr
, "comment", r
->comment
);
6447 ndr_print_string(ndr
, "comment", r
->comment
);
6453 static enum ndr_err_code
ndr_push_srvsvc_NetSrvInfo102(struct ndr_push
*ndr
, int ndr_flags
, const struct srvsvc_NetSrvInfo102
*r
)
6455 if (ndr_flags
& NDR_SCALARS
) {
6456 NDR_CHECK(ndr_push_align(ndr
, 4));
6457 NDR_CHECK(ndr_push_srvsvc_PlatformId(ndr
, NDR_SCALARS
, r
->platform_id
));
6458 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->server_name
));
6459 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->version_major
));
6460 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->version_minor
));
6461 NDR_CHECK(ndr_push_svcctl_ServerType(ndr
, NDR_SCALARS
, r
->server_type
));
6462 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->comment
));
6463 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->users
));
6464 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->disc
));
6465 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->hidden
));
6466 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->announce
));
6467 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->anndelta
));
6468 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->licenses
));
6469 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->userpath
));
6471 if (ndr_flags
& NDR_BUFFERS
) {
6472 if (r
->server_name
) {
6473 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->server_name
, CH_UTF16
)));
6474 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
6475 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->server_name
, CH_UTF16
)));
6476 NDR_CHECK(ndr_push_charset(ndr
, NDR_SCALARS
, r
->server_name
, ndr_charset_length(r
->server_name
, CH_UTF16
), sizeof(uint16_t), CH_UTF16
));
6479 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->comment
, CH_UTF16
)));
6480 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
6481 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->comment
, CH_UTF16
)));
6482 NDR_CHECK(ndr_push_charset(ndr
, NDR_SCALARS
, r
->comment
, ndr_charset_length(r
->comment
, CH_UTF16
), sizeof(uint16_t), CH_UTF16
));
6485 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->userpath
, CH_UTF16
)));
6486 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
6487 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->userpath
, CH_UTF16
)));
6488 NDR_CHECK(ndr_push_charset(ndr
, NDR_SCALARS
, r
->userpath
, ndr_charset_length(r
->userpath
, CH_UTF16
), sizeof(uint16_t), CH_UTF16
));
6491 return NDR_ERR_SUCCESS
;
6494 static enum ndr_err_code
ndr_pull_srvsvc_NetSrvInfo102(struct ndr_pull
*ndr
, int ndr_flags
, struct srvsvc_NetSrvInfo102
*r
)
6496 uint32_t _ptr_server_name
;
6497 TALLOC_CTX
*_mem_save_server_name_0
;
6498 uint32_t _ptr_comment
;
6499 TALLOC_CTX
*_mem_save_comment_0
;
6500 uint32_t _ptr_userpath
;
6501 TALLOC_CTX
*_mem_save_userpath_0
;
6502 if (ndr_flags
& NDR_SCALARS
) {
6503 NDR_CHECK(ndr_pull_align(ndr
, 4));
6504 NDR_CHECK(ndr_pull_srvsvc_PlatformId(ndr
, NDR_SCALARS
, &r
->platform_id
));
6505 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_server_name
));
6506 if (_ptr_server_name
) {
6507 NDR_PULL_ALLOC(ndr
, r
->server_name
);
6509 r
->server_name
= NULL
;
6511 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->version_major
));
6512 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->version_minor
));
6513 NDR_CHECK(ndr_pull_svcctl_ServerType(ndr
, NDR_SCALARS
, &r
->server_type
));
6514 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_comment
));
6516 NDR_PULL_ALLOC(ndr
, r
->comment
);
6520 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->users
));
6521 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->disc
));
6522 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->hidden
));
6523 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->announce
));
6524 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->anndelta
));
6525 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->licenses
));
6526 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_userpath
));
6527 if (_ptr_userpath
) {
6528 NDR_PULL_ALLOC(ndr
, r
->userpath
);
6533 if (ndr_flags
& NDR_BUFFERS
) {
6534 if (r
->server_name
) {
6535 _mem_save_server_name_0
= NDR_PULL_GET_MEM_CTX(ndr
);
6536 NDR_PULL_SET_MEM_CTX(ndr
, r
->server_name
, 0);
6537 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->server_name
));
6538 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->server_name
));
6539 if (ndr_get_array_length(ndr
, &r
->server_name
) > ndr_get_array_size(ndr
, &r
->server_name
)) {
6540 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", ndr_get_array_size(ndr
, &r
->server_name
), ndr_get_array_length(ndr
, &r
->server_name
));
6542 NDR_CHECK(ndr_check_string_terminator(ndr
, ndr_get_array_length(ndr
, &r
->server_name
), sizeof(uint16_t)));
6543 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->server_name
, ndr_get_array_length(ndr
, &r
->server_name
), sizeof(uint16_t), CH_UTF16
));
6544 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_server_name_0
, 0);
6547 _mem_save_comment_0
= NDR_PULL_GET_MEM_CTX(ndr
);
6548 NDR_PULL_SET_MEM_CTX(ndr
, r
->comment
, 0);
6549 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->comment
));
6550 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->comment
));
6551 if (ndr_get_array_length(ndr
, &r
->comment
) > ndr_get_array_size(ndr
, &r
->comment
)) {
6552 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", ndr_get_array_size(ndr
, &r
->comment
), ndr_get_array_length(ndr
, &r
->comment
));
6554 NDR_CHECK(ndr_check_string_terminator(ndr
, ndr_get_array_length(ndr
, &r
->comment
), sizeof(uint16_t)));
6555 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->comment
, ndr_get_array_length(ndr
, &r
->comment
), sizeof(uint16_t), CH_UTF16
));
6556 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_comment_0
, 0);
6559 _mem_save_userpath_0
= NDR_PULL_GET_MEM_CTX(ndr
);
6560 NDR_PULL_SET_MEM_CTX(ndr
, r
->userpath
, 0);
6561 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->userpath
));
6562 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->userpath
));
6563 if (ndr_get_array_length(ndr
, &r
->userpath
) > ndr_get_array_size(ndr
, &r
->userpath
)) {
6564 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", ndr_get_array_size(ndr
, &r
->userpath
), ndr_get_array_length(ndr
, &r
->userpath
));
6566 NDR_CHECK(ndr_check_string_terminator(ndr
, ndr_get_array_length(ndr
, &r
->userpath
), sizeof(uint16_t)));
6567 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->userpath
, ndr_get_array_length(ndr
, &r
->userpath
), sizeof(uint16_t), CH_UTF16
));
6568 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_userpath_0
, 0);
6571 return NDR_ERR_SUCCESS
;
6574 _PUBLIC_
void ndr_print_srvsvc_NetSrvInfo102(struct ndr_print
*ndr
, const char *name
, const struct srvsvc_NetSrvInfo102
*r
)
6576 ndr_print_struct(ndr
, name
, "srvsvc_NetSrvInfo102");
6578 ndr_print_srvsvc_PlatformId(ndr
, "platform_id", r
->platform_id
);
6579 ndr_print_ptr(ndr
, "server_name", r
->server_name
);
6581 if (r
->server_name
) {
6582 ndr_print_string(ndr
, "server_name", r
->server_name
);
6585 ndr_print_uint32(ndr
, "version_major", r
->version_major
);
6586 ndr_print_uint32(ndr
, "version_minor", r
->version_minor
);
6587 ndr_print_svcctl_ServerType(ndr
, "server_type", r
->server_type
);
6588 ndr_print_ptr(ndr
, "comment", r
->comment
);
6591 ndr_print_string(ndr
, "comment", r
->comment
);
6594 ndr_print_uint32(ndr
, "users", r
->users
);
6595 ndr_print_uint32(ndr
, "disc", r
->disc
);
6596 ndr_print_uint32(ndr
, "hidden", r
->hidden
);
6597 ndr_print_uint32(ndr
, "announce", r
->announce
);
6598 ndr_print_uint32(ndr
, "anndelta", r
->anndelta
);
6599 ndr_print_uint32(ndr
, "licenses", r
->licenses
);
6600 ndr_print_ptr(ndr
, "userpath", r
->userpath
);
6603 ndr_print_string(ndr
, "userpath", r
->userpath
);
6609 static enum ndr_err_code
ndr_push_srvsvc_NetSrvInfo402(struct ndr_push
*ndr
, int ndr_flags
, const struct srvsvc_NetSrvInfo402
*r
)
6611 if (ndr_flags
& NDR_SCALARS
) {
6612 NDR_CHECK(ndr_push_align(ndr
, 4));
6613 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->ulist_mtime
));
6614 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->glist_mtime
));
6615 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->alist_mtime
));
6616 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->alerts
));
6617 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->security
));
6618 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->numadmin
));
6619 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->lanmask
));
6620 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->guestaccount
));
6621 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->chdevs
));
6622 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->chdevqs
));
6623 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->chdevjobs
));
6624 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->connections
));
6625 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->shares
));
6626 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->openfiles
));
6627 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->sessopen
));
6628 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->sesssvc
));
6629 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->sessreqs
));
6630 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->opensearch
));
6631 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->activelocks
));
6632 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->sizereqbufs
));
6633 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->numbigbufs
));
6634 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->numfiletasks
));
6635 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->alertsched
));
6636 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->erroralert
));
6637 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->logonalert
));
6638 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->accessalert
));
6639 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->diskalert
));
6640 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->netioalert
));
6641 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->maxaudits
));
6642 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->srvheuristics
));
6644 if (ndr_flags
& NDR_BUFFERS
) {
6646 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->alerts
, CH_UTF16
)));
6647 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
6648 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->alerts
, CH_UTF16
)));
6649 NDR_CHECK(ndr_push_charset(ndr
, NDR_SCALARS
, r
->alerts
, ndr_charset_length(r
->alerts
, CH_UTF16
), sizeof(uint16_t), CH_UTF16
));
6651 if (r
->guestaccount
) {
6652 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->guestaccount
, CH_UTF16
)));
6653 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
6654 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->guestaccount
, CH_UTF16
)));
6655 NDR_CHECK(ndr_push_charset(ndr
, NDR_SCALARS
, r
->guestaccount
, ndr_charset_length(r
->guestaccount
, CH_UTF16
), sizeof(uint16_t), CH_UTF16
));
6657 if (r
->srvheuristics
) {
6658 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->srvheuristics
, CH_UTF16
)));
6659 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
6660 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->srvheuristics
, CH_UTF16
)));
6661 NDR_CHECK(ndr_push_charset(ndr
, NDR_SCALARS
, r
->srvheuristics
, ndr_charset_length(r
->srvheuristics
, CH_UTF16
), sizeof(uint16_t), CH_UTF16
));
6664 return NDR_ERR_SUCCESS
;
6667 static enum ndr_err_code
ndr_pull_srvsvc_NetSrvInfo402(struct ndr_pull
*ndr
, int ndr_flags
, struct srvsvc_NetSrvInfo402
*r
)
6669 uint32_t _ptr_alerts
;
6670 TALLOC_CTX
*_mem_save_alerts_0
;
6671 uint32_t _ptr_guestaccount
;
6672 TALLOC_CTX
*_mem_save_guestaccount_0
;
6673 uint32_t _ptr_srvheuristics
;
6674 TALLOC_CTX
*_mem_save_srvheuristics_0
;
6675 if (ndr_flags
& NDR_SCALARS
) {
6676 NDR_CHECK(ndr_pull_align(ndr
, 4));
6677 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->ulist_mtime
));
6678 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->glist_mtime
));
6679 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->alist_mtime
));
6680 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_alerts
));
6682 NDR_PULL_ALLOC(ndr
, r
->alerts
);
6686 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->security
));
6687 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->numadmin
));
6688 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->lanmask
));
6689 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_guestaccount
));
6690 if (_ptr_guestaccount
) {
6691 NDR_PULL_ALLOC(ndr
, r
->guestaccount
);
6693 r
->guestaccount
= NULL
;
6695 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->chdevs
));
6696 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->chdevqs
));
6697 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->chdevjobs
));
6698 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->connections
));
6699 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->shares
));
6700 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->openfiles
));
6701 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->sessopen
));
6702 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->sesssvc
));
6703 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->sessreqs
));
6704 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->opensearch
));
6705 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->activelocks
));
6706 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->sizereqbufs
));
6707 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->numbigbufs
));
6708 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->numfiletasks
));
6709 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->alertsched
));
6710 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->erroralert
));
6711 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->logonalert
));
6712 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->accessalert
));
6713 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->diskalert
));
6714 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->netioalert
));
6715 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->maxaudits
));
6716 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_srvheuristics
));
6717 if (_ptr_srvheuristics
) {
6718 NDR_PULL_ALLOC(ndr
, r
->srvheuristics
);
6720 r
->srvheuristics
= NULL
;
6723 if (ndr_flags
& NDR_BUFFERS
) {
6725 _mem_save_alerts_0
= NDR_PULL_GET_MEM_CTX(ndr
);
6726 NDR_PULL_SET_MEM_CTX(ndr
, r
->alerts
, 0);
6727 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->alerts
));
6728 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->alerts
));
6729 if (ndr_get_array_length(ndr
, &r
->alerts
) > ndr_get_array_size(ndr
, &r
->alerts
)) {
6730 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", ndr_get_array_size(ndr
, &r
->alerts
), ndr_get_array_length(ndr
, &r
->alerts
));
6732 NDR_CHECK(ndr_check_string_terminator(ndr
, ndr_get_array_length(ndr
, &r
->alerts
), sizeof(uint16_t)));
6733 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->alerts
, ndr_get_array_length(ndr
, &r
->alerts
), sizeof(uint16_t), CH_UTF16
));
6734 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_alerts_0
, 0);
6736 if (r
->guestaccount
) {
6737 _mem_save_guestaccount_0
= NDR_PULL_GET_MEM_CTX(ndr
);
6738 NDR_PULL_SET_MEM_CTX(ndr
, r
->guestaccount
, 0);
6739 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->guestaccount
));
6740 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->guestaccount
));
6741 if (ndr_get_array_length(ndr
, &r
->guestaccount
) > ndr_get_array_size(ndr
, &r
->guestaccount
)) {
6742 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", ndr_get_array_size(ndr
, &r
->guestaccount
), ndr_get_array_length(ndr
, &r
->guestaccount
));
6744 NDR_CHECK(ndr_check_string_terminator(ndr
, ndr_get_array_length(ndr
, &r
->guestaccount
), sizeof(uint16_t)));
6745 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->guestaccount
, ndr_get_array_length(ndr
, &r
->guestaccount
), sizeof(uint16_t), CH_UTF16
));
6746 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_guestaccount_0
, 0);
6748 if (r
->srvheuristics
) {
6749 _mem_save_srvheuristics_0
= NDR_PULL_GET_MEM_CTX(ndr
);
6750 NDR_PULL_SET_MEM_CTX(ndr
, r
->srvheuristics
, 0);
6751 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->srvheuristics
));
6752 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->srvheuristics
));
6753 if (ndr_get_array_length(ndr
, &r
->srvheuristics
) > ndr_get_array_size(ndr
, &r
->srvheuristics
)) {
6754 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", ndr_get_array_size(ndr
, &r
->srvheuristics
), ndr_get_array_length(ndr
, &r
->srvheuristics
));
6756 NDR_CHECK(ndr_check_string_terminator(ndr
, ndr_get_array_length(ndr
, &r
->srvheuristics
), sizeof(uint16_t)));
6757 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->srvheuristics
, ndr_get_array_length(ndr
, &r
->srvheuristics
), sizeof(uint16_t), CH_UTF16
));
6758 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_srvheuristics_0
, 0);
6761 return NDR_ERR_SUCCESS
;
6764 _PUBLIC_
void ndr_print_srvsvc_NetSrvInfo402(struct ndr_print
*ndr
, const char *name
, const struct srvsvc_NetSrvInfo402
*r
)
6766 ndr_print_struct(ndr
, name
, "srvsvc_NetSrvInfo402");
6768 ndr_print_uint32(ndr
, "ulist_mtime", r
->ulist_mtime
);
6769 ndr_print_uint32(ndr
, "glist_mtime", r
->glist_mtime
);
6770 ndr_print_uint32(ndr
, "alist_mtime", r
->alist_mtime
);
6771 ndr_print_ptr(ndr
, "alerts", r
->alerts
);
6774 ndr_print_string(ndr
, "alerts", r
->alerts
);
6777 ndr_print_uint32(ndr
, "security", r
->security
);
6778 ndr_print_uint32(ndr
, "numadmin", r
->numadmin
);
6779 ndr_print_uint32(ndr
, "lanmask", r
->lanmask
);
6780 ndr_print_ptr(ndr
, "guestaccount", r
->guestaccount
);
6782 if (r
->guestaccount
) {
6783 ndr_print_string(ndr
, "guestaccount", r
->guestaccount
);
6786 ndr_print_uint32(ndr
, "chdevs", r
->chdevs
);
6787 ndr_print_uint32(ndr
, "chdevqs", r
->chdevqs
);
6788 ndr_print_uint32(ndr
, "chdevjobs", r
->chdevjobs
);
6789 ndr_print_uint32(ndr
, "connections", r
->connections
);
6790 ndr_print_uint32(ndr
, "shares", r
->shares
);
6791 ndr_print_uint32(ndr
, "openfiles", r
->openfiles
);
6792 ndr_print_uint32(ndr
, "sessopen", r
->sessopen
);
6793 ndr_print_uint32(ndr
, "sesssvc", r
->sesssvc
);
6794 ndr_print_uint32(ndr
, "sessreqs", r
->sessreqs
);
6795 ndr_print_uint32(ndr
, "opensearch", r
->opensearch
);
6796 ndr_print_uint32(ndr
, "activelocks", r
->activelocks
);
6797 ndr_print_uint32(ndr
, "sizereqbufs", r
->sizereqbufs
);
6798 ndr_print_uint32(ndr
, "numbigbufs", r
->numbigbufs
);
6799 ndr_print_uint32(ndr
, "numfiletasks", r
->numfiletasks
);
6800 ndr_print_uint32(ndr
, "alertsched", r
->alertsched
);
6801 ndr_print_uint32(ndr
, "erroralert", r
->erroralert
);
6802 ndr_print_uint32(ndr
, "logonalert", r
->logonalert
);
6803 ndr_print_uint32(ndr
, "accessalert", r
->accessalert
);
6804 ndr_print_uint32(ndr
, "diskalert", r
->diskalert
);
6805 ndr_print_uint32(ndr
, "netioalert", r
->netioalert
);
6806 ndr_print_uint32(ndr
, "maxaudits", r
->maxaudits
);
6807 ndr_print_ptr(ndr
, "srvheuristics", r
->srvheuristics
);
6809 if (r
->srvheuristics
) {
6810 ndr_print_string(ndr
, "srvheuristics", r
->srvheuristics
);
6816 static enum ndr_err_code
ndr_push_srvsvc_NetSrvInfo403(struct ndr_push
*ndr
, int ndr_flags
, const struct srvsvc_NetSrvInfo403
*r
)
6818 if (ndr_flags
& NDR_SCALARS
) {
6819 NDR_CHECK(ndr_push_align(ndr
, 4));
6820 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->ulist_mtime
));
6821 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->glist_mtime
));
6822 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->alist_mtime
));
6823 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->alerts
));
6824 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->security
));
6825 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->numadmin
));
6826 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->lanmask
));
6827 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->guestaccount
));
6828 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->chdevs
));
6829 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->chdevqs
));
6830 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->chdevjobs
));
6831 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->connections
));
6832 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->shares
));
6833 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->openfiles
));
6834 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->sessopen
));
6835 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->sesssvc
));
6836 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->sessreqs
));
6837 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->opensearch
));
6838 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->activelocks
));
6839 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->sizereqbufs
));
6840 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->numbigbufs
));
6841 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->numfiletasks
));
6842 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->alertsched
));
6843 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->eroralert
));
6844 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->logonalert
));
6845 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->accessalert
));
6846 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->diskalert
));
6847 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->netioalert
));
6848 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->maxaudits
));
6849 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->srvheuristics
));
6850 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->auditedevents
));
6851 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->auditprofile
));
6852 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->autopath
));
6854 if (ndr_flags
& NDR_BUFFERS
) {
6856 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->alerts
, CH_UTF16
)));
6857 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
6858 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->alerts
, CH_UTF16
)));
6859 NDR_CHECK(ndr_push_charset(ndr
, NDR_SCALARS
, r
->alerts
, ndr_charset_length(r
->alerts
, CH_UTF16
), sizeof(uint16_t), CH_UTF16
));
6861 if (r
->guestaccount
) {
6862 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->guestaccount
, CH_UTF16
)));
6863 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
6864 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->guestaccount
, CH_UTF16
)));
6865 NDR_CHECK(ndr_push_charset(ndr
, NDR_SCALARS
, r
->guestaccount
, ndr_charset_length(r
->guestaccount
, CH_UTF16
), sizeof(uint16_t), CH_UTF16
));
6867 if (r
->srvheuristics
) {
6868 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->srvheuristics
, CH_UTF16
)));
6869 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
6870 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->srvheuristics
, CH_UTF16
)));
6871 NDR_CHECK(ndr_push_charset(ndr
, NDR_SCALARS
, r
->srvheuristics
, ndr_charset_length(r
->srvheuristics
, CH_UTF16
), sizeof(uint16_t), CH_UTF16
));
6874 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->autopath
, CH_UTF16
)));
6875 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
6876 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->autopath
, CH_UTF16
)));
6877 NDR_CHECK(ndr_push_charset(ndr
, NDR_SCALARS
, r
->autopath
, ndr_charset_length(r
->autopath
, CH_UTF16
), sizeof(uint16_t), CH_UTF16
));
6880 return NDR_ERR_SUCCESS
;
6883 static enum ndr_err_code
ndr_pull_srvsvc_NetSrvInfo403(struct ndr_pull
*ndr
, int ndr_flags
, struct srvsvc_NetSrvInfo403
*r
)
6885 uint32_t _ptr_alerts
;
6886 TALLOC_CTX
*_mem_save_alerts_0
;
6887 uint32_t _ptr_guestaccount
;
6888 TALLOC_CTX
*_mem_save_guestaccount_0
;
6889 uint32_t _ptr_srvheuristics
;
6890 TALLOC_CTX
*_mem_save_srvheuristics_0
;
6891 uint32_t _ptr_autopath
;
6892 TALLOC_CTX
*_mem_save_autopath_0
;
6893 if (ndr_flags
& NDR_SCALARS
) {
6894 NDR_CHECK(ndr_pull_align(ndr
, 4));
6895 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->ulist_mtime
));
6896 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->glist_mtime
));
6897 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->alist_mtime
));
6898 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_alerts
));
6900 NDR_PULL_ALLOC(ndr
, r
->alerts
);
6904 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->security
));
6905 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->numadmin
));
6906 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->lanmask
));
6907 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_guestaccount
));
6908 if (_ptr_guestaccount
) {
6909 NDR_PULL_ALLOC(ndr
, r
->guestaccount
);
6911 r
->guestaccount
= NULL
;
6913 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->chdevs
));
6914 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->chdevqs
));
6915 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->chdevjobs
));
6916 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->connections
));
6917 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->shares
));
6918 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->openfiles
));
6919 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->sessopen
));
6920 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->sesssvc
));
6921 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->sessreqs
));
6922 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->opensearch
));
6923 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->activelocks
));
6924 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->sizereqbufs
));
6925 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->numbigbufs
));
6926 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->numfiletasks
));
6927 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->alertsched
));
6928 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->eroralert
));
6929 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->logonalert
));
6930 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->accessalert
));
6931 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->diskalert
));
6932 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->netioalert
));
6933 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->maxaudits
));
6934 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_srvheuristics
));
6935 if (_ptr_srvheuristics
) {
6936 NDR_PULL_ALLOC(ndr
, r
->srvheuristics
);
6938 r
->srvheuristics
= NULL
;
6940 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->auditedevents
));
6941 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->auditprofile
));
6942 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_autopath
));
6943 if (_ptr_autopath
) {
6944 NDR_PULL_ALLOC(ndr
, r
->autopath
);
6949 if (ndr_flags
& NDR_BUFFERS
) {
6951 _mem_save_alerts_0
= NDR_PULL_GET_MEM_CTX(ndr
);
6952 NDR_PULL_SET_MEM_CTX(ndr
, r
->alerts
, 0);
6953 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->alerts
));
6954 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->alerts
));
6955 if (ndr_get_array_length(ndr
, &r
->alerts
) > ndr_get_array_size(ndr
, &r
->alerts
)) {
6956 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", ndr_get_array_size(ndr
, &r
->alerts
), ndr_get_array_length(ndr
, &r
->alerts
));
6958 NDR_CHECK(ndr_check_string_terminator(ndr
, ndr_get_array_length(ndr
, &r
->alerts
), sizeof(uint16_t)));
6959 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->alerts
, ndr_get_array_length(ndr
, &r
->alerts
), sizeof(uint16_t), CH_UTF16
));
6960 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_alerts_0
, 0);
6962 if (r
->guestaccount
) {
6963 _mem_save_guestaccount_0
= NDR_PULL_GET_MEM_CTX(ndr
);
6964 NDR_PULL_SET_MEM_CTX(ndr
, r
->guestaccount
, 0);
6965 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->guestaccount
));
6966 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->guestaccount
));
6967 if (ndr_get_array_length(ndr
, &r
->guestaccount
) > ndr_get_array_size(ndr
, &r
->guestaccount
)) {
6968 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", ndr_get_array_size(ndr
, &r
->guestaccount
), ndr_get_array_length(ndr
, &r
->guestaccount
));
6970 NDR_CHECK(ndr_check_string_terminator(ndr
, ndr_get_array_length(ndr
, &r
->guestaccount
), sizeof(uint16_t)));
6971 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->guestaccount
, ndr_get_array_length(ndr
, &r
->guestaccount
), sizeof(uint16_t), CH_UTF16
));
6972 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_guestaccount_0
, 0);
6974 if (r
->srvheuristics
) {
6975 _mem_save_srvheuristics_0
= NDR_PULL_GET_MEM_CTX(ndr
);
6976 NDR_PULL_SET_MEM_CTX(ndr
, r
->srvheuristics
, 0);
6977 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->srvheuristics
));
6978 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->srvheuristics
));
6979 if (ndr_get_array_length(ndr
, &r
->srvheuristics
) > ndr_get_array_size(ndr
, &r
->srvheuristics
)) {
6980 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", ndr_get_array_size(ndr
, &r
->srvheuristics
), ndr_get_array_length(ndr
, &r
->srvheuristics
));
6982 NDR_CHECK(ndr_check_string_terminator(ndr
, ndr_get_array_length(ndr
, &r
->srvheuristics
), sizeof(uint16_t)));
6983 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->srvheuristics
, ndr_get_array_length(ndr
, &r
->srvheuristics
), sizeof(uint16_t), CH_UTF16
));
6984 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_srvheuristics_0
, 0);
6987 _mem_save_autopath_0
= NDR_PULL_GET_MEM_CTX(ndr
);
6988 NDR_PULL_SET_MEM_CTX(ndr
, r
->autopath
, 0);
6989 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->autopath
));
6990 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->autopath
));
6991 if (ndr_get_array_length(ndr
, &r
->autopath
) > ndr_get_array_size(ndr
, &r
->autopath
)) {
6992 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", ndr_get_array_size(ndr
, &r
->autopath
), ndr_get_array_length(ndr
, &r
->autopath
));
6994 NDR_CHECK(ndr_check_string_terminator(ndr
, ndr_get_array_length(ndr
, &r
->autopath
), sizeof(uint16_t)));
6995 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->autopath
, ndr_get_array_length(ndr
, &r
->autopath
), sizeof(uint16_t), CH_UTF16
));
6996 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_autopath_0
, 0);
6999 return NDR_ERR_SUCCESS
;
7002 _PUBLIC_
void ndr_print_srvsvc_NetSrvInfo403(struct ndr_print
*ndr
, const char *name
, const struct srvsvc_NetSrvInfo403
*r
)
7004 ndr_print_struct(ndr
, name
, "srvsvc_NetSrvInfo403");
7006 ndr_print_uint32(ndr
, "ulist_mtime", r
->ulist_mtime
);
7007 ndr_print_uint32(ndr
, "glist_mtime", r
->glist_mtime
);
7008 ndr_print_uint32(ndr
, "alist_mtime", r
->alist_mtime
);
7009 ndr_print_ptr(ndr
, "alerts", r
->alerts
);
7012 ndr_print_string(ndr
, "alerts", r
->alerts
);
7015 ndr_print_uint32(ndr
, "security", r
->security
);
7016 ndr_print_uint32(ndr
, "numadmin", r
->numadmin
);
7017 ndr_print_uint32(ndr
, "lanmask", r
->lanmask
);
7018 ndr_print_ptr(ndr
, "guestaccount", r
->guestaccount
);
7020 if (r
->guestaccount
) {
7021 ndr_print_string(ndr
, "guestaccount", r
->guestaccount
);
7024 ndr_print_uint32(ndr
, "chdevs", r
->chdevs
);
7025 ndr_print_uint32(ndr
, "chdevqs", r
->chdevqs
);
7026 ndr_print_uint32(ndr
, "chdevjobs", r
->chdevjobs
);
7027 ndr_print_uint32(ndr
, "connections", r
->connections
);
7028 ndr_print_uint32(ndr
, "shares", r
->shares
);
7029 ndr_print_uint32(ndr
, "openfiles", r
->openfiles
);
7030 ndr_print_uint32(ndr
, "sessopen", r
->sessopen
);
7031 ndr_print_uint32(ndr
, "sesssvc", r
->sesssvc
);
7032 ndr_print_uint32(ndr
, "sessreqs", r
->sessreqs
);
7033 ndr_print_uint32(ndr
, "opensearch", r
->opensearch
);
7034 ndr_print_uint32(ndr
, "activelocks", r
->activelocks
);
7035 ndr_print_uint32(ndr
, "sizereqbufs", r
->sizereqbufs
);
7036 ndr_print_uint32(ndr
, "numbigbufs", r
->numbigbufs
);
7037 ndr_print_uint32(ndr
, "numfiletasks", r
->numfiletasks
);
7038 ndr_print_uint32(ndr
, "alertsched", r
->alertsched
);
7039 ndr_print_uint32(ndr
, "eroralert", r
->eroralert
);
7040 ndr_print_uint32(ndr
, "logonalert", r
->logonalert
);
7041 ndr_print_uint32(ndr
, "accessalert", r
->accessalert
);
7042 ndr_print_uint32(ndr
, "diskalert", r
->diskalert
);
7043 ndr_print_uint32(ndr
, "netioalert", r
->netioalert
);
7044 ndr_print_uint32(ndr
, "maxaudits", r
->maxaudits
);
7045 ndr_print_ptr(ndr
, "srvheuristics", r
->srvheuristics
);
7047 if (r
->srvheuristics
) {
7048 ndr_print_string(ndr
, "srvheuristics", r
->srvheuristics
);
7051 ndr_print_uint32(ndr
, "auditedevents", r
->auditedevents
);
7052 ndr_print_uint32(ndr
, "auditprofile", r
->auditprofile
);
7053 ndr_print_ptr(ndr
, "autopath", r
->autopath
);
7056 ndr_print_string(ndr
, "autopath", r
->autopath
);
7062 static enum ndr_err_code
ndr_push_srvsvc_NetSrvInfo502(struct ndr_push
*ndr
, int ndr_flags
, const struct srvsvc_NetSrvInfo502
*r
)
7064 if (ndr_flags
& NDR_SCALARS
) {
7065 NDR_CHECK(ndr_push_align(ndr
, 4));
7066 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->sessopen
));
7067 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->sesssvc
));
7068 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->opensearch
));
7069 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->sizereqbufs
));
7070 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->initworkitems
));
7071 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->maxworkitems
));
7072 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->rawworkitems
));
7073 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->irpstacksize
));
7074 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->maxrawbuflen
));
7075 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->sessusers
));
7076 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->sessconns
));
7077 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->maxpagedmemoryusage
));
7078 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->maxnonpagedmemoryusage
));
7079 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->enablesoftcompat
));
7080 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->enableforcedlogoff
));
7081 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->timesource
));
7082 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->acceptdownlevelapis
));
7083 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->lmannounce
));
7085 if (ndr_flags
& NDR_BUFFERS
) {
7087 return NDR_ERR_SUCCESS
;
7090 static enum ndr_err_code
ndr_pull_srvsvc_NetSrvInfo502(struct ndr_pull
*ndr
, int ndr_flags
, struct srvsvc_NetSrvInfo502
*r
)
7092 if (ndr_flags
& NDR_SCALARS
) {
7093 NDR_CHECK(ndr_pull_align(ndr
, 4));
7094 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->sessopen
));
7095 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->sesssvc
));
7096 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->opensearch
));
7097 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->sizereqbufs
));
7098 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->initworkitems
));
7099 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->maxworkitems
));
7100 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->rawworkitems
));
7101 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->irpstacksize
));
7102 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->maxrawbuflen
));
7103 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->sessusers
));
7104 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->sessconns
));
7105 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->maxpagedmemoryusage
));
7106 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->maxnonpagedmemoryusage
));
7107 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->enablesoftcompat
));
7108 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->enableforcedlogoff
));
7109 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->timesource
));
7110 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->acceptdownlevelapis
));
7111 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->lmannounce
));
7113 if (ndr_flags
& NDR_BUFFERS
) {
7115 return NDR_ERR_SUCCESS
;
7118 _PUBLIC_
void ndr_print_srvsvc_NetSrvInfo502(struct ndr_print
*ndr
, const char *name
, const struct srvsvc_NetSrvInfo502
*r
)
7120 ndr_print_struct(ndr
, name
, "srvsvc_NetSrvInfo502");
7122 ndr_print_uint32(ndr
, "sessopen", r
->sessopen
);
7123 ndr_print_uint32(ndr
, "sesssvc", r
->sesssvc
);
7124 ndr_print_uint32(ndr
, "opensearch", r
->opensearch
);
7125 ndr_print_uint32(ndr
, "sizereqbufs", r
->sizereqbufs
);
7126 ndr_print_uint32(ndr
, "initworkitems", r
->initworkitems
);
7127 ndr_print_uint32(ndr
, "maxworkitems", r
->maxworkitems
);
7128 ndr_print_uint32(ndr
, "rawworkitems", r
->rawworkitems
);
7129 ndr_print_uint32(ndr
, "irpstacksize", r
->irpstacksize
);
7130 ndr_print_uint32(ndr
, "maxrawbuflen", r
->maxrawbuflen
);
7131 ndr_print_uint32(ndr
, "sessusers", r
->sessusers
);
7132 ndr_print_uint32(ndr
, "sessconns", r
->sessconns
);
7133 ndr_print_uint32(ndr
, "maxpagedmemoryusage", r
->maxpagedmemoryusage
);
7134 ndr_print_uint32(ndr
, "maxnonpagedmemoryusage", r
->maxnonpagedmemoryusage
);
7135 ndr_print_uint32(ndr
, "enablesoftcompat", r
->enablesoftcompat
);
7136 ndr_print_uint32(ndr
, "enableforcedlogoff", r
->enableforcedlogoff
);
7137 ndr_print_uint32(ndr
, "timesource", r
->timesource
);
7138 ndr_print_uint32(ndr
, "acceptdownlevelapis", r
->acceptdownlevelapis
);
7139 ndr_print_uint32(ndr
, "lmannounce", r
->lmannounce
);
7143 static enum ndr_err_code
ndr_push_srvsvc_NetSrvInfo503(struct ndr_push
*ndr
, int ndr_flags
, const struct srvsvc_NetSrvInfo503
*r
)
7145 if (ndr_flags
& NDR_SCALARS
) {
7146 NDR_CHECK(ndr_push_align(ndr
, 4));
7147 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->sessopen
));
7148 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->sesssvc
));
7149 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->opensearch
));
7150 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->sizereqbufs
));
7151 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->initworkitems
));
7152 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->maxworkitems
));
7153 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->rawworkitems
));
7154 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->irpstacksize
));
7155 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->maxrawbuflen
));
7156 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->sessusers
));
7157 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->sessconns
));
7158 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->maxpagedmemoryusage
));
7159 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->maxnonpagedmemoryusage
));
7160 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->enablesoftcompat
));
7161 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->enableforcedlogoff
));
7162 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->timesource
));
7163 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->acceptdownlevelapis
));
7164 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->lmannounce
));
7165 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->domain
));
7166 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->maxcopyreadlen
));
7167 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->maxcopywritelen
));
7168 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->minkeepsearch
));
7169 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->maxkeepsearch
));
7170 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->minkeepcomplsearch
));
7171 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->maxkeepcomplsearch
));
7172 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->threadcountadd
));
7173 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->numlockthreads
));
7174 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->scavtimeout
));
7175 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->minrcvqueue
));
7176 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->minfreeworkitems
));
7177 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->xactmemsize
));
7178 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->threadpriority
));
7179 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->maxmpxct
));
7180 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->oplockbreakwait
));
7181 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->oplockbreakresponsewait
));
7182 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->enableoplocks
));
7183 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->enableoplockforceclose
));
7184 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->enablefcbopens
));
7185 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->enableraw
));
7186 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->enablesharednetdrives
));
7187 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->minfreeconnections
));
7188 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->maxfreeconnections
));
7190 if (ndr_flags
& NDR_BUFFERS
) {
7192 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->domain
, CH_UTF16
)));
7193 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
7194 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->domain
, CH_UTF16
)));
7195 NDR_CHECK(ndr_push_charset(ndr
, NDR_SCALARS
, r
->domain
, ndr_charset_length(r
->domain
, CH_UTF16
), sizeof(uint16_t), CH_UTF16
));
7198 return NDR_ERR_SUCCESS
;
7201 static enum ndr_err_code
ndr_pull_srvsvc_NetSrvInfo503(struct ndr_pull
*ndr
, int ndr_flags
, struct srvsvc_NetSrvInfo503
*r
)
7203 uint32_t _ptr_domain
;
7204 TALLOC_CTX
*_mem_save_domain_0
;
7205 if (ndr_flags
& NDR_SCALARS
) {
7206 NDR_CHECK(ndr_pull_align(ndr
, 4));
7207 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->sessopen
));
7208 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->sesssvc
));
7209 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->opensearch
));
7210 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->sizereqbufs
));
7211 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->initworkitems
));
7212 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->maxworkitems
));
7213 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->rawworkitems
));
7214 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->irpstacksize
));
7215 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->maxrawbuflen
));
7216 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->sessusers
));
7217 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->sessconns
));
7218 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->maxpagedmemoryusage
));
7219 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->maxnonpagedmemoryusage
));
7220 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->enablesoftcompat
));
7221 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->enableforcedlogoff
));
7222 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->timesource
));
7223 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->acceptdownlevelapis
));
7224 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->lmannounce
));
7225 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_domain
));
7227 NDR_PULL_ALLOC(ndr
, r
->domain
);
7231 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->maxcopyreadlen
));
7232 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->maxcopywritelen
));
7233 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->minkeepsearch
));
7234 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->maxkeepsearch
));
7235 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->minkeepcomplsearch
));
7236 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->maxkeepcomplsearch
));
7237 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->threadcountadd
));
7238 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->numlockthreads
));
7239 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->scavtimeout
));
7240 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->minrcvqueue
));
7241 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->minfreeworkitems
));
7242 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->xactmemsize
));
7243 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->threadpriority
));
7244 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->maxmpxct
));
7245 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->oplockbreakwait
));
7246 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->oplockbreakresponsewait
));
7247 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->enableoplocks
));
7248 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->enableoplockforceclose
));
7249 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->enablefcbopens
));
7250 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->enableraw
));
7251 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->enablesharednetdrives
));
7252 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->minfreeconnections
));
7253 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->maxfreeconnections
));
7255 if (ndr_flags
& NDR_BUFFERS
) {
7257 _mem_save_domain_0
= NDR_PULL_GET_MEM_CTX(ndr
);
7258 NDR_PULL_SET_MEM_CTX(ndr
, r
->domain
, 0);
7259 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->domain
));
7260 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->domain
));
7261 if (ndr_get_array_length(ndr
, &r
->domain
) > ndr_get_array_size(ndr
, &r
->domain
)) {
7262 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", ndr_get_array_size(ndr
, &r
->domain
), ndr_get_array_length(ndr
, &r
->domain
));
7264 NDR_CHECK(ndr_check_string_terminator(ndr
, ndr_get_array_length(ndr
, &r
->domain
), sizeof(uint16_t)));
7265 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->domain
, ndr_get_array_length(ndr
, &r
->domain
), sizeof(uint16_t), CH_UTF16
));
7266 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_domain_0
, 0);
7269 return NDR_ERR_SUCCESS
;
7272 _PUBLIC_
void ndr_print_srvsvc_NetSrvInfo503(struct ndr_print
*ndr
, const char *name
, const struct srvsvc_NetSrvInfo503
*r
)
7274 ndr_print_struct(ndr
, name
, "srvsvc_NetSrvInfo503");
7276 ndr_print_uint32(ndr
, "sessopen", r
->sessopen
);
7277 ndr_print_uint32(ndr
, "sesssvc", r
->sesssvc
);
7278 ndr_print_uint32(ndr
, "opensearch", r
->opensearch
);
7279 ndr_print_uint32(ndr
, "sizereqbufs", r
->sizereqbufs
);
7280 ndr_print_uint32(ndr
, "initworkitems", r
->initworkitems
);
7281 ndr_print_uint32(ndr
, "maxworkitems", r
->maxworkitems
);
7282 ndr_print_uint32(ndr
, "rawworkitems", r
->rawworkitems
);
7283 ndr_print_uint32(ndr
, "irpstacksize", r
->irpstacksize
);
7284 ndr_print_uint32(ndr
, "maxrawbuflen", r
->maxrawbuflen
);
7285 ndr_print_uint32(ndr
, "sessusers", r
->sessusers
);
7286 ndr_print_uint32(ndr
, "sessconns", r
->sessconns
);
7287 ndr_print_uint32(ndr
, "maxpagedmemoryusage", r
->maxpagedmemoryusage
);
7288 ndr_print_uint32(ndr
, "maxnonpagedmemoryusage", r
->maxnonpagedmemoryusage
);
7289 ndr_print_uint32(ndr
, "enablesoftcompat", r
->enablesoftcompat
);
7290 ndr_print_uint32(ndr
, "enableforcedlogoff", r
->enableforcedlogoff
);
7291 ndr_print_uint32(ndr
, "timesource", r
->timesource
);
7292 ndr_print_uint32(ndr
, "acceptdownlevelapis", r
->acceptdownlevelapis
);
7293 ndr_print_uint32(ndr
, "lmannounce", r
->lmannounce
);
7294 ndr_print_ptr(ndr
, "domain", r
->domain
);
7297 ndr_print_string(ndr
, "domain", r
->domain
);
7300 ndr_print_uint32(ndr
, "maxcopyreadlen", r
->maxcopyreadlen
);
7301 ndr_print_uint32(ndr
, "maxcopywritelen", r
->maxcopywritelen
);
7302 ndr_print_uint32(ndr
, "minkeepsearch", r
->minkeepsearch
);
7303 ndr_print_uint32(ndr
, "maxkeepsearch", r
->maxkeepsearch
);
7304 ndr_print_uint32(ndr
, "minkeepcomplsearch", r
->minkeepcomplsearch
);
7305 ndr_print_uint32(ndr
, "maxkeepcomplsearch", r
->maxkeepcomplsearch
);
7306 ndr_print_uint32(ndr
, "threadcountadd", r
->threadcountadd
);
7307 ndr_print_uint32(ndr
, "numlockthreads", r
->numlockthreads
);
7308 ndr_print_uint32(ndr
, "scavtimeout", r
->scavtimeout
);
7309 ndr_print_uint32(ndr
, "minrcvqueue", r
->minrcvqueue
);
7310 ndr_print_uint32(ndr
, "minfreeworkitems", r
->minfreeworkitems
);
7311 ndr_print_uint32(ndr
, "xactmemsize", r
->xactmemsize
);
7312 ndr_print_uint32(ndr
, "threadpriority", r
->threadpriority
);
7313 ndr_print_uint32(ndr
, "maxmpxct", r
->maxmpxct
);
7314 ndr_print_uint32(ndr
, "oplockbreakwait", r
->oplockbreakwait
);
7315 ndr_print_uint32(ndr
, "oplockbreakresponsewait", r
->oplockbreakresponsewait
);
7316 ndr_print_uint32(ndr
, "enableoplocks", r
->enableoplocks
);
7317 ndr_print_uint32(ndr
, "enableoplockforceclose", r
->enableoplockforceclose
);
7318 ndr_print_uint32(ndr
, "enablefcbopens", r
->enablefcbopens
);
7319 ndr_print_uint32(ndr
, "enableraw", r
->enableraw
);
7320 ndr_print_uint32(ndr
, "enablesharednetdrives", r
->enablesharednetdrives
);
7321 ndr_print_uint32(ndr
, "minfreeconnections", r
->minfreeconnections
);
7322 ndr_print_uint32(ndr
, "maxfreeconnections", r
->maxfreeconnections
);
7326 static enum ndr_err_code
ndr_push_srvsvc_NetSrvInfo599(struct ndr_push
*ndr
, int ndr_flags
, const struct srvsvc_NetSrvInfo599
*r
)
7328 if (ndr_flags
& NDR_SCALARS
) {
7329 NDR_CHECK(ndr_push_align(ndr
, 4));
7330 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->sessopen
));
7331 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->sesssvc
));
7332 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->opensearch
));
7333 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->sizereqbufs
));
7334 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->initworkitems
));
7335 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->maxworkitems
));
7336 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->rawworkitems
));
7337 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->irpstacksize
));
7338 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->maxrawbuflen
));
7339 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->sessusers
));
7340 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->sessconns
));
7341 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->maxpagedmemoryusage
));
7342 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->maxnonpagedmemoryusage
));
7343 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->enablesoftcompat
));
7344 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->enableforcedlogoff
));
7345 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->timesource
));
7346 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->acceptdownlevelapis
));
7347 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->lmannounce
));
7348 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->domain
));
7349 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->maxcopyreadlen
));
7350 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->maxcopywritelen
));
7351 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->minkeepsearch
));
7352 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->minkeepcomplsearch
));
7353 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->maxkeepcomplsearch
));
7354 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->threadcountadd
));
7355 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->numlockthreads
));
7356 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->scavtimeout
));
7357 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->minrcvqueue
));
7358 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->minfreeworkitems
));
7359 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->xactmemsize
));
7360 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->threadpriority
));
7361 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->maxmpxct
));
7362 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->oplockbreakwait
));
7363 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->oplockbreakresponsewait
));
7364 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->enableoplocks
));
7365 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->enableoplockforceclose
));
7366 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->enablefcbopens
));
7367 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->enableraw
));
7368 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->enablesharednetdrives
));
7369 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->minfreeconnections
));
7370 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->maxfreeconnections
));
7371 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->initsesstable
));
7372 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->initconntable
));
7373 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->initfiletable
));
7374 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->initsearchtable
));
7375 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->alertsched
));
7376 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->errortreshold
));
7377 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->networkerrortreshold
));
7378 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->diskspacetreshold
));
7379 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->reserved
));
7380 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->maxlinkdelay
));
7381 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->minlinkthroughput
));
7382 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->linkinfovalidtime
));
7383 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->scavqosinfoupdatetime
));
7384 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->maxworkitemidletime
));
7386 if (ndr_flags
& NDR_BUFFERS
) {
7388 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->domain
, CH_UTF16
)));
7389 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
7390 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->domain
, CH_UTF16
)));
7391 NDR_CHECK(ndr_push_charset(ndr
, NDR_SCALARS
, r
->domain
, ndr_charset_length(r
->domain
, CH_UTF16
), sizeof(uint16_t), CH_UTF16
));
7394 return NDR_ERR_SUCCESS
;
7397 static enum ndr_err_code
ndr_pull_srvsvc_NetSrvInfo599(struct ndr_pull
*ndr
, int ndr_flags
, struct srvsvc_NetSrvInfo599
*r
)
7399 uint32_t _ptr_domain
;
7400 TALLOC_CTX
*_mem_save_domain_0
;
7401 if (ndr_flags
& NDR_SCALARS
) {
7402 NDR_CHECK(ndr_pull_align(ndr
, 4));
7403 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->sessopen
));
7404 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->sesssvc
));
7405 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->opensearch
));
7406 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->sizereqbufs
));
7407 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->initworkitems
));
7408 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->maxworkitems
));
7409 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->rawworkitems
));
7410 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->irpstacksize
));
7411 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->maxrawbuflen
));
7412 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->sessusers
));
7413 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->sessconns
));
7414 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->maxpagedmemoryusage
));
7415 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->maxnonpagedmemoryusage
));
7416 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->enablesoftcompat
));
7417 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->enableforcedlogoff
));
7418 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->timesource
));
7419 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->acceptdownlevelapis
));
7420 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->lmannounce
));
7421 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_domain
));
7423 NDR_PULL_ALLOC(ndr
, r
->domain
);
7427 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->maxcopyreadlen
));
7428 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->maxcopywritelen
));
7429 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->minkeepsearch
));
7430 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->minkeepcomplsearch
));
7431 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->maxkeepcomplsearch
));
7432 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->threadcountadd
));
7433 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->numlockthreads
));
7434 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->scavtimeout
));
7435 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->minrcvqueue
));
7436 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->minfreeworkitems
));
7437 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->xactmemsize
));
7438 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->threadpriority
));
7439 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->maxmpxct
));
7440 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->oplockbreakwait
));
7441 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->oplockbreakresponsewait
));
7442 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->enableoplocks
));
7443 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->enableoplockforceclose
));
7444 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->enablefcbopens
));
7445 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->enableraw
));
7446 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->enablesharednetdrives
));
7447 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->minfreeconnections
));
7448 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->maxfreeconnections
));
7449 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->initsesstable
));
7450 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->initconntable
));
7451 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->initfiletable
));
7452 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->initsearchtable
));
7453 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->alertsched
));
7454 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->errortreshold
));
7455 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->networkerrortreshold
));
7456 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->diskspacetreshold
));
7457 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->reserved
));
7458 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->maxlinkdelay
));
7459 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->minlinkthroughput
));
7460 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->linkinfovalidtime
));
7461 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->scavqosinfoupdatetime
));
7462 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->maxworkitemidletime
));
7464 if (ndr_flags
& NDR_BUFFERS
) {
7466 _mem_save_domain_0
= NDR_PULL_GET_MEM_CTX(ndr
);
7467 NDR_PULL_SET_MEM_CTX(ndr
, r
->domain
, 0);
7468 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->domain
));
7469 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->domain
));
7470 if (ndr_get_array_length(ndr
, &r
->domain
) > ndr_get_array_size(ndr
, &r
->domain
)) {
7471 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", ndr_get_array_size(ndr
, &r
->domain
), ndr_get_array_length(ndr
, &r
->domain
));
7473 NDR_CHECK(ndr_check_string_terminator(ndr
, ndr_get_array_length(ndr
, &r
->domain
), sizeof(uint16_t)));
7474 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->domain
, ndr_get_array_length(ndr
, &r
->domain
), sizeof(uint16_t), CH_UTF16
));
7475 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_domain_0
, 0);
7478 return NDR_ERR_SUCCESS
;
7481 _PUBLIC_
void ndr_print_srvsvc_NetSrvInfo599(struct ndr_print
*ndr
, const char *name
, const struct srvsvc_NetSrvInfo599
*r
)
7483 ndr_print_struct(ndr
, name
, "srvsvc_NetSrvInfo599");
7485 ndr_print_uint32(ndr
, "sessopen", r
->sessopen
);
7486 ndr_print_uint32(ndr
, "sesssvc", r
->sesssvc
);
7487 ndr_print_uint32(ndr
, "opensearch", r
->opensearch
);
7488 ndr_print_uint32(ndr
, "sizereqbufs", r
->sizereqbufs
);
7489 ndr_print_uint32(ndr
, "initworkitems", r
->initworkitems
);
7490 ndr_print_uint32(ndr
, "maxworkitems", r
->maxworkitems
);
7491 ndr_print_uint32(ndr
, "rawworkitems", r
->rawworkitems
);
7492 ndr_print_uint32(ndr
, "irpstacksize", r
->irpstacksize
);
7493 ndr_print_uint32(ndr
, "maxrawbuflen", r
->maxrawbuflen
);
7494 ndr_print_uint32(ndr
, "sessusers", r
->sessusers
);
7495 ndr_print_uint32(ndr
, "sessconns", r
->sessconns
);
7496 ndr_print_uint32(ndr
, "maxpagedmemoryusage", r
->maxpagedmemoryusage
);
7497 ndr_print_uint32(ndr
, "maxnonpagedmemoryusage", r
->maxnonpagedmemoryusage
);
7498 ndr_print_uint32(ndr
, "enablesoftcompat", r
->enablesoftcompat
);
7499 ndr_print_uint32(ndr
, "enableforcedlogoff", r
->enableforcedlogoff
);
7500 ndr_print_uint32(ndr
, "timesource", r
->timesource
);
7501 ndr_print_uint32(ndr
, "acceptdownlevelapis", r
->acceptdownlevelapis
);
7502 ndr_print_uint32(ndr
, "lmannounce", r
->lmannounce
);
7503 ndr_print_ptr(ndr
, "domain", r
->domain
);
7506 ndr_print_string(ndr
, "domain", r
->domain
);
7509 ndr_print_uint32(ndr
, "maxcopyreadlen", r
->maxcopyreadlen
);
7510 ndr_print_uint32(ndr
, "maxcopywritelen", r
->maxcopywritelen
);
7511 ndr_print_uint32(ndr
, "minkeepsearch", r
->minkeepsearch
);
7512 ndr_print_uint32(ndr
, "minkeepcomplsearch", r
->minkeepcomplsearch
);
7513 ndr_print_uint32(ndr
, "maxkeepcomplsearch", r
->maxkeepcomplsearch
);
7514 ndr_print_uint32(ndr
, "threadcountadd", r
->threadcountadd
);
7515 ndr_print_uint32(ndr
, "numlockthreads", r
->numlockthreads
);
7516 ndr_print_uint32(ndr
, "scavtimeout", r
->scavtimeout
);
7517 ndr_print_uint32(ndr
, "minrcvqueue", r
->minrcvqueue
);
7518 ndr_print_uint32(ndr
, "minfreeworkitems", r
->minfreeworkitems
);
7519 ndr_print_uint32(ndr
, "xactmemsize", r
->xactmemsize
);
7520 ndr_print_uint32(ndr
, "threadpriority", r
->threadpriority
);
7521 ndr_print_uint32(ndr
, "maxmpxct", r
->maxmpxct
);
7522 ndr_print_uint32(ndr
, "oplockbreakwait", r
->oplockbreakwait
);
7523 ndr_print_uint32(ndr
, "oplockbreakresponsewait", r
->oplockbreakresponsewait
);
7524 ndr_print_uint32(ndr
, "enableoplocks", r
->enableoplocks
);
7525 ndr_print_uint32(ndr
, "enableoplockforceclose", r
->enableoplockforceclose
);
7526 ndr_print_uint32(ndr
, "enablefcbopens", r
->enablefcbopens
);
7527 ndr_print_uint32(ndr
, "enableraw", r
->enableraw
);
7528 ndr_print_uint32(ndr
, "enablesharednetdrives", r
->enablesharednetdrives
);
7529 ndr_print_uint32(ndr
, "minfreeconnections", r
->minfreeconnections
);
7530 ndr_print_uint32(ndr
, "maxfreeconnections", r
->maxfreeconnections
);
7531 ndr_print_uint32(ndr
, "initsesstable", r
->initsesstable
);
7532 ndr_print_uint32(ndr
, "initconntable", r
->initconntable
);
7533 ndr_print_uint32(ndr
, "initfiletable", r
->initfiletable
);
7534 ndr_print_uint32(ndr
, "initsearchtable", r
->initsearchtable
);
7535 ndr_print_uint32(ndr
, "alertsched", r
->alertsched
);
7536 ndr_print_uint32(ndr
, "errortreshold", r
->errortreshold
);
7537 ndr_print_uint32(ndr
, "networkerrortreshold", r
->networkerrortreshold
);
7538 ndr_print_uint32(ndr
, "diskspacetreshold", r
->diskspacetreshold
);
7539 ndr_print_uint32(ndr
, "reserved", r
->reserved
);
7540 ndr_print_uint32(ndr
, "maxlinkdelay", r
->maxlinkdelay
);
7541 ndr_print_uint32(ndr
, "minlinkthroughput", r
->minlinkthroughput
);
7542 ndr_print_uint32(ndr
, "linkinfovalidtime", r
->linkinfovalidtime
);
7543 ndr_print_uint32(ndr
, "scavqosinfoupdatetime", r
->scavqosinfoupdatetime
);
7544 ndr_print_uint32(ndr
, "maxworkitemidletime", r
->maxworkitemidletime
);
7548 static enum ndr_err_code
ndr_push_srvsvc_NetSrvInfo1005(struct ndr_push
*ndr
, int ndr_flags
, const struct srvsvc_NetSrvInfo1005
*r
)
7550 if (ndr_flags
& NDR_SCALARS
) {
7551 NDR_CHECK(ndr_push_align(ndr
, 4));
7552 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->comment
));
7554 if (ndr_flags
& NDR_BUFFERS
) {
7556 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->comment
, CH_UTF16
)));
7557 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
7558 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->comment
, CH_UTF16
)));
7559 NDR_CHECK(ndr_push_charset(ndr
, NDR_SCALARS
, r
->comment
, ndr_charset_length(r
->comment
, CH_UTF16
), sizeof(uint16_t), CH_UTF16
));
7562 return NDR_ERR_SUCCESS
;
7565 static enum ndr_err_code
ndr_pull_srvsvc_NetSrvInfo1005(struct ndr_pull
*ndr
, int ndr_flags
, struct srvsvc_NetSrvInfo1005
*r
)
7567 uint32_t _ptr_comment
;
7568 TALLOC_CTX
*_mem_save_comment_0
;
7569 if (ndr_flags
& NDR_SCALARS
) {
7570 NDR_CHECK(ndr_pull_align(ndr
, 4));
7571 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_comment
));
7573 NDR_PULL_ALLOC(ndr
, r
->comment
);
7578 if (ndr_flags
& NDR_BUFFERS
) {
7580 _mem_save_comment_0
= NDR_PULL_GET_MEM_CTX(ndr
);
7581 NDR_PULL_SET_MEM_CTX(ndr
, r
->comment
, 0);
7582 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->comment
));
7583 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->comment
));
7584 if (ndr_get_array_length(ndr
, &r
->comment
) > ndr_get_array_size(ndr
, &r
->comment
)) {
7585 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", ndr_get_array_size(ndr
, &r
->comment
), ndr_get_array_length(ndr
, &r
->comment
));
7587 NDR_CHECK(ndr_check_string_terminator(ndr
, ndr_get_array_length(ndr
, &r
->comment
), sizeof(uint16_t)));
7588 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->comment
, ndr_get_array_length(ndr
, &r
->comment
), sizeof(uint16_t), CH_UTF16
));
7589 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_comment_0
, 0);
7592 return NDR_ERR_SUCCESS
;
7595 _PUBLIC_
void ndr_print_srvsvc_NetSrvInfo1005(struct ndr_print
*ndr
, const char *name
, const struct srvsvc_NetSrvInfo1005
*r
)
7597 ndr_print_struct(ndr
, name
, "srvsvc_NetSrvInfo1005");
7599 ndr_print_ptr(ndr
, "comment", r
->comment
);
7602 ndr_print_string(ndr
, "comment", r
->comment
);
7608 static enum ndr_err_code
ndr_push_srvsvc_NetSrvInfo1010(struct ndr_push
*ndr
, int ndr_flags
, const struct srvsvc_NetSrvInfo1010
*r
)
7610 if (ndr_flags
& NDR_SCALARS
) {
7611 NDR_CHECK(ndr_push_align(ndr
, 4));
7612 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->disc
));
7614 if (ndr_flags
& NDR_BUFFERS
) {
7616 return NDR_ERR_SUCCESS
;
7619 static enum ndr_err_code
ndr_pull_srvsvc_NetSrvInfo1010(struct ndr_pull
*ndr
, int ndr_flags
, struct srvsvc_NetSrvInfo1010
*r
)
7621 if (ndr_flags
& NDR_SCALARS
) {
7622 NDR_CHECK(ndr_pull_align(ndr
, 4));
7623 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->disc
));
7625 if (ndr_flags
& NDR_BUFFERS
) {
7627 return NDR_ERR_SUCCESS
;
7630 _PUBLIC_
void ndr_print_srvsvc_NetSrvInfo1010(struct ndr_print
*ndr
, const char *name
, const struct srvsvc_NetSrvInfo1010
*r
)
7632 ndr_print_struct(ndr
, name
, "srvsvc_NetSrvInfo1010");
7634 ndr_print_uint32(ndr
, "disc", r
->disc
);
7638 static enum ndr_err_code
ndr_push_srvsvc_NetSrvInfo1016(struct ndr_push
*ndr
, int ndr_flags
, const struct srvsvc_NetSrvInfo1016
*r
)
7640 if (ndr_flags
& NDR_SCALARS
) {
7641 NDR_CHECK(ndr_push_align(ndr
, 4));
7642 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->hidden
));
7644 if (ndr_flags
& NDR_BUFFERS
) {
7646 return NDR_ERR_SUCCESS
;
7649 static enum ndr_err_code
ndr_pull_srvsvc_NetSrvInfo1016(struct ndr_pull
*ndr
, int ndr_flags
, struct srvsvc_NetSrvInfo1016
*r
)
7651 if (ndr_flags
& NDR_SCALARS
) {
7652 NDR_CHECK(ndr_pull_align(ndr
, 4));
7653 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->hidden
));
7655 if (ndr_flags
& NDR_BUFFERS
) {
7657 return NDR_ERR_SUCCESS
;
7660 _PUBLIC_
void ndr_print_srvsvc_NetSrvInfo1016(struct ndr_print
*ndr
, const char *name
, const struct srvsvc_NetSrvInfo1016
*r
)
7662 ndr_print_struct(ndr
, name
, "srvsvc_NetSrvInfo1016");
7664 ndr_print_uint32(ndr
, "hidden", r
->hidden
);
7668 static enum ndr_err_code
ndr_push_srvsvc_NetSrvInfo1017(struct ndr_push
*ndr
, int ndr_flags
, const struct srvsvc_NetSrvInfo1017
*r
)
7670 if (ndr_flags
& NDR_SCALARS
) {
7671 NDR_CHECK(ndr_push_align(ndr
, 4));
7672 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->announce
));
7674 if (ndr_flags
& NDR_BUFFERS
) {
7676 return NDR_ERR_SUCCESS
;
7679 static enum ndr_err_code
ndr_pull_srvsvc_NetSrvInfo1017(struct ndr_pull
*ndr
, int ndr_flags
, struct srvsvc_NetSrvInfo1017
*r
)
7681 if (ndr_flags
& NDR_SCALARS
) {
7682 NDR_CHECK(ndr_pull_align(ndr
, 4));
7683 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->announce
));
7685 if (ndr_flags
& NDR_BUFFERS
) {
7687 return NDR_ERR_SUCCESS
;
7690 _PUBLIC_
void ndr_print_srvsvc_NetSrvInfo1017(struct ndr_print
*ndr
, const char *name
, const struct srvsvc_NetSrvInfo1017
*r
)
7692 ndr_print_struct(ndr
, name
, "srvsvc_NetSrvInfo1017");
7694 ndr_print_uint32(ndr
, "announce", r
->announce
);
7698 static enum ndr_err_code
ndr_push_srvsvc_NetSrvInfo1018(struct ndr_push
*ndr
, int ndr_flags
, const struct srvsvc_NetSrvInfo1018
*r
)
7700 if (ndr_flags
& NDR_SCALARS
) {
7701 NDR_CHECK(ndr_push_align(ndr
, 4));
7702 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->anndelta
));
7704 if (ndr_flags
& NDR_BUFFERS
) {
7706 return NDR_ERR_SUCCESS
;
7709 static enum ndr_err_code
ndr_pull_srvsvc_NetSrvInfo1018(struct ndr_pull
*ndr
, int ndr_flags
, struct srvsvc_NetSrvInfo1018
*r
)
7711 if (ndr_flags
& NDR_SCALARS
) {
7712 NDR_CHECK(ndr_pull_align(ndr
, 4));
7713 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->anndelta
));
7715 if (ndr_flags
& NDR_BUFFERS
) {
7717 return NDR_ERR_SUCCESS
;
7720 _PUBLIC_
void ndr_print_srvsvc_NetSrvInfo1018(struct ndr_print
*ndr
, const char *name
, const struct srvsvc_NetSrvInfo1018
*r
)
7722 ndr_print_struct(ndr
, name
, "srvsvc_NetSrvInfo1018");
7724 ndr_print_uint32(ndr
, "anndelta", r
->anndelta
);
7728 static enum ndr_err_code
ndr_push_srvsvc_NetSrvInfo1107(struct ndr_push
*ndr
, int ndr_flags
, const struct srvsvc_NetSrvInfo1107
*r
)
7730 if (ndr_flags
& NDR_SCALARS
) {
7731 NDR_CHECK(ndr_push_align(ndr
, 4));
7732 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->users
));
7734 if (ndr_flags
& NDR_BUFFERS
) {
7736 return NDR_ERR_SUCCESS
;
7739 static enum ndr_err_code
ndr_pull_srvsvc_NetSrvInfo1107(struct ndr_pull
*ndr
, int ndr_flags
, struct srvsvc_NetSrvInfo1107
*r
)
7741 if (ndr_flags
& NDR_SCALARS
) {
7742 NDR_CHECK(ndr_pull_align(ndr
, 4));
7743 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->users
));
7745 if (ndr_flags
& NDR_BUFFERS
) {
7747 return NDR_ERR_SUCCESS
;
7750 _PUBLIC_
void ndr_print_srvsvc_NetSrvInfo1107(struct ndr_print
*ndr
, const char *name
, const struct srvsvc_NetSrvInfo1107
*r
)
7752 ndr_print_struct(ndr
, name
, "srvsvc_NetSrvInfo1107");
7754 ndr_print_uint32(ndr
, "users", r
->users
);
7758 static enum ndr_err_code
ndr_push_srvsvc_NetSrvInfo1501(struct ndr_push
*ndr
, int ndr_flags
, const struct srvsvc_NetSrvInfo1501
*r
)
7760 if (ndr_flags
& NDR_SCALARS
) {
7761 NDR_CHECK(ndr_push_align(ndr
, 4));
7762 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->sessopens
));
7764 if (ndr_flags
& NDR_BUFFERS
) {
7766 return NDR_ERR_SUCCESS
;
7769 static enum ndr_err_code
ndr_pull_srvsvc_NetSrvInfo1501(struct ndr_pull
*ndr
, int ndr_flags
, struct srvsvc_NetSrvInfo1501
*r
)
7771 if (ndr_flags
& NDR_SCALARS
) {
7772 NDR_CHECK(ndr_pull_align(ndr
, 4));
7773 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->sessopens
));
7775 if (ndr_flags
& NDR_BUFFERS
) {
7777 return NDR_ERR_SUCCESS
;
7780 _PUBLIC_
void ndr_print_srvsvc_NetSrvInfo1501(struct ndr_print
*ndr
, const char *name
, const struct srvsvc_NetSrvInfo1501
*r
)
7782 ndr_print_struct(ndr
, name
, "srvsvc_NetSrvInfo1501");
7784 ndr_print_uint32(ndr
, "sessopens", r
->sessopens
);
7788 static enum ndr_err_code
ndr_push_srvsvc_NetSrvInfo1502(struct ndr_push
*ndr
, int ndr_flags
, const struct srvsvc_NetSrvInfo1502
*r
)
7790 if (ndr_flags
& NDR_SCALARS
) {
7791 NDR_CHECK(ndr_push_align(ndr
, 4));
7792 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->sessvcs
));
7794 if (ndr_flags
& NDR_BUFFERS
) {
7796 return NDR_ERR_SUCCESS
;
7799 static enum ndr_err_code
ndr_pull_srvsvc_NetSrvInfo1502(struct ndr_pull
*ndr
, int ndr_flags
, struct srvsvc_NetSrvInfo1502
*r
)
7801 if (ndr_flags
& NDR_SCALARS
) {
7802 NDR_CHECK(ndr_pull_align(ndr
, 4));
7803 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->sessvcs
));
7805 if (ndr_flags
& NDR_BUFFERS
) {
7807 return NDR_ERR_SUCCESS
;
7810 _PUBLIC_
void ndr_print_srvsvc_NetSrvInfo1502(struct ndr_print
*ndr
, const char *name
, const struct srvsvc_NetSrvInfo1502
*r
)
7812 ndr_print_struct(ndr
, name
, "srvsvc_NetSrvInfo1502");
7814 ndr_print_uint32(ndr
, "sessvcs", r
->sessvcs
);
7818 static enum ndr_err_code
ndr_push_srvsvc_NetSrvInfo1503(struct ndr_push
*ndr
, int ndr_flags
, const struct srvsvc_NetSrvInfo1503
*r
)
7820 if (ndr_flags
& NDR_SCALARS
) {
7821 NDR_CHECK(ndr_push_align(ndr
, 4));
7822 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->opensearch
));
7824 if (ndr_flags
& NDR_BUFFERS
) {
7826 return NDR_ERR_SUCCESS
;
7829 static enum ndr_err_code
ndr_pull_srvsvc_NetSrvInfo1503(struct ndr_pull
*ndr
, int ndr_flags
, struct srvsvc_NetSrvInfo1503
*r
)
7831 if (ndr_flags
& NDR_SCALARS
) {
7832 NDR_CHECK(ndr_pull_align(ndr
, 4));
7833 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->opensearch
));
7835 if (ndr_flags
& NDR_BUFFERS
) {
7837 return NDR_ERR_SUCCESS
;
7840 _PUBLIC_
void ndr_print_srvsvc_NetSrvInfo1503(struct ndr_print
*ndr
, const char *name
, const struct srvsvc_NetSrvInfo1503
*r
)
7842 ndr_print_struct(ndr
, name
, "srvsvc_NetSrvInfo1503");
7844 ndr_print_uint32(ndr
, "opensearch", r
->opensearch
);
7848 static enum ndr_err_code
ndr_push_srvsvc_NetSrvInfo1506(struct ndr_push
*ndr
, int ndr_flags
, const struct srvsvc_NetSrvInfo1506
*r
)
7850 if (ndr_flags
& NDR_SCALARS
) {
7851 NDR_CHECK(ndr_push_align(ndr
, 4));
7852 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->maxworkitems
));
7854 if (ndr_flags
& NDR_BUFFERS
) {
7856 return NDR_ERR_SUCCESS
;
7859 static enum ndr_err_code
ndr_pull_srvsvc_NetSrvInfo1506(struct ndr_pull
*ndr
, int ndr_flags
, struct srvsvc_NetSrvInfo1506
*r
)
7861 if (ndr_flags
& NDR_SCALARS
) {
7862 NDR_CHECK(ndr_pull_align(ndr
, 4));
7863 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->maxworkitems
));
7865 if (ndr_flags
& NDR_BUFFERS
) {
7867 return NDR_ERR_SUCCESS
;
7870 _PUBLIC_
void ndr_print_srvsvc_NetSrvInfo1506(struct ndr_print
*ndr
, const char *name
, const struct srvsvc_NetSrvInfo1506
*r
)
7872 ndr_print_struct(ndr
, name
, "srvsvc_NetSrvInfo1506");
7874 ndr_print_uint32(ndr
, "maxworkitems", r
->maxworkitems
);
7878 static enum ndr_err_code
ndr_push_srvsvc_NetSrvInfo1509(struct ndr_push
*ndr
, int ndr_flags
, const struct srvsvc_NetSrvInfo1509
*r
)
7880 if (ndr_flags
& NDR_SCALARS
) {
7881 NDR_CHECK(ndr_push_align(ndr
, 4));
7882 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->maxrawbuflen
));
7884 if (ndr_flags
& NDR_BUFFERS
) {
7886 return NDR_ERR_SUCCESS
;
7889 static enum ndr_err_code
ndr_pull_srvsvc_NetSrvInfo1509(struct ndr_pull
*ndr
, int ndr_flags
, struct srvsvc_NetSrvInfo1509
*r
)
7891 if (ndr_flags
& NDR_SCALARS
) {
7892 NDR_CHECK(ndr_pull_align(ndr
, 4));
7893 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->maxrawbuflen
));
7895 if (ndr_flags
& NDR_BUFFERS
) {
7897 return NDR_ERR_SUCCESS
;
7900 _PUBLIC_
void ndr_print_srvsvc_NetSrvInfo1509(struct ndr_print
*ndr
, const char *name
, const struct srvsvc_NetSrvInfo1509
*r
)
7902 ndr_print_struct(ndr
, name
, "srvsvc_NetSrvInfo1509");
7904 ndr_print_uint32(ndr
, "maxrawbuflen", r
->maxrawbuflen
);
7908 static enum ndr_err_code
ndr_push_srvsvc_NetSrvInfo1510(struct ndr_push
*ndr
, int ndr_flags
, const struct srvsvc_NetSrvInfo1510
*r
)
7910 if (ndr_flags
& NDR_SCALARS
) {
7911 NDR_CHECK(ndr_push_align(ndr
, 4));
7912 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->sessusers
));
7914 if (ndr_flags
& NDR_BUFFERS
) {
7916 return NDR_ERR_SUCCESS
;
7919 static enum ndr_err_code
ndr_pull_srvsvc_NetSrvInfo1510(struct ndr_pull
*ndr
, int ndr_flags
, struct srvsvc_NetSrvInfo1510
*r
)
7921 if (ndr_flags
& NDR_SCALARS
) {
7922 NDR_CHECK(ndr_pull_align(ndr
, 4));
7923 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->sessusers
));
7925 if (ndr_flags
& NDR_BUFFERS
) {
7927 return NDR_ERR_SUCCESS
;
7930 _PUBLIC_
void ndr_print_srvsvc_NetSrvInfo1510(struct ndr_print
*ndr
, const char *name
, const struct srvsvc_NetSrvInfo1510
*r
)
7932 ndr_print_struct(ndr
, name
, "srvsvc_NetSrvInfo1510");
7934 ndr_print_uint32(ndr
, "sessusers", r
->sessusers
);
7938 static enum ndr_err_code
ndr_push_srvsvc_NetSrvInfo1511(struct ndr_push
*ndr
, int ndr_flags
, const struct srvsvc_NetSrvInfo1511
*r
)
7940 if (ndr_flags
& NDR_SCALARS
) {
7941 NDR_CHECK(ndr_push_align(ndr
, 4));
7942 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->sesscons
));
7944 if (ndr_flags
& NDR_BUFFERS
) {
7946 return NDR_ERR_SUCCESS
;
7949 static enum ndr_err_code
ndr_pull_srvsvc_NetSrvInfo1511(struct ndr_pull
*ndr
, int ndr_flags
, struct srvsvc_NetSrvInfo1511
*r
)
7951 if (ndr_flags
& NDR_SCALARS
) {
7952 NDR_CHECK(ndr_pull_align(ndr
, 4));
7953 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->sesscons
));
7955 if (ndr_flags
& NDR_BUFFERS
) {
7957 return NDR_ERR_SUCCESS
;
7960 _PUBLIC_
void ndr_print_srvsvc_NetSrvInfo1511(struct ndr_print
*ndr
, const char *name
, const struct srvsvc_NetSrvInfo1511
*r
)
7962 ndr_print_struct(ndr
, name
, "srvsvc_NetSrvInfo1511");
7964 ndr_print_uint32(ndr
, "sesscons", r
->sesscons
);
7968 static enum ndr_err_code
ndr_push_srvsvc_NetSrvInfo1512(struct ndr_push
*ndr
, int ndr_flags
, const struct srvsvc_NetSrvInfo1512
*r
)
7970 if (ndr_flags
& NDR_SCALARS
) {
7971 NDR_CHECK(ndr_push_align(ndr
, 4));
7972 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->maxnonpagedmemoryusage
));
7974 if (ndr_flags
& NDR_BUFFERS
) {
7976 return NDR_ERR_SUCCESS
;
7979 static enum ndr_err_code
ndr_pull_srvsvc_NetSrvInfo1512(struct ndr_pull
*ndr
, int ndr_flags
, struct srvsvc_NetSrvInfo1512
*r
)
7981 if (ndr_flags
& NDR_SCALARS
) {
7982 NDR_CHECK(ndr_pull_align(ndr
, 4));
7983 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->maxnonpagedmemoryusage
));
7985 if (ndr_flags
& NDR_BUFFERS
) {
7987 return NDR_ERR_SUCCESS
;
7990 _PUBLIC_
void ndr_print_srvsvc_NetSrvInfo1512(struct ndr_print
*ndr
, const char *name
, const struct srvsvc_NetSrvInfo1512
*r
)
7992 ndr_print_struct(ndr
, name
, "srvsvc_NetSrvInfo1512");
7994 ndr_print_uint32(ndr
, "maxnonpagedmemoryusage", r
->maxnonpagedmemoryusage
);
7998 static enum ndr_err_code
ndr_push_srvsvc_NetSrvInfo1513(struct ndr_push
*ndr
, int ndr_flags
, const struct srvsvc_NetSrvInfo1513
*r
)
8000 if (ndr_flags
& NDR_SCALARS
) {
8001 NDR_CHECK(ndr_push_align(ndr
, 4));
8002 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->maxpagedmemoryusage
));
8004 if (ndr_flags
& NDR_BUFFERS
) {
8006 return NDR_ERR_SUCCESS
;
8009 static enum ndr_err_code
ndr_pull_srvsvc_NetSrvInfo1513(struct ndr_pull
*ndr
, int ndr_flags
, struct srvsvc_NetSrvInfo1513
*r
)
8011 if (ndr_flags
& NDR_SCALARS
) {
8012 NDR_CHECK(ndr_pull_align(ndr
, 4));
8013 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->maxpagedmemoryusage
));
8015 if (ndr_flags
& NDR_BUFFERS
) {
8017 return NDR_ERR_SUCCESS
;
8020 _PUBLIC_
void ndr_print_srvsvc_NetSrvInfo1513(struct ndr_print
*ndr
, const char *name
, const struct srvsvc_NetSrvInfo1513
*r
)
8022 ndr_print_struct(ndr
, name
, "srvsvc_NetSrvInfo1513");
8024 ndr_print_uint32(ndr
, "maxpagedmemoryusage", r
->maxpagedmemoryusage
);
8028 static enum ndr_err_code
ndr_push_srvsvc_NetSrvInfo1514(struct ndr_push
*ndr
, int ndr_flags
, const struct srvsvc_NetSrvInfo1514
*r
)
8030 if (ndr_flags
& NDR_SCALARS
) {
8031 NDR_CHECK(ndr_push_align(ndr
, 4));
8032 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->enablesoftcompat
));
8034 if (ndr_flags
& NDR_BUFFERS
) {
8036 return NDR_ERR_SUCCESS
;
8039 static enum ndr_err_code
ndr_pull_srvsvc_NetSrvInfo1514(struct ndr_pull
*ndr
, int ndr_flags
, struct srvsvc_NetSrvInfo1514
*r
)
8041 if (ndr_flags
& NDR_SCALARS
) {
8042 NDR_CHECK(ndr_pull_align(ndr
, 4));
8043 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->enablesoftcompat
));
8045 if (ndr_flags
& NDR_BUFFERS
) {
8047 return NDR_ERR_SUCCESS
;
8050 _PUBLIC_
void ndr_print_srvsvc_NetSrvInfo1514(struct ndr_print
*ndr
, const char *name
, const struct srvsvc_NetSrvInfo1514
*r
)
8052 ndr_print_struct(ndr
, name
, "srvsvc_NetSrvInfo1514");
8054 ndr_print_uint32(ndr
, "enablesoftcompat", r
->enablesoftcompat
);
8058 static enum ndr_err_code
ndr_push_srvsvc_NetSrvInfo1515(struct ndr_push
*ndr
, int ndr_flags
, const struct srvsvc_NetSrvInfo1515
*r
)
8060 if (ndr_flags
& NDR_SCALARS
) {
8061 NDR_CHECK(ndr_push_align(ndr
, 4));
8062 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->enableforcedlogoff
));
8064 if (ndr_flags
& NDR_BUFFERS
) {
8066 return NDR_ERR_SUCCESS
;
8069 static enum ndr_err_code
ndr_pull_srvsvc_NetSrvInfo1515(struct ndr_pull
*ndr
, int ndr_flags
, struct srvsvc_NetSrvInfo1515
*r
)
8071 if (ndr_flags
& NDR_SCALARS
) {
8072 NDR_CHECK(ndr_pull_align(ndr
, 4));
8073 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->enableforcedlogoff
));
8075 if (ndr_flags
& NDR_BUFFERS
) {
8077 return NDR_ERR_SUCCESS
;
8080 _PUBLIC_
void ndr_print_srvsvc_NetSrvInfo1515(struct ndr_print
*ndr
, const char *name
, const struct srvsvc_NetSrvInfo1515
*r
)
8082 ndr_print_struct(ndr
, name
, "srvsvc_NetSrvInfo1515");
8084 ndr_print_uint32(ndr
, "enableforcedlogoff", r
->enableforcedlogoff
);
8088 static enum ndr_err_code
ndr_push_srvsvc_NetSrvInfo1516(struct ndr_push
*ndr
, int ndr_flags
, const struct srvsvc_NetSrvInfo1516
*r
)
8090 if (ndr_flags
& NDR_SCALARS
) {
8091 NDR_CHECK(ndr_push_align(ndr
, 4));
8092 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->timesource
));
8094 if (ndr_flags
& NDR_BUFFERS
) {
8096 return NDR_ERR_SUCCESS
;
8099 static enum ndr_err_code
ndr_pull_srvsvc_NetSrvInfo1516(struct ndr_pull
*ndr
, int ndr_flags
, struct srvsvc_NetSrvInfo1516
*r
)
8101 if (ndr_flags
& NDR_SCALARS
) {
8102 NDR_CHECK(ndr_pull_align(ndr
, 4));
8103 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->timesource
));
8105 if (ndr_flags
& NDR_BUFFERS
) {
8107 return NDR_ERR_SUCCESS
;
8110 _PUBLIC_
void ndr_print_srvsvc_NetSrvInfo1516(struct ndr_print
*ndr
, const char *name
, const struct srvsvc_NetSrvInfo1516
*r
)
8112 ndr_print_struct(ndr
, name
, "srvsvc_NetSrvInfo1516");
8114 ndr_print_uint32(ndr
, "timesource", r
->timesource
);
8118 static enum ndr_err_code
ndr_push_srvsvc_NetSrvInfo1518(struct ndr_push
*ndr
, int ndr_flags
, const struct srvsvc_NetSrvInfo1518
*r
)
8120 if (ndr_flags
& NDR_SCALARS
) {
8121 NDR_CHECK(ndr_push_align(ndr
, 4));
8122 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->lmannounce
));
8124 if (ndr_flags
& NDR_BUFFERS
) {
8126 return NDR_ERR_SUCCESS
;
8129 static enum ndr_err_code
ndr_pull_srvsvc_NetSrvInfo1518(struct ndr_pull
*ndr
, int ndr_flags
, struct srvsvc_NetSrvInfo1518
*r
)
8131 if (ndr_flags
& NDR_SCALARS
) {
8132 NDR_CHECK(ndr_pull_align(ndr
, 4));
8133 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->lmannounce
));
8135 if (ndr_flags
& NDR_BUFFERS
) {
8137 return NDR_ERR_SUCCESS
;
8140 _PUBLIC_
void ndr_print_srvsvc_NetSrvInfo1518(struct ndr_print
*ndr
, const char *name
, const struct srvsvc_NetSrvInfo1518
*r
)
8142 ndr_print_struct(ndr
, name
, "srvsvc_NetSrvInfo1518");
8144 ndr_print_uint32(ndr
, "lmannounce", r
->lmannounce
);
8148 static enum ndr_err_code
ndr_push_srvsvc_NetSrvInfo1520(struct ndr_push
*ndr
, int ndr_flags
, const struct srvsvc_NetSrvInfo1520
*r
)
8150 if (ndr_flags
& NDR_SCALARS
) {
8151 NDR_CHECK(ndr_push_align(ndr
, 4));
8152 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->maxcopyreadlen
));
8154 if (ndr_flags
& NDR_BUFFERS
) {
8156 return NDR_ERR_SUCCESS
;
8159 static enum ndr_err_code
ndr_pull_srvsvc_NetSrvInfo1520(struct ndr_pull
*ndr
, int ndr_flags
, struct srvsvc_NetSrvInfo1520
*r
)
8161 if (ndr_flags
& NDR_SCALARS
) {
8162 NDR_CHECK(ndr_pull_align(ndr
, 4));
8163 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->maxcopyreadlen
));
8165 if (ndr_flags
& NDR_BUFFERS
) {
8167 return NDR_ERR_SUCCESS
;
8170 _PUBLIC_
void ndr_print_srvsvc_NetSrvInfo1520(struct ndr_print
*ndr
, const char *name
, const struct srvsvc_NetSrvInfo1520
*r
)
8172 ndr_print_struct(ndr
, name
, "srvsvc_NetSrvInfo1520");
8174 ndr_print_uint32(ndr
, "maxcopyreadlen", r
->maxcopyreadlen
);
8178 static enum ndr_err_code
ndr_push_srvsvc_NetSrvInfo1521(struct ndr_push
*ndr
, int ndr_flags
, const struct srvsvc_NetSrvInfo1521
*r
)
8180 if (ndr_flags
& NDR_SCALARS
) {
8181 NDR_CHECK(ndr_push_align(ndr
, 4));
8182 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->maxcopywritelen
));
8184 if (ndr_flags
& NDR_BUFFERS
) {
8186 return NDR_ERR_SUCCESS
;
8189 static enum ndr_err_code
ndr_pull_srvsvc_NetSrvInfo1521(struct ndr_pull
*ndr
, int ndr_flags
, struct srvsvc_NetSrvInfo1521
*r
)
8191 if (ndr_flags
& NDR_SCALARS
) {
8192 NDR_CHECK(ndr_pull_align(ndr
, 4));
8193 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->maxcopywritelen
));
8195 if (ndr_flags
& NDR_BUFFERS
) {
8197 return NDR_ERR_SUCCESS
;
8200 _PUBLIC_
void ndr_print_srvsvc_NetSrvInfo1521(struct ndr_print
*ndr
, const char *name
, const struct srvsvc_NetSrvInfo1521
*r
)
8202 ndr_print_struct(ndr
, name
, "srvsvc_NetSrvInfo1521");
8204 ndr_print_uint32(ndr
, "maxcopywritelen", r
->maxcopywritelen
);
8208 static enum ndr_err_code
ndr_push_srvsvc_NetSrvInfo1522(struct ndr_push
*ndr
, int ndr_flags
, const struct srvsvc_NetSrvInfo1522
*r
)
8210 if (ndr_flags
& NDR_SCALARS
) {
8211 NDR_CHECK(ndr_push_align(ndr
, 4));
8212 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->minkeepsearch
));
8214 if (ndr_flags
& NDR_BUFFERS
) {
8216 return NDR_ERR_SUCCESS
;
8219 static enum ndr_err_code
ndr_pull_srvsvc_NetSrvInfo1522(struct ndr_pull
*ndr
, int ndr_flags
, struct srvsvc_NetSrvInfo1522
*r
)
8221 if (ndr_flags
& NDR_SCALARS
) {
8222 NDR_CHECK(ndr_pull_align(ndr
, 4));
8223 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->minkeepsearch
));
8225 if (ndr_flags
& NDR_BUFFERS
) {
8227 return NDR_ERR_SUCCESS
;
8230 _PUBLIC_
void ndr_print_srvsvc_NetSrvInfo1522(struct ndr_print
*ndr
, const char *name
, const struct srvsvc_NetSrvInfo1522
*r
)
8232 ndr_print_struct(ndr
, name
, "srvsvc_NetSrvInfo1522");
8234 ndr_print_uint32(ndr
, "minkeepsearch", r
->minkeepsearch
);
8238 static enum ndr_err_code
ndr_push_srvsvc_NetSrvInfo1523(struct ndr_push
*ndr
, int ndr_flags
, const struct srvsvc_NetSrvInfo1523
*r
)
8240 if (ndr_flags
& NDR_SCALARS
) {
8241 NDR_CHECK(ndr_push_align(ndr
, 4));
8242 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->maxkeepsearch
));
8244 if (ndr_flags
& NDR_BUFFERS
) {
8246 return NDR_ERR_SUCCESS
;
8249 static enum ndr_err_code
ndr_pull_srvsvc_NetSrvInfo1523(struct ndr_pull
*ndr
, int ndr_flags
, struct srvsvc_NetSrvInfo1523
*r
)
8251 if (ndr_flags
& NDR_SCALARS
) {
8252 NDR_CHECK(ndr_pull_align(ndr
, 4));
8253 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->maxkeepsearch
));
8255 if (ndr_flags
& NDR_BUFFERS
) {
8257 return NDR_ERR_SUCCESS
;
8260 _PUBLIC_
void ndr_print_srvsvc_NetSrvInfo1523(struct ndr_print
*ndr
, const char *name
, const struct srvsvc_NetSrvInfo1523
*r
)
8262 ndr_print_struct(ndr
, name
, "srvsvc_NetSrvInfo1523");
8264 ndr_print_uint32(ndr
, "maxkeepsearch", r
->maxkeepsearch
);
8268 static enum ndr_err_code
ndr_push_srvsvc_NetSrvInfo1524(struct ndr_push
*ndr
, int ndr_flags
, const struct srvsvc_NetSrvInfo1524
*r
)
8270 if (ndr_flags
& NDR_SCALARS
) {
8271 NDR_CHECK(ndr_push_align(ndr
, 4));
8272 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->minkeepcomplsearch
));
8274 if (ndr_flags
& NDR_BUFFERS
) {
8276 return NDR_ERR_SUCCESS
;
8279 static enum ndr_err_code
ndr_pull_srvsvc_NetSrvInfo1524(struct ndr_pull
*ndr
, int ndr_flags
, struct srvsvc_NetSrvInfo1524
*r
)
8281 if (ndr_flags
& NDR_SCALARS
) {
8282 NDR_CHECK(ndr_pull_align(ndr
, 4));
8283 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->minkeepcomplsearch
));
8285 if (ndr_flags
& NDR_BUFFERS
) {
8287 return NDR_ERR_SUCCESS
;
8290 _PUBLIC_
void ndr_print_srvsvc_NetSrvInfo1524(struct ndr_print
*ndr
, const char *name
, const struct srvsvc_NetSrvInfo1524
*r
)
8292 ndr_print_struct(ndr
, name
, "srvsvc_NetSrvInfo1524");
8294 ndr_print_uint32(ndr
, "minkeepcomplsearch", r
->minkeepcomplsearch
);
8298 static enum ndr_err_code
ndr_push_srvsvc_NetSrvInfo1525(struct ndr_push
*ndr
, int ndr_flags
, const struct srvsvc_NetSrvInfo1525
*r
)
8300 if (ndr_flags
& NDR_SCALARS
) {
8301 NDR_CHECK(ndr_push_align(ndr
, 4));
8302 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->maxkeepcomplsearch
));
8304 if (ndr_flags
& NDR_BUFFERS
) {
8306 return NDR_ERR_SUCCESS
;
8309 static enum ndr_err_code
ndr_pull_srvsvc_NetSrvInfo1525(struct ndr_pull
*ndr
, int ndr_flags
, struct srvsvc_NetSrvInfo1525
*r
)
8311 if (ndr_flags
& NDR_SCALARS
) {
8312 NDR_CHECK(ndr_pull_align(ndr
, 4));
8313 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->maxkeepcomplsearch
));
8315 if (ndr_flags
& NDR_BUFFERS
) {
8317 return NDR_ERR_SUCCESS
;
8320 _PUBLIC_
void ndr_print_srvsvc_NetSrvInfo1525(struct ndr_print
*ndr
, const char *name
, const struct srvsvc_NetSrvInfo1525
*r
)
8322 ndr_print_struct(ndr
, name
, "srvsvc_NetSrvInfo1525");
8324 ndr_print_uint32(ndr
, "maxkeepcomplsearch", r
->maxkeepcomplsearch
);
8328 static enum ndr_err_code
ndr_push_srvsvc_NetSrvInfo1528(struct ndr_push
*ndr
, int ndr_flags
, const struct srvsvc_NetSrvInfo1528
*r
)
8330 if (ndr_flags
& NDR_SCALARS
) {
8331 NDR_CHECK(ndr_push_align(ndr
, 4));
8332 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->scavtimeout
));
8334 if (ndr_flags
& NDR_BUFFERS
) {
8336 return NDR_ERR_SUCCESS
;
8339 static enum ndr_err_code
ndr_pull_srvsvc_NetSrvInfo1528(struct ndr_pull
*ndr
, int ndr_flags
, struct srvsvc_NetSrvInfo1528
*r
)
8341 if (ndr_flags
& NDR_SCALARS
) {
8342 NDR_CHECK(ndr_pull_align(ndr
, 4));
8343 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->scavtimeout
));
8345 if (ndr_flags
& NDR_BUFFERS
) {
8347 return NDR_ERR_SUCCESS
;
8350 _PUBLIC_
void ndr_print_srvsvc_NetSrvInfo1528(struct ndr_print
*ndr
, const char *name
, const struct srvsvc_NetSrvInfo1528
*r
)
8352 ndr_print_struct(ndr
, name
, "srvsvc_NetSrvInfo1528");
8354 ndr_print_uint32(ndr
, "scavtimeout", r
->scavtimeout
);
8358 static enum ndr_err_code
ndr_push_srvsvc_NetSrvInfo1529(struct ndr_push
*ndr
, int ndr_flags
, const struct srvsvc_NetSrvInfo1529
*r
)
8360 if (ndr_flags
& NDR_SCALARS
) {
8361 NDR_CHECK(ndr_push_align(ndr
, 4));
8362 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->minrcvqueue
));
8364 if (ndr_flags
& NDR_BUFFERS
) {
8366 return NDR_ERR_SUCCESS
;
8369 static enum ndr_err_code
ndr_pull_srvsvc_NetSrvInfo1529(struct ndr_pull
*ndr
, int ndr_flags
, struct srvsvc_NetSrvInfo1529
*r
)
8371 if (ndr_flags
& NDR_SCALARS
) {
8372 NDR_CHECK(ndr_pull_align(ndr
, 4));
8373 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->minrcvqueue
));
8375 if (ndr_flags
& NDR_BUFFERS
) {
8377 return NDR_ERR_SUCCESS
;
8380 _PUBLIC_
void ndr_print_srvsvc_NetSrvInfo1529(struct ndr_print
*ndr
, const char *name
, const struct srvsvc_NetSrvInfo1529
*r
)
8382 ndr_print_struct(ndr
, name
, "srvsvc_NetSrvInfo1529");
8384 ndr_print_uint32(ndr
, "minrcvqueue", r
->minrcvqueue
);
8388 static enum ndr_err_code
ndr_push_srvsvc_NetSrvInfo1530(struct ndr_push
*ndr
, int ndr_flags
, const struct srvsvc_NetSrvInfo1530
*r
)
8390 if (ndr_flags
& NDR_SCALARS
) {
8391 NDR_CHECK(ndr_push_align(ndr
, 4));
8392 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->minfreeworkitems
));
8394 if (ndr_flags
& NDR_BUFFERS
) {
8396 return NDR_ERR_SUCCESS
;
8399 static enum ndr_err_code
ndr_pull_srvsvc_NetSrvInfo1530(struct ndr_pull
*ndr
, int ndr_flags
, struct srvsvc_NetSrvInfo1530
*r
)
8401 if (ndr_flags
& NDR_SCALARS
) {
8402 NDR_CHECK(ndr_pull_align(ndr
, 4));
8403 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->minfreeworkitems
));
8405 if (ndr_flags
& NDR_BUFFERS
) {
8407 return NDR_ERR_SUCCESS
;
8410 _PUBLIC_
void ndr_print_srvsvc_NetSrvInfo1530(struct ndr_print
*ndr
, const char *name
, const struct srvsvc_NetSrvInfo1530
*r
)
8412 ndr_print_struct(ndr
, name
, "srvsvc_NetSrvInfo1530");
8414 ndr_print_uint32(ndr
, "minfreeworkitems", r
->minfreeworkitems
);
8418 static enum ndr_err_code
ndr_push_srvsvc_NetSrvInfo1533(struct ndr_push
*ndr
, int ndr_flags
, const struct srvsvc_NetSrvInfo1533
*r
)
8420 if (ndr_flags
& NDR_SCALARS
) {
8421 NDR_CHECK(ndr_push_align(ndr
, 4));
8422 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->maxmpxct
));
8424 if (ndr_flags
& NDR_BUFFERS
) {
8426 return NDR_ERR_SUCCESS
;
8429 static enum ndr_err_code
ndr_pull_srvsvc_NetSrvInfo1533(struct ndr_pull
*ndr
, int ndr_flags
, struct srvsvc_NetSrvInfo1533
*r
)
8431 if (ndr_flags
& NDR_SCALARS
) {
8432 NDR_CHECK(ndr_pull_align(ndr
, 4));
8433 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->maxmpxct
));
8435 if (ndr_flags
& NDR_BUFFERS
) {
8437 return NDR_ERR_SUCCESS
;
8440 _PUBLIC_
void ndr_print_srvsvc_NetSrvInfo1533(struct ndr_print
*ndr
, const char *name
, const struct srvsvc_NetSrvInfo1533
*r
)
8442 ndr_print_struct(ndr
, name
, "srvsvc_NetSrvInfo1533");
8444 ndr_print_uint32(ndr
, "maxmpxct", r
->maxmpxct
);
8448 static enum ndr_err_code
ndr_push_srvsvc_NetSrvInfo1534(struct ndr_push
*ndr
, int ndr_flags
, const struct srvsvc_NetSrvInfo1534
*r
)
8450 if (ndr_flags
& NDR_SCALARS
) {
8451 NDR_CHECK(ndr_push_align(ndr
, 4));
8452 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->oplockbreakwait
));
8454 if (ndr_flags
& NDR_BUFFERS
) {
8456 return NDR_ERR_SUCCESS
;
8459 static enum ndr_err_code
ndr_pull_srvsvc_NetSrvInfo1534(struct ndr_pull
*ndr
, int ndr_flags
, struct srvsvc_NetSrvInfo1534
*r
)
8461 if (ndr_flags
& NDR_SCALARS
) {
8462 NDR_CHECK(ndr_pull_align(ndr
, 4));
8463 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->oplockbreakwait
));
8465 if (ndr_flags
& NDR_BUFFERS
) {
8467 return NDR_ERR_SUCCESS
;
8470 _PUBLIC_
void ndr_print_srvsvc_NetSrvInfo1534(struct ndr_print
*ndr
, const char *name
, const struct srvsvc_NetSrvInfo1534
*r
)
8472 ndr_print_struct(ndr
, name
, "srvsvc_NetSrvInfo1534");
8474 ndr_print_uint32(ndr
, "oplockbreakwait", r
->oplockbreakwait
);
8478 static enum ndr_err_code
ndr_push_srvsvc_NetSrvInfo1535(struct ndr_push
*ndr
, int ndr_flags
, const struct srvsvc_NetSrvInfo1535
*r
)
8480 if (ndr_flags
& NDR_SCALARS
) {
8481 NDR_CHECK(ndr_push_align(ndr
, 4));
8482 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->oplockbreakresponsewait
));
8484 if (ndr_flags
& NDR_BUFFERS
) {
8486 return NDR_ERR_SUCCESS
;
8489 static enum ndr_err_code
ndr_pull_srvsvc_NetSrvInfo1535(struct ndr_pull
*ndr
, int ndr_flags
, struct srvsvc_NetSrvInfo1535
*r
)
8491 if (ndr_flags
& NDR_SCALARS
) {
8492 NDR_CHECK(ndr_pull_align(ndr
, 4));
8493 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->oplockbreakresponsewait
));
8495 if (ndr_flags
& NDR_BUFFERS
) {
8497 return NDR_ERR_SUCCESS
;
8500 _PUBLIC_
void ndr_print_srvsvc_NetSrvInfo1535(struct ndr_print
*ndr
, const char *name
, const struct srvsvc_NetSrvInfo1535
*r
)
8502 ndr_print_struct(ndr
, name
, "srvsvc_NetSrvInfo1535");
8504 ndr_print_uint32(ndr
, "oplockbreakresponsewait", r
->oplockbreakresponsewait
);
8508 static enum ndr_err_code
ndr_push_srvsvc_NetSrvInfo1536(struct ndr_push
*ndr
, int ndr_flags
, const struct srvsvc_NetSrvInfo1536
*r
)
8510 if (ndr_flags
& NDR_SCALARS
) {
8511 NDR_CHECK(ndr_push_align(ndr
, 4));
8512 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->enableoplocks
));
8514 if (ndr_flags
& NDR_BUFFERS
) {
8516 return NDR_ERR_SUCCESS
;
8519 static enum ndr_err_code
ndr_pull_srvsvc_NetSrvInfo1536(struct ndr_pull
*ndr
, int ndr_flags
, struct srvsvc_NetSrvInfo1536
*r
)
8521 if (ndr_flags
& NDR_SCALARS
) {
8522 NDR_CHECK(ndr_pull_align(ndr
, 4));
8523 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->enableoplocks
));
8525 if (ndr_flags
& NDR_BUFFERS
) {
8527 return NDR_ERR_SUCCESS
;
8530 _PUBLIC_
void ndr_print_srvsvc_NetSrvInfo1536(struct ndr_print
*ndr
, const char *name
, const struct srvsvc_NetSrvInfo1536
*r
)
8532 ndr_print_struct(ndr
, name
, "srvsvc_NetSrvInfo1536");
8534 ndr_print_uint32(ndr
, "enableoplocks", r
->enableoplocks
);
8538 static enum ndr_err_code
ndr_push_srvsvc_NetSrvInfo1537(struct ndr_push
*ndr
, int ndr_flags
, const struct srvsvc_NetSrvInfo1537
*r
)
8540 if (ndr_flags
& NDR_SCALARS
) {
8541 NDR_CHECK(ndr_push_align(ndr
, 4));
8542 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->enableoplockforceclose
));
8544 if (ndr_flags
& NDR_BUFFERS
) {
8546 return NDR_ERR_SUCCESS
;
8549 static enum ndr_err_code
ndr_pull_srvsvc_NetSrvInfo1537(struct ndr_pull
*ndr
, int ndr_flags
, struct srvsvc_NetSrvInfo1537
*r
)
8551 if (ndr_flags
& NDR_SCALARS
) {
8552 NDR_CHECK(ndr_pull_align(ndr
, 4));
8553 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->enableoplockforceclose
));
8555 if (ndr_flags
& NDR_BUFFERS
) {
8557 return NDR_ERR_SUCCESS
;
8560 _PUBLIC_
void ndr_print_srvsvc_NetSrvInfo1537(struct ndr_print
*ndr
, const char *name
, const struct srvsvc_NetSrvInfo1537
*r
)
8562 ndr_print_struct(ndr
, name
, "srvsvc_NetSrvInfo1537");
8564 ndr_print_uint32(ndr
, "enableoplockforceclose", r
->enableoplockforceclose
);
8568 static enum ndr_err_code
ndr_push_srvsvc_NetSrvInfo1538(struct ndr_push
*ndr
, int ndr_flags
, const struct srvsvc_NetSrvInfo1538
*r
)
8570 if (ndr_flags
& NDR_SCALARS
) {
8571 NDR_CHECK(ndr_push_align(ndr
, 4));
8572 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->enablefcbopens
));
8574 if (ndr_flags
& NDR_BUFFERS
) {
8576 return NDR_ERR_SUCCESS
;
8579 static enum ndr_err_code
ndr_pull_srvsvc_NetSrvInfo1538(struct ndr_pull
*ndr
, int ndr_flags
, struct srvsvc_NetSrvInfo1538
*r
)
8581 if (ndr_flags
& NDR_SCALARS
) {
8582 NDR_CHECK(ndr_pull_align(ndr
, 4));
8583 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->enablefcbopens
));
8585 if (ndr_flags
& NDR_BUFFERS
) {
8587 return NDR_ERR_SUCCESS
;
8590 _PUBLIC_
void ndr_print_srvsvc_NetSrvInfo1538(struct ndr_print
*ndr
, const char *name
, const struct srvsvc_NetSrvInfo1538
*r
)
8592 ndr_print_struct(ndr
, name
, "srvsvc_NetSrvInfo1538");
8594 ndr_print_uint32(ndr
, "enablefcbopens", r
->enablefcbopens
);
8598 static enum ndr_err_code
ndr_push_srvsvc_NetSrvInfo1539(struct ndr_push
*ndr
, int ndr_flags
, const struct srvsvc_NetSrvInfo1539
*r
)
8600 if (ndr_flags
& NDR_SCALARS
) {
8601 NDR_CHECK(ndr_push_align(ndr
, 4));
8602 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->enableraw
));
8604 if (ndr_flags
& NDR_BUFFERS
) {
8606 return NDR_ERR_SUCCESS
;
8609 static enum ndr_err_code
ndr_pull_srvsvc_NetSrvInfo1539(struct ndr_pull
*ndr
, int ndr_flags
, struct srvsvc_NetSrvInfo1539
*r
)
8611 if (ndr_flags
& NDR_SCALARS
) {
8612 NDR_CHECK(ndr_pull_align(ndr
, 4));
8613 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->enableraw
));
8615 if (ndr_flags
& NDR_BUFFERS
) {
8617 return NDR_ERR_SUCCESS
;
8620 _PUBLIC_
void ndr_print_srvsvc_NetSrvInfo1539(struct ndr_print
*ndr
, const char *name
, const struct srvsvc_NetSrvInfo1539
*r
)
8622 ndr_print_struct(ndr
, name
, "srvsvc_NetSrvInfo1539");
8624 ndr_print_uint32(ndr
, "enableraw", r
->enableraw
);
8628 static enum ndr_err_code
ndr_push_srvsvc_NetSrvInfo1540(struct ndr_push
*ndr
, int ndr_flags
, const struct srvsvc_NetSrvInfo1540
*r
)
8630 if (ndr_flags
& NDR_SCALARS
) {
8631 NDR_CHECK(ndr_push_align(ndr
, 4));
8632 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->enablesharednetdrives
));
8634 if (ndr_flags
& NDR_BUFFERS
) {
8636 return NDR_ERR_SUCCESS
;
8639 static enum ndr_err_code
ndr_pull_srvsvc_NetSrvInfo1540(struct ndr_pull
*ndr
, int ndr_flags
, struct srvsvc_NetSrvInfo1540
*r
)
8641 if (ndr_flags
& NDR_SCALARS
) {
8642 NDR_CHECK(ndr_pull_align(ndr
, 4));
8643 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->enablesharednetdrives
));
8645 if (ndr_flags
& NDR_BUFFERS
) {
8647 return NDR_ERR_SUCCESS
;
8650 _PUBLIC_
void ndr_print_srvsvc_NetSrvInfo1540(struct ndr_print
*ndr
, const char *name
, const struct srvsvc_NetSrvInfo1540
*r
)
8652 ndr_print_struct(ndr
, name
, "srvsvc_NetSrvInfo1540");
8654 ndr_print_uint32(ndr
, "enablesharednetdrives", r
->enablesharednetdrives
);
8658 static enum ndr_err_code
ndr_push_srvsvc_NetSrvInfo1541(struct ndr_push
*ndr
, int ndr_flags
, const struct srvsvc_NetSrvInfo1541
*r
)
8660 if (ndr_flags
& NDR_SCALARS
) {
8661 NDR_CHECK(ndr_push_align(ndr
, 4));
8662 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->minfreeconnections
));
8664 if (ndr_flags
& NDR_BUFFERS
) {
8666 return NDR_ERR_SUCCESS
;
8669 static enum ndr_err_code
ndr_pull_srvsvc_NetSrvInfo1541(struct ndr_pull
*ndr
, int ndr_flags
, struct srvsvc_NetSrvInfo1541
*r
)
8671 if (ndr_flags
& NDR_SCALARS
) {
8672 NDR_CHECK(ndr_pull_align(ndr
, 4));
8673 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->minfreeconnections
));
8675 if (ndr_flags
& NDR_BUFFERS
) {
8677 return NDR_ERR_SUCCESS
;
8680 _PUBLIC_
void ndr_print_srvsvc_NetSrvInfo1541(struct ndr_print
*ndr
, const char *name
, const struct srvsvc_NetSrvInfo1541
*r
)
8682 ndr_print_struct(ndr
, name
, "srvsvc_NetSrvInfo1541");
8684 ndr_print_uint32(ndr
, "minfreeconnections", r
->minfreeconnections
);
8688 static enum ndr_err_code
ndr_push_srvsvc_NetSrvInfo1542(struct ndr_push
*ndr
, int ndr_flags
, const struct srvsvc_NetSrvInfo1542
*r
)
8690 if (ndr_flags
& NDR_SCALARS
) {
8691 NDR_CHECK(ndr_push_align(ndr
, 4));
8692 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->maxfreeconnections
));
8694 if (ndr_flags
& NDR_BUFFERS
) {
8696 return NDR_ERR_SUCCESS
;
8699 static enum ndr_err_code
ndr_pull_srvsvc_NetSrvInfo1542(struct ndr_pull
*ndr
, int ndr_flags
, struct srvsvc_NetSrvInfo1542
*r
)
8701 if (ndr_flags
& NDR_SCALARS
) {
8702 NDR_CHECK(ndr_pull_align(ndr
, 4));
8703 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->maxfreeconnections
));
8705 if (ndr_flags
& NDR_BUFFERS
) {
8707 return NDR_ERR_SUCCESS
;
8710 _PUBLIC_
void ndr_print_srvsvc_NetSrvInfo1542(struct ndr_print
*ndr
, const char *name
, const struct srvsvc_NetSrvInfo1542
*r
)
8712 ndr_print_struct(ndr
, name
, "srvsvc_NetSrvInfo1542");
8714 ndr_print_uint32(ndr
, "maxfreeconnections", r
->maxfreeconnections
);
8718 static enum ndr_err_code
ndr_push_srvsvc_NetSrvInfo1543(struct ndr_push
*ndr
, int ndr_flags
, const struct srvsvc_NetSrvInfo1543
*r
)
8720 if (ndr_flags
& NDR_SCALARS
) {
8721 NDR_CHECK(ndr_push_align(ndr
, 4));
8722 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->initsesstable
));
8724 if (ndr_flags
& NDR_BUFFERS
) {
8726 return NDR_ERR_SUCCESS
;
8729 static enum ndr_err_code
ndr_pull_srvsvc_NetSrvInfo1543(struct ndr_pull
*ndr
, int ndr_flags
, struct srvsvc_NetSrvInfo1543
*r
)
8731 if (ndr_flags
& NDR_SCALARS
) {
8732 NDR_CHECK(ndr_pull_align(ndr
, 4));
8733 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->initsesstable
));
8735 if (ndr_flags
& NDR_BUFFERS
) {
8737 return NDR_ERR_SUCCESS
;
8740 _PUBLIC_
void ndr_print_srvsvc_NetSrvInfo1543(struct ndr_print
*ndr
, const char *name
, const struct srvsvc_NetSrvInfo1543
*r
)
8742 ndr_print_struct(ndr
, name
, "srvsvc_NetSrvInfo1543");
8744 ndr_print_uint32(ndr
, "initsesstable", r
->initsesstable
);
8748 static enum ndr_err_code
ndr_push_srvsvc_NetSrvInfo1544(struct ndr_push
*ndr
, int ndr_flags
, const struct srvsvc_NetSrvInfo1544
*r
)
8750 if (ndr_flags
& NDR_SCALARS
) {
8751 NDR_CHECK(ndr_push_align(ndr
, 4));
8752 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->initconntable
));
8754 if (ndr_flags
& NDR_BUFFERS
) {
8756 return NDR_ERR_SUCCESS
;
8759 static enum ndr_err_code
ndr_pull_srvsvc_NetSrvInfo1544(struct ndr_pull
*ndr
, int ndr_flags
, struct srvsvc_NetSrvInfo1544
*r
)
8761 if (ndr_flags
& NDR_SCALARS
) {
8762 NDR_CHECK(ndr_pull_align(ndr
, 4));
8763 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->initconntable
));
8765 if (ndr_flags
& NDR_BUFFERS
) {
8767 return NDR_ERR_SUCCESS
;
8770 _PUBLIC_
void ndr_print_srvsvc_NetSrvInfo1544(struct ndr_print
*ndr
, const char *name
, const struct srvsvc_NetSrvInfo1544
*r
)
8772 ndr_print_struct(ndr
, name
, "srvsvc_NetSrvInfo1544");
8774 ndr_print_uint32(ndr
, "initconntable", r
->initconntable
);
8778 static enum ndr_err_code
ndr_push_srvsvc_NetSrvInfo1545(struct ndr_push
*ndr
, int ndr_flags
, const struct srvsvc_NetSrvInfo1545
*r
)
8780 if (ndr_flags
& NDR_SCALARS
) {
8781 NDR_CHECK(ndr_push_align(ndr
, 4));
8782 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->initfiletable
));
8784 if (ndr_flags
& NDR_BUFFERS
) {
8786 return NDR_ERR_SUCCESS
;
8789 static enum ndr_err_code
ndr_pull_srvsvc_NetSrvInfo1545(struct ndr_pull
*ndr
, int ndr_flags
, struct srvsvc_NetSrvInfo1545
*r
)
8791 if (ndr_flags
& NDR_SCALARS
) {
8792 NDR_CHECK(ndr_pull_align(ndr
, 4));
8793 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->initfiletable
));
8795 if (ndr_flags
& NDR_BUFFERS
) {
8797 return NDR_ERR_SUCCESS
;
8800 _PUBLIC_
void ndr_print_srvsvc_NetSrvInfo1545(struct ndr_print
*ndr
, const char *name
, const struct srvsvc_NetSrvInfo1545
*r
)
8802 ndr_print_struct(ndr
, name
, "srvsvc_NetSrvInfo1545");
8804 ndr_print_uint32(ndr
, "initfiletable", r
->initfiletable
);
8808 static enum ndr_err_code
ndr_push_srvsvc_NetSrvInfo1546(struct ndr_push
*ndr
, int ndr_flags
, const struct srvsvc_NetSrvInfo1546
*r
)
8810 if (ndr_flags
& NDR_SCALARS
) {
8811 NDR_CHECK(ndr_push_align(ndr
, 4));
8812 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->initsearchtable
));
8814 if (ndr_flags
& NDR_BUFFERS
) {
8816 return NDR_ERR_SUCCESS
;
8819 static enum ndr_err_code
ndr_pull_srvsvc_NetSrvInfo1546(struct ndr_pull
*ndr
, int ndr_flags
, struct srvsvc_NetSrvInfo1546
*r
)
8821 if (ndr_flags
& NDR_SCALARS
) {
8822 NDR_CHECK(ndr_pull_align(ndr
, 4));
8823 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->initsearchtable
));
8825 if (ndr_flags
& NDR_BUFFERS
) {
8827 return NDR_ERR_SUCCESS
;
8830 _PUBLIC_
void ndr_print_srvsvc_NetSrvInfo1546(struct ndr_print
*ndr
, const char *name
, const struct srvsvc_NetSrvInfo1546
*r
)
8832 ndr_print_struct(ndr
, name
, "srvsvc_NetSrvInfo1546");
8834 ndr_print_uint32(ndr
, "initsearchtable", r
->initsearchtable
);
8838 static enum ndr_err_code
ndr_push_srvsvc_NetSrvInfo1547(struct ndr_push
*ndr
, int ndr_flags
, const struct srvsvc_NetSrvInfo1547
*r
)
8840 if (ndr_flags
& NDR_SCALARS
) {
8841 NDR_CHECK(ndr_push_align(ndr
, 4));
8842 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->alertsched
));
8844 if (ndr_flags
& NDR_BUFFERS
) {
8846 return NDR_ERR_SUCCESS
;
8849 static enum ndr_err_code
ndr_pull_srvsvc_NetSrvInfo1547(struct ndr_pull
*ndr
, int ndr_flags
, struct srvsvc_NetSrvInfo1547
*r
)
8851 if (ndr_flags
& NDR_SCALARS
) {
8852 NDR_CHECK(ndr_pull_align(ndr
, 4));
8853 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->alertsched
));
8855 if (ndr_flags
& NDR_BUFFERS
) {
8857 return NDR_ERR_SUCCESS
;
8860 _PUBLIC_
void ndr_print_srvsvc_NetSrvInfo1547(struct ndr_print
*ndr
, const char *name
, const struct srvsvc_NetSrvInfo1547
*r
)
8862 ndr_print_struct(ndr
, name
, "srvsvc_NetSrvInfo1547");
8864 ndr_print_uint32(ndr
, "alertsched", r
->alertsched
);
8868 static enum ndr_err_code
ndr_push_srvsvc_NetSrvInfo1548(struct ndr_push
*ndr
, int ndr_flags
, const struct srvsvc_NetSrvInfo1548
*r
)
8870 if (ndr_flags
& NDR_SCALARS
) {
8871 NDR_CHECK(ndr_push_align(ndr
, 4));
8872 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->errortreshold
));
8874 if (ndr_flags
& NDR_BUFFERS
) {
8876 return NDR_ERR_SUCCESS
;
8879 static enum ndr_err_code
ndr_pull_srvsvc_NetSrvInfo1548(struct ndr_pull
*ndr
, int ndr_flags
, struct srvsvc_NetSrvInfo1548
*r
)
8881 if (ndr_flags
& NDR_SCALARS
) {
8882 NDR_CHECK(ndr_pull_align(ndr
, 4));
8883 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->errortreshold
));
8885 if (ndr_flags
& NDR_BUFFERS
) {
8887 return NDR_ERR_SUCCESS
;
8890 _PUBLIC_
void ndr_print_srvsvc_NetSrvInfo1548(struct ndr_print
*ndr
, const char *name
, const struct srvsvc_NetSrvInfo1548
*r
)
8892 ndr_print_struct(ndr
, name
, "srvsvc_NetSrvInfo1548");
8894 ndr_print_uint32(ndr
, "errortreshold", r
->errortreshold
);
8898 static enum ndr_err_code
ndr_push_srvsvc_NetSrvInfo1549(struct ndr_push
*ndr
, int ndr_flags
, const struct srvsvc_NetSrvInfo1549
*r
)
8900 if (ndr_flags
& NDR_SCALARS
) {
8901 NDR_CHECK(ndr_push_align(ndr
, 4));
8902 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->networkerrortreshold
));
8904 if (ndr_flags
& NDR_BUFFERS
) {
8906 return NDR_ERR_SUCCESS
;
8909 static enum ndr_err_code
ndr_pull_srvsvc_NetSrvInfo1549(struct ndr_pull
*ndr
, int ndr_flags
, struct srvsvc_NetSrvInfo1549
*r
)
8911 if (ndr_flags
& NDR_SCALARS
) {
8912 NDR_CHECK(ndr_pull_align(ndr
, 4));
8913 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->networkerrortreshold
));
8915 if (ndr_flags
& NDR_BUFFERS
) {
8917 return NDR_ERR_SUCCESS
;
8920 _PUBLIC_
void ndr_print_srvsvc_NetSrvInfo1549(struct ndr_print
*ndr
, const char *name
, const struct srvsvc_NetSrvInfo1549
*r
)
8922 ndr_print_struct(ndr
, name
, "srvsvc_NetSrvInfo1549");
8924 ndr_print_uint32(ndr
, "networkerrortreshold", r
->networkerrortreshold
);
8928 static enum ndr_err_code
ndr_push_srvsvc_NetSrvInfo1550(struct ndr_push
*ndr
, int ndr_flags
, const struct srvsvc_NetSrvInfo1550
*r
)
8930 if (ndr_flags
& NDR_SCALARS
) {
8931 NDR_CHECK(ndr_push_align(ndr
, 4));
8932 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->diskspacetreshold
));
8934 if (ndr_flags
& NDR_BUFFERS
) {
8936 return NDR_ERR_SUCCESS
;
8939 static enum ndr_err_code
ndr_pull_srvsvc_NetSrvInfo1550(struct ndr_pull
*ndr
, int ndr_flags
, struct srvsvc_NetSrvInfo1550
*r
)
8941 if (ndr_flags
& NDR_SCALARS
) {
8942 NDR_CHECK(ndr_pull_align(ndr
, 4));
8943 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->diskspacetreshold
));
8945 if (ndr_flags
& NDR_BUFFERS
) {
8947 return NDR_ERR_SUCCESS
;
8950 _PUBLIC_
void ndr_print_srvsvc_NetSrvInfo1550(struct ndr_print
*ndr
, const char *name
, const struct srvsvc_NetSrvInfo1550
*r
)
8952 ndr_print_struct(ndr
, name
, "srvsvc_NetSrvInfo1550");
8954 ndr_print_uint32(ndr
, "diskspacetreshold", r
->diskspacetreshold
);
8958 static enum ndr_err_code
ndr_push_srvsvc_NetSrvInfo1552(struct ndr_push
*ndr
, int ndr_flags
, const struct srvsvc_NetSrvInfo1552
*r
)
8960 if (ndr_flags
& NDR_SCALARS
) {
8961 NDR_CHECK(ndr_push_align(ndr
, 4));
8962 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->maxlinkdelay
));
8964 if (ndr_flags
& NDR_BUFFERS
) {
8966 return NDR_ERR_SUCCESS
;
8969 static enum ndr_err_code
ndr_pull_srvsvc_NetSrvInfo1552(struct ndr_pull
*ndr
, int ndr_flags
, struct srvsvc_NetSrvInfo1552
*r
)
8971 if (ndr_flags
& NDR_SCALARS
) {
8972 NDR_CHECK(ndr_pull_align(ndr
, 4));
8973 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->maxlinkdelay
));
8975 if (ndr_flags
& NDR_BUFFERS
) {
8977 return NDR_ERR_SUCCESS
;
8980 _PUBLIC_
void ndr_print_srvsvc_NetSrvInfo1552(struct ndr_print
*ndr
, const char *name
, const struct srvsvc_NetSrvInfo1552
*r
)
8982 ndr_print_struct(ndr
, name
, "srvsvc_NetSrvInfo1552");
8984 ndr_print_uint32(ndr
, "maxlinkdelay", r
->maxlinkdelay
);
8988 static enum ndr_err_code
ndr_push_srvsvc_NetSrvInfo1553(struct ndr_push
*ndr
, int ndr_flags
, const struct srvsvc_NetSrvInfo1553
*r
)
8990 if (ndr_flags
& NDR_SCALARS
) {
8991 NDR_CHECK(ndr_push_align(ndr
, 4));
8992 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->minlinkthroughput
));
8994 if (ndr_flags
& NDR_BUFFERS
) {
8996 return NDR_ERR_SUCCESS
;
8999 static enum ndr_err_code
ndr_pull_srvsvc_NetSrvInfo1553(struct ndr_pull
*ndr
, int ndr_flags
, struct srvsvc_NetSrvInfo1553
*r
)
9001 if (ndr_flags
& NDR_SCALARS
) {
9002 NDR_CHECK(ndr_pull_align(ndr
, 4));
9003 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->minlinkthroughput
));
9005 if (ndr_flags
& NDR_BUFFERS
) {
9007 return NDR_ERR_SUCCESS
;
9010 _PUBLIC_
void ndr_print_srvsvc_NetSrvInfo1553(struct ndr_print
*ndr
, const char *name
, const struct srvsvc_NetSrvInfo1553
*r
)
9012 ndr_print_struct(ndr
, name
, "srvsvc_NetSrvInfo1553");
9014 ndr_print_uint32(ndr
, "minlinkthroughput", r
->minlinkthroughput
);
9018 static enum ndr_err_code
ndr_push_srvsvc_NetSrvInfo1554(struct ndr_push
*ndr
, int ndr_flags
, const struct srvsvc_NetSrvInfo1554
*r
)
9020 if (ndr_flags
& NDR_SCALARS
) {
9021 NDR_CHECK(ndr_push_align(ndr
, 4));
9022 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->linkinfovalidtime
));
9024 if (ndr_flags
& NDR_BUFFERS
) {
9026 return NDR_ERR_SUCCESS
;
9029 static enum ndr_err_code
ndr_pull_srvsvc_NetSrvInfo1554(struct ndr_pull
*ndr
, int ndr_flags
, struct srvsvc_NetSrvInfo1554
*r
)
9031 if (ndr_flags
& NDR_SCALARS
) {
9032 NDR_CHECK(ndr_pull_align(ndr
, 4));
9033 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->linkinfovalidtime
));
9035 if (ndr_flags
& NDR_BUFFERS
) {
9037 return NDR_ERR_SUCCESS
;
9040 _PUBLIC_
void ndr_print_srvsvc_NetSrvInfo1554(struct ndr_print
*ndr
, const char *name
, const struct srvsvc_NetSrvInfo1554
*r
)
9042 ndr_print_struct(ndr
, name
, "srvsvc_NetSrvInfo1554");
9044 ndr_print_uint32(ndr
, "linkinfovalidtime", r
->linkinfovalidtime
);
9048 static enum ndr_err_code
ndr_push_srvsvc_NetSrvInfo1555(struct ndr_push
*ndr
, int ndr_flags
, const struct srvsvc_NetSrvInfo1555
*r
)
9050 if (ndr_flags
& NDR_SCALARS
) {
9051 NDR_CHECK(ndr_push_align(ndr
, 4));
9052 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->scavqosinfoupdatetime
));
9054 if (ndr_flags
& NDR_BUFFERS
) {
9056 return NDR_ERR_SUCCESS
;
9059 static enum ndr_err_code
ndr_pull_srvsvc_NetSrvInfo1555(struct ndr_pull
*ndr
, int ndr_flags
, struct srvsvc_NetSrvInfo1555
*r
)
9061 if (ndr_flags
& NDR_SCALARS
) {
9062 NDR_CHECK(ndr_pull_align(ndr
, 4));
9063 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->scavqosinfoupdatetime
));
9065 if (ndr_flags
& NDR_BUFFERS
) {
9067 return NDR_ERR_SUCCESS
;
9070 _PUBLIC_
void ndr_print_srvsvc_NetSrvInfo1555(struct ndr_print
*ndr
, const char *name
, const struct srvsvc_NetSrvInfo1555
*r
)
9072 ndr_print_struct(ndr
, name
, "srvsvc_NetSrvInfo1555");
9074 ndr_print_uint32(ndr
, "scavqosinfoupdatetime", r
->scavqosinfoupdatetime
);
9078 static enum ndr_err_code
ndr_push_srvsvc_NetSrvInfo1556(struct ndr_push
*ndr
, int ndr_flags
, const struct srvsvc_NetSrvInfo1556
*r
)
9080 if (ndr_flags
& NDR_SCALARS
) {
9081 NDR_CHECK(ndr_push_align(ndr
, 4));
9082 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->maxworkitemidletime
));
9084 if (ndr_flags
& NDR_BUFFERS
) {
9086 return NDR_ERR_SUCCESS
;
9089 static enum ndr_err_code
ndr_pull_srvsvc_NetSrvInfo1556(struct ndr_pull
*ndr
, int ndr_flags
, struct srvsvc_NetSrvInfo1556
*r
)
9091 if (ndr_flags
& NDR_SCALARS
) {
9092 NDR_CHECK(ndr_pull_align(ndr
, 4));
9093 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->maxworkitemidletime
));
9095 if (ndr_flags
& NDR_BUFFERS
) {
9097 return NDR_ERR_SUCCESS
;
9100 _PUBLIC_
void ndr_print_srvsvc_NetSrvInfo1556(struct ndr_print
*ndr
, const char *name
, const struct srvsvc_NetSrvInfo1556
*r
)
9102 ndr_print_struct(ndr
, name
, "srvsvc_NetSrvInfo1556");
9104 ndr_print_uint32(ndr
, "maxworkitemidletime", r
->maxworkitemidletime
);
9108 static enum ndr_err_code
ndr_push_srvsvc_NetSrvInfo(struct ndr_push
*ndr
, int ndr_flags
, const union srvsvc_NetSrvInfo
*r
)
9110 if (ndr_flags
& NDR_SCALARS
) {
9111 int level
= ndr_push_get_switch_value(ndr
, r
);
9112 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, level
));
9115 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->info100
));
9119 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->info101
));
9123 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->info102
));
9127 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->info402
));
9131 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->info403
));
9135 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->info502
));
9139 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->info503
));
9143 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->info599
));
9147 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->info1005
));
9151 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->info1010
));
9155 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->info1016
));
9159 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->info1017
));
9163 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->info1018
));
9167 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->info1107
));
9171 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->info1501
));
9175 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->info1502
));
9179 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->info1503
));
9183 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->info1506
));
9187 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->info1509
));
9191 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->info1510
));
9195 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->info1511
));
9199 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->info1512
));
9203 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->info1513
));
9207 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->info1514
));
9211 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->info1515
));
9215 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->info1516
));
9219 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->info1518
));
9223 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->info1520
));
9227 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->info1521
));
9231 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->info1522
));
9235 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->info1523
));
9239 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->info1524
));
9243 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->info1525
));
9247 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->info1528
));
9251 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->info1529
));
9255 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->info1530
));
9259 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->info1533
));
9263 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->info1534
));
9267 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->info1535
));
9271 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->info1536
));
9275 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->info1537
));
9279 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->info1538
));
9283 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->info1539
));
9287 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->info1540
));
9291 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->info1541
));
9295 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->info1542
));
9299 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->info1543
));
9303 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->info1544
));
9307 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->info1545
));
9311 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->info1546
));
9315 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->info1547
));
9319 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->info1548
));
9323 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->info1549
));
9327 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->info1550
));
9331 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->info1552
));
9335 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->info1553
));
9339 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->info1554
));
9343 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->info1555
));
9347 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->info1556
));
9355 if (ndr_flags
& NDR_BUFFERS
) {
9356 int level
= ndr_push_get_switch_value(ndr
, r
);
9360 NDR_CHECK(ndr_push_srvsvc_NetSrvInfo100(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->info100
));
9366 NDR_CHECK(ndr_push_srvsvc_NetSrvInfo101(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->info101
));
9372 NDR_CHECK(ndr_push_srvsvc_NetSrvInfo102(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->info102
));
9378 NDR_CHECK(ndr_push_srvsvc_NetSrvInfo402(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->info402
));
9384 NDR_CHECK(ndr_push_srvsvc_NetSrvInfo403(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->info403
));
9390 NDR_CHECK(ndr_push_srvsvc_NetSrvInfo502(ndr
, NDR_SCALARS
, r
->info502
));
9396 NDR_CHECK(ndr_push_srvsvc_NetSrvInfo503(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->info503
));
9402 NDR_CHECK(ndr_push_srvsvc_NetSrvInfo599(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->info599
));
9408 NDR_CHECK(ndr_push_srvsvc_NetSrvInfo1005(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->info1005
));
9414 NDR_CHECK(ndr_push_srvsvc_NetSrvInfo1010(ndr
, NDR_SCALARS
, r
->info1010
));
9420 NDR_CHECK(ndr_push_srvsvc_NetSrvInfo1016(ndr
, NDR_SCALARS
, r
->info1016
));
9426 NDR_CHECK(ndr_push_srvsvc_NetSrvInfo1017(ndr
, NDR_SCALARS
, r
->info1017
));
9432 NDR_CHECK(ndr_push_srvsvc_NetSrvInfo1018(ndr
, NDR_SCALARS
, r
->info1018
));
9438 NDR_CHECK(ndr_push_srvsvc_NetSrvInfo1107(ndr
, NDR_SCALARS
, r
->info1107
));
9444 NDR_CHECK(ndr_push_srvsvc_NetSrvInfo1501(ndr
, NDR_SCALARS
, r
->info1501
));
9450 NDR_CHECK(ndr_push_srvsvc_NetSrvInfo1502(ndr
, NDR_SCALARS
, r
->info1502
));
9456 NDR_CHECK(ndr_push_srvsvc_NetSrvInfo1503(ndr
, NDR_SCALARS
, r
->info1503
));
9462 NDR_CHECK(ndr_push_srvsvc_NetSrvInfo1506(ndr
, NDR_SCALARS
, r
->info1506
));
9468 NDR_CHECK(ndr_push_srvsvc_NetSrvInfo1509(ndr
, NDR_SCALARS
, r
->info1509
));
9474 NDR_CHECK(ndr_push_srvsvc_NetSrvInfo1510(ndr
, NDR_SCALARS
, r
->info1510
));
9480 NDR_CHECK(ndr_push_srvsvc_NetSrvInfo1511(ndr
, NDR_SCALARS
, r
->info1511
));
9486 NDR_CHECK(ndr_push_srvsvc_NetSrvInfo1512(ndr
, NDR_SCALARS
, r
->info1512
));
9492 NDR_CHECK(ndr_push_srvsvc_NetSrvInfo1513(ndr
, NDR_SCALARS
, r
->info1513
));
9498 NDR_CHECK(ndr_push_srvsvc_NetSrvInfo1514(ndr
, NDR_SCALARS
, r
->info1514
));
9504 NDR_CHECK(ndr_push_srvsvc_NetSrvInfo1515(ndr
, NDR_SCALARS
, r
->info1515
));
9510 NDR_CHECK(ndr_push_srvsvc_NetSrvInfo1516(ndr
, NDR_SCALARS
, r
->info1516
));
9516 NDR_CHECK(ndr_push_srvsvc_NetSrvInfo1518(ndr
, NDR_SCALARS
, r
->info1518
));
9522 NDR_CHECK(ndr_push_srvsvc_NetSrvInfo1520(ndr
, NDR_SCALARS
, r
->info1520
));
9528 NDR_CHECK(ndr_push_srvsvc_NetSrvInfo1521(ndr
, NDR_SCALARS
, r
->info1521
));
9534 NDR_CHECK(ndr_push_srvsvc_NetSrvInfo1522(ndr
, NDR_SCALARS
, r
->info1522
));
9540 NDR_CHECK(ndr_push_srvsvc_NetSrvInfo1523(ndr
, NDR_SCALARS
, r
->info1523
));
9546 NDR_CHECK(ndr_push_srvsvc_NetSrvInfo1524(ndr
, NDR_SCALARS
, r
->info1524
));
9552 NDR_CHECK(ndr_push_srvsvc_NetSrvInfo1525(ndr
, NDR_SCALARS
, r
->info1525
));
9558 NDR_CHECK(ndr_push_srvsvc_NetSrvInfo1528(ndr
, NDR_SCALARS
, r
->info1528
));
9564 NDR_CHECK(ndr_push_srvsvc_NetSrvInfo1529(ndr
, NDR_SCALARS
, r
->info1529
));
9570 NDR_CHECK(ndr_push_srvsvc_NetSrvInfo1530(ndr
, NDR_SCALARS
, r
->info1530
));
9576 NDR_CHECK(ndr_push_srvsvc_NetSrvInfo1533(ndr
, NDR_SCALARS
, r
->info1533
));
9582 NDR_CHECK(ndr_push_srvsvc_NetSrvInfo1534(ndr
, NDR_SCALARS
, r
->info1534
));
9588 NDR_CHECK(ndr_push_srvsvc_NetSrvInfo1535(ndr
, NDR_SCALARS
, r
->info1535
));
9594 NDR_CHECK(ndr_push_srvsvc_NetSrvInfo1536(ndr
, NDR_SCALARS
, r
->info1536
));
9600 NDR_CHECK(ndr_push_srvsvc_NetSrvInfo1537(ndr
, NDR_SCALARS
, r
->info1537
));
9606 NDR_CHECK(ndr_push_srvsvc_NetSrvInfo1538(ndr
, NDR_SCALARS
, r
->info1538
));
9612 NDR_CHECK(ndr_push_srvsvc_NetSrvInfo1539(ndr
, NDR_SCALARS
, r
->info1539
));
9618 NDR_CHECK(ndr_push_srvsvc_NetSrvInfo1540(ndr
, NDR_SCALARS
, r
->info1540
));
9624 NDR_CHECK(ndr_push_srvsvc_NetSrvInfo1541(ndr
, NDR_SCALARS
, r
->info1541
));
9630 NDR_CHECK(ndr_push_srvsvc_NetSrvInfo1542(ndr
, NDR_SCALARS
, r
->info1542
));
9636 NDR_CHECK(ndr_push_srvsvc_NetSrvInfo1543(ndr
, NDR_SCALARS
, r
->info1543
));
9642 NDR_CHECK(ndr_push_srvsvc_NetSrvInfo1544(ndr
, NDR_SCALARS
, r
->info1544
));
9648 NDR_CHECK(ndr_push_srvsvc_NetSrvInfo1545(ndr
, NDR_SCALARS
, r
->info1545
));
9654 NDR_CHECK(ndr_push_srvsvc_NetSrvInfo1546(ndr
, NDR_SCALARS
, r
->info1546
));
9660 NDR_CHECK(ndr_push_srvsvc_NetSrvInfo1547(ndr
, NDR_SCALARS
, r
->info1547
));
9666 NDR_CHECK(ndr_push_srvsvc_NetSrvInfo1548(ndr
, NDR_SCALARS
, r
->info1548
));
9672 NDR_CHECK(ndr_push_srvsvc_NetSrvInfo1549(ndr
, NDR_SCALARS
, r
->info1549
));
9678 NDR_CHECK(ndr_push_srvsvc_NetSrvInfo1550(ndr
, NDR_SCALARS
, r
->info1550
));
9684 NDR_CHECK(ndr_push_srvsvc_NetSrvInfo1552(ndr
, NDR_SCALARS
, r
->info1552
));
9690 NDR_CHECK(ndr_push_srvsvc_NetSrvInfo1553(ndr
, NDR_SCALARS
, r
->info1553
));
9696 NDR_CHECK(ndr_push_srvsvc_NetSrvInfo1554(ndr
, NDR_SCALARS
, r
->info1554
));
9702 NDR_CHECK(ndr_push_srvsvc_NetSrvInfo1555(ndr
, NDR_SCALARS
, r
->info1555
));
9708 NDR_CHECK(ndr_push_srvsvc_NetSrvInfo1556(ndr
, NDR_SCALARS
, r
->info1556
));
9717 return NDR_ERR_SUCCESS
;
9720 static enum ndr_err_code
ndr_pull_srvsvc_NetSrvInfo(struct ndr_pull
*ndr
, int ndr_flags
, union srvsvc_NetSrvInfo
*r
)
9724 TALLOC_CTX
*_mem_save_info100_0
;
9725 TALLOC_CTX
*_mem_save_info101_0
;
9726 TALLOC_CTX
*_mem_save_info102_0
;
9727 TALLOC_CTX
*_mem_save_info402_0
;
9728 TALLOC_CTX
*_mem_save_info403_0
;
9729 TALLOC_CTX
*_mem_save_info502_0
;
9730 TALLOC_CTX
*_mem_save_info503_0
;
9731 TALLOC_CTX
*_mem_save_info599_0
;
9732 TALLOC_CTX
*_mem_save_info1005_0
;
9733 TALLOC_CTX
*_mem_save_info1010_0
;
9734 TALLOC_CTX
*_mem_save_info1016_0
;
9735 TALLOC_CTX
*_mem_save_info1017_0
;
9736 TALLOC_CTX
*_mem_save_info1018_0
;
9737 TALLOC_CTX
*_mem_save_info1107_0
;
9738 TALLOC_CTX
*_mem_save_info1501_0
;
9739 TALLOC_CTX
*_mem_save_info1502_0
;
9740 TALLOC_CTX
*_mem_save_info1503_0
;
9741 TALLOC_CTX
*_mem_save_info1506_0
;
9742 TALLOC_CTX
*_mem_save_info1509_0
;
9743 TALLOC_CTX
*_mem_save_info1510_0
;
9744 TALLOC_CTX
*_mem_save_info1511_0
;
9745 TALLOC_CTX
*_mem_save_info1512_0
;
9746 TALLOC_CTX
*_mem_save_info1513_0
;
9747 TALLOC_CTX
*_mem_save_info1514_0
;
9748 TALLOC_CTX
*_mem_save_info1515_0
;
9749 TALLOC_CTX
*_mem_save_info1516_0
;
9750 TALLOC_CTX
*_mem_save_info1518_0
;
9751 TALLOC_CTX
*_mem_save_info1520_0
;
9752 TALLOC_CTX
*_mem_save_info1521_0
;
9753 TALLOC_CTX
*_mem_save_info1522_0
;
9754 TALLOC_CTX
*_mem_save_info1523_0
;
9755 TALLOC_CTX
*_mem_save_info1524_0
;
9756 TALLOC_CTX
*_mem_save_info1525_0
;
9757 TALLOC_CTX
*_mem_save_info1528_0
;
9758 TALLOC_CTX
*_mem_save_info1529_0
;
9759 TALLOC_CTX
*_mem_save_info1530_0
;
9760 TALLOC_CTX
*_mem_save_info1533_0
;
9761 TALLOC_CTX
*_mem_save_info1534_0
;
9762 TALLOC_CTX
*_mem_save_info1535_0
;
9763 TALLOC_CTX
*_mem_save_info1536_0
;
9764 TALLOC_CTX
*_mem_save_info1537_0
;
9765 TALLOC_CTX
*_mem_save_info1538_0
;
9766 TALLOC_CTX
*_mem_save_info1539_0
;
9767 TALLOC_CTX
*_mem_save_info1540_0
;
9768 TALLOC_CTX
*_mem_save_info1541_0
;
9769 TALLOC_CTX
*_mem_save_info1542_0
;
9770 TALLOC_CTX
*_mem_save_info1543_0
;
9771 TALLOC_CTX
*_mem_save_info1544_0
;
9772 TALLOC_CTX
*_mem_save_info1545_0
;
9773 TALLOC_CTX
*_mem_save_info1546_0
;
9774 TALLOC_CTX
*_mem_save_info1547_0
;
9775 TALLOC_CTX
*_mem_save_info1548_0
;
9776 TALLOC_CTX
*_mem_save_info1549_0
;
9777 TALLOC_CTX
*_mem_save_info1550_0
;
9778 TALLOC_CTX
*_mem_save_info1552_0
;
9779 TALLOC_CTX
*_mem_save_info1553_0
;
9780 TALLOC_CTX
*_mem_save_info1554_0
;
9781 TALLOC_CTX
*_mem_save_info1555_0
;
9782 TALLOC_CTX
*_mem_save_info1556_0
;
9783 level
= ndr_pull_get_switch_value(ndr
, r
);
9784 if (ndr_flags
& NDR_SCALARS
) {
9785 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &_level
));
9786 if (_level
!= level
) {
9787 return ndr_pull_error(ndr
, NDR_ERR_BAD_SWITCH
, "Bad switch value %u for r", _level
);
9791 uint32_t _ptr_info100
;
9792 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_info100
));
9794 NDR_PULL_ALLOC(ndr
, r
->info100
);
9801 uint32_t _ptr_info101
;
9802 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_info101
));
9804 NDR_PULL_ALLOC(ndr
, r
->info101
);
9811 uint32_t _ptr_info102
;
9812 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_info102
));
9814 NDR_PULL_ALLOC(ndr
, r
->info102
);
9821 uint32_t _ptr_info402
;
9822 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_info402
));
9824 NDR_PULL_ALLOC(ndr
, r
->info402
);
9831 uint32_t _ptr_info403
;
9832 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_info403
));
9834 NDR_PULL_ALLOC(ndr
, r
->info403
);
9841 uint32_t _ptr_info502
;
9842 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_info502
));
9844 NDR_PULL_ALLOC(ndr
, r
->info502
);
9851 uint32_t _ptr_info503
;
9852 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_info503
));
9854 NDR_PULL_ALLOC(ndr
, r
->info503
);
9861 uint32_t _ptr_info599
;
9862 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_info599
));
9864 NDR_PULL_ALLOC(ndr
, r
->info599
);
9871 uint32_t _ptr_info1005
;
9872 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_info1005
));
9873 if (_ptr_info1005
) {
9874 NDR_PULL_ALLOC(ndr
, r
->info1005
);
9881 uint32_t _ptr_info1010
;
9882 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_info1010
));
9883 if (_ptr_info1010
) {
9884 NDR_PULL_ALLOC(ndr
, r
->info1010
);
9891 uint32_t _ptr_info1016
;
9892 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_info1016
));
9893 if (_ptr_info1016
) {
9894 NDR_PULL_ALLOC(ndr
, r
->info1016
);
9901 uint32_t _ptr_info1017
;
9902 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_info1017
));
9903 if (_ptr_info1017
) {
9904 NDR_PULL_ALLOC(ndr
, r
->info1017
);
9911 uint32_t _ptr_info1018
;
9912 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_info1018
));
9913 if (_ptr_info1018
) {
9914 NDR_PULL_ALLOC(ndr
, r
->info1018
);
9921 uint32_t _ptr_info1107
;
9922 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_info1107
));
9923 if (_ptr_info1107
) {
9924 NDR_PULL_ALLOC(ndr
, r
->info1107
);
9931 uint32_t _ptr_info1501
;
9932 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_info1501
));
9933 if (_ptr_info1501
) {
9934 NDR_PULL_ALLOC(ndr
, r
->info1501
);
9941 uint32_t _ptr_info1502
;
9942 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_info1502
));
9943 if (_ptr_info1502
) {
9944 NDR_PULL_ALLOC(ndr
, r
->info1502
);
9951 uint32_t _ptr_info1503
;
9952 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_info1503
));
9953 if (_ptr_info1503
) {
9954 NDR_PULL_ALLOC(ndr
, r
->info1503
);
9961 uint32_t _ptr_info1506
;
9962 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_info1506
));
9963 if (_ptr_info1506
) {
9964 NDR_PULL_ALLOC(ndr
, r
->info1506
);
9971 uint32_t _ptr_info1509
;
9972 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_info1509
));
9973 if (_ptr_info1509
) {
9974 NDR_PULL_ALLOC(ndr
, r
->info1509
);
9981 uint32_t _ptr_info1510
;
9982 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_info1510
));
9983 if (_ptr_info1510
) {
9984 NDR_PULL_ALLOC(ndr
, r
->info1510
);
9991 uint32_t _ptr_info1511
;
9992 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_info1511
));
9993 if (_ptr_info1511
) {
9994 NDR_PULL_ALLOC(ndr
, r
->info1511
);
10001 uint32_t _ptr_info1512
;
10002 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_info1512
));
10003 if (_ptr_info1512
) {
10004 NDR_PULL_ALLOC(ndr
, r
->info1512
);
10006 r
->info1512
= NULL
;
10011 uint32_t _ptr_info1513
;
10012 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_info1513
));
10013 if (_ptr_info1513
) {
10014 NDR_PULL_ALLOC(ndr
, r
->info1513
);
10016 r
->info1513
= NULL
;
10021 uint32_t _ptr_info1514
;
10022 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_info1514
));
10023 if (_ptr_info1514
) {
10024 NDR_PULL_ALLOC(ndr
, r
->info1514
);
10026 r
->info1514
= NULL
;
10031 uint32_t _ptr_info1515
;
10032 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_info1515
));
10033 if (_ptr_info1515
) {
10034 NDR_PULL_ALLOC(ndr
, r
->info1515
);
10036 r
->info1515
= NULL
;
10041 uint32_t _ptr_info1516
;
10042 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_info1516
));
10043 if (_ptr_info1516
) {
10044 NDR_PULL_ALLOC(ndr
, r
->info1516
);
10046 r
->info1516
= NULL
;
10051 uint32_t _ptr_info1518
;
10052 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_info1518
));
10053 if (_ptr_info1518
) {
10054 NDR_PULL_ALLOC(ndr
, r
->info1518
);
10056 r
->info1518
= NULL
;
10061 uint32_t _ptr_info1520
;
10062 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_info1520
));
10063 if (_ptr_info1520
) {
10064 NDR_PULL_ALLOC(ndr
, r
->info1520
);
10066 r
->info1520
= NULL
;
10071 uint32_t _ptr_info1521
;
10072 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_info1521
));
10073 if (_ptr_info1521
) {
10074 NDR_PULL_ALLOC(ndr
, r
->info1521
);
10076 r
->info1521
= NULL
;
10081 uint32_t _ptr_info1522
;
10082 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_info1522
));
10083 if (_ptr_info1522
) {
10084 NDR_PULL_ALLOC(ndr
, r
->info1522
);
10086 r
->info1522
= NULL
;
10091 uint32_t _ptr_info1523
;
10092 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_info1523
));
10093 if (_ptr_info1523
) {
10094 NDR_PULL_ALLOC(ndr
, r
->info1523
);
10096 r
->info1523
= NULL
;
10101 uint32_t _ptr_info1524
;
10102 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_info1524
));
10103 if (_ptr_info1524
) {
10104 NDR_PULL_ALLOC(ndr
, r
->info1524
);
10106 r
->info1524
= NULL
;
10111 uint32_t _ptr_info1525
;
10112 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_info1525
));
10113 if (_ptr_info1525
) {
10114 NDR_PULL_ALLOC(ndr
, r
->info1525
);
10116 r
->info1525
= NULL
;
10121 uint32_t _ptr_info1528
;
10122 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_info1528
));
10123 if (_ptr_info1528
) {
10124 NDR_PULL_ALLOC(ndr
, r
->info1528
);
10126 r
->info1528
= NULL
;
10131 uint32_t _ptr_info1529
;
10132 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_info1529
));
10133 if (_ptr_info1529
) {
10134 NDR_PULL_ALLOC(ndr
, r
->info1529
);
10136 r
->info1529
= NULL
;
10141 uint32_t _ptr_info1530
;
10142 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_info1530
));
10143 if (_ptr_info1530
) {
10144 NDR_PULL_ALLOC(ndr
, r
->info1530
);
10146 r
->info1530
= NULL
;
10151 uint32_t _ptr_info1533
;
10152 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_info1533
));
10153 if (_ptr_info1533
) {
10154 NDR_PULL_ALLOC(ndr
, r
->info1533
);
10156 r
->info1533
= NULL
;
10161 uint32_t _ptr_info1534
;
10162 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_info1534
));
10163 if (_ptr_info1534
) {
10164 NDR_PULL_ALLOC(ndr
, r
->info1534
);
10166 r
->info1534
= NULL
;
10171 uint32_t _ptr_info1535
;
10172 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_info1535
));
10173 if (_ptr_info1535
) {
10174 NDR_PULL_ALLOC(ndr
, r
->info1535
);
10176 r
->info1535
= NULL
;
10181 uint32_t _ptr_info1536
;
10182 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_info1536
));
10183 if (_ptr_info1536
) {
10184 NDR_PULL_ALLOC(ndr
, r
->info1536
);
10186 r
->info1536
= NULL
;
10191 uint32_t _ptr_info1537
;
10192 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_info1537
));
10193 if (_ptr_info1537
) {
10194 NDR_PULL_ALLOC(ndr
, r
->info1537
);
10196 r
->info1537
= NULL
;
10201 uint32_t _ptr_info1538
;
10202 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_info1538
));
10203 if (_ptr_info1538
) {
10204 NDR_PULL_ALLOC(ndr
, r
->info1538
);
10206 r
->info1538
= NULL
;
10211 uint32_t _ptr_info1539
;
10212 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_info1539
));
10213 if (_ptr_info1539
) {
10214 NDR_PULL_ALLOC(ndr
, r
->info1539
);
10216 r
->info1539
= NULL
;
10221 uint32_t _ptr_info1540
;
10222 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_info1540
));
10223 if (_ptr_info1540
) {
10224 NDR_PULL_ALLOC(ndr
, r
->info1540
);
10226 r
->info1540
= NULL
;
10231 uint32_t _ptr_info1541
;
10232 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_info1541
));
10233 if (_ptr_info1541
) {
10234 NDR_PULL_ALLOC(ndr
, r
->info1541
);
10236 r
->info1541
= NULL
;
10241 uint32_t _ptr_info1542
;
10242 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_info1542
));
10243 if (_ptr_info1542
) {
10244 NDR_PULL_ALLOC(ndr
, r
->info1542
);
10246 r
->info1542
= NULL
;
10251 uint32_t _ptr_info1543
;
10252 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_info1543
));
10253 if (_ptr_info1543
) {
10254 NDR_PULL_ALLOC(ndr
, r
->info1543
);
10256 r
->info1543
= NULL
;
10261 uint32_t _ptr_info1544
;
10262 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_info1544
));
10263 if (_ptr_info1544
) {
10264 NDR_PULL_ALLOC(ndr
, r
->info1544
);
10266 r
->info1544
= NULL
;
10271 uint32_t _ptr_info1545
;
10272 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_info1545
));
10273 if (_ptr_info1545
) {
10274 NDR_PULL_ALLOC(ndr
, r
->info1545
);
10276 r
->info1545
= NULL
;
10281 uint32_t _ptr_info1546
;
10282 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_info1546
));
10283 if (_ptr_info1546
) {
10284 NDR_PULL_ALLOC(ndr
, r
->info1546
);
10286 r
->info1546
= NULL
;
10291 uint32_t _ptr_info1547
;
10292 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_info1547
));
10293 if (_ptr_info1547
) {
10294 NDR_PULL_ALLOC(ndr
, r
->info1547
);
10296 r
->info1547
= NULL
;
10301 uint32_t _ptr_info1548
;
10302 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_info1548
));
10303 if (_ptr_info1548
) {
10304 NDR_PULL_ALLOC(ndr
, r
->info1548
);
10306 r
->info1548
= NULL
;
10311 uint32_t _ptr_info1549
;
10312 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_info1549
));
10313 if (_ptr_info1549
) {
10314 NDR_PULL_ALLOC(ndr
, r
->info1549
);
10316 r
->info1549
= NULL
;
10321 uint32_t _ptr_info1550
;
10322 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_info1550
));
10323 if (_ptr_info1550
) {
10324 NDR_PULL_ALLOC(ndr
, r
->info1550
);
10326 r
->info1550
= NULL
;
10331 uint32_t _ptr_info1552
;
10332 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_info1552
));
10333 if (_ptr_info1552
) {
10334 NDR_PULL_ALLOC(ndr
, r
->info1552
);
10336 r
->info1552
= NULL
;
10341 uint32_t _ptr_info1553
;
10342 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_info1553
));
10343 if (_ptr_info1553
) {
10344 NDR_PULL_ALLOC(ndr
, r
->info1553
);
10346 r
->info1553
= NULL
;
10351 uint32_t _ptr_info1554
;
10352 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_info1554
));
10353 if (_ptr_info1554
) {
10354 NDR_PULL_ALLOC(ndr
, r
->info1554
);
10356 r
->info1554
= NULL
;
10361 uint32_t _ptr_info1555
;
10362 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_info1555
));
10363 if (_ptr_info1555
) {
10364 NDR_PULL_ALLOC(ndr
, r
->info1555
);
10366 r
->info1555
= NULL
;
10371 uint32_t _ptr_info1556
;
10372 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_info1556
));
10373 if (_ptr_info1556
) {
10374 NDR_PULL_ALLOC(ndr
, r
->info1556
);
10376 r
->info1556
= NULL
;
10385 if (ndr_flags
& NDR_BUFFERS
) {
10389 _mem_save_info100_0
= NDR_PULL_GET_MEM_CTX(ndr
);
10390 NDR_PULL_SET_MEM_CTX(ndr
, r
->info100
, 0);
10391 NDR_CHECK(ndr_pull_srvsvc_NetSrvInfo100(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->info100
));
10392 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_info100_0
, 0);
10398 _mem_save_info101_0
= NDR_PULL_GET_MEM_CTX(ndr
);
10399 NDR_PULL_SET_MEM_CTX(ndr
, r
->info101
, 0);
10400 NDR_CHECK(ndr_pull_srvsvc_NetSrvInfo101(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->info101
));
10401 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_info101_0
, 0);
10407 _mem_save_info102_0
= NDR_PULL_GET_MEM_CTX(ndr
);
10408 NDR_PULL_SET_MEM_CTX(ndr
, r
->info102
, 0);
10409 NDR_CHECK(ndr_pull_srvsvc_NetSrvInfo102(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->info102
));
10410 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_info102_0
, 0);
10416 _mem_save_info402_0
= NDR_PULL_GET_MEM_CTX(ndr
);
10417 NDR_PULL_SET_MEM_CTX(ndr
, r
->info402
, 0);
10418 NDR_CHECK(ndr_pull_srvsvc_NetSrvInfo402(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->info402
));
10419 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_info402_0
, 0);
10425 _mem_save_info403_0
= NDR_PULL_GET_MEM_CTX(ndr
);
10426 NDR_PULL_SET_MEM_CTX(ndr
, r
->info403
, 0);
10427 NDR_CHECK(ndr_pull_srvsvc_NetSrvInfo403(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->info403
));
10428 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_info403_0
, 0);
10434 _mem_save_info502_0
= NDR_PULL_GET_MEM_CTX(ndr
);
10435 NDR_PULL_SET_MEM_CTX(ndr
, r
->info502
, 0);
10436 NDR_CHECK(ndr_pull_srvsvc_NetSrvInfo502(ndr
, NDR_SCALARS
, r
->info502
));
10437 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_info502_0
, 0);
10443 _mem_save_info503_0
= NDR_PULL_GET_MEM_CTX(ndr
);
10444 NDR_PULL_SET_MEM_CTX(ndr
, r
->info503
, 0);
10445 NDR_CHECK(ndr_pull_srvsvc_NetSrvInfo503(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->info503
));
10446 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_info503_0
, 0);
10452 _mem_save_info599_0
= NDR_PULL_GET_MEM_CTX(ndr
);
10453 NDR_PULL_SET_MEM_CTX(ndr
, r
->info599
, 0);
10454 NDR_CHECK(ndr_pull_srvsvc_NetSrvInfo599(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->info599
));
10455 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_info599_0
, 0);
10461 _mem_save_info1005_0
= NDR_PULL_GET_MEM_CTX(ndr
);
10462 NDR_PULL_SET_MEM_CTX(ndr
, r
->info1005
, 0);
10463 NDR_CHECK(ndr_pull_srvsvc_NetSrvInfo1005(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->info1005
));
10464 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_info1005_0
, 0);
10470 _mem_save_info1010_0
= NDR_PULL_GET_MEM_CTX(ndr
);
10471 NDR_PULL_SET_MEM_CTX(ndr
, r
->info1010
, 0);
10472 NDR_CHECK(ndr_pull_srvsvc_NetSrvInfo1010(ndr
, NDR_SCALARS
, r
->info1010
));
10473 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_info1010_0
, 0);
10479 _mem_save_info1016_0
= NDR_PULL_GET_MEM_CTX(ndr
);
10480 NDR_PULL_SET_MEM_CTX(ndr
, r
->info1016
, 0);
10481 NDR_CHECK(ndr_pull_srvsvc_NetSrvInfo1016(ndr
, NDR_SCALARS
, r
->info1016
));
10482 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_info1016_0
, 0);
10488 _mem_save_info1017_0
= NDR_PULL_GET_MEM_CTX(ndr
);
10489 NDR_PULL_SET_MEM_CTX(ndr
, r
->info1017
, 0);
10490 NDR_CHECK(ndr_pull_srvsvc_NetSrvInfo1017(ndr
, NDR_SCALARS
, r
->info1017
));
10491 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_info1017_0
, 0);
10497 _mem_save_info1018_0
= NDR_PULL_GET_MEM_CTX(ndr
);
10498 NDR_PULL_SET_MEM_CTX(ndr
, r
->info1018
, 0);
10499 NDR_CHECK(ndr_pull_srvsvc_NetSrvInfo1018(ndr
, NDR_SCALARS
, r
->info1018
));
10500 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_info1018_0
, 0);
10506 _mem_save_info1107_0
= NDR_PULL_GET_MEM_CTX(ndr
);
10507 NDR_PULL_SET_MEM_CTX(ndr
, r
->info1107
, 0);
10508 NDR_CHECK(ndr_pull_srvsvc_NetSrvInfo1107(ndr
, NDR_SCALARS
, r
->info1107
));
10509 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_info1107_0
, 0);
10515 _mem_save_info1501_0
= NDR_PULL_GET_MEM_CTX(ndr
);
10516 NDR_PULL_SET_MEM_CTX(ndr
, r
->info1501
, 0);
10517 NDR_CHECK(ndr_pull_srvsvc_NetSrvInfo1501(ndr
, NDR_SCALARS
, r
->info1501
));
10518 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_info1501_0
, 0);
10524 _mem_save_info1502_0
= NDR_PULL_GET_MEM_CTX(ndr
);
10525 NDR_PULL_SET_MEM_CTX(ndr
, r
->info1502
, 0);
10526 NDR_CHECK(ndr_pull_srvsvc_NetSrvInfo1502(ndr
, NDR_SCALARS
, r
->info1502
));
10527 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_info1502_0
, 0);
10533 _mem_save_info1503_0
= NDR_PULL_GET_MEM_CTX(ndr
);
10534 NDR_PULL_SET_MEM_CTX(ndr
, r
->info1503
, 0);
10535 NDR_CHECK(ndr_pull_srvsvc_NetSrvInfo1503(ndr
, NDR_SCALARS
, r
->info1503
));
10536 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_info1503_0
, 0);
10542 _mem_save_info1506_0
= NDR_PULL_GET_MEM_CTX(ndr
);
10543 NDR_PULL_SET_MEM_CTX(ndr
, r
->info1506
, 0);
10544 NDR_CHECK(ndr_pull_srvsvc_NetSrvInfo1506(ndr
, NDR_SCALARS
, r
->info1506
));
10545 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_info1506_0
, 0);
10551 _mem_save_info1509_0
= NDR_PULL_GET_MEM_CTX(ndr
);
10552 NDR_PULL_SET_MEM_CTX(ndr
, r
->info1509
, 0);
10553 NDR_CHECK(ndr_pull_srvsvc_NetSrvInfo1509(ndr
, NDR_SCALARS
, r
->info1509
));
10554 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_info1509_0
, 0);
10560 _mem_save_info1510_0
= NDR_PULL_GET_MEM_CTX(ndr
);
10561 NDR_PULL_SET_MEM_CTX(ndr
, r
->info1510
, 0);
10562 NDR_CHECK(ndr_pull_srvsvc_NetSrvInfo1510(ndr
, NDR_SCALARS
, r
->info1510
));
10563 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_info1510_0
, 0);
10569 _mem_save_info1511_0
= NDR_PULL_GET_MEM_CTX(ndr
);
10570 NDR_PULL_SET_MEM_CTX(ndr
, r
->info1511
, 0);
10571 NDR_CHECK(ndr_pull_srvsvc_NetSrvInfo1511(ndr
, NDR_SCALARS
, r
->info1511
));
10572 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_info1511_0
, 0);
10578 _mem_save_info1512_0
= NDR_PULL_GET_MEM_CTX(ndr
);
10579 NDR_PULL_SET_MEM_CTX(ndr
, r
->info1512
, 0);
10580 NDR_CHECK(ndr_pull_srvsvc_NetSrvInfo1512(ndr
, NDR_SCALARS
, r
->info1512
));
10581 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_info1512_0
, 0);
10587 _mem_save_info1513_0
= NDR_PULL_GET_MEM_CTX(ndr
);
10588 NDR_PULL_SET_MEM_CTX(ndr
, r
->info1513
, 0);
10589 NDR_CHECK(ndr_pull_srvsvc_NetSrvInfo1513(ndr
, NDR_SCALARS
, r
->info1513
));
10590 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_info1513_0
, 0);
10596 _mem_save_info1514_0
= NDR_PULL_GET_MEM_CTX(ndr
);
10597 NDR_PULL_SET_MEM_CTX(ndr
, r
->info1514
, 0);
10598 NDR_CHECK(ndr_pull_srvsvc_NetSrvInfo1514(ndr
, NDR_SCALARS
, r
->info1514
));
10599 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_info1514_0
, 0);
10605 _mem_save_info1515_0
= NDR_PULL_GET_MEM_CTX(ndr
);
10606 NDR_PULL_SET_MEM_CTX(ndr
, r
->info1515
, 0);
10607 NDR_CHECK(ndr_pull_srvsvc_NetSrvInfo1515(ndr
, NDR_SCALARS
, r
->info1515
));
10608 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_info1515_0
, 0);
10614 _mem_save_info1516_0
= NDR_PULL_GET_MEM_CTX(ndr
);
10615 NDR_PULL_SET_MEM_CTX(ndr
, r
->info1516
, 0);
10616 NDR_CHECK(ndr_pull_srvsvc_NetSrvInfo1516(ndr
, NDR_SCALARS
, r
->info1516
));
10617 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_info1516_0
, 0);
10623 _mem_save_info1518_0
= NDR_PULL_GET_MEM_CTX(ndr
);
10624 NDR_PULL_SET_MEM_CTX(ndr
, r
->info1518
, 0);
10625 NDR_CHECK(ndr_pull_srvsvc_NetSrvInfo1518(ndr
, NDR_SCALARS
, r
->info1518
));
10626 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_info1518_0
, 0);
10632 _mem_save_info1520_0
= NDR_PULL_GET_MEM_CTX(ndr
);
10633 NDR_PULL_SET_MEM_CTX(ndr
, r
->info1520
, 0);
10634 NDR_CHECK(ndr_pull_srvsvc_NetSrvInfo1520(ndr
, NDR_SCALARS
, r
->info1520
));
10635 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_info1520_0
, 0);
10641 _mem_save_info1521_0
= NDR_PULL_GET_MEM_CTX(ndr
);
10642 NDR_PULL_SET_MEM_CTX(ndr
, r
->info1521
, 0);
10643 NDR_CHECK(ndr_pull_srvsvc_NetSrvInfo1521(ndr
, NDR_SCALARS
, r
->info1521
));
10644 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_info1521_0
, 0);
10650 _mem_save_info1522_0
= NDR_PULL_GET_MEM_CTX(ndr
);
10651 NDR_PULL_SET_MEM_CTX(ndr
, r
->info1522
, 0);
10652 NDR_CHECK(ndr_pull_srvsvc_NetSrvInfo1522(ndr
, NDR_SCALARS
, r
->info1522
));
10653 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_info1522_0
, 0);
10659 _mem_save_info1523_0
= NDR_PULL_GET_MEM_CTX(ndr
);
10660 NDR_PULL_SET_MEM_CTX(ndr
, r
->info1523
, 0);
10661 NDR_CHECK(ndr_pull_srvsvc_NetSrvInfo1523(ndr
, NDR_SCALARS
, r
->info1523
));
10662 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_info1523_0
, 0);
10668 _mem_save_info1524_0
= NDR_PULL_GET_MEM_CTX(ndr
);
10669 NDR_PULL_SET_MEM_CTX(ndr
, r
->info1524
, 0);
10670 NDR_CHECK(ndr_pull_srvsvc_NetSrvInfo1524(ndr
, NDR_SCALARS
, r
->info1524
));
10671 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_info1524_0
, 0);
10677 _mem_save_info1525_0
= NDR_PULL_GET_MEM_CTX(ndr
);
10678 NDR_PULL_SET_MEM_CTX(ndr
, r
->info1525
, 0);
10679 NDR_CHECK(ndr_pull_srvsvc_NetSrvInfo1525(ndr
, NDR_SCALARS
, r
->info1525
));
10680 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_info1525_0
, 0);
10686 _mem_save_info1528_0
= NDR_PULL_GET_MEM_CTX(ndr
);
10687 NDR_PULL_SET_MEM_CTX(ndr
, r
->info1528
, 0);
10688 NDR_CHECK(ndr_pull_srvsvc_NetSrvInfo1528(ndr
, NDR_SCALARS
, r
->info1528
));
10689 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_info1528_0
, 0);
10695 _mem_save_info1529_0
= NDR_PULL_GET_MEM_CTX(ndr
);
10696 NDR_PULL_SET_MEM_CTX(ndr
, r
->info1529
, 0);
10697 NDR_CHECK(ndr_pull_srvsvc_NetSrvInfo1529(ndr
, NDR_SCALARS
, r
->info1529
));
10698 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_info1529_0
, 0);
10704 _mem_save_info1530_0
= NDR_PULL_GET_MEM_CTX(ndr
);
10705 NDR_PULL_SET_MEM_CTX(ndr
, r
->info1530
, 0);
10706 NDR_CHECK(ndr_pull_srvsvc_NetSrvInfo1530(ndr
, NDR_SCALARS
, r
->info1530
));
10707 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_info1530_0
, 0);
10713 _mem_save_info1533_0
= NDR_PULL_GET_MEM_CTX(ndr
);
10714 NDR_PULL_SET_MEM_CTX(ndr
, r
->info1533
, 0);
10715 NDR_CHECK(ndr_pull_srvsvc_NetSrvInfo1533(ndr
, NDR_SCALARS
, r
->info1533
));
10716 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_info1533_0
, 0);
10722 _mem_save_info1534_0
= NDR_PULL_GET_MEM_CTX(ndr
);
10723 NDR_PULL_SET_MEM_CTX(ndr
, r
->info1534
, 0);
10724 NDR_CHECK(ndr_pull_srvsvc_NetSrvInfo1534(ndr
, NDR_SCALARS
, r
->info1534
));
10725 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_info1534_0
, 0);
10731 _mem_save_info1535_0
= NDR_PULL_GET_MEM_CTX(ndr
);
10732 NDR_PULL_SET_MEM_CTX(ndr
, r
->info1535
, 0);
10733 NDR_CHECK(ndr_pull_srvsvc_NetSrvInfo1535(ndr
, NDR_SCALARS
, r
->info1535
));
10734 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_info1535_0
, 0);
10740 _mem_save_info1536_0
= NDR_PULL_GET_MEM_CTX(ndr
);
10741 NDR_PULL_SET_MEM_CTX(ndr
, r
->info1536
, 0);
10742 NDR_CHECK(ndr_pull_srvsvc_NetSrvInfo1536(ndr
, NDR_SCALARS
, r
->info1536
));
10743 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_info1536_0
, 0);
10749 _mem_save_info1537_0
= NDR_PULL_GET_MEM_CTX(ndr
);
10750 NDR_PULL_SET_MEM_CTX(ndr
, r
->info1537
, 0);
10751 NDR_CHECK(ndr_pull_srvsvc_NetSrvInfo1537(ndr
, NDR_SCALARS
, r
->info1537
));
10752 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_info1537_0
, 0);
10758 _mem_save_info1538_0
= NDR_PULL_GET_MEM_CTX(ndr
);
10759 NDR_PULL_SET_MEM_CTX(ndr
, r
->info1538
, 0);
10760 NDR_CHECK(ndr_pull_srvsvc_NetSrvInfo1538(ndr
, NDR_SCALARS
, r
->info1538
));
10761 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_info1538_0
, 0);
10767 _mem_save_info1539_0
= NDR_PULL_GET_MEM_CTX(ndr
);
10768 NDR_PULL_SET_MEM_CTX(ndr
, r
->info1539
, 0);
10769 NDR_CHECK(ndr_pull_srvsvc_NetSrvInfo1539(ndr
, NDR_SCALARS
, r
->info1539
));
10770 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_info1539_0
, 0);
10776 _mem_save_info1540_0
= NDR_PULL_GET_MEM_CTX(ndr
);
10777 NDR_PULL_SET_MEM_CTX(ndr
, r
->info1540
, 0);
10778 NDR_CHECK(ndr_pull_srvsvc_NetSrvInfo1540(ndr
, NDR_SCALARS
, r
->info1540
));
10779 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_info1540_0
, 0);
10785 _mem_save_info1541_0
= NDR_PULL_GET_MEM_CTX(ndr
);
10786 NDR_PULL_SET_MEM_CTX(ndr
, r
->info1541
, 0);
10787 NDR_CHECK(ndr_pull_srvsvc_NetSrvInfo1541(ndr
, NDR_SCALARS
, r
->info1541
));
10788 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_info1541_0
, 0);
10794 _mem_save_info1542_0
= NDR_PULL_GET_MEM_CTX(ndr
);
10795 NDR_PULL_SET_MEM_CTX(ndr
, r
->info1542
, 0);
10796 NDR_CHECK(ndr_pull_srvsvc_NetSrvInfo1542(ndr
, NDR_SCALARS
, r
->info1542
));
10797 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_info1542_0
, 0);
10803 _mem_save_info1543_0
= NDR_PULL_GET_MEM_CTX(ndr
);
10804 NDR_PULL_SET_MEM_CTX(ndr
, r
->info1543
, 0);
10805 NDR_CHECK(ndr_pull_srvsvc_NetSrvInfo1543(ndr
, NDR_SCALARS
, r
->info1543
));
10806 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_info1543_0
, 0);
10812 _mem_save_info1544_0
= NDR_PULL_GET_MEM_CTX(ndr
);
10813 NDR_PULL_SET_MEM_CTX(ndr
, r
->info1544
, 0);
10814 NDR_CHECK(ndr_pull_srvsvc_NetSrvInfo1544(ndr
, NDR_SCALARS
, r
->info1544
));
10815 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_info1544_0
, 0);
10821 _mem_save_info1545_0
= NDR_PULL_GET_MEM_CTX(ndr
);
10822 NDR_PULL_SET_MEM_CTX(ndr
, r
->info1545
, 0);
10823 NDR_CHECK(ndr_pull_srvsvc_NetSrvInfo1545(ndr
, NDR_SCALARS
, r
->info1545
));
10824 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_info1545_0
, 0);
10830 _mem_save_info1546_0
= NDR_PULL_GET_MEM_CTX(ndr
);
10831 NDR_PULL_SET_MEM_CTX(ndr
, r
->info1546
, 0);
10832 NDR_CHECK(ndr_pull_srvsvc_NetSrvInfo1546(ndr
, NDR_SCALARS
, r
->info1546
));
10833 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_info1546_0
, 0);
10839 _mem_save_info1547_0
= NDR_PULL_GET_MEM_CTX(ndr
);
10840 NDR_PULL_SET_MEM_CTX(ndr
, r
->info1547
, 0);
10841 NDR_CHECK(ndr_pull_srvsvc_NetSrvInfo1547(ndr
, NDR_SCALARS
, r
->info1547
));
10842 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_info1547_0
, 0);
10848 _mem_save_info1548_0
= NDR_PULL_GET_MEM_CTX(ndr
);
10849 NDR_PULL_SET_MEM_CTX(ndr
, r
->info1548
, 0);
10850 NDR_CHECK(ndr_pull_srvsvc_NetSrvInfo1548(ndr
, NDR_SCALARS
, r
->info1548
));
10851 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_info1548_0
, 0);
10857 _mem_save_info1549_0
= NDR_PULL_GET_MEM_CTX(ndr
);
10858 NDR_PULL_SET_MEM_CTX(ndr
, r
->info1549
, 0);
10859 NDR_CHECK(ndr_pull_srvsvc_NetSrvInfo1549(ndr
, NDR_SCALARS
, r
->info1549
));
10860 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_info1549_0
, 0);
10866 _mem_save_info1550_0
= NDR_PULL_GET_MEM_CTX(ndr
);
10867 NDR_PULL_SET_MEM_CTX(ndr
, r
->info1550
, 0);
10868 NDR_CHECK(ndr_pull_srvsvc_NetSrvInfo1550(ndr
, NDR_SCALARS
, r
->info1550
));
10869 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_info1550_0
, 0);
10875 _mem_save_info1552_0
= NDR_PULL_GET_MEM_CTX(ndr
);
10876 NDR_PULL_SET_MEM_CTX(ndr
, r
->info1552
, 0);
10877 NDR_CHECK(ndr_pull_srvsvc_NetSrvInfo1552(ndr
, NDR_SCALARS
, r
->info1552
));
10878 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_info1552_0
, 0);
10884 _mem_save_info1553_0
= NDR_PULL_GET_MEM_CTX(ndr
);
10885 NDR_PULL_SET_MEM_CTX(ndr
, r
->info1553
, 0);
10886 NDR_CHECK(ndr_pull_srvsvc_NetSrvInfo1553(ndr
, NDR_SCALARS
, r
->info1553
));
10887 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_info1553_0
, 0);
10893 _mem_save_info1554_0
= NDR_PULL_GET_MEM_CTX(ndr
);
10894 NDR_PULL_SET_MEM_CTX(ndr
, r
->info1554
, 0);
10895 NDR_CHECK(ndr_pull_srvsvc_NetSrvInfo1554(ndr
, NDR_SCALARS
, r
->info1554
));
10896 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_info1554_0
, 0);
10902 _mem_save_info1555_0
= NDR_PULL_GET_MEM_CTX(ndr
);
10903 NDR_PULL_SET_MEM_CTX(ndr
, r
->info1555
, 0);
10904 NDR_CHECK(ndr_pull_srvsvc_NetSrvInfo1555(ndr
, NDR_SCALARS
, r
->info1555
));
10905 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_info1555_0
, 0);
10911 _mem_save_info1556_0
= NDR_PULL_GET_MEM_CTX(ndr
);
10912 NDR_PULL_SET_MEM_CTX(ndr
, r
->info1556
, 0);
10913 NDR_CHECK(ndr_pull_srvsvc_NetSrvInfo1556(ndr
, NDR_SCALARS
, r
->info1556
));
10914 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_info1556_0
, 0);
10923 return NDR_ERR_SUCCESS
;
10926 _PUBLIC_
void ndr_print_srvsvc_NetSrvInfo(struct ndr_print
*ndr
, const char *name
, const union srvsvc_NetSrvInfo
*r
)
10929 level
= ndr_print_get_switch_value(ndr
, r
);
10930 ndr_print_union(ndr
, name
, level
, "srvsvc_NetSrvInfo");
10933 ndr_print_ptr(ndr
, "info100", r
->info100
);
10936 ndr_print_srvsvc_NetSrvInfo100(ndr
, "info100", r
->info100
);
10942 ndr_print_ptr(ndr
, "info101", r
->info101
);
10945 ndr_print_srvsvc_NetSrvInfo101(ndr
, "info101", r
->info101
);
10951 ndr_print_ptr(ndr
, "info102", r
->info102
);
10954 ndr_print_srvsvc_NetSrvInfo102(ndr
, "info102", r
->info102
);
10960 ndr_print_ptr(ndr
, "info402", r
->info402
);
10963 ndr_print_srvsvc_NetSrvInfo402(ndr
, "info402", r
->info402
);
10969 ndr_print_ptr(ndr
, "info403", r
->info403
);
10972 ndr_print_srvsvc_NetSrvInfo403(ndr
, "info403", r
->info403
);
10978 ndr_print_ptr(ndr
, "info502", r
->info502
);
10981 ndr_print_srvsvc_NetSrvInfo502(ndr
, "info502", r
->info502
);
10987 ndr_print_ptr(ndr
, "info503", r
->info503
);
10990 ndr_print_srvsvc_NetSrvInfo503(ndr
, "info503", r
->info503
);
10996 ndr_print_ptr(ndr
, "info599", r
->info599
);
10999 ndr_print_srvsvc_NetSrvInfo599(ndr
, "info599", r
->info599
);
11005 ndr_print_ptr(ndr
, "info1005", r
->info1005
);
11008 ndr_print_srvsvc_NetSrvInfo1005(ndr
, "info1005", r
->info1005
);
11014 ndr_print_ptr(ndr
, "info1010", r
->info1010
);
11017 ndr_print_srvsvc_NetSrvInfo1010(ndr
, "info1010", r
->info1010
);
11023 ndr_print_ptr(ndr
, "info1016", r
->info1016
);
11026 ndr_print_srvsvc_NetSrvInfo1016(ndr
, "info1016", r
->info1016
);
11032 ndr_print_ptr(ndr
, "info1017", r
->info1017
);
11035 ndr_print_srvsvc_NetSrvInfo1017(ndr
, "info1017", r
->info1017
);
11041 ndr_print_ptr(ndr
, "info1018", r
->info1018
);
11044 ndr_print_srvsvc_NetSrvInfo1018(ndr
, "info1018", r
->info1018
);
11050 ndr_print_ptr(ndr
, "info1107", r
->info1107
);
11053 ndr_print_srvsvc_NetSrvInfo1107(ndr
, "info1107", r
->info1107
);
11059 ndr_print_ptr(ndr
, "info1501", r
->info1501
);
11062 ndr_print_srvsvc_NetSrvInfo1501(ndr
, "info1501", r
->info1501
);
11068 ndr_print_ptr(ndr
, "info1502", r
->info1502
);
11071 ndr_print_srvsvc_NetSrvInfo1502(ndr
, "info1502", r
->info1502
);
11077 ndr_print_ptr(ndr
, "info1503", r
->info1503
);
11080 ndr_print_srvsvc_NetSrvInfo1503(ndr
, "info1503", r
->info1503
);
11086 ndr_print_ptr(ndr
, "info1506", r
->info1506
);
11089 ndr_print_srvsvc_NetSrvInfo1506(ndr
, "info1506", r
->info1506
);
11095 ndr_print_ptr(ndr
, "info1509", r
->info1509
);
11098 ndr_print_srvsvc_NetSrvInfo1509(ndr
, "info1509", r
->info1509
);
11104 ndr_print_ptr(ndr
, "info1510", r
->info1510
);
11107 ndr_print_srvsvc_NetSrvInfo1510(ndr
, "info1510", r
->info1510
);
11113 ndr_print_ptr(ndr
, "info1511", r
->info1511
);
11116 ndr_print_srvsvc_NetSrvInfo1511(ndr
, "info1511", r
->info1511
);
11122 ndr_print_ptr(ndr
, "info1512", r
->info1512
);
11125 ndr_print_srvsvc_NetSrvInfo1512(ndr
, "info1512", r
->info1512
);
11131 ndr_print_ptr(ndr
, "info1513", r
->info1513
);
11134 ndr_print_srvsvc_NetSrvInfo1513(ndr
, "info1513", r
->info1513
);
11140 ndr_print_ptr(ndr
, "info1514", r
->info1514
);
11143 ndr_print_srvsvc_NetSrvInfo1514(ndr
, "info1514", r
->info1514
);
11149 ndr_print_ptr(ndr
, "info1515", r
->info1515
);
11152 ndr_print_srvsvc_NetSrvInfo1515(ndr
, "info1515", r
->info1515
);
11158 ndr_print_ptr(ndr
, "info1516", r
->info1516
);
11161 ndr_print_srvsvc_NetSrvInfo1516(ndr
, "info1516", r
->info1516
);
11167 ndr_print_ptr(ndr
, "info1518", r
->info1518
);
11170 ndr_print_srvsvc_NetSrvInfo1518(ndr
, "info1518", r
->info1518
);
11176 ndr_print_ptr(ndr
, "info1520", r
->info1520
);
11179 ndr_print_srvsvc_NetSrvInfo1520(ndr
, "info1520", r
->info1520
);
11185 ndr_print_ptr(ndr
, "info1521", r
->info1521
);
11188 ndr_print_srvsvc_NetSrvInfo1521(ndr
, "info1521", r
->info1521
);
11194 ndr_print_ptr(ndr
, "info1522", r
->info1522
);
11197 ndr_print_srvsvc_NetSrvInfo1522(ndr
, "info1522", r
->info1522
);
11203 ndr_print_ptr(ndr
, "info1523", r
->info1523
);
11206 ndr_print_srvsvc_NetSrvInfo1523(ndr
, "info1523", r
->info1523
);
11212 ndr_print_ptr(ndr
, "info1524", r
->info1524
);
11215 ndr_print_srvsvc_NetSrvInfo1524(ndr
, "info1524", r
->info1524
);
11221 ndr_print_ptr(ndr
, "info1525", r
->info1525
);
11224 ndr_print_srvsvc_NetSrvInfo1525(ndr
, "info1525", r
->info1525
);
11230 ndr_print_ptr(ndr
, "info1528", r
->info1528
);
11233 ndr_print_srvsvc_NetSrvInfo1528(ndr
, "info1528", r
->info1528
);
11239 ndr_print_ptr(ndr
, "info1529", r
->info1529
);
11242 ndr_print_srvsvc_NetSrvInfo1529(ndr
, "info1529", r
->info1529
);
11248 ndr_print_ptr(ndr
, "info1530", r
->info1530
);
11251 ndr_print_srvsvc_NetSrvInfo1530(ndr
, "info1530", r
->info1530
);
11257 ndr_print_ptr(ndr
, "info1533", r
->info1533
);
11260 ndr_print_srvsvc_NetSrvInfo1533(ndr
, "info1533", r
->info1533
);
11266 ndr_print_ptr(ndr
, "info1534", r
->info1534
);
11269 ndr_print_srvsvc_NetSrvInfo1534(ndr
, "info1534", r
->info1534
);
11275 ndr_print_ptr(ndr
, "info1535", r
->info1535
);
11278 ndr_print_srvsvc_NetSrvInfo1535(ndr
, "info1535", r
->info1535
);
11284 ndr_print_ptr(ndr
, "info1536", r
->info1536
);
11287 ndr_print_srvsvc_NetSrvInfo1536(ndr
, "info1536", r
->info1536
);
11293 ndr_print_ptr(ndr
, "info1537", r
->info1537
);
11296 ndr_print_srvsvc_NetSrvInfo1537(ndr
, "info1537", r
->info1537
);
11302 ndr_print_ptr(ndr
, "info1538", r
->info1538
);
11305 ndr_print_srvsvc_NetSrvInfo1538(ndr
, "info1538", r
->info1538
);
11311 ndr_print_ptr(ndr
, "info1539", r
->info1539
);
11314 ndr_print_srvsvc_NetSrvInfo1539(ndr
, "info1539", r
->info1539
);
11320 ndr_print_ptr(ndr
, "info1540", r
->info1540
);
11323 ndr_print_srvsvc_NetSrvInfo1540(ndr
, "info1540", r
->info1540
);
11329 ndr_print_ptr(ndr
, "info1541", r
->info1541
);
11332 ndr_print_srvsvc_NetSrvInfo1541(ndr
, "info1541", r
->info1541
);
11338 ndr_print_ptr(ndr
, "info1542", r
->info1542
);
11341 ndr_print_srvsvc_NetSrvInfo1542(ndr
, "info1542", r
->info1542
);
11347 ndr_print_ptr(ndr
, "info1543", r
->info1543
);
11350 ndr_print_srvsvc_NetSrvInfo1543(ndr
, "info1543", r
->info1543
);
11356 ndr_print_ptr(ndr
, "info1544", r
->info1544
);
11359 ndr_print_srvsvc_NetSrvInfo1544(ndr
, "info1544", r
->info1544
);
11365 ndr_print_ptr(ndr
, "info1545", r
->info1545
);
11368 ndr_print_srvsvc_NetSrvInfo1545(ndr
, "info1545", r
->info1545
);
11374 ndr_print_ptr(ndr
, "info1546", r
->info1546
);
11377 ndr_print_srvsvc_NetSrvInfo1546(ndr
, "info1546", r
->info1546
);
11383 ndr_print_ptr(ndr
, "info1547", r
->info1547
);
11386 ndr_print_srvsvc_NetSrvInfo1547(ndr
, "info1547", r
->info1547
);
11392 ndr_print_ptr(ndr
, "info1548", r
->info1548
);
11395 ndr_print_srvsvc_NetSrvInfo1548(ndr
, "info1548", r
->info1548
);
11401 ndr_print_ptr(ndr
, "info1549", r
->info1549
);
11404 ndr_print_srvsvc_NetSrvInfo1549(ndr
, "info1549", r
->info1549
);
11410 ndr_print_ptr(ndr
, "info1550", r
->info1550
);
11413 ndr_print_srvsvc_NetSrvInfo1550(ndr
, "info1550", r
->info1550
);
11419 ndr_print_ptr(ndr
, "info1552", r
->info1552
);
11422 ndr_print_srvsvc_NetSrvInfo1552(ndr
, "info1552", r
->info1552
);
11428 ndr_print_ptr(ndr
, "info1553", r
->info1553
);
11431 ndr_print_srvsvc_NetSrvInfo1553(ndr
, "info1553", r
->info1553
);
11437 ndr_print_ptr(ndr
, "info1554", r
->info1554
);
11440 ndr_print_srvsvc_NetSrvInfo1554(ndr
, "info1554", r
->info1554
);
11446 ndr_print_ptr(ndr
, "info1555", r
->info1555
);
11449 ndr_print_srvsvc_NetSrvInfo1555(ndr
, "info1555", r
->info1555
);
11455 ndr_print_ptr(ndr
, "info1556", r
->info1556
);
11458 ndr_print_srvsvc_NetSrvInfo1556(ndr
, "info1556", r
->info1556
);
11469 static enum ndr_err_code
ndr_push_srvsvc_NetDiskInfo0(struct ndr_push
*ndr
, int ndr_flags
, const struct srvsvc_NetDiskInfo0
*r
)
11471 if (ndr_flags
& NDR_SCALARS
) {
11472 NDR_CHECK(ndr_push_align(ndr
, 4));
11474 uint32_t _flags_save_string
= ndr
->flags
;
11475 ndr_set_flags(&ndr
->flags
, LIBNDR_FLAG_STR_LEN4
);
11476 NDR_CHECK(ndr_push_string(ndr
, NDR_SCALARS
, r
->disk
));
11477 ndr
->flags
= _flags_save_string
;
11480 if (ndr_flags
& NDR_BUFFERS
) {
11482 return NDR_ERR_SUCCESS
;
11485 static enum ndr_err_code
ndr_pull_srvsvc_NetDiskInfo0(struct ndr_pull
*ndr
, int ndr_flags
, struct srvsvc_NetDiskInfo0
*r
)
11487 if (ndr_flags
& NDR_SCALARS
) {
11488 NDR_CHECK(ndr_pull_align(ndr
, 4));
11490 uint32_t _flags_save_string
= ndr
->flags
;
11491 ndr_set_flags(&ndr
->flags
, LIBNDR_FLAG_STR_LEN4
);
11492 NDR_CHECK(ndr_pull_string(ndr
, NDR_SCALARS
, &r
->disk
));
11493 ndr
->flags
= _flags_save_string
;
11496 if (ndr_flags
& NDR_BUFFERS
) {
11498 return NDR_ERR_SUCCESS
;
11501 _PUBLIC_
void ndr_print_srvsvc_NetDiskInfo0(struct ndr_print
*ndr
, const char *name
, const struct srvsvc_NetDiskInfo0
*r
)
11503 ndr_print_struct(ndr
, name
, "srvsvc_NetDiskInfo0");
11505 ndr_print_string(ndr
, "disk", r
->disk
);
11509 static enum ndr_err_code
ndr_push_srvsvc_NetDiskInfo(struct ndr_push
*ndr
, int ndr_flags
, const struct srvsvc_NetDiskInfo
*r
)
11511 uint32_t cntr_disks_1
;
11512 if (ndr_flags
& NDR_SCALARS
) {
11513 NDR_CHECK(ndr_push_align(ndr
, 4));
11514 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->count
));
11515 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->disks
));
11517 if (ndr_flags
& NDR_BUFFERS
) {
11519 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->count
));
11520 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
11521 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->count
));
11522 for (cntr_disks_1
= 0; cntr_disks_1
< r
->count
; cntr_disks_1
++) {
11523 NDR_CHECK(ndr_push_srvsvc_NetDiskInfo0(ndr
, NDR_SCALARS
, &r
->disks
[cntr_disks_1
]));
11527 return NDR_ERR_SUCCESS
;
11530 static enum ndr_err_code
ndr_pull_srvsvc_NetDiskInfo(struct ndr_pull
*ndr
, int ndr_flags
, struct srvsvc_NetDiskInfo
*r
)
11532 uint32_t _ptr_disks
;
11533 uint32_t cntr_disks_1
;
11534 TALLOC_CTX
*_mem_save_disks_0
;
11535 TALLOC_CTX
*_mem_save_disks_1
;
11536 if (ndr_flags
& NDR_SCALARS
) {
11537 NDR_CHECK(ndr_pull_align(ndr
, 4));
11538 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->count
));
11539 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_disks
));
11541 NDR_PULL_ALLOC(ndr
, r
->disks
);
11546 if (ndr_flags
& NDR_BUFFERS
) {
11548 _mem_save_disks_0
= NDR_PULL_GET_MEM_CTX(ndr
);
11549 NDR_PULL_SET_MEM_CTX(ndr
, r
->disks
, 0);
11550 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->disks
));
11551 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->disks
));
11552 if (ndr_get_array_length(ndr
, &r
->disks
) > ndr_get_array_size(ndr
, &r
->disks
)) {
11553 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", ndr_get_array_size(ndr
, &r
->disks
), ndr_get_array_length(ndr
, &r
->disks
));
11555 NDR_PULL_ALLOC_N(ndr
, r
->disks
, ndr_get_array_size(ndr
, &r
->disks
));
11556 _mem_save_disks_1
= NDR_PULL_GET_MEM_CTX(ndr
);
11557 NDR_PULL_SET_MEM_CTX(ndr
, r
->disks
, 0);
11558 for (cntr_disks_1
= 0; cntr_disks_1
< r
->count
; cntr_disks_1
++) {
11559 NDR_CHECK(ndr_pull_srvsvc_NetDiskInfo0(ndr
, NDR_SCALARS
, &r
->disks
[cntr_disks_1
]));
11561 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_disks_1
, 0);
11562 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_disks_0
, 0);
11565 NDR_CHECK(ndr_check_array_size(ndr
, (void*)&r
->disks
, r
->count
));
11568 NDR_CHECK(ndr_check_array_length(ndr
, (void*)&r
->disks
, r
->count
));
11571 return NDR_ERR_SUCCESS
;
11574 _PUBLIC_
void ndr_print_srvsvc_NetDiskInfo(struct ndr_print
*ndr
, const char *name
, const struct srvsvc_NetDiskInfo
*r
)
11576 uint32_t cntr_disks_1
;
11577 ndr_print_struct(ndr
, name
, "srvsvc_NetDiskInfo");
11579 ndr_print_uint32(ndr
, "count", r
->count
);
11580 ndr_print_ptr(ndr
, "disks", r
->disks
);
11583 ndr
->print(ndr
, "%s: ARRAY(%d)", "disks", (int)r
->count
);
11585 for (cntr_disks_1
=0;cntr_disks_1
<r
->count
;cntr_disks_1
++) {
11587 if (asprintf(&idx_1
, "[%d]", cntr_disks_1
) != -1) {
11588 ndr_print_srvsvc_NetDiskInfo0(ndr
, "disks", &r
->disks
[cntr_disks_1
]);
11598 static enum ndr_err_code
ndr_push_srvsvc_Statistics(struct ndr_push
*ndr
, int ndr_flags
, const struct srvsvc_Statistics
*r
)
11600 if (ndr_flags
& NDR_SCALARS
) {
11601 NDR_CHECK(ndr_push_align(ndr
, 4));
11602 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->start
));
11603 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->fopens
));
11604 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->devopens
));
11605 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->jobsqueued
));
11606 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->sopens
));
11607 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->stimeouts
));
11608 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->serrorout
));
11609 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->pwerrors
));
11610 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->permerrors
));
11611 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->syserrors
));
11612 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->bytessent_low
));
11613 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->bytessent_high
));
11614 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->bytesrcvd_low
));
11615 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->bytesrcvd_high
));
11616 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->avresponse
));
11617 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->reqbufneed
));
11618 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->bigbufneed
));
11620 if (ndr_flags
& NDR_BUFFERS
) {
11622 return NDR_ERR_SUCCESS
;
11625 static enum ndr_err_code
ndr_pull_srvsvc_Statistics(struct ndr_pull
*ndr
, int ndr_flags
, struct srvsvc_Statistics
*r
)
11627 if (ndr_flags
& NDR_SCALARS
) {
11628 NDR_CHECK(ndr_pull_align(ndr
, 4));
11629 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->start
));
11630 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->fopens
));
11631 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->devopens
));
11632 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->jobsqueued
));
11633 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->sopens
));
11634 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->stimeouts
));
11635 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->serrorout
));
11636 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->pwerrors
));
11637 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->permerrors
));
11638 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->syserrors
));
11639 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->bytessent_low
));
11640 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->bytessent_high
));
11641 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->bytesrcvd_low
));
11642 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->bytesrcvd_high
));
11643 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->avresponse
));
11644 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->reqbufneed
));
11645 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->bigbufneed
));
11647 if (ndr_flags
& NDR_BUFFERS
) {
11649 return NDR_ERR_SUCCESS
;
11652 _PUBLIC_
void ndr_print_srvsvc_Statistics(struct ndr_print
*ndr
, const char *name
, const struct srvsvc_Statistics
*r
)
11654 ndr_print_struct(ndr
, name
, "srvsvc_Statistics");
11656 ndr_print_uint32(ndr
, "start", r
->start
);
11657 ndr_print_uint32(ndr
, "fopens", r
->fopens
);
11658 ndr_print_uint32(ndr
, "devopens", r
->devopens
);
11659 ndr_print_uint32(ndr
, "jobsqueued", r
->jobsqueued
);
11660 ndr_print_uint32(ndr
, "sopens", r
->sopens
);
11661 ndr_print_uint32(ndr
, "stimeouts", r
->stimeouts
);
11662 ndr_print_uint32(ndr
, "serrorout", r
->serrorout
);
11663 ndr_print_uint32(ndr
, "pwerrors", r
->pwerrors
);
11664 ndr_print_uint32(ndr
, "permerrors", r
->permerrors
);
11665 ndr_print_uint32(ndr
, "syserrors", r
->syserrors
);
11666 ndr_print_uint32(ndr
, "bytessent_low", r
->bytessent_low
);
11667 ndr_print_uint32(ndr
, "bytessent_high", r
->bytessent_high
);
11668 ndr_print_uint32(ndr
, "bytesrcvd_low", r
->bytesrcvd_low
);
11669 ndr_print_uint32(ndr
, "bytesrcvd_high", r
->bytesrcvd_high
);
11670 ndr_print_uint32(ndr
, "avresponse", r
->avresponse
);
11671 ndr_print_uint32(ndr
, "reqbufneed", r
->reqbufneed
);
11672 ndr_print_uint32(ndr
, "bigbufneed", r
->bigbufneed
);
11676 static enum ndr_err_code
ndr_push_srvsvc_NetTransportInfo0(struct ndr_push
*ndr
, int ndr_flags
, const struct srvsvc_NetTransportInfo0
*r
)
11678 if (ndr_flags
& NDR_SCALARS
) {
11679 NDR_CHECK(ndr_push_align(ndr
, 4));
11680 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->vcs
));
11681 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->name
));
11682 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->addr
));
11683 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->addr_len
));
11684 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->net_addr
));
11686 if (ndr_flags
& NDR_BUFFERS
) {
11688 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->name
, CH_UTF16
)));
11689 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
11690 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->name
, CH_UTF16
)));
11691 NDR_CHECK(ndr_push_charset(ndr
, NDR_SCALARS
, r
->name
, ndr_charset_length(r
->name
, CH_UTF16
), sizeof(uint16_t), CH_UTF16
));
11694 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->addr_len
));
11695 NDR_CHECK(ndr_push_array_uint8(ndr
, NDR_SCALARS
, r
->addr
, r
->addr_len
));
11698 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->net_addr
, CH_UTF16
)));
11699 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
11700 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->net_addr
, CH_UTF16
)));
11701 NDR_CHECK(ndr_push_charset(ndr
, NDR_SCALARS
, r
->net_addr
, ndr_charset_length(r
->net_addr
, CH_UTF16
), sizeof(uint16_t), CH_UTF16
));
11704 return NDR_ERR_SUCCESS
;
11707 static enum ndr_err_code
ndr_pull_srvsvc_NetTransportInfo0(struct ndr_pull
*ndr
, int ndr_flags
, struct srvsvc_NetTransportInfo0
*r
)
11709 uint32_t _ptr_name
;
11710 TALLOC_CTX
*_mem_save_name_0
;
11711 uint32_t _ptr_addr
;
11712 TALLOC_CTX
*_mem_save_addr_0
;
11713 uint32_t _ptr_net_addr
;
11714 TALLOC_CTX
*_mem_save_net_addr_0
;
11715 if (ndr_flags
& NDR_SCALARS
) {
11716 NDR_CHECK(ndr_pull_align(ndr
, 4));
11717 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->vcs
));
11718 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_name
));
11720 NDR_PULL_ALLOC(ndr
, r
->name
);
11724 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_addr
));
11726 NDR_PULL_ALLOC(ndr
, r
->addr
);
11730 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->addr_len
));
11731 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_net_addr
));
11732 if (_ptr_net_addr
) {
11733 NDR_PULL_ALLOC(ndr
, r
->net_addr
);
11735 r
->net_addr
= NULL
;
11738 if (ndr_flags
& NDR_BUFFERS
) {
11740 _mem_save_name_0
= NDR_PULL_GET_MEM_CTX(ndr
);
11741 NDR_PULL_SET_MEM_CTX(ndr
, r
->name
, 0);
11742 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->name
));
11743 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->name
));
11744 if (ndr_get_array_length(ndr
, &r
->name
) > ndr_get_array_size(ndr
, &r
->name
)) {
11745 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", ndr_get_array_size(ndr
, &r
->name
), ndr_get_array_length(ndr
, &r
->name
));
11747 NDR_CHECK(ndr_check_string_terminator(ndr
, ndr_get_array_length(ndr
, &r
->name
), sizeof(uint16_t)));
11748 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->name
, ndr_get_array_length(ndr
, &r
->name
), sizeof(uint16_t), CH_UTF16
));
11749 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_name_0
, 0);
11752 _mem_save_addr_0
= NDR_PULL_GET_MEM_CTX(ndr
);
11753 NDR_PULL_SET_MEM_CTX(ndr
, r
->addr
, 0);
11754 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->addr
));
11755 NDR_PULL_ALLOC_N(ndr
, r
->addr
, ndr_get_array_size(ndr
, &r
->addr
));
11756 NDR_CHECK(ndr_pull_array_uint8(ndr
, NDR_SCALARS
, r
->addr
, ndr_get_array_size(ndr
, &r
->addr
)));
11757 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_addr_0
, 0);
11760 _mem_save_net_addr_0
= NDR_PULL_GET_MEM_CTX(ndr
);
11761 NDR_PULL_SET_MEM_CTX(ndr
, r
->net_addr
, 0);
11762 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->net_addr
));
11763 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->net_addr
));
11764 if (ndr_get_array_length(ndr
, &r
->net_addr
) > ndr_get_array_size(ndr
, &r
->net_addr
)) {
11765 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", ndr_get_array_size(ndr
, &r
->net_addr
), ndr_get_array_length(ndr
, &r
->net_addr
));
11767 NDR_CHECK(ndr_check_string_terminator(ndr
, ndr_get_array_length(ndr
, &r
->net_addr
), sizeof(uint16_t)));
11768 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->net_addr
, ndr_get_array_length(ndr
, &r
->net_addr
), sizeof(uint16_t), CH_UTF16
));
11769 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_net_addr_0
, 0);
11772 NDR_CHECK(ndr_check_array_size(ndr
, (void*)&r
->addr
, r
->addr_len
));
11775 return NDR_ERR_SUCCESS
;
11778 _PUBLIC_
void ndr_print_srvsvc_NetTransportInfo0(struct ndr_print
*ndr
, const char *name
, const struct srvsvc_NetTransportInfo0
*r
)
11780 ndr_print_struct(ndr
, name
, "srvsvc_NetTransportInfo0");
11782 ndr_print_uint32(ndr
, "vcs", r
->vcs
);
11783 ndr_print_ptr(ndr
, "name", r
->name
);
11786 ndr_print_string(ndr
, "name", r
->name
);
11789 ndr_print_ptr(ndr
, "addr", r
->addr
);
11792 ndr_print_array_uint8(ndr
, "addr", r
->addr
, r
->addr_len
);
11795 ndr_print_uint32(ndr
, "addr_len", r
->addr_len
);
11796 ndr_print_ptr(ndr
, "net_addr", r
->net_addr
);
11799 ndr_print_string(ndr
, "net_addr", r
->net_addr
);
11805 static enum ndr_err_code
ndr_push_srvsvc_NetTransportCtr0(struct ndr_push
*ndr
, int ndr_flags
, const struct srvsvc_NetTransportCtr0
*r
)
11807 uint32_t cntr_array_1
;
11808 if (ndr_flags
& NDR_SCALARS
) {
11809 NDR_CHECK(ndr_push_align(ndr
, 4));
11810 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->count
));
11811 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->array
));
11813 if (ndr_flags
& NDR_BUFFERS
) {
11815 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->count
));
11816 for (cntr_array_1
= 0; cntr_array_1
< r
->count
; cntr_array_1
++) {
11817 NDR_CHECK(ndr_push_srvsvc_NetTransportInfo0(ndr
, NDR_SCALARS
, &r
->array
[cntr_array_1
]));
11819 for (cntr_array_1
= 0; cntr_array_1
< r
->count
; cntr_array_1
++) {
11820 NDR_CHECK(ndr_push_srvsvc_NetTransportInfo0(ndr
, NDR_BUFFERS
, &r
->array
[cntr_array_1
]));
11824 return NDR_ERR_SUCCESS
;
11827 static enum ndr_err_code
ndr_pull_srvsvc_NetTransportCtr0(struct ndr_pull
*ndr
, int ndr_flags
, struct srvsvc_NetTransportCtr0
*r
)
11829 uint32_t _ptr_array
;
11830 uint32_t cntr_array_1
;
11831 TALLOC_CTX
*_mem_save_array_0
;
11832 TALLOC_CTX
*_mem_save_array_1
;
11833 if (ndr_flags
& NDR_SCALARS
) {
11834 NDR_CHECK(ndr_pull_align(ndr
, 4));
11835 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->count
));
11836 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_array
));
11838 NDR_PULL_ALLOC(ndr
, r
->array
);
11843 if (ndr_flags
& NDR_BUFFERS
) {
11845 _mem_save_array_0
= NDR_PULL_GET_MEM_CTX(ndr
);
11846 NDR_PULL_SET_MEM_CTX(ndr
, r
->array
, 0);
11847 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->array
));
11848 NDR_PULL_ALLOC_N(ndr
, r
->array
, ndr_get_array_size(ndr
, &r
->array
));
11849 _mem_save_array_1
= NDR_PULL_GET_MEM_CTX(ndr
);
11850 NDR_PULL_SET_MEM_CTX(ndr
, r
->array
, 0);
11851 for (cntr_array_1
= 0; cntr_array_1
< r
->count
; cntr_array_1
++) {
11852 NDR_CHECK(ndr_pull_srvsvc_NetTransportInfo0(ndr
, NDR_SCALARS
, &r
->array
[cntr_array_1
]));
11854 for (cntr_array_1
= 0; cntr_array_1
< r
->count
; cntr_array_1
++) {
11855 NDR_CHECK(ndr_pull_srvsvc_NetTransportInfo0(ndr
, NDR_BUFFERS
, &r
->array
[cntr_array_1
]));
11857 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_array_1
, 0);
11858 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_array_0
, 0);
11861 NDR_CHECK(ndr_check_array_size(ndr
, (void*)&r
->array
, r
->count
));
11864 return NDR_ERR_SUCCESS
;
11867 _PUBLIC_
void ndr_print_srvsvc_NetTransportCtr0(struct ndr_print
*ndr
, const char *name
, const struct srvsvc_NetTransportCtr0
*r
)
11869 uint32_t cntr_array_1
;
11870 ndr_print_struct(ndr
, name
, "srvsvc_NetTransportCtr0");
11872 ndr_print_uint32(ndr
, "count", r
->count
);
11873 ndr_print_ptr(ndr
, "array", r
->array
);
11876 ndr
->print(ndr
, "%s: ARRAY(%d)", "array", (int)r
->count
);
11878 for (cntr_array_1
=0;cntr_array_1
<r
->count
;cntr_array_1
++) {
11880 if (asprintf(&idx_1
, "[%d]", cntr_array_1
) != -1) {
11881 ndr_print_srvsvc_NetTransportInfo0(ndr
, "array", &r
->array
[cntr_array_1
]);
11891 static enum ndr_err_code
ndr_push_srvsvc_NetTransportInfo1(struct ndr_push
*ndr
, int ndr_flags
, const struct srvsvc_NetTransportInfo1
*r
)
11893 if (ndr_flags
& NDR_SCALARS
) {
11894 NDR_CHECK(ndr_push_align(ndr
, 4));
11895 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->vcs
));
11896 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->name
));
11897 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->addr
));
11898 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->addr_len
));
11899 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->net_addr
));
11900 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->domain
));
11902 if (ndr_flags
& NDR_BUFFERS
) {
11904 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->name
, CH_UTF16
)));
11905 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
11906 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->name
, CH_UTF16
)));
11907 NDR_CHECK(ndr_push_charset(ndr
, NDR_SCALARS
, r
->name
, ndr_charset_length(r
->name
, CH_UTF16
), sizeof(uint16_t), CH_UTF16
));
11910 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->addr_len
));
11911 NDR_CHECK(ndr_push_array_uint8(ndr
, NDR_SCALARS
, r
->addr
, r
->addr_len
));
11914 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->net_addr
, CH_UTF16
)));
11915 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
11916 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->net_addr
, CH_UTF16
)));
11917 NDR_CHECK(ndr_push_charset(ndr
, NDR_SCALARS
, r
->net_addr
, ndr_charset_length(r
->net_addr
, CH_UTF16
), sizeof(uint16_t), CH_UTF16
));
11920 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->domain
, CH_UTF16
)));
11921 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
11922 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->domain
, CH_UTF16
)));
11923 NDR_CHECK(ndr_push_charset(ndr
, NDR_SCALARS
, r
->domain
, ndr_charset_length(r
->domain
, CH_UTF16
), sizeof(uint16_t), CH_UTF16
));
11926 return NDR_ERR_SUCCESS
;
11929 static enum ndr_err_code
ndr_pull_srvsvc_NetTransportInfo1(struct ndr_pull
*ndr
, int ndr_flags
, struct srvsvc_NetTransportInfo1
*r
)
11931 uint32_t _ptr_name
;
11932 TALLOC_CTX
*_mem_save_name_0
;
11933 uint32_t _ptr_addr
;
11934 TALLOC_CTX
*_mem_save_addr_0
;
11935 uint32_t _ptr_net_addr
;
11936 TALLOC_CTX
*_mem_save_net_addr_0
;
11937 uint32_t _ptr_domain
;
11938 TALLOC_CTX
*_mem_save_domain_0
;
11939 if (ndr_flags
& NDR_SCALARS
) {
11940 NDR_CHECK(ndr_pull_align(ndr
, 4));
11941 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->vcs
));
11942 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_name
));
11944 NDR_PULL_ALLOC(ndr
, r
->name
);
11948 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_addr
));
11950 NDR_PULL_ALLOC(ndr
, r
->addr
);
11954 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->addr_len
));
11955 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_net_addr
));
11956 if (_ptr_net_addr
) {
11957 NDR_PULL_ALLOC(ndr
, r
->net_addr
);
11959 r
->net_addr
= NULL
;
11961 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_domain
));
11963 NDR_PULL_ALLOC(ndr
, r
->domain
);
11968 if (ndr_flags
& NDR_BUFFERS
) {
11970 _mem_save_name_0
= NDR_PULL_GET_MEM_CTX(ndr
);
11971 NDR_PULL_SET_MEM_CTX(ndr
, r
->name
, 0);
11972 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->name
));
11973 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->name
));
11974 if (ndr_get_array_length(ndr
, &r
->name
) > ndr_get_array_size(ndr
, &r
->name
)) {
11975 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", ndr_get_array_size(ndr
, &r
->name
), ndr_get_array_length(ndr
, &r
->name
));
11977 NDR_CHECK(ndr_check_string_terminator(ndr
, ndr_get_array_length(ndr
, &r
->name
), sizeof(uint16_t)));
11978 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->name
, ndr_get_array_length(ndr
, &r
->name
), sizeof(uint16_t), CH_UTF16
));
11979 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_name_0
, 0);
11982 _mem_save_addr_0
= NDR_PULL_GET_MEM_CTX(ndr
);
11983 NDR_PULL_SET_MEM_CTX(ndr
, r
->addr
, 0);
11984 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->addr
));
11985 NDR_PULL_ALLOC_N(ndr
, r
->addr
, ndr_get_array_size(ndr
, &r
->addr
));
11986 NDR_CHECK(ndr_pull_array_uint8(ndr
, NDR_SCALARS
, r
->addr
, ndr_get_array_size(ndr
, &r
->addr
)));
11987 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_addr_0
, 0);
11990 _mem_save_net_addr_0
= NDR_PULL_GET_MEM_CTX(ndr
);
11991 NDR_PULL_SET_MEM_CTX(ndr
, r
->net_addr
, 0);
11992 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->net_addr
));
11993 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->net_addr
));
11994 if (ndr_get_array_length(ndr
, &r
->net_addr
) > ndr_get_array_size(ndr
, &r
->net_addr
)) {
11995 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", ndr_get_array_size(ndr
, &r
->net_addr
), ndr_get_array_length(ndr
, &r
->net_addr
));
11997 NDR_CHECK(ndr_check_string_terminator(ndr
, ndr_get_array_length(ndr
, &r
->net_addr
), sizeof(uint16_t)));
11998 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->net_addr
, ndr_get_array_length(ndr
, &r
->net_addr
), sizeof(uint16_t), CH_UTF16
));
11999 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_net_addr_0
, 0);
12002 _mem_save_domain_0
= NDR_PULL_GET_MEM_CTX(ndr
);
12003 NDR_PULL_SET_MEM_CTX(ndr
, r
->domain
, 0);
12004 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->domain
));
12005 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->domain
));
12006 if (ndr_get_array_length(ndr
, &r
->domain
) > ndr_get_array_size(ndr
, &r
->domain
)) {
12007 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", ndr_get_array_size(ndr
, &r
->domain
), ndr_get_array_length(ndr
, &r
->domain
));
12009 NDR_CHECK(ndr_check_string_terminator(ndr
, ndr_get_array_length(ndr
, &r
->domain
), sizeof(uint16_t)));
12010 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->domain
, ndr_get_array_length(ndr
, &r
->domain
), sizeof(uint16_t), CH_UTF16
));
12011 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_domain_0
, 0);
12014 NDR_CHECK(ndr_check_array_size(ndr
, (void*)&r
->addr
, r
->addr_len
));
12017 return NDR_ERR_SUCCESS
;
12020 _PUBLIC_
void ndr_print_srvsvc_NetTransportInfo1(struct ndr_print
*ndr
, const char *name
, const struct srvsvc_NetTransportInfo1
*r
)
12022 ndr_print_struct(ndr
, name
, "srvsvc_NetTransportInfo1");
12024 ndr_print_uint32(ndr
, "vcs", r
->vcs
);
12025 ndr_print_ptr(ndr
, "name", r
->name
);
12028 ndr_print_string(ndr
, "name", r
->name
);
12031 ndr_print_ptr(ndr
, "addr", r
->addr
);
12034 ndr_print_array_uint8(ndr
, "addr", r
->addr
, r
->addr_len
);
12037 ndr_print_uint32(ndr
, "addr_len", r
->addr_len
);
12038 ndr_print_ptr(ndr
, "net_addr", r
->net_addr
);
12041 ndr_print_string(ndr
, "net_addr", r
->net_addr
);
12044 ndr_print_ptr(ndr
, "domain", r
->domain
);
12047 ndr_print_string(ndr
, "domain", r
->domain
);
12053 static enum ndr_err_code
ndr_push_srvsvc_NetTransportCtr1(struct ndr_push
*ndr
, int ndr_flags
, const struct srvsvc_NetTransportCtr1
*r
)
12055 uint32_t cntr_array_1
;
12056 if (ndr_flags
& NDR_SCALARS
) {
12057 NDR_CHECK(ndr_push_align(ndr
, 4));
12058 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->count
));
12059 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->array
));
12061 if (ndr_flags
& NDR_BUFFERS
) {
12063 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->count
));
12064 for (cntr_array_1
= 0; cntr_array_1
< r
->count
; cntr_array_1
++) {
12065 NDR_CHECK(ndr_push_srvsvc_NetTransportInfo1(ndr
, NDR_SCALARS
, &r
->array
[cntr_array_1
]));
12067 for (cntr_array_1
= 0; cntr_array_1
< r
->count
; cntr_array_1
++) {
12068 NDR_CHECK(ndr_push_srvsvc_NetTransportInfo1(ndr
, NDR_BUFFERS
, &r
->array
[cntr_array_1
]));
12072 return NDR_ERR_SUCCESS
;
12075 static enum ndr_err_code
ndr_pull_srvsvc_NetTransportCtr1(struct ndr_pull
*ndr
, int ndr_flags
, struct srvsvc_NetTransportCtr1
*r
)
12077 uint32_t _ptr_array
;
12078 uint32_t cntr_array_1
;
12079 TALLOC_CTX
*_mem_save_array_0
;
12080 TALLOC_CTX
*_mem_save_array_1
;
12081 if (ndr_flags
& NDR_SCALARS
) {
12082 NDR_CHECK(ndr_pull_align(ndr
, 4));
12083 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->count
));
12084 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_array
));
12086 NDR_PULL_ALLOC(ndr
, r
->array
);
12091 if (ndr_flags
& NDR_BUFFERS
) {
12093 _mem_save_array_0
= NDR_PULL_GET_MEM_CTX(ndr
);
12094 NDR_PULL_SET_MEM_CTX(ndr
, r
->array
, 0);
12095 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->array
));
12096 NDR_PULL_ALLOC_N(ndr
, r
->array
, ndr_get_array_size(ndr
, &r
->array
));
12097 _mem_save_array_1
= NDR_PULL_GET_MEM_CTX(ndr
);
12098 NDR_PULL_SET_MEM_CTX(ndr
, r
->array
, 0);
12099 for (cntr_array_1
= 0; cntr_array_1
< r
->count
; cntr_array_1
++) {
12100 NDR_CHECK(ndr_pull_srvsvc_NetTransportInfo1(ndr
, NDR_SCALARS
, &r
->array
[cntr_array_1
]));
12102 for (cntr_array_1
= 0; cntr_array_1
< r
->count
; cntr_array_1
++) {
12103 NDR_CHECK(ndr_pull_srvsvc_NetTransportInfo1(ndr
, NDR_BUFFERS
, &r
->array
[cntr_array_1
]));
12105 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_array_1
, 0);
12106 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_array_0
, 0);
12109 NDR_CHECK(ndr_check_array_size(ndr
, (void*)&r
->array
, r
->count
));
12112 return NDR_ERR_SUCCESS
;
12115 _PUBLIC_
void ndr_print_srvsvc_NetTransportCtr1(struct ndr_print
*ndr
, const char *name
, const struct srvsvc_NetTransportCtr1
*r
)
12117 uint32_t cntr_array_1
;
12118 ndr_print_struct(ndr
, name
, "srvsvc_NetTransportCtr1");
12120 ndr_print_uint32(ndr
, "count", r
->count
);
12121 ndr_print_ptr(ndr
, "array", r
->array
);
12124 ndr
->print(ndr
, "%s: ARRAY(%d)", "array", (int)r
->count
);
12126 for (cntr_array_1
=0;cntr_array_1
<r
->count
;cntr_array_1
++) {
12128 if (asprintf(&idx_1
, "[%d]", cntr_array_1
) != -1) {
12129 ndr_print_srvsvc_NetTransportInfo1(ndr
, "array", &r
->array
[cntr_array_1
]);
12139 static enum ndr_err_code
ndr_push_srvsvc_NetTransportInfo2(struct ndr_push
*ndr
, int ndr_flags
, const struct srvsvc_NetTransportInfo2
*r
)
12141 if (ndr_flags
& NDR_SCALARS
) {
12142 NDR_CHECK(ndr_push_align(ndr
, 4));
12143 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->vcs
));
12144 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->name
));
12145 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->addr
));
12146 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->addr_len
));
12147 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->net_addr
));
12148 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->domain
));
12149 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->unknown
));
12151 if (ndr_flags
& NDR_BUFFERS
) {
12153 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->name
, CH_UTF16
)));
12154 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
12155 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->name
, CH_UTF16
)));
12156 NDR_CHECK(ndr_push_charset(ndr
, NDR_SCALARS
, r
->name
, ndr_charset_length(r
->name
, CH_UTF16
), sizeof(uint16_t), CH_UTF16
));
12159 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->addr_len
));
12160 NDR_CHECK(ndr_push_array_uint8(ndr
, NDR_SCALARS
, r
->addr
, r
->addr_len
));
12163 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->net_addr
, CH_UTF16
)));
12164 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
12165 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->net_addr
, CH_UTF16
)));
12166 NDR_CHECK(ndr_push_charset(ndr
, NDR_SCALARS
, r
->net_addr
, ndr_charset_length(r
->net_addr
, CH_UTF16
), sizeof(uint16_t), CH_UTF16
));
12169 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->domain
, CH_UTF16
)));
12170 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
12171 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->domain
, CH_UTF16
)));
12172 NDR_CHECK(ndr_push_charset(ndr
, NDR_SCALARS
, r
->domain
, ndr_charset_length(r
->domain
, CH_UTF16
), sizeof(uint16_t), CH_UTF16
));
12175 return NDR_ERR_SUCCESS
;
12178 static enum ndr_err_code
ndr_pull_srvsvc_NetTransportInfo2(struct ndr_pull
*ndr
, int ndr_flags
, struct srvsvc_NetTransportInfo2
*r
)
12180 uint32_t _ptr_name
;
12181 TALLOC_CTX
*_mem_save_name_0
;
12182 uint32_t _ptr_addr
;
12183 TALLOC_CTX
*_mem_save_addr_0
;
12184 uint32_t _ptr_net_addr
;
12185 TALLOC_CTX
*_mem_save_net_addr_0
;
12186 uint32_t _ptr_domain
;
12187 TALLOC_CTX
*_mem_save_domain_0
;
12188 if (ndr_flags
& NDR_SCALARS
) {
12189 NDR_CHECK(ndr_pull_align(ndr
, 4));
12190 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->vcs
));
12191 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_name
));
12193 NDR_PULL_ALLOC(ndr
, r
->name
);
12197 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_addr
));
12199 NDR_PULL_ALLOC(ndr
, r
->addr
);
12203 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->addr_len
));
12204 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_net_addr
));
12205 if (_ptr_net_addr
) {
12206 NDR_PULL_ALLOC(ndr
, r
->net_addr
);
12208 r
->net_addr
= NULL
;
12210 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_domain
));
12212 NDR_PULL_ALLOC(ndr
, r
->domain
);
12216 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->unknown
));
12218 if (ndr_flags
& NDR_BUFFERS
) {
12220 _mem_save_name_0
= NDR_PULL_GET_MEM_CTX(ndr
);
12221 NDR_PULL_SET_MEM_CTX(ndr
, r
->name
, 0);
12222 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->name
));
12223 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->name
));
12224 if (ndr_get_array_length(ndr
, &r
->name
) > ndr_get_array_size(ndr
, &r
->name
)) {
12225 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", ndr_get_array_size(ndr
, &r
->name
), ndr_get_array_length(ndr
, &r
->name
));
12227 NDR_CHECK(ndr_check_string_terminator(ndr
, ndr_get_array_length(ndr
, &r
->name
), sizeof(uint16_t)));
12228 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->name
, ndr_get_array_length(ndr
, &r
->name
), sizeof(uint16_t), CH_UTF16
));
12229 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_name_0
, 0);
12232 _mem_save_addr_0
= NDR_PULL_GET_MEM_CTX(ndr
);
12233 NDR_PULL_SET_MEM_CTX(ndr
, r
->addr
, 0);
12234 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->addr
));
12235 NDR_PULL_ALLOC_N(ndr
, r
->addr
, ndr_get_array_size(ndr
, &r
->addr
));
12236 NDR_CHECK(ndr_pull_array_uint8(ndr
, NDR_SCALARS
, r
->addr
, ndr_get_array_size(ndr
, &r
->addr
)));
12237 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_addr_0
, 0);
12240 _mem_save_net_addr_0
= NDR_PULL_GET_MEM_CTX(ndr
);
12241 NDR_PULL_SET_MEM_CTX(ndr
, r
->net_addr
, 0);
12242 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->net_addr
));
12243 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->net_addr
));
12244 if (ndr_get_array_length(ndr
, &r
->net_addr
) > ndr_get_array_size(ndr
, &r
->net_addr
)) {
12245 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", ndr_get_array_size(ndr
, &r
->net_addr
), ndr_get_array_length(ndr
, &r
->net_addr
));
12247 NDR_CHECK(ndr_check_string_terminator(ndr
, ndr_get_array_length(ndr
, &r
->net_addr
), sizeof(uint16_t)));
12248 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->net_addr
, ndr_get_array_length(ndr
, &r
->net_addr
), sizeof(uint16_t), CH_UTF16
));
12249 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_net_addr_0
, 0);
12252 _mem_save_domain_0
= NDR_PULL_GET_MEM_CTX(ndr
);
12253 NDR_PULL_SET_MEM_CTX(ndr
, r
->domain
, 0);
12254 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->domain
));
12255 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->domain
));
12256 if (ndr_get_array_length(ndr
, &r
->domain
) > ndr_get_array_size(ndr
, &r
->domain
)) {
12257 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", ndr_get_array_size(ndr
, &r
->domain
), ndr_get_array_length(ndr
, &r
->domain
));
12259 NDR_CHECK(ndr_check_string_terminator(ndr
, ndr_get_array_length(ndr
, &r
->domain
), sizeof(uint16_t)));
12260 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->domain
, ndr_get_array_length(ndr
, &r
->domain
), sizeof(uint16_t), CH_UTF16
));
12261 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_domain_0
, 0);
12264 NDR_CHECK(ndr_check_array_size(ndr
, (void*)&r
->addr
, r
->addr_len
));
12267 return NDR_ERR_SUCCESS
;
12270 _PUBLIC_
void ndr_print_srvsvc_NetTransportInfo2(struct ndr_print
*ndr
, const char *name
, const struct srvsvc_NetTransportInfo2
*r
)
12272 ndr_print_struct(ndr
, name
, "srvsvc_NetTransportInfo2");
12274 ndr_print_uint32(ndr
, "vcs", r
->vcs
);
12275 ndr_print_ptr(ndr
, "name", r
->name
);
12278 ndr_print_string(ndr
, "name", r
->name
);
12281 ndr_print_ptr(ndr
, "addr", r
->addr
);
12284 ndr_print_array_uint8(ndr
, "addr", r
->addr
, r
->addr_len
);
12287 ndr_print_uint32(ndr
, "addr_len", r
->addr_len
);
12288 ndr_print_ptr(ndr
, "net_addr", r
->net_addr
);
12291 ndr_print_string(ndr
, "net_addr", r
->net_addr
);
12294 ndr_print_ptr(ndr
, "domain", r
->domain
);
12297 ndr_print_string(ndr
, "domain", r
->domain
);
12300 ndr_print_uint32(ndr
, "unknown", r
->unknown
);
12304 static enum ndr_err_code
ndr_push_srvsvc_NetTransportCtr2(struct ndr_push
*ndr
, int ndr_flags
, const struct srvsvc_NetTransportCtr2
*r
)
12306 uint32_t cntr_array_1
;
12307 if (ndr_flags
& NDR_SCALARS
) {
12308 NDR_CHECK(ndr_push_align(ndr
, 4));
12309 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->count
));
12310 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->array
));
12312 if (ndr_flags
& NDR_BUFFERS
) {
12314 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->count
));
12315 for (cntr_array_1
= 0; cntr_array_1
< r
->count
; cntr_array_1
++) {
12316 NDR_CHECK(ndr_push_srvsvc_NetTransportInfo2(ndr
, NDR_SCALARS
, &r
->array
[cntr_array_1
]));
12318 for (cntr_array_1
= 0; cntr_array_1
< r
->count
; cntr_array_1
++) {
12319 NDR_CHECK(ndr_push_srvsvc_NetTransportInfo2(ndr
, NDR_BUFFERS
, &r
->array
[cntr_array_1
]));
12323 return NDR_ERR_SUCCESS
;
12326 static enum ndr_err_code
ndr_pull_srvsvc_NetTransportCtr2(struct ndr_pull
*ndr
, int ndr_flags
, struct srvsvc_NetTransportCtr2
*r
)
12328 uint32_t _ptr_array
;
12329 uint32_t cntr_array_1
;
12330 TALLOC_CTX
*_mem_save_array_0
;
12331 TALLOC_CTX
*_mem_save_array_1
;
12332 if (ndr_flags
& NDR_SCALARS
) {
12333 NDR_CHECK(ndr_pull_align(ndr
, 4));
12334 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->count
));
12335 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_array
));
12337 NDR_PULL_ALLOC(ndr
, r
->array
);
12342 if (ndr_flags
& NDR_BUFFERS
) {
12344 _mem_save_array_0
= NDR_PULL_GET_MEM_CTX(ndr
);
12345 NDR_PULL_SET_MEM_CTX(ndr
, r
->array
, 0);
12346 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->array
));
12347 NDR_PULL_ALLOC_N(ndr
, r
->array
, ndr_get_array_size(ndr
, &r
->array
));
12348 _mem_save_array_1
= NDR_PULL_GET_MEM_CTX(ndr
);
12349 NDR_PULL_SET_MEM_CTX(ndr
, r
->array
, 0);
12350 for (cntr_array_1
= 0; cntr_array_1
< r
->count
; cntr_array_1
++) {
12351 NDR_CHECK(ndr_pull_srvsvc_NetTransportInfo2(ndr
, NDR_SCALARS
, &r
->array
[cntr_array_1
]));
12353 for (cntr_array_1
= 0; cntr_array_1
< r
->count
; cntr_array_1
++) {
12354 NDR_CHECK(ndr_pull_srvsvc_NetTransportInfo2(ndr
, NDR_BUFFERS
, &r
->array
[cntr_array_1
]));
12356 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_array_1
, 0);
12357 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_array_0
, 0);
12360 NDR_CHECK(ndr_check_array_size(ndr
, (void*)&r
->array
, r
->count
));
12363 return NDR_ERR_SUCCESS
;
12366 _PUBLIC_
void ndr_print_srvsvc_NetTransportCtr2(struct ndr_print
*ndr
, const char *name
, const struct srvsvc_NetTransportCtr2
*r
)
12368 uint32_t cntr_array_1
;
12369 ndr_print_struct(ndr
, name
, "srvsvc_NetTransportCtr2");
12371 ndr_print_uint32(ndr
, "count", r
->count
);
12372 ndr_print_ptr(ndr
, "array", r
->array
);
12375 ndr
->print(ndr
, "%s: ARRAY(%d)", "array", (int)r
->count
);
12377 for (cntr_array_1
=0;cntr_array_1
<r
->count
;cntr_array_1
++) {
12379 if (asprintf(&idx_1
, "[%d]", cntr_array_1
) != -1) {
12380 ndr_print_srvsvc_NetTransportInfo2(ndr
, "array", &r
->array
[cntr_array_1
]);
12390 static enum ndr_err_code
ndr_push_srvsvc_NetTransportInfo3(struct ndr_push
*ndr
, int ndr_flags
, const struct srvsvc_NetTransportInfo3
*r
)
12392 if (ndr_flags
& NDR_SCALARS
) {
12393 NDR_CHECK(ndr_push_align(ndr
, 4));
12394 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->vcs
));
12395 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->name
));
12396 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->addr
));
12397 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->addr_len
));
12398 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->net_addr
));
12399 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->domain
));
12400 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->unknown1
));
12401 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->unknown2
));
12402 NDR_CHECK(ndr_push_array_uint8(ndr
, NDR_SCALARS
, r
->unknown3
, 256));
12404 if (ndr_flags
& NDR_BUFFERS
) {
12406 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->name
, CH_UTF16
)));
12407 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
12408 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->name
, CH_UTF16
)));
12409 NDR_CHECK(ndr_push_charset(ndr
, NDR_SCALARS
, r
->name
, ndr_charset_length(r
->name
, CH_UTF16
), sizeof(uint16_t), CH_UTF16
));
12412 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->addr_len
));
12413 NDR_CHECK(ndr_push_array_uint8(ndr
, NDR_SCALARS
, r
->addr
, r
->addr_len
));
12416 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->net_addr
, CH_UTF16
)));
12417 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
12418 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->net_addr
, CH_UTF16
)));
12419 NDR_CHECK(ndr_push_charset(ndr
, NDR_SCALARS
, r
->net_addr
, ndr_charset_length(r
->net_addr
, CH_UTF16
), sizeof(uint16_t), CH_UTF16
));
12422 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->domain
, CH_UTF16
)));
12423 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
12424 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->domain
, CH_UTF16
)));
12425 NDR_CHECK(ndr_push_charset(ndr
, NDR_SCALARS
, r
->domain
, ndr_charset_length(r
->domain
, CH_UTF16
), sizeof(uint16_t), CH_UTF16
));
12428 return NDR_ERR_SUCCESS
;
12431 static enum ndr_err_code
ndr_pull_srvsvc_NetTransportInfo3(struct ndr_pull
*ndr
, int ndr_flags
, struct srvsvc_NetTransportInfo3
*r
)
12433 uint32_t _ptr_name
;
12434 TALLOC_CTX
*_mem_save_name_0
;
12435 uint32_t _ptr_addr
;
12436 TALLOC_CTX
*_mem_save_addr_0
;
12437 uint32_t _ptr_net_addr
;
12438 TALLOC_CTX
*_mem_save_net_addr_0
;
12439 uint32_t _ptr_domain
;
12440 TALLOC_CTX
*_mem_save_domain_0
;
12441 if (ndr_flags
& NDR_SCALARS
) {
12442 NDR_CHECK(ndr_pull_align(ndr
, 4));
12443 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->vcs
));
12444 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_name
));
12446 NDR_PULL_ALLOC(ndr
, r
->name
);
12450 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_addr
));
12452 NDR_PULL_ALLOC(ndr
, r
->addr
);
12456 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->addr_len
));
12457 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_net_addr
));
12458 if (_ptr_net_addr
) {
12459 NDR_PULL_ALLOC(ndr
, r
->net_addr
);
12461 r
->net_addr
= NULL
;
12463 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_domain
));
12465 NDR_PULL_ALLOC(ndr
, r
->domain
);
12469 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->unknown1
));
12470 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->unknown2
));
12471 NDR_CHECK(ndr_pull_array_uint8(ndr
, NDR_SCALARS
, r
->unknown3
, 256));
12473 if (ndr_flags
& NDR_BUFFERS
) {
12475 _mem_save_name_0
= NDR_PULL_GET_MEM_CTX(ndr
);
12476 NDR_PULL_SET_MEM_CTX(ndr
, r
->name
, 0);
12477 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->name
));
12478 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->name
));
12479 if (ndr_get_array_length(ndr
, &r
->name
) > ndr_get_array_size(ndr
, &r
->name
)) {
12480 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", ndr_get_array_size(ndr
, &r
->name
), ndr_get_array_length(ndr
, &r
->name
));
12482 NDR_CHECK(ndr_check_string_terminator(ndr
, ndr_get_array_length(ndr
, &r
->name
), sizeof(uint16_t)));
12483 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->name
, ndr_get_array_length(ndr
, &r
->name
), sizeof(uint16_t), CH_UTF16
));
12484 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_name_0
, 0);
12487 _mem_save_addr_0
= NDR_PULL_GET_MEM_CTX(ndr
);
12488 NDR_PULL_SET_MEM_CTX(ndr
, r
->addr
, 0);
12489 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->addr
));
12490 NDR_PULL_ALLOC_N(ndr
, r
->addr
, ndr_get_array_size(ndr
, &r
->addr
));
12491 NDR_CHECK(ndr_pull_array_uint8(ndr
, NDR_SCALARS
, r
->addr
, ndr_get_array_size(ndr
, &r
->addr
)));
12492 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_addr_0
, 0);
12495 _mem_save_net_addr_0
= NDR_PULL_GET_MEM_CTX(ndr
);
12496 NDR_PULL_SET_MEM_CTX(ndr
, r
->net_addr
, 0);
12497 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->net_addr
));
12498 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->net_addr
));
12499 if (ndr_get_array_length(ndr
, &r
->net_addr
) > ndr_get_array_size(ndr
, &r
->net_addr
)) {
12500 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", ndr_get_array_size(ndr
, &r
->net_addr
), ndr_get_array_length(ndr
, &r
->net_addr
));
12502 NDR_CHECK(ndr_check_string_terminator(ndr
, ndr_get_array_length(ndr
, &r
->net_addr
), sizeof(uint16_t)));
12503 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->net_addr
, ndr_get_array_length(ndr
, &r
->net_addr
), sizeof(uint16_t), CH_UTF16
));
12504 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_net_addr_0
, 0);
12507 _mem_save_domain_0
= NDR_PULL_GET_MEM_CTX(ndr
);
12508 NDR_PULL_SET_MEM_CTX(ndr
, r
->domain
, 0);
12509 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->domain
));
12510 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->domain
));
12511 if (ndr_get_array_length(ndr
, &r
->domain
) > ndr_get_array_size(ndr
, &r
->domain
)) {
12512 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", ndr_get_array_size(ndr
, &r
->domain
), ndr_get_array_length(ndr
, &r
->domain
));
12514 NDR_CHECK(ndr_check_string_terminator(ndr
, ndr_get_array_length(ndr
, &r
->domain
), sizeof(uint16_t)));
12515 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->domain
, ndr_get_array_length(ndr
, &r
->domain
), sizeof(uint16_t), CH_UTF16
));
12516 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_domain_0
, 0);
12519 NDR_CHECK(ndr_check_array_size(ndr
, (void*)&r
->addr
, r
->addr_len
));
12522 return NDR_ERR_SUCCESS
;
12525 _PUBLIC_
void ndr_print_srvsvc_NetTransportInfo3(struct ndr_print
*ndr
, const char *name
, const struct srvsvc_NetTransportInfo3
*r
)
12527 ndr_print_struct(ndr
, name
, "srvsvc_NetTransportInfo3");
12529 ndr_print_uint32(ndr
, "vcs", r
->vcs
);
12530 ndr_print_ptr(ndr
, "name", r
->name
);
12533 ndr_print_string(ndr
, "name", r
->name
);
12536 ndr_print_ptr(ndr
, "addr", r
->addr
);
12539 ndr_print_array_uint8(ndr
, "addr", r
->addr
, r
->addr_len
);
12542 ndr_print_uint32(ndr
, "addr_len", r
->addr_len
);
12543 ndr_print_ptr(ndr
, "net_addr", r
->net_addr
);
12546 ndr_print_string(ndr
, "net_addr", r
->net_addr
);
12549 ndr_print_ptr(ndr
, "domain", r
->domain
);
12552 ndr_print_string(ndr
, "domain", r
->domain
);
12555 ndr_print_uint32(ndr
, "unknown1", r
->unknown1
);
12556 ndr_print_uint32(ndr
, "unknown2", r
->unknown2
);
12557 ndr_print_array_uint8(ndr
, "unknown3", r
->unknown3
, 256);
12561 static enum ndr_err_code
ndr_push_srvsvc_NetTransportCtr3(struct ndr_push
*ndr
, int ndr_flags
, const struct srvsvc_NetTransportCtr3
*r
)
12563 uint32_t cntr_array_1
;
12564 if (ndr_flags
& NDR_SCALARS
) {
12565 NDR_CHECK(ndr_push_align(ndr
, 4));
12566 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->count
));
12567 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->array
));
12569 if (ndr_flags
& NDR_BUFFERS
) {
12571 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->count
));
12572 for (cntr_array_1
= 0; cntr_array_1
< r
->count
; cntr_array_1
++) {
12573 NDR_CHECK(ndr_push_srvsvc_NetTransportInfo3(ndr
, NDR_SCALARS
, &r
->array
[cntr_array_1
]));
12575 for (cntr_array_1
= 0; cntr_array_1
< r
->count
; cntr_array_1
++) {
12576 NDR_CHECK(ndr_push_srvsvc_NetTransportInfo3(ndr
, NDR_BUFFERS
, &r
->array
[cntr_array_1
]));
12580 return NDR_ERR_SUCCESS
;
12583 static enum ndr_err_code
ndr_pull_srvsvc_NetTransportCtr3(struct ndr_pull
*ndr
, int ndr_flags
, struct srvsvc_NetTransportCtr3
*r
)
12585 uint32_t _ptr_array
;
12586 uint32_t cntr_array_1
;
12587 TALLOC_CTX
*_mem_save_array_0
;
12588 TALLOC_CTX
*_mem_save_array_1
;
12589 if (ndr_flags
& NDR_SCALARS
) {
12590 NDR_CHECK(ndr_pull_align(ndr
, 4));
12591 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->count
));
12592 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_array
));
12594 NDR_PULL_ALLOC(ndr
, r
->array
);
12599 if (ndr_flags
& NDR_BUFFERS
) {
12601 _mem_save_array_0
= NDR_PULL_GET_MEM_CTX(ndr
);
12602 NDR_PULL_SET_MEM_CTX(ndr
, r
->array
, 0);
12603 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->array
));
12604 NDR_PULL_ALLOC_N(ndr
, r
->array
, ndr_get_array_size(ndr
, &r
->array
));
12605 _mem_save_array_1
= NDR_PULL_GET_MEM_CTX(ndr
);
12606 NDR_PULL_SET_MEM_CTX(ndr
, r
->array
, 0);
12607 for (cntr_array_1
= 0; cntr_array_1
< r
->count
; cntr_array_1
++) {
12608 NDR_CHECK(ndr_pull_srvsvc_NetTransportInfo3(ndr
, NDR_SCALARS
, &r
->array
[cntr_array_1
]));
12610 for (cntr_array_1
= 0; cntr_array_1
< r
->count
; cntr_array_1
++) {
12611 NDR_CHECK(ndr_pull_srvsvc_NetTransportInfo3(ndr
, NDR_BUFFERS
, &r
->array
[cntr_array_1
]));
12613 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_array_1
, 0);
12614 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_array_0
, 0);
12617 NDR_CHECK(ndr_check_array_size(ndr
, (void*)&r
->array
, r
->count
));
12620 return NDR_ERR_SUCCESS
;
12623 _PUBLIC_
void ndr_print_srvsvc_NetTransportCtr3(struct ndr_print
*ndr
, const char *name
, const struct srvsvc_NetTransportCtr3
*r
)
12625 uint32_t cntr_array_1
;
12626 ndr_print_struct(ndr
, name
, "srvsvc_NetTransportCtr3");
12628 ndr_print_uint32(ndr
, "count", r
->count
);
12629 ndr_print_ptr(ndr
, "array", r
->array
);
12632 ndr
->print(ndr
, "%s: ARRAY(%d)", "array", (int)r
->count
);
12634 for (cntr_array_1
=0;cntr_array_1
<r
->count
;cntr_array_1
++) {
12636 if (asprintf(&idx_1
, "[%d]", cntr_array_1
) != -1) {
12637 ndr_print_srvsvc_NetTransportInfo3(ndr
, "array", &r
->array
[cntr_array_1
]);
12647 static enum ndr_err_code
ndr_push_srvsvc_NetTransportCtr(struct ndr_push
*ndr
, int ndr_flags
, const union srvsvc_NetTransportCtr
*r
)
12649 if (ndr_flags
& NDR_SCALARS
) {
12650 int level
= ndr_push_get_switch_value(ndr
, r
);
12651 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, level
));
12654 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->ctr0
));
12658 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->ctr1
));
12662 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->ctr2
));
12666 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->ctr3
));
12674 if (ndr_flags
& NDR_BUFFERS
) {
12675 int level
= ndr_push_get_switch_value(ndr
, r
);
12679 NDR_CHECK(ndr_push_srvsvc_NetTransportCtr0(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->ctr0
));
12685 NDR_CHECK(ndr_push_srvsvc_NetTransportCtr1(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->ctr1
));
12691 NDR_CHECK(ndr_push_srvsvc_NetTransportCtr2(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->ctr2
));
12697 NDR_CHECK(ndr_push_srvsvc_NetTransportCtr3(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->ctr3
));
12706 return NDR_ERR_SUCCESS
;
12709 static enum ndr_err_code
ndr_pull_srvsvc_NetTransportCtr(struct ndr_pull
*ndr
, int ndr_flags
, union srvsvc_NetTransportCtr
*r
)
12713 TALLOC_CTX
*_mem_save_ctr0_0
;
12714 TALLOC_CTX
*_mem_save_ctr1_0
;
12715 TALLOC_CTX
*_mem_save_ctr2_0
;
12716 TALLOC_CTX
*_mem_save_ctr3_0
;
12717 level
= ndr_pull_get_switch_value(ndr
, r
);
12718 if (ndr_flags
& NDR_SCALARS
) {
12719 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &_level
));
12720 if (_level
!= level
) {
12721 return ndr_pull_error(ndr
, NDR_ERR_BAD_SWITCH
, "Bad switch value %u for r", _level
);
12725 uint32_t _ptr_ctr0
;
12726 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_ctr0
));
12728 NDR_PULL_ALLOC(ndr
, r
->ctr0
);
12735 uint32_t _ptr_ctr1
;
12736 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_ctr1
));
12738 NDR_PULL_ALLOC(ndr
, r
->ctr1
);
12745 uint32_t _ptr_ctr2
;
12746 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_ctr2
));
12748 NDR_PULL_ALLOC(ndr
, r
->ctr2
);
12755 uint32_t _ptr_ctr3
;
12756 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_ctr3
));
12758 NDR_PULL_ALLOC(ndr
, r
->ctr3
);
12769 if (ndr_flags
& NDR_BUFFERS
) {
12773 _mem_save_ctr0_0
= NDR_PULL_GET_MEM_CTX(ndr
);
12774 NDR_PULL_SET_MEM_CTX(ndr
, r
->ctr0
, 0);
12775 NDR_CHECK(ndr_pull_srvsvc_NetTransportCtr0(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->ctr0
));
12776 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_ctr0_0
, 0);
12782 _mem_save_ctr1_0
= NDR_PULL_GET_MEM_CTX(ndr
);
12783 NDR_PULL_SET_MEM_CTX(ndr
, r
->ctr1
, 0);
12784 NDR_CHECK(ndr_pull_srvsvc_NetTransportCtr1(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->ctr1
));
12785 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_ctr1_0
, 0);
12791 _mem_save_ctr2_0
= NDR_PULL_GET_MEM_CTX(ndr
);
12792 NDR_PULL_SET_MEM_CTX(ndr
, r
->ctr2
, 0);
12793 NDR_CHECK(ndr_pull_srvsvc_NetTransportCtr2(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->ctr2
));
12794 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_ctr2_0
, 0);
12800 _mem_save_ctr3_0
= NDR_PULL_GET_MEM_CTX(ndr
);
12801 NDR_PULL_SET_MEM_CTX(ndr
, r
->ctr3
, 0);
12802 NDR_CHECK(ndr_pull_srvsvc_NetTransportCtr3(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->ctr3
));
12803 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_ctr3_0
, 0);
12812 return NDR_ERR_SUCCESS
;
12815 _PUBLIC_
void ndr_print_srvsvc_NetTransportCtr(struct ndr_print
*ndr
, const char *name
, const union srvsvc_NetTransportCtr
*r
)
12818 level
= ndr_print_get_switch_value(ndr
, r
);
12819 ndr_print_union(ndr
, name
, level
, "srvsvc_NetTransportCtr");
12822 ndr_print_ptr(ndr
, "ctr0", r
->ctr0
);
12825 ndr_print_srvsvc_NetTransportCtr0(ndr
, "ctr0", r
->ctr0
);
12831 ndr_print_ptr(ndr
, "ctr1", r
->ctr1
);
12834 ndr_print_srvsvc_NetTransportCtr1(ndr
, "ctr1", r
->ctr1
);
12840 ndr_print_ptr(ndr
, "ctr2", r
->ctr2
);
12843 ndr_print_srvsvc_NetTransportCtr2(ndr
, "ctr2", r
->ctr2
);
12849 ndr_print_ptr(ndr
, "ctr3", r
->ctr3
);
12852 ndr_print_srvsvc_NetTransportCtr3(ndr
, "ctr3", r
->ctr3
);
12863 static enum ndr_err_code
ndr_push_srvsvc_NetRemoteTODInfo(struct ndr_push
*ndr
, int ndr_flags
, const struct srvsvc_NetRemoteTODInfo
*r
)
12865 if (ndr_flags
& NDR_SCALARS
) {
12866 NDR_CHECK(ndr_push_align(ndr
, 4));
12867 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->elapsed
));
12868 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->msecs
));
12869 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->hours
));
12870 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->mins
));
12871 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->secs
));
12872 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->hunds
));
12873 NDR_CHECK(ndr_push_int32(ndr
, NDR_SCALARS
, r
->timezone
));
12874 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->tinterval
));
12875 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->day
));
12876 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->month
));
12877 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->year
));
12878 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->weekday
));
12880 if (ndr_flags
& NDR_BUFFERS
) {
12882 return NDR_ERR_SUCCESS
;
12885 static enum ndr_err_code
ndr_pull_srvsvc_NetRemoteTODInfo(struct ndr_pull
*ndr
, int ndr_flags
, struct srvsvc_NetRemoteTODInfo
*r
)
12887 if (ndr_flags
& NDR_SCALARS
) {
12888 NDR_CHECK(ndr_pull_align(ndr
, 4));
12889 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->elapsed
));
12890 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->msecs
));
12891 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->hours
));
12892 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->mins
));
12893 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->secs
));
12894 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->hunds
));
12895 NDR_CHECK(ndr_pull_int32(ndr
, NDR_SCALARS
, &r
->timezone
));
12896 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->tinterval
));
12897 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->day
));
12898 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->month
));
12899 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->year
));
12900 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->weekday
));
12902 if (ndr_flags
& NDR_BUFFERS
) {
12904 return NDR_ERR_SUCCESS
;
12907 _PUBLIC_
void ndr_print_srvsvc_NetRemoteTODInfo(struct ndr_print
*ndr
, const char *name
, const struct srvsvc_NetRemoteTODInfo
*r
)
12909 ndr_print_struct(ndr
, name
, "srvsvc_NetRemoteTODInfo");
12911 ndr_print_uint32(ndr
, "elapsed", r
->elapsed
);
12912 ndr_print_uint32(ndr
, "msecs", r
->msecs
);
12913 ndr_print_uint32(ndr
, "hours", r
->hours
);
12914 ndr_print_uint32(ndr
, "mins", r
->mins
);
12915 ndr_print_uint32(ndr
, "secs", r
->secs
);
12916 ndr_print_uint32(ndr
, "hunds", r
->hunds
);
12917 ndr_print_int32(ndr
, "timezone", r
->timezone
);
12918 ndr_print_uint32(ndr
, "tinterval", r
->tinterval
);
12919 ndr_print_uint32(ndr
, "day", r
->day
);
12920 ndr_print_uint32(ndr
, "month", r
->month
);
12921 ndr_print_uint32(ndr
, "year", r
->year
);
12922 ndr_print_uint32(ndr
, "weekday", r
->weekday
);
12926 static enum ndr_err_code
ndr_push_srvsvc_NetTransportInfo(struct ndr_push
*ndr
, int ndr_flags
, const union srvsvc_NetTransportInfo
*r
)
12928 if (ndr_flags
& NDR_SCALARS
) {
12929 int level
= ndr_push_get_switch_value(ndr
, r
);
12930 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, level
));
12933 NDR_CHECK(ndr_push_srvsvc_NetTransportInfo0(ndr
, NDR_SCALARS
, &r
->info0
));
12937 NDR_CHECK(ndr_push_srvsvc_NetTransportInfo1(ndr
, NDR_SCALARS
, &r
->info1
));
12941 NDR_CHECK(ndr_push_srvsvc_NetTransportInfo2(ndr
, NDR_SCALARS
, &r
->info2
));
12945 NDR_CHECK(ndr_push_srvsvc_NetTransportInfo3(ndr
, NDR_SCALARS
, &r
->info3
));
12949 return ndr_push_error(ndr
, NDR_ERR_BAD_SWITCH
, "Bad switch value %u", level
);
12952 if (ndr_flags
& NDR_BUFFERS
) {
12953 int level
= ndr_push_get_switch_value(ndr
, r
);
12956 NDR_CHECK(ndr_push_srvsvc_NetTransportInfo0(ndr
, NDR_BUFFERS
, &r
->info0
));
12960 NDR_CHECK(ndr_push_srvsvc_NetTransportInfo1(ndr
, NDR_BUFFERS
, &r
->info1
));
12964 NDR_CHECK(ndr_push_srvsvc_NetTransportInfo2(ndr
, NDR_BUFFERS
, &r
->info2
));
12968 NDR_CHECK(ndr_push_srvsvc_NetTransportInfo3(ndr
, NDR_BUFFERS
, &r
->info3
));
12972 return ndr_push_error(ndr
, NDR_ERR_BAD_SWITCH
, "Bad switch value %u", level
);
12975 return NDR_ERR_SUCCESS
;
12978 static enum ndr_err_code
ndr_pull_srvsvc_NetTransportInfo(struct ndr_pull
*ndr
, int ndr_flags
, union srvsvc_NetTransportInfo
*r
)
12982 level
= ndr_pull_get_switch_value(ndr
, r
);
12983 if (ndr_flags
& NDR_SCALARS
) {
12984 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &_level
));
12985 if (_level
!= level
) {
12986 return ndr_pull_error(ndr
, NDR_ERR_BAD_SWITCH
, "Bad switch value %u for r", _level
);
12990 NDR_CHECK(ndr_pull_srvsvc_NetTransportInfo0(ndr
, NDR_SCALARS
, &r
->info0
));
12994 NDR_CHECK(ndr_pull_srvsvc_NetTransportInfo1(ndr
, NDR_SCALARS
, &r
->info1
));
12998 NDR_CHECK(ndr_pull_srvsvc_NetTransportInfo2(ndr
, NDR_SCALARS
, &r
->info2
));
13002 NDR_CHECK(ndr_pull_srvsvc_NetTransportInfo3(ndr
, NDR_SCALARS
, &r
->info3
));
13006 return ndr_pull_error(ndr
, NDR_ERR_BAD_SWITCH
, "Bad switch value %u", level
);
13009 if (ndr_flags
& NDR_BUFFERS
) {
13012 NDR_CHECK(ndr_pull_srvsvc_NetTransportInfo0(ndr
, NDR_BUFFERS
, &r
->info0
));
13016 NDR_CHECK(ndr_pull_srvsvc_NetTransportInfo1(ndr
, NDR_BUFFERS
, &r
->info1
));
13020 NDR_CHECK(ndr_pull_srvsvc_NetTransportInfo2(ndr
, NDR_BUFFERS
, &r
->info2
));
13024 NDR_CHECK(ndr_pull_srvsvc_NetTransportInfo3(ndr
, NDR_BUFFERS
, &r
->info3
));
13028 return ndr_pull_error(ndr
, NDR_ERR_BAD_SWITCH
, "Bad switch value %u", level
);
13031 return NDR_ERR_SUCCESS
;
13034 _PUBLIC_
void ndr_print_srvsvc_NetTransportInfo(struct ndr_print
*ndr
, const char *name
, const union srvsvc_NetTransportInfo
*r
)
13037 level
= ndr_print_get_switch_value(ndr
, r
);
13038 ndr_print_union(ndr
, name
, level
, "srvsvc_NetTransportInfo");
13041 ndr_print_srvsvc_NetTransportInfo0(ndr
, "info0", &r
->info0
);
13045 ndr_print_srvsvc_NetTransportInfo1(ndr
, "info1", &r
->info1
);
13049 ndr_print_srvsvc_NetTransportInfo2(ndr
, "info2", &r
->info2
);
13053 ndr_print_srvsvc_NetTransportInfo3(ndr
, "info3", &r
->info3
);
13057 ndr_print_bad_level(ndr
, name
, level
);
13061 static enum ndr_err_code
ndr_push_srvsvc_NetCharDevEnum(struct ndr_push
*ndr
, int flags
, const struct srvsvc_NetCharDevEnum
*r
)
13063 if (flags
& NDR_IN
) {
13064 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->in
.server_unc
));
13065 if (r
->in
.server_unc
) {
13066 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.server_unc
, CH_UTF16
)));
13067 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
13068 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.server_unc
, CH_UTF16
)));
13069 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
));
13071 if (r
->in
.level
== NULL
) {
13072 return ndr_push_error(ndr
, NDR_ERR_INVALID_POINTER
, "NULL [ref] pointer");
13074 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, *r
->in
.level
));
13075 if (r
->in
.ctr
== NULL
) {
13076 return ndr_push_error(ndr
, NDR_ERR_INVALID_POINTER
, "NULL [ref] pointer");
13078 NDR_CHECK(ndr_push_set_switch_value(ndr
, r
->in
.ctr
, *r
->in
.level
));
13079 NDR_CHECK(ndr_push_srvsvc_NetCharDevCtr(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->in
.ctr
));
13080 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->in
.max_buffer
));
13081 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->in
.resume_handle
));
13082 if (r
->in
.resume_handle
) {
13083 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, *r
->in
.resume_handle
));
13086 if (flags
& NDR_OUT
) {
13087 if (r
->out
.level
== NULL
) {
13088 return ndr_push_error(ndr
, NDR_ERR_INVALID_POINTER
, "NULL [ref] pointer");
13090 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, *r
->out
.level
));
13091 if (r
->out
.ctr
== NULL
) {
13092 return ndr_push_error(ndr
, NDR_ERR_INVALID_POINTER
, "NULL [ref] pointer");
13094 NDR_CHECK(ndr_push_set_switch_value(ndr
, r
->out
.ctr
, *r
->out
.level
));
13095 NDR_CHECK(ndr_push_srvsvc_NetCharDevCtr(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->out
.ctr
));
13096 if (r
->out
.totalentries
== NULL
) {
13097 return ndr_push_error(ndr
, NDR_ERR_INVALID_POINTER
, "NULL [ref] pointer");
13099 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, *r
->out
.totalentries
));
13100 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->out
.resume_handle
));
13101 if (r
->out
.resume_handle
) {
13102 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, *r
->out
.resume_handle
));
13104 NDR_CHECK(ndr_push_WERROR(ndr
, NDR_SCALARS
, r
->out
.result
));
13106 return NDR_ERR_SUCCESS
;
13109 static enum ndr_err_code
ndr_pull_srvsvc_NetCharDevEnum(struct ndr_pull
*ndr
, int flags
, struct srvsvc_NetCharDevEnum
*r
)
13111 uint32_t _ptr_server_unc
;
13112 uint32_t _ptr_resume_handle
;
13113 TALLOC_CTX
*_mem_save_server_unc_0
;
13114 TALLOC_CTX
*_mem_save_level_0
;
13115 TALLOC_CTX
*_mem_save_ctr_0
;
13116 TALLOC_CTX
*_mem_save_totalentries_0
;
13117 TALLOC_CTX
*_mem_save_resume_handle_0
;
13118 if (flags
& NDR_IN
) {
13119 ZERO_STRUCT(r
->out
);
13121 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_server_unc
));
13122 if (_ptr_server_unc
) {
13123 NDR_PULL_ALLOC(ndr
, r
->in
.server_unc
);
13125 r
->in
.server_unc
= NULL
;
13127 if (r
->in
.server_unc
) {
13128 _mem_save_server_unc_0
= NDR_PULL_GET_MEM_CTX(ndr
);
13129 NDR_PULL_SET_MEM_CTX(ndr
, r
->in
.server_unc
, 0);
13130 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->in
.server_unc
));
13131 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->in
.server_unc
));
13132 if (ndr_get_array_length(ndr
, &r
->in
.server_unc
) > ndr_get_array_size(ndr
, &r
->in
.server_unc
)) {
13133 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", ndr_get_array_size(ndr
, &r
->in
.server_unc
), ndr_get_array_length(ndr
, &r
->in
.server_unc
));
13135 NDR_CHECK(ndr_check_string_terminator(ndr
, ndr_get_array_length(ndr
, &r
->in
.server_unc
), sizeof(uint16_t)));
13136 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->in
.server_unc
, ndr_get_array_length(ndr
, &r
->in
.server_unc
), sizeof(uint16_t), CH_UTF16
));
13137 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_server_unc_0
, 0);
13139 if (ndr
->flags
& LIBNDR_FLAG_REF_ALLOC
) {
13140 NDR_PULL_ALLOC(ndr
, r
->in
.level
);
13142 _mem_save_level_0
= NDR_PULL_GET_MEM_CTX(ndr
);
13143 NDR_PULL_SET_MEM_CTX(ndr
, r
->in
.level
, LIBNDR_FLAG_REF_ALLOC
);
13144 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, r
->in
.level
));
13145 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_level_0
, LIBNDR_FLAG_REF_ALLOC
);
13146 if (ndr
->flags
& LIBNDR_FLAG_REF_ALLOC
) {
13147 NDR_PULL_ALLOC(ndr
, r
->in
.ctr
);
13149 _mem_save_ctr_0
= NDR_PULL_GET_MEM_CTX(ndr
);
13150 NDR_PULL_SET_MEM_CTX(ndr
, r
->in
.ctr
, LIBNDR_FLAG_REF_ALLOC
);
13151 NDR_CHECK(ndr_pull_set_switch_value(ndr
, r
->in
.ctr
, *r
->in
.level
));
13152 NDR_CHECK(ndr_pull_srvsvc_NetCharDevCtr(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->in
.ctr
));
13153 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_ctr_0
, LIBNDR_FLAG_REF_ALLOC
);
13154 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->in
.max_buffer
));
13155 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_resume_handle
));
13156 if (_ptr_resume_handle
) {
13157 NDR_PULL_ALLOC(ndr
, r
->in
.resume_handle
);
13159 r
->in
.resume_handle
= NULL
;
13161 if (r
->in
.resume_handle
) {
13162 _mem_save_resume_handle_0
= NDR_PULL_GET_MEM_CTX(ndr
);
13163 NDR_PULL_SET_MEM_CTX(ndr
, r
->in
.resume_handle
, 0);
13164 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, r
->in
.resume_handle
));
13165 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_resume_handle_0
, 0);
13167 NDR_PULL_ALLOC(ndr
, r
->out
.level
);
13168 *r
->out
.level
= *r
->in
.level
;
13169 NDR_PULL_ALLOC(ndr
, r
->out
.ctr
);
13170 *r
->out
.ctr
= *r
->in
.ctr
;
13171 NDR_PULL_ALLOC(ndr
, r
->out
.totalentries
);
13172 ZERO_STRUCTP(r
->out
.totalentries
);
13174 if (flags
& NDR_OUT
) {
13175 if (ndr
->flags
& LIBNDR_FLAG_REF_ALLOC
) {
13176 NDR_PULL_ALLOC(ndr
, r
->out
.level
);
13178 _mem_save_level_0
= NDR_PULL_GET_MEM_CTX(ndr
);
13179 NDR_PULL_SET_MEM_CTX(ndr
, r
->out
.level
, LIBNDR_FLAG_REF_ALLOC
);
13180 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, r
->out
.level
));
13181 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_level_0
, LIBNDR_FLAG_REF_ALLOC
);
13182 if (ndr
->flags
& LIBNDR_FLAG_REF_ALLOC
) {
13183 NDR_PULL_ALLOC(ndr
, r
->out
.ctr
);
13185 _mem_save_ctr_0
= NDR_PULL_GET_MEM_CTX(ndr
);
13186 NDR_PULL_SET_MEM_CTX(ndr
, r
->out
.ctr
, LIBNDR_FLAG_REF_ALLOC
);
13187 NDR_CHECK(ndr_pull_set_switch_value(ndr
, r
->out
.ctr
, *r
->out
.level
));
13188 NDR_CHECK(ndr_pull_srvsvc_NetCharDevCtr(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->out
.ctr
));
13189 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_ctr_0
, LIBNDR_FLAG_REF_ALLOC
);
13190 if (ndr
->flags
& LIBNDR_FLAG_REF_ALLOC
) {
13191 NDR_PULL_ALLOC(ndr
, r
->out
.totalentries
);
13193 _mem_save_totalentries_0
= NDR_PULL_GET_MEM_CTX(ndr
);
13194 NDR_PULL_SET_MEM_CTX(ndr
, r
->out
.totalentries
, LIBNDR_FLAG_REF_ALLOC
);
13195 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, r
->out
.totalentries
));
13196 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_totalentries_0
, LIBNDR_FLAG_REF_ALLOC
);
13197 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_resume_handle
));
13198 if (_ptr_resume_handle
) {
13199 NDR_PULL_ALLOC(ndr
, r
->out
.resume_handle
);
13201 r
->out
.resume_handle
= NULL
;
13203 if (r
->out
.resume_handle
) {
13204 _mem_save_resume_handle_0
= NDR_PULL_GET_MEM_CTX(ndr
);
13205 NDR_PULL_SET_MEM_CTX(ndr
, r
->out
.resume_handle
, 0);
13206 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, r
->out
.resume_handle
));
13207 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_resume_handle_0
, 0);
13209 NDR_CHECK(ndr_pull_WERROR(ndr
, NDR_SCALARS
, &r
->out
.result
));
13211 return NDR_ERR_SUCCESS
;
13214 _PUBLIC_
void ndr_print_srvsvc_NetCharDevEnum(struct ndr_print
*ndr
, const char *name
, int flags
, const struct srvsvc_NetCharDevEnum
*r
)
13216 ndr_print_struct(ndr
, name
, "srvsvc_NetCharDevEnum");
13218 if (flags
& NDR_SET_VALUES
) {
13219 ndr
->flags
|= LIBNDR_PRINT_SET_VALUES
;
13221 if (flags
& NDR_IN
) {
13222 ndr_print_struct(ndr
, "in", "srvsvc_NetCharDevEnum");
13224 ndr_print_ptr(ndr
, "server_unc", r
->in
.server_unc
);
13226 if (r
->in
.server_unc
) {
13227 ndr_print_string(ndr
, "server_unc", r
->in
.server_unc
);
13230 ndr_print_ptr(ndr
, "level", r
->in
.level
);
13232 ndr_print_uint32(ndr
, "level", *r
->in
.level
);
13234 ndr_print_ptr(ndr
, "ctr", r
->in
.ctr
);
13236 ndr_print_set_switch_value(ndr
, r
->in
.ctr
, *r
->in
.level
);
13237 ndr_print_srvsvc_NetCharDevCtr(ndr
, "ctr", r
->in
.ctr
);
13239 ndr_print_uint32(ndr
, "max_buffer", r
->in
.max_buffer
);
13240 ndr_print_ptr(ndr
, "resume_handle", r
->in
.resume_handle
);
13242 if (r
->in
.resume_handle
) {
13243 ndr_print_uint32(ndr
, "resume_handle", *r
->in
.resume_handle
);
13248 if (flags
& NDR_OUT
) {
13249 ndr_print_struct(ndr
, "out", "srvsvc_NetCharDevEnum");
13251 ndr_print_ptr(ndr
, "level", r
->out
.level
);
13253 ndr_print_uint32(ndr
, "level", *r
->out
.level
);
13255 ndr_print_ptr(ndr
, "ctr", r
->out
.ctr
);
13257 ndr_print_set_switch_value(ndr
, r
->out
.ctr
, *r
->out
.level
);
13258 ndr_print_srvsvc_NetCharDevCtr(ndr
, "ctr", r
->out
.ctr
);
13260 ndr_print_ptr(ndr
, "totalentries", r
->out
.totalentries
);
13262 ndr_print_uint32(ndr
, "totalentries", *r
->out
.totalentries
);
13264 ndr_print_ptr(ndr
, "resume_handle", r
->out
.resume_handle
);
13266 if (r
->out
.resume_handle
) {
13267 ndr_print_uint32(ndr
, "resume_handle", *r
->out
.resume_handle
);
13270 ndr_print_WERROR(ndr
, "result", r
->out
.result
);
13276 static enum ndr_err_code
ndr_push_srvsvc_NetCharDevGetInfo(struct ndr_push
*ndr
, int flags
, const struct srvsvc_NetCharDevGetInfo
*r
)
13278 if (flags
& NDR_IN
) {
13279 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->in
.server_unc
));
13280 if (r
->in
.server_unc
) {
13281 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.server_unc
, CH_UTF16
)));
13282 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
13283 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.server_unc
, CH_UTF16
)));
13284 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
));
13286 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.device_name
, CH_UTF16
)));
13287 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
13288 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.device_name
, CH_UTF16
)));
13289 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
));
13290 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->in
.level
));
13292 if (flags
& NDR_OUT
) {
13293 if (r
->out
.info
== NULL
) {
13294 return ndr_push_error(ndr
, NDR_ERR_INVALID_POINTER
, "NULL [ref] pointer");
13296 NDR_CHECK(ndr_push_set_switch_value(ndr
, r
->out
.info
, r
->in
.level
));
13297 NDR_CHECK(ndr_push_srvsvc_NetCharDevInfo(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->out
.info
));
13298 NDR_CHECK(ndr_push_WERROR(ndr
, NDR_SCALARS
, r
->out
.result
));
13300 return NDR_ERR_SUCCESS
;
13303 static enum ndr_err_code
ndr_pull_srvsvc_NetCharDevGetInfo(struct ndr_pull
*ndr
, int flags
, struct srvsvc_NetCharDevGetInfo
*r
)
13305 uint32_t _ptr_server_unc
;
13306 TALLOC_CTX
*_mem_save_server_unc_0
;
13307 TALLOC_CTX
*_mem_save_info_0
;
13308 if (flags
& NDR_IN
) {
13309 ZERO_STRUCT(r
->out
);
13311 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_server_unc
));
13312 if (_ptr_server_unc
) {
13313 NDR_PULL_ALLOC(ndr
, r
->in
.server_unc
);
13315 r
->in
.server_unc
= NULL
;
13317 if (r
->in
.server_unc
) {
13318 _mem_save_server_unc_0
= NDR_PULL_GET_MEM_CTX(ndr
);
13319 NDR_PULL_SET_MEM_CTX(ndr
, r
->in
.server_unc
, 0);
13320 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->in
.server_unc
));
13321 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->in
.server_unc
));
13322 if (ndr_get_array_length(ndr
, &r
->in
.server_unc
) > ndr_get_array_size(ndr
, &r
->in
.server_unc
)) {
13323 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", ndr_get_array_size(ndr
, &r
->in
.server_unc
), ndr_get_array_length(ndr
, &r
->in
.server_unc
));
13325 NDR_CHECK(ndr_check_string_terminator(ndr
, ndr_get_array_length(ndr
, &r
->in
.server_unc
), sizeof(uint16_t)));
13326 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->in
.server_unc
, ndr_get_array_length(ndr
, &r
->in
.server_unc
), sizeof(uint16_t), CH_UTF16
));
13327 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_server_unc_0
, 0);
13329 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->in
.device_name
));
13330 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->in
.device_name
));
13331 if (ndr_get_array_length(ndr
, &r
->in
.device_name
) > ndr_get_array_size(ndr
, &r
->in
.device_name
)) {
13332 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", ndr_get_array_size(ndr
, &r
->in
.device_name
), ndr_get_array_length(ndr
, &r
->in
.device_name
));
13334 NDR_CHECK(ndr_check_string_terminator(ndr
, ndr_get_array_length(ndr
, &r
->in
.device_name
), sizeof(uint16_t)));
13335 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->in
.device_name
, ndr_get_array_length(ndr
, &r
->in
.device_name
), sizeof(uint16_t), CH_UTF16
));
13336 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->in
.level
));
13337 NDR_PULL_ALLOC(ndr
, r
->out
.info
);
13338 ZERO_STRUCTP(r
->out
.info
);
13340 if (flags
& NDR_OUT
) {
13341 if (ndr
->flags
& LIBNDR_FLAG_REF_ALLOC
) {
13342 NDR_PULL_ALLOC(ndr
, r
->out
.info
);
13344 _mem_save_info_0
= NDR_PULL_GET_MEM_CTX(ndr
);
13345 NDR_PULL_SET_MEM_CTX(ndr
, r
->out
.info
, LIBNDR_FLAG_REF_ALLOC
);
13346 NDR_CHECK(ndr_pull_set_switch_value(ndr
, r
->out
.info
, r
->in
.level
));
13347 NDR_CHECK(ndr_pull_srvsvc_NetCharDevInfo(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->out
.info
));
13348 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_info_0
, LIBNDR_FLAG_REF_ALLOC
);
13349 NDR_CHECK(ndr_pull_WERROR(ndr
, NDR_SCALARS
, &r
->out
.result
));
13351 return NDR_ERR_SUCCESS
;
13354 _PUBLIC_
void ndr_print_srvsvc_NetCharDevGetInfo(struct ndr_print
*ndr
, const char *name
, int flags
, const struct srvsvc_NetCharDevGetInfo
*r
)
13356 ndr_print_struct(ndr
, name
, "srvsvc_NetCharDevGetInfo");
13358 if (flags
& NDR_SET_VALUES
) {
13359 ndr
->flags
|= LIBNDR_PRINT_SET_VALUES
;
13361 if (flags
& NDR_IN
) {
13362 ndr_print_struct(ndr
, "in", "srvsvc_NetCharDevGetInfo");
13364 ndr_print_ptr(ndr
, "server_unc", r
->in
.server_unc
);
13366 if (r
->in
.server_unc
) {
13367 ndr_print_string(ndr
, "server_unc", r
->in
.server_unc
);
13370 ndr_print_string(ndr
, "device_name", r
->in
.device_name
);
13371 ndr_print_uint32(ndr
, "level", r
->in
.level
);
13374 if (flags
& NDR_OUT
) {
13375 ndr_print_struct(ndr
, "out", "srvsvc_NetCharDevGetInfo");
13377 ndr_print_ptr(ndr
, "info", r
->out
.info
);
13379 ndr_print_set_switch_value(ndr
, r
->out
.info
, r
->in
.level
);
13380 ndr_print_srvsvc_NetCharDevInfo(ndr
, "info", r
->out
.info
);
13382 ndr_print_WERROR(ndr
, "result", r
->out
.result
);
13388 static enum ndr_err_code
ndr_push_srvsvc_NetCharDevControl(struct ndr_push
*ndr
, int flags
, const struct srvsvc_NetCharDevControl
*r
)
13390 if (flags
& NDR_IN
) {
13391 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->in
.server_unc
));
13392 if (r
->in
.server_unc
) {
13393 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.server_unc
, CH_UTF16
)));
13394 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
13395 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.server_unc
, CH_UTF16
)));
13396 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
));
13398 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.device_name
, CH_UTF16
)));
13399 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
13400 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.device_name
, CH_UTF16
)));
13401 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
));
13402 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->in
.opcode
));
13404 if (flags
& NDR_OUT
) {
13405 NDR_CHECK(ndr_push_WERROR(ndr
, NDR_SCALARS
, r
->out
.result
));
13407 return NDR_ERR_SUCCESS
;
13410 static enum ndr_err_code
ndr_pull_srvsvc_NetCharDevControl(struct ndr_pull
*ndr
, int flags
, struct srvsvc_NetCharDevControl
*r
)
13412 uint32_t _ptr_server_unc
;
13413 TALLOC_CTX
*_mem_save_server_unc_0
;
13414 if (flags
& NDR_IN
) {
13415 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_server_unc
));
13416 if (_ptr_server_unc
) {
13417 NDR_PULL_ALLOC(ndr
, r
->in
.server_unc
);
13419 r
->in
.server_unc
= NULL
;
13421 if (r
->in
.server_unc
) {
13422 _mem_save_server_unc_0
= NDR_PULL_GET_MEM_CTX(ndr
);
13423 NDR_PULL_SET_MEM_CTX(ndr
, r
->in
.server_unc
, 0);
13424 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->in
.server_unc
));
13425 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->in
.server_unc
));
13426 if (ndr_get_array_length(ndr
, &r
->in
.server_unc
) > ndr_get_array_size(ndr
, &r
->in
.server_unc
)) {
13427 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", ndr_get_array_size(ndr
, &r
->in
.server_unc
), ndr_get_array_length(ndr
, &r
->in
.server_unc
));
13429 NDR_CHECK(ndr_check_string_terminator(ndr
, ndr_get_array_length(ndr
, &r
->in
.server_unc
), sizeof(uint16_t)));
13430 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->in
.server_unc
, ndr_get_array_length(ndr
, &r
->in
.server_unc
), sizeof(uint16_t), CH_UTF16
));
13431 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_server_unc_0
, 0);
13433 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->in
.device_name
));
13434 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->in
.device_name
));
13435 if (ndr_get_array_length(ndr
, &r
->in
.device_name
) > ndr_get_array_size(ndr
, &r
->in
.device_name
)) {
13436 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", ndr_get_array_size(ndr
, &r
->in
.device_name
), ndr_get_array_length(ndr
, &r
->in
.device_name
));
13438 NDR_CHECK(ndr_check_string_terminator(ndr
, ndr_get_array_length(ndr
, &r
->in
.device_name
), sizeof(uint16_t)));
13439 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->in
.device_name
, ndr_get_array_length(ndr
, &r
->in
.device_name
), sizeof(uint16_t), CH_UTF16
));
13440 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->in
.opcode
));
13442 if (flags
& NDR_OUT
) {
13443 NDR_CHECK(ndr_pull_WERROR(ndr
, NDR_SCALARS
, &r
->out
.result
));
13445 return NDR_ERR_SUCCESS
;
13448 _PUBLIC_
void ndr_print_srvsvc_NetCharDevControl(struct ndr_print
*ndr
, const char *name
, int flags
, const struct srvsvc_NetCharDevControl
*r
)
13450 ndr_print_struct(ndr
, name
, "srvsvc_NetCharDevControl");
13452 if (flags
& NDR_SET_VALUES
) {
13453 ndr
->flags
|= LIBNDR_PRINT_SET_VALUES
;
13455 if (flags
& NDR_IN
) {
13456 ndr_print_struct(ndr
, "in", "srvsvc_NetCharDevControl");
13458 ndr_print_ptr(ndr
, "server_unc", r
->in
.server_unc
);
13460 if (r
->in
.server_unc
) {
13461 ndr_print_string(ndr
, "server_unc", r
->in
.server_unc
);
13464 ndr_print_string(ndr
, "device_name", r
->in
.device_name
);
13465 ndr_print_uint32(ndr
, "opcode", r
->in
.opcode
);
13468 if (flags
& NDR_OUT
) {
13469 ndr_print_struct(ndr
, "out", "srvsvc_NetCharDevControl");
13471 ndr_print_WERROR(ndr
, "result", r
->out
.result
);
13477 static enum ndr_err_code
ndr_push_srvsvc_NetCharDevQEnum(struct ndr_push
*ndr
, int flags
, const struct srvsvc_NetCharDevQEnum
*r
)
13479 if (flags
& NDR_IN
) {
13480 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->in
.server_unc
));
13481 if (r
->in
.server_unc
) {
13482 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.server_unc
, CH_UTF16
)));
13483 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
13484 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.server_unc
, CH_UTF16
)));
13485 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
));
13487 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->in
.user
));
13489 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.user
, CH_UTF16
)));
13490 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
13491 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.user
, CH_UTF16
)));
13492 NDR_CHECK(ndr_push_charset(ndr
, NDR_SCALARS
, r
->in
.user
, ndr_charset_length(r
->in
.user
, CH_UTF16
), sizeof(uint16_t), CH_UTF16
));
13494 if (r
->in
.level
== NULL
) {
13495 return ndr_push_error(ndr
, NDR_ERR_INVALID_POINTER
, "NULL [ref] pointer");
13497 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, *r
->in
.level
));
13498 if (r
->in
.ctr
== NULL
) {
13499 return ndr_push_error(ndr
, NDR_ERR_INVALID_POINTER
, "NULL [ref] pointer");
13501 NDR_CHECK(ndr_push_set_switch_value(ndr
, r
->in
.ctr
, *r
->in
.level
));
13502 NDR_CHECK(ndr_push_srvsvc_NetCharDevQCtr(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->in
.ctr
));
13503 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->in
.max_buffer
));
13504 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->in
.resume_handle
));
13505 if (r
->in
.resume_handle
) {
13506 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, *r
->in
.resume_handle
));
13509 if (flags
& NDR_OUT
) {
13510 if (r
->out
.level
== NULL
) {
13511 return ndr_push_error(ndr
, NDR_ERR_INVALID_POINTER
, "NULL [ref] pointer");
13513 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, *r
->out
.level
));
13514 if (r
->out
.ctr
== NULL
) {
13515 return ndr_push_error(ndr
, NDR_ERR_INVALID_POINTER
, "NULL [ref] pointer");
13517 NDR_CHECK(ndr_push_set_switch_value(ndr
, r
->out
.ctr
, *r
->out
.level
));
13518 NDR_CHECK(ndr_push_srvsvc_NetCharDevQCtr(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->out
.ctr
));
13519 if (r
->out
.totalentries
== NULL
) {
13520 return ndr_push_error(ndr
, NDR_ERR_INVALID_POINTER
, "NULL [ref] pointer");
13522 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, *r
->out
.totalentries
));
13523 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->out
.resume_handle
));
13524 if (r
->out
.resume_handle
) {
13525 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, *r
->out
.resume_handle
));
13527 NDR_CHECK(ndr_push_WERROR(ndr
, NDR_SCALARS
, r
->out
.result
));
13529 return NDR_ERR_SUCCESS
;
13532 static enum ndr_err_code
ndr_pull_srvsvc_NetCharDevQEnum(struct ndr_pull
*ndr
, int flags
, struct srvsvc_NetCharDevQEnum
*r
)
13534 uint32_t _ptr_server_unc
;
13535 uint32_t _ptr_user
;
13536 uint32_t _ptr_resume_handle
;
13537 TALLOC_CTX
*_mem_save_server_unc_0
;
13538 TALLOC_CTX
*_mem_save_user_0
;
13539 TALLOC_CTX
*_mem_save_level_0
;
13540 TALLOC_CTX
*_mem_save_ctr_0
;
13541 TALLOC_CTX
*_mem_save_totalentries_0
;
13542 TALLOC_CTX
*_mem_save_resume_handle_0
;
13543 if (flags
& NDR_IN
) {
13544 ZERO_STRUCT(r
->out
);
13546 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_server_unc
));
13547 if (_ptr_server_unc
) {
13548 NDR_PULL_ALLOC(ndr
, r
->in
.server_unc
);
13550 r
->in
.server_unc
= NULL
;
13552 if (r
->in
.server_unc
) {
13553 _mem_save_server_unc_0
= NDR_PULL_GET_MEM_CTX(ndr
);
13554 NDR_PULL_SET_MEM_CTX(ndr
, r
->in
.server_unc
, 0);
13555 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->in
.server_unc
));
13556 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->in
.server_unc
));
13557 if (ndr_get_array_length(ndr
, &r
->in
.server_unc
) > ndr_get_array_size(ndr
, &r
->in
.server_unc
)) {
13558 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", ndr_get_array_size(ndr
, &r
->in
.server_unc
), ndr_get_array_length(ndr
, &r
->in
.server_unc
));
13560 NDR_CHECK(ndr_check_string_terminator(ndr
, ndr_get_array_length(ndr
, &r
->in
.server_unc
), sizeof(uint16_t)));
13561 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->in
.server_unc
, ndr_get_array_length(ndr
, &r
->in
.server_unc
), sizeof(uint16_t), CH_UTF16
));
13562 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_server_unc_0
, 0);
13564 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_user
));
13566 NDR_PULL_ALLOC(ndr
, r
->in
.user
);
13571 _mem_save_user_0
= NDR_PULL_GET_MEM_CTX(ndr
);
13572 NDR_PULL_SET_MEM_CTX(ndr
, r
->in
.user
, 0);
13573 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->in
.user
));
13574 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->in
.user
));
13575 if (ndr_get_array_length(ndr
, &r
->in
.user
) > ndr_get_array_size(ndr
, &r
->in
.user
)) {
13576 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", ndr_get_array_size(ndr
, &r
->in
.user
), ndr_get_array_length(ndr
, &r
->in
.user
));
13578 NDR_CHECK(ndr_check_string_terminator(ndr
, ndr_get_array_length(ndr
, &r
->in
.user
), sizeof(uint16_t)));
13579 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->in
.user
, ndr_get_array_length(ndr
, &r
->in
.user
), sizeof(uint16_t), CH_UTF16
));
13580 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_user_0
, 0);
13582 if (ndr
->flags
& LIBNDR_FLAG_REF_ALLOC
) {
13583 NDR_PULL_ALLOC(ndr
, r
->in
.level
);
13585 _mem_save_level_0
= NDR_PULL_GET_MEM_CTX(ndr
);
13586 NDR_PULL_SET_MEM_CTX(ndr
, r
->in
.level
, LIBNDR_FLAG_REF_ALLOC
);
13587 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, r
->in
.level
));
13588 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_level_0
, LIBNDR_FLAG_REF_ALLOC
);
13589 if (ndr
->flags
& LIBNDR_FLAG_REF_ALLOC
) {
13590 NDR_PULL_ALLOC(ndr
, r
->in
.ctr
);
13592 _mem_save_ctr_0
= NDR_PULL_GET_MEM_CTX(ndr
);
13593 NDR_PULL_SET_MEM_CTX(ndr
, r
->in
.ctr
, LIBNDR_FLAG_REF_ALLOC
);
13594 NDR_CHECK(ndr_pull_set_switch_value(ndr
, r
->in
.ctr
, *r
->in
.level
));
13595 NDR_CHECK(ndr_pull_srvsvc_NetCharDevQCtr(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->in
.ctr
));
13596 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_ctr_0
, LIBNDR_FLAG_REF_ALLOC
);
13597 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->in
.max_buffer
));
13598 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_resume_handle
));
13599 if (_ptr_resume_handle
) {
13600 NDR_PULL_ALLOC(ndr
, r
->in
.resume_handle
);
13602 r
->in
.resume_handle
= NULL
;
13604 if (r
->in
.resume_handle
) {
13605 _mem_save_resume_handle_0
= NDR_PULL_GET_MEM_CTX(ndr
);
13606 NDR_PULL_SET_MEM_CTX(ndr
, r
->in
.resume_handle
, 0);
13607 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, r
->in
.resume_handle
));
13608 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_resume_handle_0
, 0);
13610 NDR_PULL_ALLOC(ndr
, r
->out
.level
);
13611 *r
->out
.level
= *r
->in
.level
;
13612 NDR_PULL_ALLOC(ndr
, r
->out
.ctr
);
13613 *r
->out
.ctr
= *r
->in
.ctr
;
13614 NDR_PULL_ALLOC(ndr
, r
->out
.totalentries
);
13615 ZERO_STRUCTP(r
->out
.totalentries
);
13617 if (flags
& NDR_OUT
) {
13618 if (ndr
->flags
& LIBNDR_FLAG_REF_ALLOC
) {
13619 NDR_PULL_ALLOC(ndr
, r
->out
.level
);
13621 _mem_save_level_0
= NDR_PULL_GET_MEM_CTX(ndr
);
13622 NDR_PULL_SET_MEM_CTX(ndr
, r
->out
.level
, LIBNDR_FLAG_REF_ALLOC
);
13623 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, r
->out
.level
));
13624 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_level_0
, LIBNDR_FLAG_REF_ALLOC
);
13625 if (ndr
->flags
& LIBNDR_FLAG_REF_ALLOC
) {
13626 NDR_PULL_ALLOC(ndr
, r
->out
.ctr
);
13628 _mem_save_ctr_0
= NDR_PULL_GET_MEM_CTX(ndr
);
13629 NDR_PULL_SET_MEM_CTX(ndr
, r
->out
.ctr
, LIBNDR_FLAG_REF_ALLOC
);
13630 NDR_CHECK(ndr_pull_set_switch_value(ndr
, r
->out
.ctr
, *r
->out
.level
));
13631 NDR_CHECK(ndr_pull_srvsvc_NetCharDevQCtr(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->out
.ctr
));
13632 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_ctr_0
, LIBNDR_FLAG_REF_ALLOC
);
13633 if (ndr
->flags
& LIBNDR_FLAG_REF_ALLOC
) {
13634 NDR_PULL_ALLOC(ndr
, r
->out
.totalentries
);
13636 _mem_save_totalentries_0
= NDR_PULL_GET_MEM_CTX(ndr
);
13637 NDR_PULL_SET_MEM_CTX(ndr
, r
->out
.totalentries
, LIBNDR_FLAG_REF_ALLOC
);
13638 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, r
->out
.totalentries
));
13639 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_totalentries_0
, LIBNDR_FLAG_REF_ALLOC
);
13640 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_resume_handle
));
13641 if (_ptr_resume_handle
) {
13642 NDR_PULL_ALLOC(ndr
, r
->out
.resume_handle
);
13644 r
->out
.resume_handle
= NULL
;
13646 if (r
->out
.resume_handle
) {
13647 _mem_save_resume_handle_0
= NDR_PULL_GET_MEM_CTX(ndr
);
13648 NDR_PULL_SET_MEM_CTX(ndr
, r
->out
.resume_handle
, 0);
13649 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, r
->out
.resume_handle
));
13650 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_resume_handle_0
, 0);
13652 NDR_CHECK(ndr_pull_WERROR(ndr
, NDR_SCALARS
, &r
->out
.result
));
13654 return NDR_ERR_SUCCESS
;
13657 _PUBLIC_
void ndr_print_srvsvc_NetCharDevQEnum(struct ndr_print
*ndr
, const char *name
, int flags
, const struct srvsvc_NetCharDevQEnum
*r
)
13659 ndr_print_struct(ndr
, name
, "srvsvc_NetCharDevQEnum");
13661 if (flags
& NDR_SET_VALUES
) {
13662 ndr
->flags
|= LIBNDR_PRINT_SET_VALUES
;
13664 if (flags
& NDR_IN
) {
13665 ndr_print_struct(ndr
, "in", "srvsvc_NetCharDevQEnum");
13667 ndr_print_ptr(ndr
, "server_unc", r
->in
.server_unc
);
13669 if (r
->in
.server_unc
) {
13670 ndr_print_string(ndr
, "server_unc", r
->in
.server_unc
);
13673 ndr_print_ptr(ndr
, "user", r
->in
.user
);
13676 ndr_print_string(ndr
, "user", r
->in
.user
);
13679 ndr_print_ptr(ndr
, "level", r
->in
.level
);
13681 ndr_print_uint32(ndr
, "level", *r
->in
.level
);
13683 ndr_print_ptr(ndr
, "ctr", r
->in
.ctr
);
13685 ndr_print_set_switch_value(ndr
, r
->in
.ctr
, *r
->in
.level
);
13686 ndr_print_srvsvc_NetCharDevQCtr(ndr
, "ctr", r
->in
.ctr
);
13688 ndr_print_uint32(ndr
, "max_buffer", r
->in
.max_buffer
);
13689 ndr_print_ptr(ndr
, "resume_handle", r
->in
.resume_handle
);
13691 if (r
->in
.resume_handle
) {
13692 ndr_print_uint32(ndr
, "resume_handle", *r
->in
.resume_handle
);
13697 if (flags
& NDR_OUT
) {
13698 ndr_print_struct(ndr
, "out", "srvsvc_NetCharDevQEnum");
13700 ndr_print_ptr(ndr
, "level", r
->out
.level
);
13702 ndr_print_uint32(ndr
, "level", *r
->out
.level
);
13704 ndr_print_ptr(ndr
, "ctr", r
->out
.ctr
);
13706 ndr_print_set_switch_value(ndr
, r
->out
.ctr
, *r
->out
.level
);
13707 ndr_print_srvsvc_NetCharDevQCtr(ndr
, "ctr", r
->out
.ctr
);
13709 ndr_print_ptr(ndr
, "totalentries", r
->out
.totalentries
);
13711 ndr_print_uint32(ndr
, "totalentries", *r
->out
.totalentries
);
13713 ndr_print_ptr(ndr
, "resume_handle", r
->out
.resume_handle
);
13715 if (r
->out
.resume_handle
) {
13716 ndr_print_uint32(ndr
, "resume_handle", *r
->out
.resume_handle
);
13719 ndr_print_WERROR(ndr
, "result", r
->out
.result
);
13725 static enum ndr_err_code
ndr_push_srvsvc_NetCharDevQGetInfo(struct ndr_push
*ndr
, int flags
, const struct srvsvc_NetCharDevQGetInfo
*r
)
13727 if (flags
& NDR_IN
) {
13728 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->in
.server_unc
));
13729 if (r
->in
.server_unc
) {
13730 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.server_unc
, CH_UTF16
)));
13731 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
13732 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.server_unc
, CH_UTF16
)));
13733 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
));
13735 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.queue_name
, CH_UTF16
)));
13736 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
13737 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.queue_name
, CH_UTF16
)));
13738 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
));
13739 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.user
, CH_UTF16
)));
13740 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
13741 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.user
, CH_UTF16
)));
13742 NDR_CHECK(ndr_push_charset(ndr
, NDR_SCALARS
, r
->in
.user
, ndr_charset_length(r
->in
.user
, CH_UTF16
), sizeof(uint16_t), CH_UTF16
));
13743 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->in
.level
));
13745 if (flags
& NDR_OUT
) {
13746 if (r
->out
.info
== NULL
) {
13747 return ndr_push_error(ndr
, NDR_ERR_INVALID_POINTER
, "NULL [ref] pointer");
13749 NDR_CHECK(ndr_push_set_switch_value(ndr
, r
->out
.info
, r
->in
.level
));
13750 NDR_CHECK(ndr_push_srvsvc_NetCharDevQInfo(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->out
.info
));
13751 NDR_CHECK(ndr_push_WERROR(ndr
, NDR_SCALARS
, r
->out
.result
));
13753 return NDR_ERR_SUCCESS
;
13756 static enum ndr_err_code
ndr_pull_srvsvc_NetCharDevQGetInfo(struct ndr_pull
*ndr
, int flags
, struct srvsvc_NetCharDevQGetInfo
*r
)
13758 uint32_t _ptr_server_unc
;
13759 TALLOC_CTX
*_mem_save_server_unc_0
;
13760 TALLOC_CTX
*_mem_save_info_0
;
13761 if (flags
& NDR_IN
) {
13762 ZERO_STRUCT(r
->out
);
13764 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_server_unc
));
13765 if (_ptr_server_unc
) {
13766 NDR_PULL_ALLOC(ndr
, r
->in
.server_unc
);
13768 r
->in
.server_unc
= NULL
;
13770 if (r
->in
.server_unc
) {
13771 _mem_save_server_unc_0
= NDR_PULL_GET_MEM_CTX(ndr
);
13772 NDR_PULL_SET_MEM_CTX(ndr
, r
->in
.server_unc
, 0);
13773 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->in
.server_unc
));
13774 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->in
.server_unc
));
13775 if (ndr_get_array_length(ndr
, &r
->in
.server_unc
) > ndr_get_array_size(ndr
, &r
->in
.server_unc
)) {
13776 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", ndr_get_array_size(ndr
, &r
->in
.server_unc
), ndr_get_array_length(ndr
, &r
->in
.server_unc
));
13778 NDR_CHECK(ndr_check_string_terminator(ndr
, ndr_get_array_length(ndr
, &r
->in
.server_unc
), sizeof(uint16_t)));
13779 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->in
.server_unc
, ndr_get_array_length(ndr
, &r
->in
.server_unc
), sizeof(uint16_t), CH_UTF16
));
13780 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_server_unc_0
, 0);
13782 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->in
.queue_name
));
13783 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->in
.queue_name
));
13784 if (ndr_get_array_length(ndr
, &r
->in
.queue_name
) > ndr_get_array_size(ndr
, &r
->in
.queue_name
)) {
13785 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", ndr_get_array_size(ndr
, &r
->in
.queue_name
), ndr_get_array_length(ndr
, &r
->in
.queue_name
));
13787 NDR_CHECK(ndr_check_string_terminator(ndr
, ndr_get_array_length(ndr
, &r
->in
.queue_name
), sizeof(uint16_t)));
13788 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->in
.queue_name
, ndr_get_array_length(ndr
, &r
->in
.queue_name
), sizeof(uint16_t), CH_UTF16
));
13789 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->in
.user
));
13790 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->in
.user
));
13791 if (ndr_get_array_length(ndr
, &r
->in
.user
) > ndr_get_array_size(ndr
, &r
->in
.user
)) {
13792 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", ndr_get_array_size(ndr
, &r
->in
.user
), ndr_get_array_length(ndr
, &r
->in
.user
));
13794 NDR_CHECK(ndr_check_string_terminator(ndr
, ndr_get_array_length(ndr
, &r
->in
.user
), sizeof(uint16_t)));
13795 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->in
.user
, ndr_get_array_length(ndr
, &r
->in
.user
), sizeof(uint16_t), CH_UTF16
));
13796 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->in
.level
));
13797 NDR_PULL_ALLOC(ndr
, r
->out
.info
);
13798 ZERO_STRUCTP(r
->out
.info
);
13800 if (flags
& NDR_OUT
) {
13801 if (ndr
->flags
& LIBNDR_FLAG_REF_ALLOC
) {
13802 NDR_PULL_ALLOC(ndr
, r
->out
.info
);
13804 _mem_save_info_0
= NDR_PULL_GET_MEM_CTX(ndr
);
13805 NDR_PULL_SET_MEM_CTX(ndr
, r
->out
.info
, LIBNDR_FLAG_REF_ALLOC
);
13806 NDR_CHECK(ndr_pull_set_switch_value(ndr
, r
->out
.info
, r
->in
.level
));
13807 NDR_CHECK(ndr_pull_srvsvc_NetCharDevQInfo(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->out
.info
));
13808 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_info_0
, LIBNDR_FLAG_REF_ALLOC
);
13809 NDR_CHECK(ndr_pull_WERROR(ndr
, NDR_SCALARS
, &r
->out
.result
));
13811 return NDR_ERR_SUCCESS
;
13814 _PUBLIC_
void ndr_print_srvsvc_NetCharDevQGetInfo(struct ndr_print
*ndr
, const char *name
, int flags
, const struct srvsvc_NetCharDevQGetInfo
*r
)
13816 ndr_print_struct(ndr
, name
, "srvsvc_NetCharDevQGetInfo");
13818 if (flags
& NDR_SET_VALUES
) {
13819 ndr
->flags
|= LIBNDR_PRINT_SET_VALUES
;
13821 if (flags
& NDR_IN
) {
13822 ndr_print_struct(ndr
, "in", "srvsvc_NetCharDevQGetInfo");
13824 ndr_print_ptr(ndr
, "server_unc", r
->in
.server_unc
);
13826 if (r
->in
.server_unc
) {
13827 ndr_print_string(ndr
, "server_unc", r
->in
.server_unc
);
13830 ndr_print_string(ndr
, "queue_name", r
->in
.queue_name
);
13831 ndr_print_string(ndr
, "user", r
->in
.user
);
13832 ndr_print_uint32(ndr
, "level", r
->in
.level
);
13835 if (flags
& NDR_OUT
) {
13836 ndr_print_struct(ndr
, "out", "srvsvc_NetCharDevQGetInfo");
13838 ndr_print_ptr(ndr
, "info", r
->out
.info
);
13840 ndr_print_set_switch_value(ndr
, r
->out
.info
, r
->in
.level
);
13841 ndr_print_srvsvc_NetCharDevQInfo(ndr
, "info", r
->out
.info
);
13843 ndr_print_WERROR(ndr
, "result", r
->out
.result
);
13849 static enum ndr_err_code
ndr_push_srvsvc_NetCharDevQSetInfo(struct ndr_push
*ndr
, int flags
, const struct srvsvc_NetCharDevQSetInfo
*r
)
13851 if (flags
& NDR_IN
) {
13852 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->in
.server_unc
));
13853 if (r
->in
.server_unc
) {
13854 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.server_unc
, CH_UTF16
)));
13855 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
13856 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.server_unc
, CH_UTF16
)));
13857 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
));
13859 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.queue_name
, CH_UTF16
)));
13860 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
13861 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.queue_name
, CH_UTF16
)));
13862 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
));
13863 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->in
.level
));
13864 NDR_CHECK(ndr_push_set_switch_value(ndr
, &r
->in
.info
, r
->in
.level
));
13865 NDR_CHECK(ndr_push_srvsvc_NetCharDevQInfo(ndr
, NDR_SCALARS
|NDR_BUFFERS
, &r
->in
.info
));
13866 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->in
.parm_error
));
13867 if (r
->in
.parm_error
) {
13868 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, *r
->in
.parm_error
));
13871 if (flags
& NDR_OUT
) {
13872 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->out
.parm_error
));
13873 if (r
->out
.parm_error
) {
13874 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, *r
->out
.parm_error
));
13876 NDR_CHECK(ndr_push_WERROR(ndr
, NDR_SCALARS
, r
->out
.result
));
13878 return NDR_ERR_SUCCESS
;
13881 static enum ndr_err_code
ndr_pull_srvsvc_NetCharDevQSetInfo(struct ndr_pull
*ndr
, int flags
, struct srvsvc_NetCharDevQSetInfo
*r
)
13883 uint32_t _ptr_server_unc
;
13884 uint32_t _ptr_parm_error
;
13885 TALLOC_CTX
*_mem_save_server_unc_0
;
13886 TALLOC_CTX
*_mem_save_parm_error_0
;
13887 if (flags
& NDR_IN
) {
13888 ZERO_STRUCT(r
->out
);
13890 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_server_unc
));
13891 if (_ptr_server_unc
) {
13892 NDR_PULL_ALLOC(ndr
, r
->in
.server_unc
);
13894 r
->in
.server_unc
= NULL
;
13896 if (r
->in
.server_unc
) {
13897 _mem_save_server_unc_0
= NDR_PULL_GET_MEM_CTX(ndr
);
13898 NDR_PULL_SET_MEM_CTX(ndr
, r
->in
.server_unc
, 0);
13899 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->in
.server_unc
));
13900 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->in
.server_unc
));
13901 if (ndr_get_array_length(ndr
, &r
->in
.server_unc
) > ndr_get_array_size(ndr
, &r
->in
.server_unc
)) {
13902 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", ndr_get_array_size(ndr
, &r
->in
.server_unc
), ndr_get_array_length(ndr
, &r
->in
.server_unc
));
13904 NDR_CHECK(ndr_check_string_terminator(ndr
, ndr_get_array_length(ndr
, &r
->in
.server_unc
), sizeof(uint16_t)));
13905 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->in
.server_unc
, ndr_get_array_length(ndr
, &r
->in
.server_unc
), sizeof(uint16_t), CH_UTF16
));
13906 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_server_unc_0
, 0);
13908 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->in
.queue_name
));
13909 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->in
.queue_name
));
13910 if (ndr_get_array_length(ndr
, &r
->in
.queue_name
) > ndr_get_array_size(ndr
, &r
->in
.queue_name
)) {
13911 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", ndr_get_array_size(ndr
, &r
->in
.queue_name
), ndr_get_array_length(ndr
, &r
->in
.queue_name
));
13913 NDR_CHECK(ndr_check_string_terminator(ndr
, ndr_get_array_length(ndr
, &r
->in
.queue_name
), sizeof(uint16_t)));
13914 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->in
.queue_name
, ndr_get_array_length(ndr
, &r
->in
.queue_name
), sizeof(uint16_t), CH_UTF16
));
13915 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->in
.level
));
13916 NDR_CHECK(ndr_pull_set_switch_value(ndr
, &r
->in
.info
, r
->in
.level
));
13917 NDR_CHECK(ndr_pull_srvsvc_NetCharDevQInfo(ndr
, NDR_SCALARS
|NDR_BUFFERS
, &r
->in
.info
));
13918 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_parm_error
));
13919 if (_ptr_parm_error
) {
13920 NDR_PULL_ALLOC(ndr
, r
->in
.parm_error
);
13922 r
->in
.parm_error
= NULL
;
13924 if (r
->in
.parm_error
) {
13925 _mem_save_parm_error_0
= NDR_PULL_GET_MEM_CTX(ndr
);
13926 NDR_PULL_SET_MEM_CTX(ndr
, r
->in
.parm_error
, 0);
13927 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, r
->in
.parm_error
));
13928 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_parm_error_0
, 0);
13931 if (flags
& NDR_OUT
) {
13932 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_parm_error
));
13933 if (_ptr_parm_error
) {
13934 NDR_PULL_ALLOC(ndr
, r
->out
.parm_error
);
13936 r
->out
.parm_error
= NULL
;
13938 if (r
->out
.parm_error
) {
13939 _mem_save_parm_error_0
= NDR_PULL_GET_MEM_CTX(ndr
);
13940 NDR_PULL_SET_MEM_CTX(ndr
, r
->out
.parm_error
, 0);
13941 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, r
->out
.parm_error
));
13942 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_parm_error_0
, 0);
13944 NDR_CHECK(ndr_pull_WERROR(ndr
, NDR_SCALARS
, &r
->out
.result
));
13946 return NDR_ERR_SUCCESS
;
13949 _PUBLIC_
void ndr_print_srvsvc_NetCharDevQSetInfo(struct ndr_print
*ndr
, const char *name
, int flags
, const struct srvsvc_NetCharDevQSetInfo
*r
)
13951 ndr_print_struct(ndr
, name
, "srvsvc_NetCharDevQSetInfo");
13953 if (flags
& NDR_SET_VALUES
) {
13954 ndr
->flags
|= LIBNDR_PRINT_SET_VALUES
;
13956 if (flags
& NDR_IN
) {
13957 ndr_print_struct(ndr
, "in", "srvsvc_NetCharDevQSetInfo");
13959 ndr_print_ptr(ndr
, "server_unc", r
->in
.server_unc
);
13961 if (r
->in
.server_unc
) {
13962 ndr_print_string(ndr
, "server_unc", r
->in
.server_unc
);
13965 ndr_print_string(ndr
, "queue_name", r
->in
.queue_name
);
13966 ndr_print_uint32(ndr
, "level", r
->in
.level
);
13967 ndr_print_set_switch_value(ndr
, &r
->in
.info
, r
->in
.level
);
13968 ndr_print_srvsvc_NetCharDevQInfo(ndr
, "info", &r
->in
.info
);
13969 ndr_print_ptr(ndr
, "parm_error", r
->in
.parm_error
);
13971 if (r
->in
.parm_error
) {
13972 ndr_print_uint32(ndr
, "parm_error", *r
->in
.parm_error
);
13977 if (flags
& NDR_OUT
) {
13978 ndr_print_struct(ndr
, "out", "srvsvc_NetCharDevQSetInfo");
13980 ndr_print_ptr(ndr
, "parm_error", r
->out
.parm_error
);
13982 if (r
->out
.parm_error
) {
13983 ndr_print_uint32(ndr
, "parm_error", *r
->out
.parm_error
);
13986 ndr_print_WERROR(ndr
, "result", r
->out
.result
);
13992 static enum ndr_err_code
ndr_push_srvsvc_NetCharDevQPurge(struct ndr_push
*ndr
, int flags
, const struct srvsvc_NetCharDevQPurge
*r
)
13994 if (flags
& NDR_IN
) {
13995 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->in
.server_unc
));
13996 if (r
->in
.server_unc
) {
13997 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.server_unc
, CH_UTF16
)));
13998 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
13999 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.server_unc
, CH_UTF16
)));
14000 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
));
14002 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.queue_name
, CH_UTF16
)));
14003 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
14004 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.queue_name
, CH_UTF16
)));
14005 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
));
14007 if (flags
& NDR_OUT
) {
14008 NDR_CHECK(ndr_push_WERROR(ndr
, NDR_SCALARS
, r
->out
.result
));
14010 return NDR_ERR_SUCCESS
;
14013 static enum ndr_err_code
ndr_pull_srvsvc_NetCharDevQPurge(struct ndr_pull
*ndr
, int flags
, struct srvsvc_NetCharDevQPurge
*r
)
14015 uint32_t _ptr_server_unc
;
14016 TALLOC_CTX
*_mem_save_server_unc_0
;
14017 if (flags
& NDR_IN
) {
14018 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_server_unc
));
14019 if (_ptr_server_unc
) {
14020 NDR_PULL_ALLOC(ndr
, r
->in
.server_unc
);
14022 r
->in
.server_unc
= NULL
;
14024 if (r
->in
.server_unc
) {
14025 _mem_save_server_unc_0
= NDR_PULL_GET_MEM_CTX(ndr
);
14026 NDR_PULL_SET_MEM_CTX(ndr
, r
->in
.server_unc
, 0);
14027 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->in
.server_unc
));
14028 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->in
.server_unc
));
14029 if (ndr_get_array_length(ndr
, &r
->in
.server_unc
) > ndr_get_array_size(ndr
, &r
->in
.server_unc
)) {
14030 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", ndr_get_array_size(ndr
, &r
->in
.server_unc
), ndr_get_array_length(ndr
, &r
->in
.server_unc
));
14032 NDR_CHECK(ndr_check_string_terminator(ndr
, ndr_get_array_length(ndr
, &r
->in
.server_unc
), sizeof(uint16_t)));
14033 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->in
.server_unc
, ndr_get_array_length(ndr
, &r
->in
.server_unc
), sizeof(uint16_t), CH_UTF16
));
14034 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_server_unc_0
, 0);
14036 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->in
.queue_name
));
14037 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->in
.queue_name
));
14038 if (ndr_get_array_length(ndr
, &r
->in
.queue_name
) > ndr_get_array_size(ndr
, &r
->in
.queue_name
)) {
14039 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", ndr_get_array_size(ndr
, &r
->in
.queue_name
), ndr_get_array_length(ndr
, &r
->in
.queue_name
));
14041 NDR_CHECK(ndr_check_string_terminator(ndr
, ndr_get_array_length(ndr
, &r
->in
.queue_name
), sizeof(uint16_t)));
14042 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->in
.queue_name
, ndr_get_array_length(ndr
, &r
->in
.queue_name
), sizeof(uint16_t), CH_UTF16
));
14044 if (flags
& NDR_OUT
) {
14045 NDR_CHECK(ndr_pull_WERROR(ndr
, NDR_SCALARS
, &r
->out
.result
));
14047 return NDR_ERR_SUCCESS
;
14050 _PUBLIC_
void ndr_print_srvsvc_NetCharDevQPurge(struct ndr_print
*ndr
, const char *name
, int flags
, const struct srvsvc_NetCharDevQPurge
*r
)
14052 ndr_print_struct(ndr
, name
, "srvsvc_NetCharDevQPurge");
14054 if (flags
& NDR_SET_VALUES
) {
14055 ndr
->flags
|= LIBNDR_PRINT_SET_VALUES
;
14057 if (flags
& NDR_IN
) {
14058 ndr_print_struct(ndr
, "in", "srvsvc_NetCharDevQPurge");
14060 ndr_print_ptr(ndr
, "server_unc", r
->in
.server_unc
);
14062 if (r
->in
.server_unc
) {
14063 ndr_print_string(ndr
, "server_unc", r
->in
.server_unc
);
14066 ndr_print_string(ndr
, "queue_name", r
->in
.queue_name
);
14069 if (flags
& NDR_OUT
) {
14070 ndr_print_struct(ndr
, "out", "srvsvc_NetCharDevQPurge");
14072 ndr_print_WERROR(ndr
, "result", r
->out
.result
);
14078 static enum ndr_err_code
ndr_push_srvsvc_NetCharDevQPurgeSelf(struct ndr_push
*ndr
, int flags
, const struct srvsvc_NetCharDevQPurgeSelf
*r
)
14080 if (flags
& NDR_IN
) {
14081 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->in
.server_unc
));
14082 if (r
->in
.server_unc
) {
14083 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.server_unc
, CH_UTF16
)));
14084 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
14085 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.server_unc
, CH_UTF16
)));
14086 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
));
14088 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.queue_name
, CH_UTF16
)));
14089 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
14090 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.queue_name
, CH_UTF16
)));
14091 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
));
14092 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.computer_name
, CH_UTF16
)));
14093 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
14094 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.computer_name
, CH_UTF16
)));
14095 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
));
14097 if (flags
& NDR_OUT
) {
14098 NDR_CHECK(ndr_push_WERROR(ndr
, NDR_SCALARS
, r
->out
.result
));
14100 return NDR_ERR_SUCCESS
;
14103 static enum ndr_err_code
ndr_pull_srvsvc_NetCharDevQPurgeSelf(struct ndr_pull
*ndr
, int flags
, struct srvsvc_NetCharDevQPurgeSelf
*r
)
14105 uint32_t _ptr_server_unc
;
14106 TALLOC_CTX
*_mem_save_server_unc_0
;
14107 if (flags
& NDR_IN
) {
14108 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_server_unc
));
14109 if (_ptr_server_unc
) {
14110 NDR_PULL_ALLOC(ndr
, r
->in
.server_unc
);
14112 r
->in
.server_unc
= NULL
;
14114 if (r
->in
.server_unc
) {
14115 _mem_save_server_unc_0
= NDR_PULL_GET_MEM_CTX(ndr
);
14116 NDR_PULL_SET_MEM_CTX(ndr
, r
->in
.server_unc
, 0);
14117 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->in
.server_unc
));
14118 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->in
.server_unc
));
14119 if (ndr_get_array_length(ndr
, &r
->in
.server_unc
) > ndr_get_array_size(ndr
, &r
->in
.server_unc
)) {
14120 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", ndr_get_array_size(ndr
, &r
->in
.server_unc
), ndr_get_array_length(ndr
, &r
->in
.server_unc
));
14122 NDR_CHECK(ndr_check_string_terminator(ndr
, ndr_get_array_length(ndr
, &r
->in
.server_unc
), sizeof(uint16_t)));
14123 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->in
.server_unc
, ndr_get_array_length(ndr
, &r
->in
.server_unc
), sizeof(uint16_t), CH_UTF16
));
14124 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_server_unc_0
, 0);
14126 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->in
.queue_name
));
14127 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->in
.queue_name
));
14128 if (ndr_get_array_length(ndr
, &r
->in
.queue_name
) > ndr_get_array_size(ndr
, &r
->in
.queue_name
)) {
14129 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", ndr_get_array_size(ndr
, &r
->in
.queue_name
), ndr_get_array_length(ndr
, &r
->in
.queue_name
));
14131 NDR_CHECK(ndr_check_string_terminator(ndr
, ndr_get_array_length(ndr
, &r
->in
.queue_name
), sizeof(uint16_t)));
14132 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->in
.queue_name
, ndr_get_array_length(ndr
, &r
->in
.queue_name
), sizeof(uint16_t), CH_UTF16
));
14133 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->in
.computer_name
));
14134 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->in
.computer_name
));
14135 if (ndr_get_array_length(ndr
, &r
->in
.computer_name
) > ndr_get_array_size(ndr
, &r
->in
.computer_name
)) {
14136 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", ndr_get_array_size(ndr
, &r
->in
.computer_name
), ndr_get_array_length(ndr
, &r
->in
.computer_name
));
14138 NDR_CHECK(ndr_check_string_terminator(ndr
, ndr_get_array_length(ndr
, &r
->in
.computer_name
), sizeof(uint16_t)));
14139 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->in
.computer_name
, ndr_get_array_length(ndr
, &r
->in
.computer_name
), sizeof(uint16_t), CH_UTF16
));
14141 if (flags
& NDR_OUT
) {
14142 NDR_CHECK(ndr_pull_WERROR(ndr
, NDR_SCALARS
, &r
->out
.result
));
14144 return NDR_ERR_SUCCESS
;
14147 _PUBLIC_
void ndr_print_srvsvc_NetCharDevQPurgeSelf(struct ndr_print
*ndr
, const char *name
, int flags
, const struct srvsvc_NetCharDevQPurgeSelf
*r
)
14149 ndr_print_struct(ndr
, name
, "srvsvc_NetCharDevQPurgeSelf");
14151 if (flags
& NDR_SET_VALUES
) {
14152 ndr
->flags
|= LIBNDR_PRINT_SET_VALUES
;
14154 if (flags
& NDR_IN
) {
14155 ndr_print_struct(ndr
, "in", "srvsvc_NetCharDevQPurgeSelf");
14157 ndr_print_ptr(ndr
, "server_unc", r
->in
.server_unc
);
14159 if (r
->in
.server_unc
) {
14160 ndr_print_string(ndr
, "server_unc", r
->in
.server_unc
);
14163 ndr_print_string(ndr
, "queue_name", r
->in
.queue_name
);
14164 ndr_print_string(ndr
, "computer_name", r
->in
.computer_name
);
14167 if (flags
& NDR_OUT
) {
14168 ndr_print_struct(ndr
, "out", "srvsvc_NetCharDevQPurgeSelf");
14170 ndr_print_WERROR(ndr
, "result", r
->out
.result
);
14176 static enum ndr_err_code
ndr_push_srvsvc_NetConnEnum(struct ndr_push
*ndr
, int flags
, const struct srvsvc_NetConnEnum
*r
)
14178 if (flags
& NDR_IN
) {
14179 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->in
.server_unc
));
14180 if (r
->in
.server_unc
) {
14181 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.server_unc
, CH_UTF16
)));
14182 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
14183 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.server_unc
, CH_UTF16
)));
14184 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
));
14186 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->in
.path
));
14188 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.path
, CH_UTF16
)));
14189 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
14190 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.path
, CH_UTF16
)));
14191 NDR_CHECK(ndr_push_charset(ndr
, NDR_SCALARS
, r
->in
.path
, ndr_charset_length(r
->in
.path
, CH_UTF16
), sizeof(uint16_t), CH_UTF16
));
14193 if (r
->in
.info_ctr
== NULL
) {
14194 return ndr_push_error(ndr
, NDR_ERR_INVALID_POINTER
, "NULL [ref] pointer");
14196 NDR_CHECK(ndr_push_srvsvc_NetConnInfoCtr(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->in
.info_ctr
));
14197 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->in
.max_buffer
));
14198 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->in
.resume_handle
));
14199 if (r
->in
.resume_handle
) {
14200 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, *r
->in
.resume_handle
));
14203 if (flags
& NDR_OUT
) {
14204 if (r
->out
.info_ctr
== NULL
) {
14205 return ndr_push_error(ndr
, NDR_ERR_INVALID_POINTER
, "NULL [ref] pointer");
14207 NDR_CHECK(ndr_push_srvsvc_NetConnInfoCtr(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->out
.info_ctr
));
14208 if (r
->out
.totalentries
== NULL
) {
14209 return ndr_push_error(ndr
, NDR_ERR_INVALID_POINTER
, "NULL [ref] pointer");
14211 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, *r
->out
.totalentries
));
14212 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->out
.resume_handle
));
14213 if (r
->out
.resume_handle
) {
14214 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, *r
->out
.resume_handle
));
14216 NDR_CHECK(ndr_push_WERROR(ndr
, NDR_SCALARS
, r
->out
.result
));
14218 return NDR_ERR_SUCCESS
;
14221 static enum ndr_err_code
ndr_pull_srvsvc_NetConnEnum(struct ndr_pull
*ndr
, int flags
, struct srvsvc_NetConnEnum
*r
)
14223 uint32_t _ptr_server_unc
;
14224 uint32_t _ptr_path
;
14225 uint32_t _ptr_resume_handle
;
14226 TALLOC_CTX
*_mem_save_server_unc_0
;
14227 TALLOC_CTX
*_mem_save_path_0
;
14228 TALLOC_CTX
*_mem_save_info_ctr_0
;
14229 TALLOC_CTX
*_mem_save_totalentries_0
;
14230 TALLOC_CTX
*_mem_save_resume_handle_0
;
14231 if (flags
& NDR_IN
) {
14232 ZERO_STRUCT(r
->out
);
14234 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_server_unc
));
14235 if (_ptr_server_unc
) {
14236 NDR_PULL_ALLOC(ndr
, r
->in
.server_unc
);
14238 r
->in
.server_unc
= NULL
;
14240 if (r
->in
.server_unc
) {
14241 _mem_save_server_unc_0
= NDR_PULL_GET_MEM_CTX(ndr
);
14242 NDR_PULL_SET_MEM_CTX(ndr
, r
->in
.server_unc
, 0);
14243 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->in
.server_unc
));
14244 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->in
.server_unc
));
14245 if (ndr_get_array_length(ndr
, &r
->in
.server_unc
) > ndr_get_array_size(ndr
, &r
->in
.server_unc
)) {
14246 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", ndr_get_array_size(ndr
, &r
->in
.server_unc
), ndr_get_array_length(ndr
, &r
->in
.server_unc
));
14248 NDR_CHECK(ndr_check_string_terminator(ndr
, ndr_get_array_length(ndr
, &r
->in
.server_unc
), sizeof(uint16_t)));
14249 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->in
.server_unc
, ndr_get_array_length(ndr
, &r
->in
.server_unc
), sizeof(uint16_t), CH_UTF16
));
14250 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_server_unc_0
, 0);
14252 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_path
));
14254 NDR_PULL_ALLOC(ndr
, r
->in
.path
);
14259 _mem_save_path_0
= NDR_PULL_GET_MEM_CTX(ndr
);
14260 NDR_PULL_SET_MEM_CTX(ndr
, r
->in
.path
, 0);
14261 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->in
.path
));
14262 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->in
.path
));
14263 if (ndr_get_array_length(ndr
, &r
->in
.path
) > ndr_get_array_size(ndr
, &r
->in
.path
)) {
14264 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", ndr_get_array_size(ndr
, &r
->in
.path
), ndr_get_array_length(ndr
, &r
->in
.path
));
14266 NDR_CHECK(ndr_check_string_terminator(ndr
, ndr_get_array_length(ndr
, &r
->in
.path
), sizeof(uint16_t)));
14267 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->in
.path
, ndr_get_array_length(ndr
, &r
->in
.path
), sizeof(uint16_t), CH_UTF16
));
14268 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_path_0
, 0);
14270 if (ndr
->flags
& LIBNDR_FLAG_REF_ALLOC
) {
14271 NDR_PULL_ALLOC(ndr
, r
->in
.info_ctr
);
14273 _mem_save_info_ctr_0
= NDR_PULL_GET_MEM_CTX(ndr
);
14274 NDR_PULL_SET_MEM_CTX(ndr
, r
->in
.info_ctr
, LIBNDR_FLAG_REF_ALLOC
);
14275 NDR_CHECK(ndr_pull_srvsvc_NetConnInfoCtr(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->in
.info_ctr
));
14276 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_info_ctr_0
, LIBNDR_FLAG_REF_ALLOC
);
14277 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->in
.max_buffer
));
14278 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_resume_handle
));
14279 if (_ptr_resume_handle
) {
14280 NDR_PULL_ALLOC(ndr
, r
->in
.resume_handle
);
14282 r
->in
.resume_handle
= NULL
;
14284 if (r
->in
.resume_handle
) {
14285 _mem_save_resume_handle_0
= NDR_PULL_GET_MEM_CTX(ndr
);
14286 NDR_PULL_SET_MEM_CTX(ndr
, r
->in
.resume_handle
, 0);
14287 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, r
->in
.resume_handle
));
14288 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_resume_handle_0
, 0);
14290 NDR_PULL_ALLOC(ndr
, r
->out
.info_ctr
);
14291 *r
->out
.info_ctr
= *r
->in
.info_ctr
;
14292 NDR_PULL_ALLOC(ndr
, r
->out
.totalentries
);
14293 ZERO_STRUCTP(r
->out
.totalentries
);
14295 if (flags
& NDR_OUT
) {
14296 if (ndr
->flags
& LIBNDR_FLAG_REF_ALLOC
) {
14297 NDR_PULL_ALLOC(ndr
, r
->out
.info_ctr
);
14299 _mem_save_info_ctr_0
= NDR_PULL_GET_MEM_CTX(ndr
);
14300 NDR_PULL_SET_MEM_CTX(ndr
, r
->out
.info_ctr
, LIBNDR_FLAG_REF_ALLOC
);
14301 NDR_CHECK(ndr_pull_srvsvc_NetConnInfoCtr(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->out
.info_ctr
));
14302 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_info_ctr_0
, LIBNDR_FLAG_REF_ALLOC
);
14303 if (ndr
->flags
& LIBNDR_FLAG_REF_ALLOC
) {
14304 NDR_PULL_ALLOC(ndr
, r
->out
.totalentries
);
14306 _mem_save_totalentries_0
= NDR_PULL_GET_MEM_CTX(ndr
);
14307 NDR_PULL_SET_MEM_CTX(ndr
, r
->out
.totalentries
, LIBNDR_FLAG_REF_ALLOC
);
14308 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, r
->out
.totalentries
));
14309 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_totalentries_0
, LIBNDR_FLAG_REF_ALLOC
);
14310 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_resume_handle
));
14311 if (_ptr_resume_handle
) {
14312 NDR_PULL_ALLOC(ndr
, r
->out
.resume_handle
);
14314 r
->out
.resume_handle
= NULL
;
14316 if (r
->out
.resume_handle
) {
14317 _mem_save_resume_handle_0
= NDR_PULL_GET_MEM_CTX(ndr
);
14318 NDR_PULL_SET_MEM_CTX(ndr
, r
->out
.resume_handle
, 0);
14319 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, r
->out
.resume_handle
));
14320 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_resume_handle_0
, 0);
14322 NDR_CHECK(ndr_pull_WERROR(ndr
, NDR_SCALARS
, &r
->out
.result
));
14324 return NDR_ERR_SUCCESS
;
14327 _PUBLIC_
void ndr_print_srvsvc_NetConnEnum(struct ndr_print
*ndr
, const char *name
, int flags
, const struct srvsvc_NetConnEnum
*r
)
14329 ndr_print_struct(ndr
, name
, "srvsvc_NetConnEnum");
14331 if (flags
& NDR_SET_VALUES
) {
14332 ndr
->flags
|= LIBNDR_PRINT_SET_VALUES
;
14334 if (flags
& NDR_IN
) {
14335 ndr_print_struct(ndr
, "in", "srvsvc_NetConnEnum");
14337 ndr_print_ptr(ndr
, "server_unc", r
->in
.server_unc
);
14339 if (r
->in
.server_unc
) {
14340 ndr_print_string(ndr
, "server_unc", r
->in
.server_unc
);
14343 ndr_print_ptr(ndr
, "path", r
->in
.path
);
14346 ndr_print_string(ndr
, "path", r
->in
.path
);
14349 ndr_print_ptr(ndr
, "info_ctr", r
->in
.info_ctr
);
14351 ndr_print_srvsvc_NetConnInfoCtr(ndr
, "info_ctr", r
->in
.info_ctr
);
14353 ndr_print_uint32(ndr
, "max_buffer", r
->in
.max_buffer
);
14354 ndr_print_ptr(ndr
, "resume_handle", r
->in
.resume_handle
);
14356 if (r
->in
.resume_handle
) {
14357 ndr_print_uint32(ndr
, "resume_handle", *r
->in
.resume_handle
);
14362 if (flags
& NDR_OUT
) {
14363 ndr_print_struct(ndr
, "out", "srvsvc_NetConnEnum");
14365 ndr_print_ptr(ndr
, "info_ctr", r
->out
.info_ctr
);
14367 ndr_print_srvsvc_NetConnInfoCtr(ndr
, "info_ctr", r
->out
.info_ctr
);
14369 ndr_print_ptr(ndr
, "totalentries", r
->out
.totalentries
);
14371 ndr_print_uint32(ndr
, "totalentries", *r
->out
.totalentries
);
14373 ndr_print_ptr(ndr
, "resume_handle", r
->out
.resume_handle
);
14375 if (r
->out
.resume_handle
) {
14376 ndr_print_uint32(ndr
, "resume_handle", *r
->out
.resume_handle
);
14379 ndr_print_WERROR(ndr
, "result", r
->out
.result
);
14385 static enum ndr_err_code
ndr_push_srvsvc_NetFileEnum(struct ndr_push
*ndr
, int flags
, const struct srvsvc_NetFileEnum
*r
)
14387 if (flags
& NDR_IN
) {
14388 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->in
.server_unc
));
14389 if (r
->in
.server_unc
) {
14390 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.server_unc
, CH_UTF16
)));
14391 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
14392 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.server_unc
, CH_UTF16
)));
14393 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
));
14395 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->in
.path
));
14397 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.path
, CH_UTF16
)));
14398 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
14399 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.path
, CH_UTF16
)));
14400 NDR_CHECK(ndr_push_charset(ndr
, NDR_SCALARS
, r
->in
.path
, ndr_charset_length(r
->in
.path
, CH_UTF16
), sizeof(uint16_t), CH_UTF16
));
14402 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->in
.user
));
14404 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.user
, CH_UTF16
)));
14405 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
14406 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.user
, CH_UTF16
)));
14407 NDR_CHECK(ndr_push_charset(ndr
, NDR_SCALARS
, r
->in
.user
, ndr_charset_length(r
->in
.user
, CH_UTF16
), sizeof(uint16_t), CH_UTF16
));
14409 if (r
->in
.info_ctr
== NULL
) {
14410 return ndr_push_error(ndr
, NDR_ERR_INVALID_POINTER
, "NULL [ref] pointer");
14412 NDR_CHECK(ndr_push_srvsvc_NetFileInfoCtr(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->in
.info_ctr
));
14413 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->in
.max_buffer
));
14414 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->in
.resume_handle
));
14415 if (r
->in
.resume_handle
) {
14416 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, *r
->in
.resume_handle
));
14419 if (flags
& NDR_OUT
) {
14420 if (r
->out
.info_ctr
== NULL
) {
14421 return ndr_push_error(ndr
, NDR_ERR_INVALID_POINTER
, "NULL [ref] pointer");
14423 NDR_CHECK(ndr_push_srvsvc_NetFileInfoCtr(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->out
.info_ctr
));
14424 if (r
->out
.totalentries
== NULL
) {
14425 return ndr_push_error(ndr
, NDR_ERR_INVALID_POINTER
, "NULL [ref] pointer");
14427 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, *r
->out
.totalentries
));
14428 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->out
.resume_handle
));
14429 if (r
->out
.resume_handle
) {
14430 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, *r
->out
.resume_handle
));
14432 NDR_CHECK(ndr_push_WERROR(ndr
, NDR_SCALARS
, r
->out
.result
));
14434 return NDR_ERR_SUCCESS
;
14437 static enum ndr_err_code
ndr_pull_srvsvc_NetFileEnum(struct ndr_pull
*ndr
, int flags
, struct srvsvc_NetFileEnum
*r
)
14439 uint32_t _ptr_server_unc
;
14440 uint32_t _ptr_path
;
14441 uint32_t _ptr_user
;
14442 uint32_t _ptr_resume_handle
;
14443 TALLOC_CTX
*_mem_save_server_unc_0
;
14444 TALLOC_CTX
*_mem_save_path_0
;
14445 TALLOC_CTX
*_mem_save_user_0
;
14446 TALLOC_CTX
*_mem_save_info_ctr_0
;
14447 TALLOC_CTX
*_mem_save_totalentries_0
;
14448 TALLOC_CTX
*_mem_save_resume_handle_0
;
14449 if (flags
& NDR_IN
) {
14450 ZERO_STRUCT(r
->out
);
14452 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_server_unc
));
14453 if (_ptr_server_unc
) {
14454 NDR_PULL_ALLOC(ndr
, r
->in
.server_unc
);
14456 r
->in
.server_unc
= NULL
;
14458 if (r
->in
.server_unc
) {
14459 _mem_save_server_unc_0
= NDR_PULL_GET_MEM_CTX(ndr
);
14460 NDR_PULL_SET_MEM_CTX(ndr
, r
->in
.server_unc
, 0);
14461 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->in
.server_unc
));
14462 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->in
.server_unc
));
14463 if (ndr_get_array_length(ndr
, &r
->in
.server_unc
) > ndr_get_array_size(ndr
, &r
->in
.server_unc
)) {
14464 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", ndr_get_array_size(ndr
, &r
->in
.server_unc
), ndr_get_array_length(ndr
, &r
->in
.server_unc
));
14466 NDR_CHECK(ndr_check_string_terminator(ndr
, ndr_get_array_length(ndr
, &r
->in
.server_unc
), sizeof(uint16_t)));
14467 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->in
.server_unc
, ndr_get_array_length(ndr
, &r
->in
.server_unc
), sizeof(uint16_t), CH_UTF16
));
14468 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_server_unc_0
, 0);
14470 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_path
));
14472 NDR_PULL_ALLOC(ndr
, r
->in
.path
);
14477 _mem_save_path_0
= NDR_PULL_GET_MEM_CTX(ndr
);
14478 NDR_PULL_SET_MEM_CTX(ndr
, r
->in
.path
, 0);
14479 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->in
.path
));
14480 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->in
.path
));
14481 if (ndr_get_array_length(ndr
, &r
->in
.path
) > ndr_get_array_size(ndr
, &r
->in
.path
)) {
14482 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", ndr_get_array_size(ndr
, &r
->in
.path
), ndr_get_array_length(ndr
, &r
->in
.path
));
14484 NDR_CHECK(ndr_check_string_terminator(ndr
, ndr_get_array_length(ndr
, &r
->in
.path
), sizeof(uint16_t)));
14485 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->in
.path
, ndr_get_array_length(ndr
, &r
->in
.path
), sizeof(uint16_t), CH_UTF16
));
14486 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_path_0
, 0);
14488 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_user
));
14490 NDR_PULL_ALLOC(ndr
, r
->in
.user
);
14495 _mem_save_user_0
= NDR_PULL_GET_MEM_CTX(ndr
);
14496 NDR_PULL_SET_MEM_CTX(ndr
, r
->in
.user
, 0);
14497 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->in
.user
));
14498 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->in
.user
));
14499 if (ndr_get_array_length(ndr
, &r
->in
.user
) > ndr_get_array_size(ndr
, &r
->in
.user
)) {
14500 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", ndr_get_array_size(ndr
, &r
->in
.user
), ndr_get_array_length(ndr
, &r
->in
.user
));
14502 NDR_CHECK(ndr_check_string_terminator(ndr
, ndr_get_array_length(ndr
, &r
->in
.user
), sizeof(uint16_t)));
14503 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->in
.user
, ndr_get_array_length(ndr
, &r
->in
.user
), sizeof(uint16_t), CH_UTF16
));
14504 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_user_0
, 0);
14506 if (ndr
->flags
& LIBNDR_FLAG_REF_ALLOC
) {
14507 NDR_PULL_ALLOC(ndr
, r
->in
.info_ctr
);
14509 _mem_save_info_ctr_0
= NDR_PULL_GET_MEM_CTX(ndr
);
14510 NDR_PULL_SET_MEM_CTX(ndr
, r
->in
.info_ctr
, LIBNDR_FLAG_REF_ALLOC
);
14511 NDR_CHECK(ndr_pull_srvsvc_NetFileInfoCtr(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->in
.info_ctr
));
14512 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_info_ctr_0
, LIBNDR_FLAG_REF_ALLOC
);
14513 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->in
.max_buffer
));
14514 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_resume_handle
));
14515 if (_ptr_resume_handle
) {
14516 NDR_PULL_ALLOC(ndr
, r
->in
.resume_handle
);
14518 r
->in
.resume_handle
= NULL
;
14520 if (r
->in
.resume_handle
) {
14521 _mem_save_resume_handle_0
= NDR_PULL_GET_MEM_CTX(ndr
);
14522 NDR_PULL_SET_MEM_CTX(ndr
, r
->in
.resume_handle
, 0);
14523 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, r
->in
.resume_handle
));
14524 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_resume_handle_0
, 0);
14526 NDR_PULL_ALLOC(ndr
, r
->out
.info_ctr
);
14527 *r
->out
.info_ctr
= *r
->in
.info_ctr
;
14528 NDR_PULL_ALLOC(ndr
, r
->out
.totalentries
);
14529 ZERO_STRUCTP(r
->out
.totalentries
);
14531 if (flags
& NDR_OUT
) {
14532 if (ndr
->flags
& LIBNDR_FLAG_REF_ALLOC
) {
14533 NDR_PULL_ALLOC(ndr
, r
->out
.info_ctr
);
14535 _mem_save_info_ctr_0
= NDR_PULL_GET_MEM_CTX(ndr
);
14536 NDR_PULL_SET_MEM_CTX(ndr
, r
->out
.info_ctr
, LIBNDR_FLAG_REF_ALLOC
);
14537 NDR_CHECK(ndr_pull_srvsvc_NetFileInfoCtr(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->out
.info_ctr
));
14538 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_info_ctr_0
, LIBNDR_FLAG_REF_ALLOC
);
14539 if (ndr
->flags
& LIBNDR_FLAG_REF_ALLOC
) {
14540 NDR_PULL_ALLOC(ndr
, r
->out
.totalentries
);
14542 _mem_save_totalentries_0
= NDR_PULL_GET_MEM_CTX(ndr
);
14543 NDR_PULL_SET_MEM_CTX(ndr
, r
->out
.totalentries
, LIBNDR_FLAG_REF_ALLOC
);
14544 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, r
->out
.totalentries
));
14545 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_totalentries_0
, LIBNDR_FLAG_REF_ALLOC
);
14546 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_resume_handle
));
14547 if (_ptr_resume_handle
) {
14548 NDR_PULL_ALLOC(ndr
, r
->out
.resume_handle
);
14550 r
->out
.resume_handle
= NULL
;
14552 if (r
->out
.resume_handle
) {
14553 _mem_save_resume_handle_0
= NDR_PULL_GET_MEM_CTX(ndr
);
14554 NDR_PULL_SET_MEM_CTX(ndr
, r
->out
.resume_handle
, 0);
14555 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, r
->out
.resume_handle
));
14556 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_resume_handle_0
, 0);
14558 NDR_CHECK(ndr_pull_WERROR(ndr
, NDR_SCALARS
, &r
->out
.result
));
14560 return NDR_ERR_SUCCESS
;
14563 _PUBLIC_
void ndr_print_srvsvc_NetFileEnum(struct ndr_print
*ndr
, const char *name
, int flags
, const struct srvsvc_NetFileEnum
*r
)
14565 ndr_print_struct(ndr
, name
, "srvsvc_NetFileEnum");
14567 if (flags
& NDR_SET_VALUES
) {
14568 ndr
->flags
|= LIBNDR_PRINT_SET_VALUES
;
14570 if (flags
& NDR_IN
) {
14571 ndr_print_struct(ndr
, "in", "srvsvc_NetFileEnum");
14573 ndr_print_ptr(ndr
, "server_unc", r
->in
.server_unc
);
14575 if (r
->in
.server_unc
) {
14576 ndr_print_string(ndr
, "server_unc", r
->in
.server_unc
);
14579 ndr_print_ptr(ndr
, "path", r
->in
.path
);
14582 ndr_print_string(ndr
, "path", r
->in
.path
);
14585 ndr_print_ptr(ndr
, "user", r
->in
.user
);
14588 ndr_print_string(ndr
, "user", r
->in
.user
);
14591 ndr_print_ptr(ndr
, "info_ctr", r
->in
.info_ctr
);
14593 ndr_print_srvsvc_NetFileInfoCtr(ndr
, "info_ctr", r
->in
.info_ctr
);
14595 ndr_print_uint32(ndr
, "max_buffer", r
->in
.max_buffer
);
14596 ndr_print_ptr(ndr
, "resume_handle", r
->in
.resume_handle
);
14598 if (r
->in
.resume_handle
) {
14599 ndr_print_uint32(ndr
, "resume_handle", *r
->in
.resume_handle
);
14604 if (flags
& NDR_OUT
) {
14605 ndr_print_struct(ndr
, "out", "srvsvc_NetFileEnum");
14607 ndr_print_ptr(ndr
, "info_ctr", r
->out
.info_ctr
);
14609 ndr_print_srvsvc_NetFileInfoCtr(ndr
, "info_ctr", r
->out
.info_ctr
);
14611 ndr_print_ptr(ndr
, "totalentries", r
->out
.totalentries
);
14613 ndr_print_uint32(ndr
, "totalentries", *r
->out
.totalentries
);
14615 ndr_print_ptr(ndr
, "resume_handle", r
->out
.resume_handle
);
14617 if (r
->out
.resume_handle
) {
14618 ndr_print_uint32(ndr
, "resume_handle", *r
->out
.resume_handle
);
14621 ndr_print_WERROR(ndr
, "result", r
->out
.result
);
14627 static enum ndr_err_code
ndr_push_srvsvc_NetFileGetInfo(struct ndr_push
*ndr
, int flags
, const struct srvsvc_NetFileGetInfo
*r
)
14629 if (flags
& NDR_IN
) {
14630 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->in
.server_unc
));
14631 if (r
->in
.server_unc
) {
14632 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.server_unc
, CH_UTF16
)));
14633 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
14634 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.server_unc
, CH_UTF16
)));
14635 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
));
14637 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->in
.fid
));
14638 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->in
.level
));
14640 if (flags
& NDR_OUT
) {
14641 if (r
->out
.info
== NULL
) {
14642 return ndr_push_error(ndr
, NDR_ERR_INVALID_POINTER
, "NULL [ref] pointer");
14644 NDR_CHECK(ndr_push_set_switch_value(ndr
, r
->out
.info
, r
->in
.level
));
14645 NDR_CHECK(ndr_push_srvsvc_NetFileInfo(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->out
.info
));
14646 NDR_CHECK(ndr_push_WERROR(ndr
, NDR_SCALARS
, r
->out
.result
));
14648 return NDR_ERR_SUCCESS
;
14651 static enum ndr_err_code
ndr_pull_srvsvc_NetFileGetInfo(struct ndr_pull
*ndr
, int flags
, struct srvsvc_NetFileGetInfo
*r
)
14653 uint32_t _ptr_server_unc
;
14654 TALLOC_CTX
*_mem_save_server_unc_0
;
14655 TALLOC_CTX
*_mem_save_info_0
;
14656 if (flags
& NDR_IN
) {
14657 ZERO_STRUCT(r
->out
);
14659 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_server_unc
));
14660 if (_ptr_server_unc
) {
14661 NDR_PULL_ALLOC(ndr
, r
->in
.server_unc
);
14663 r
->in
.server_unc
= NULL
;
14665 if (r
->in
.server_unc
) {
14666 _mem_save_server_unc_0
= NDR_PULL_GET_MEM_CTX(ndr
);
14667 NDR_PULL_SET_MEM_CTX(ndr
, r
->in
.server_unc
, 0);
14668 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->in
.server_unc
));
14669 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->in
.server_unc
));
14670 if (ndr_get_array_length(ndr
, &r
->in
.server_unc
) > ndr_get_array_size(ndr
, &r
->in
.server_unc
)) {
14671 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", ndr_get_array_size(ndr
, &r
->in
.server_unc
), ndr_get_array_length(ndr
, &r
->in
.server_unc
));
14673 NDR_CHECK(ndr_check_string_terminator(ndr
, ndr_get_array_length(ndr
, &r
->in
.server_unc
), sizeof(uint16_t)));
14674 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->in
.server_unc
, ndr_get_array_length(ndr
, &r
->in
.server_unc
), sizeof(uint16_t), CH_UTF16
));
14675 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_server_unc_0
, 0);
14677 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->in
.fid
));
14678 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->in
.level
));
14679 NDR_PULL_ALLOC(ndr
, r
->out
.info
);
14680 ZERO_STRUCTP(r
->out
.info
);
14682 if (flags
& NDR_OUT
) {
14683 if (ndr
->flags
& LIBNDR_FLAG_REF_ALLOC
) {
14684 NDR_PULL_ALLOC(ndr
, r
->out
.info
);
14686 _mem_save_info_0
= NDR_PULL_GET_MEM_CTX(ndr
);
14687 NDR_PULL_SET_MEM_CTX(ndr
, r
->out
.info
, LIBNDR_FLAG_REF_ALLOC
);
14688 NDR_CHECK(ndr_pull_set_switch_value(ndr
, r
->out
.info
, r
->in
.level
));
14689 NDR_CHECK(ndr_pull_srvsvc_NetFileInfo(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->out
.info
));
14690 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_info_0
, LIBNDR_FLAG_REF_ALLOC
);
14691 NDR_CHECK(ndr_pull_WERROR(ndr
, NDR_SCALARS
, &r
->out
.result
));
14693 return NDR_ERR_SUCCESS
;
14696 _PUBLIC_
void ndr_print_srvsvc_NetFileGetInfo(struct ndr_print
*ndr
, const char *name
, int flags
, const struct srvsvc_NetFileGetInfo
*r
)
14698 ndr_print_struct(ndr
, name
, "srvsvc_NetFileGetInfo");
14700 if (flags
& NDR_SET_VALUES
) {
14701 ndr
->flags
|= LIBNDR_PRINT_SET_VALUES
;
14703 if (flags
& NDR_IN
) {
14704 ndr_print_struct(ndr
, "in", "srvsvc_NetFileGetInfo");
14706 ndr_print_ptr(ndr
, "server_unc", r
->in
.server_unc
);
14708 if (r
->in
.server_unc
) {
14709 ndr_print_string(ndr
, "server_unc", r
->in
.server_unc
);
14712 ndr_print_uint32(ndr
, "fid", r
->in
.fid
);
14713 ndr_print_uint32(ndr
, "level", r
->in
.level
);
14716 if (flags
& NDR_OUT
) {
14717 ndr_print_struct(ndr
, "out", "srvsvc_NetFileGetInfo");
14719 ndr_print_ptr(ndr
, "info", r
->out
.info
);
14721 ndr_print_set_switch_value(ndr
, r
->out
.info
, r
->in
.level
);
14722 ndr_print_srvsvc_NetFileInfo(ndr
, "info", r
->out
.info
);
14724 ndr_print_WERROR(ndr
, "result", r
->out
.result
);
14730 static enum ndr_err_code
ndr_push_srvsvc_NetFileClose(struct ndr_push
*ndr
, int flags
, const struct srvsvc_NetFileClose
*r
)
14732 if (flags
& NDR_IN
) {
14733 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->in
.server_unc
));
14734 if (r
->in
.server_unc
) {
14735 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.server_unc
, CH_UTF16
)));
14736 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
14737 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.server_unc
, CH_UTF16
)));
14738 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
));
14740 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->in
.fid
));
14742 if (flags
& NDR_OUT
) {
14743 NDR_CHECK(ndr_push_WERROR(ndr
, NDR_SCALARS
, r
->out
.result
));
14745 return NDR_ERR_SUCCESS
;
14748 static enum ndr_err_code
ndr_pull_srvsvc_NetFileClose(struct ndr_pull
*ndr
, int flags
, struct srvsvc_NetFileClose
*r
)
14750 uint32_t _ptr_server_unc
;
14751 TALLOC_CTX
*_mem_save_server_unc_0
;
14752 if (flags
& NDR_IN
) {
14753 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_server_unc
));
14754 if (_ptr_server_unc
) {
14755 NDR_PULL_ALLOC(ndr
, r
->in
.server_unc
);
14757 r
->in
.server_unc
= NULL
;
14759 if (r
->in
.server_unc
) {
14760 _mem_save_server_unc_0
= NDR_PULL_GET_MEM_CTX(ndr
);
14761 NDR_PULL_SET_MEM_CTX(ndr
, r
->in
.server_unc
, 0);
14762 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->in
.server_unc
));
14763 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->in
.server_unc
));
14764 if (ndr_get_array_length(ndr
, &r
->in
.server_unc
) > ndr_get_array_size(ndr
, &r
->in
.server_unc
)) {
14765 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", ndr_get_array_size(ndr
, &r
->in
.server_unc
), ndr_get_array_length(ndr
, &r
->in
.server_unc
));
14767 NDR_CHECK(ndr_check_string_terminator(ndr
, ndr_get_array_length(ndr
, &r
->in
.server_unc
), sizeof(uint16_t)));
14768 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->in
.server_unc
, ndr_get_array_length(ndr
, &r
->in
.server_unc
), sizeof(uint16_t), CH_UTF16
));
14769 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_server_unc_0
, 0);
14771 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->in
.fid
));
14773 if (flags
& NDR_OUT
) {
14774 NDR_CHECK(ndr_pull_WERROR(ndr
, NDR_SCALARS
, &r
->out
.result
));
14776 return NDR_ERR_SUCCESS
;
14779 _PUBLIC_
void ndr_print_srvsvc_NetFileClose(struct ndr_print
*ndr
, const char *name
, int flags
, const struct srvsvc_NetFileClose
*r
)
14781 ndr_print_struct(ndr
, name
, "srvsvc_NetFileClose");
14783 if (flags
& NDR_SET_VALUES
) {
14784 ndr
->flags
|= LIBNDR_PRINT_SET_VALUES
;
14786 if (flags
& NDR_IN
) {
14787 ndr_print_struct(ndr
, "in", "srvsvc_NetFileClose");
14789 ndr_print_ptr(ndr
, "server_unc", r
->in
.server_unc
);
14791 if (r
->in
.server_unc
) {
14792 ndr_print_string(ndr
, "server_unc", r
->in
.server_unc
);
14795 ndr_print_uint32(ndr
, "fid", r
->in
.fid
);
14798 if (flags
& NDR_OUT
) {
14799 ndr_print_struct(ndr
, "out", "srvsvc_NetFileClose");
14801 ndr_print_WERROR(ndr
, "result", r
->out
.result
);
14807 static enum ndr_err_code
ndr_push_srvsvc_NetSessEnum(struct ndr_push
*ndr
, int flags
, const struct srvsvc_NetSessEnum
*r
)
14809 if (flags
& NDR_IN
) {
14810 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->in
.server_unc
));
14811 if (r
->in
.server_unc
) {
14812 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.server_unc
, CH_UTF16
)));
14813 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
14814 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.server_unc
, CH_UTF16
)));
14815 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
));
14817 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->in
.client
));
14818 if (r
->in
.client
) {
14819 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.client
, CH_UTF16
)));
14820 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
14821 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.client
, CH_UTF16
)));
14822 NDR_CHECK(ndr_push_charset(ndr
, NDR_SCALARS
, r
->in
.client
, ndr_charset_length(r
->in
.client
, CH_UTF16
), sizeof(uint16_t), CH_UTF16
));
14824 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->in
.user
));
14826 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.user
, CH_UTF16
)));
14827 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
14828 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.user
, CH_UTF16
)));
14829 NDR_CHECK(ndr_push_charset(ndr
, NDR_SCALARS
, r
->in
.user
, ndr_charset_length(r
->in
.user
, CH_UTF16
), sizeof(uint16_t), CH_UTF16
));
14831 if (r
->in
.info_ctr
== NULL
) {
14832 return ndr_push_error(ndr
, NDR_ERR_INVALID_POINTER
, "NULL [ref] pointer");
14834 NDR_CHECK(ndr_push_srvsvc_NetSessInfoCtr(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->in
.info_ctr
));
14835 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->in
.max_buffer
));
14836 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->in
.resume_handle
));
14837 if (r
->in
.resume_handle
) {
14838 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, *r
->in
.resume_handle
));
14841 if (flags
& NDR_OUT
) {
14842 if (r
->out
.info_ctr
== NULL
) {
14843 return ndr_push_error(ndr
, NDR_ERR_INVALID_POINTER
, "NULL [ref] pointer");
14845 NDR_CHECK(ndr_push_srvsvc_NetSessInfoCtr(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->out
.info_ctr
));
14846 if (r
->out
.totalentries
== NULL
) {
14847 return ndr_push_error(ndr
, NDR_ERR_INVALID_POINTER
, "NULL [ref] pointer");
14849 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, *r
->out
.totalentries
));
14850 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->out
.resume_handle
));
14851 if (r
->out
.resume_handle
) {
14852 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, *r
->out
.resume_handle
));
14854 NDR_CHECK(ndr_push_WERROR(ndr
, NDR_SCALARS
, r
->out
.result
));
14856 return NDR_ERR_SUCCESS
;
14859 static enum ndr_err_code
ndr_pull_srvsvc_NetSessEnum(struct ndr_pull
*ndr
, int flags
, struct srvsvc_NetSessEnum
*r
)
14861 uint32_t _ptr_server_unc
;
14862 uint32_t _ptr_client
;
14863 uint32_t _ptr_user
;
14864 uint32_t _ptr_resume_handle
;
14865 TALLOC_CTX
*_mem_save_server_unc_0
;
14866 TALLOC_CTX
*_mem_save_client_0
;
14867 TALLOC_CTX
*_mem_save_user_0
;
14868 TALLOC_CTX
*_mem_save_info_ctr_0
;
14869 TALLOC_CTX
*_mem_save_totalentries_0
;
14870 TALLOC_CTX
*_mem_save_resume_handle_0
;
14871 if (flags
& NDR_IN
) {
14872 ZERO_STRUCT(r
->out
);
14874 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_server_unc
));
14875 if (_ptr_server_unc
) {
14876 NDR_PULL_ALLOC(ndr
, r
->in
.server_unc
);
14878 r
->in
.server_unc
= NULL
;
14880 if (r
->in
.server_unc
) {
14881 _mem_save_server_unc_0
= NDR_PULL_GET_MEM_CTX(ndr
);
14882 NDR_PULL_SET_MEM_CTX(ndr
, r
->in
.server_unc
, 0);
14883 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->in
.server_unc
));
14884 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->in
.server_unc
));
14885 if (ndr_get_array_length(ndr
, &r
->in
.server_unc
) > ndr_get_array_size(ndr
, &r
->in
.server_unc
)) {
14886 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", ndr_get_array_size(ndr
, &r
->in
.server_unc
), ndr_get_array_length(ndr
, &r
->in
.server_unc
));
14888 NDR_CHECK(ndr_check_string_terminator(ndr
, ndr_get_array_length(ndr
, &r
->in
.server_unc
), sizeof(uint16_t)));
14889 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->in
.server_unc
, ndr_get_array_length(ndr
, &r
->in
.server_unc
), sizeof(uint16_t), CH_UTF16
));
14890 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_server_unc_0
, 0);
14892 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_client
));
14894 NDR_PULL_ALLOC(ndr
, r
->in
.client
);
14896 r
->in
.client
= NULL
;
14898 if (r
->in
.client
) {
14899 _mem_save_client_0
= NDR_PULL_GET_MEM_CTX(ndr
);
14900 NDR_PULL_SET_MEM_CTX(ndr
, r
->in
.client
, 0);
14901 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->in
.client
));
14902 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->in
.client
));
14903 if (ndr_get_array_length(ndr
, &r
->in
.client
) > ndr_get_array_size(ndr
, &r
->in
.client
)) {
14904 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", ndr_get_array_size(ndr
, &r
->in
.client
), ndr_get_array_length(ndr
, &r
->in
.client
));
14906 NDR_CHECK(ndr_check_string_terminator(ndr
, ndr_get_array_length(ndr
, &r
->in
.client
), sizeof(uint16_t)));
14907 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->in
.client
, ndr_get_array_length(ndr
, &r
->in
.client
), sizeof(uint16_t), CH_UTF16
));
14908 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_client_0
, 0);
14910 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_user
));
14912 NDR_PULL_ALLOC(ndr
, r
->in
.user
);
14917 _mem_save_user_0
= NDR_PULL_GET_MEM_CTX(ndr
);
14918 NDR_PULL_SET_MEM_CTX(ndr
, r
->in
.user
, 0);
14919 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->in
.user
));
14920 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->in
.user
));
14921 if (ndr_get_array_length(ndr
, &r
->in
.user
) > ndr_get_array_size(ndr
, &r
->in
.user
)) {
14922 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", ndr_get_array_size(ndr
, &r
->in
.user
), ndr_get_array_length(ndr
, &r
->in
.user
));
14924 NDR_CHECK(ndr_check_string_terminator(ndr
, ndr_get_array_length(ndr
, &r
->in
.user
), sizeof(uint16_t)));
14925 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->in
.user
, ndr_get_array_length(ndr
, &r
->in
.user
), sizeof(uint16_t), CH_UTF16
));
14926 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_user_0
, 0);
14928 if (ndr
->flags
& LIBNDR_FLAG_REF_ALLOC
) {
14929 NDR_PULL_ALLOC(ndr
, r
->in
.info_ctr
);
14931 _mem_save_info_ctr_0
= NDR_PULL_GET_MEM_CTX(ndr
);
14932 NDR_PULL_SET_MEM_CTX(ndr
, r
->in
.info_ctr
, LIBNDR_FLAG_REF_ALLOC
);
14933 NDR_CHECK(ndr_pull_srvsvc_NetSessInfoCtr(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->in
.info_ctr
));
14934 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_info_ctr_0
, LIBNDR_FLAG_REF_ALLOC
);
14935 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->in
.max_buffer
));
14936 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_resume_handle
));
14937 if (_ptr_resume_handle
) {
14938 NDR_PULL_ALLOC(ndr
, r
->in
.resume_handle
);
14940 r
->in
.resume_handle
= NULL
;
14942 if (r
->in
.resume_handle
) {
14943 _mem_save_resume_handle_0
= NDR_PULL_GET_MEM_CTX(ndr
);
14944 NDR_PULL_SET_MEM_CTX(ndr
, r
->in
.resume_handle
, 0);
14945 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, r
->in
.resume_handle
));
14946 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_resume_handle_0
, 0);
14948 NDR_PULL_ALLOC(ndr
, r
->out
.info_ctr
);
14949 *r
->out
.info_ctr
= *r
->in
.info_ctr
;
14950 NDR_PULL_ALLOC(ndr
, r
->out
.totalentries
);
14951 ZERO_STRUCTP(r
->out
.totalentries
);
14953 if (flags
& NDR_OUT
) {
14954 if (ndr
->flags
& LIBNDR_FLAG_REF_ALLOC
) {
14955 NDR_PULL_ALLOC(ndr
, r
->out
.info_ctr
);
14957 _mem_save_info_ctr_0
= NDR_PULL_GET_MEM_CTX(ndr
);
14958 NDR_PULL_SET_MEM_CTX(ndr
, r
->out
.info_ctr
, LIBNDR_FLAG_REF_ALLOC
);
14959 NDR_CHECK(ndr_pull_srvsvc_NetSessInfoCtr(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->out
.info_ctr
));
14960 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_info_ctr_0
, LIBNDR_FLAG_REF_ALLOC
);
14961 if (ndr
->flags
& LIBNDR_FLAG_REF_ALLOC
) {
14962 NDR_PULL_ALLOC(ndr
, r
->out
.totalentries
);
14964 _mem_save_totalentries_0
= NDR_PULL_GET_MEM_CTX(ndr
);
14965 NDR_PULL_SET_MEM_CTX(ndr
, r
->out
.totalentries
, LIBNDR_FLAG_REF_ALLOC
);
14966 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, r
->out
.totalentries
));
14967 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_totalentries_0
, LIBNDR_FLAG_REF_ALLOC
);
14968 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_resume_handle
));
14969 if (_ptr_resume_handle
) {
14970 NDR_PULL_ALLOC(ndr
, r
->out
.resume_handle
);
14972 r
->out
.resume_handle
= NULL
;
14974 if (r
->out
.resume_handle
) {
14975 _mem_save_resume_handle_0
= NDR_PULL_GET_MEM_CTX(ndr
);
14976 NDR_PULL_SET_MEM_CTX(ndr
, r
->out
.resume_handle
, 0);
14977 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, r
->out
.resume_handle
));
14978 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_resume_handle_0
, 0);
14980 NDR_CHECK(ndr_pull_WERROR(ndr
, NDR_SCALARS
, &r
->out
.result
));
14982 return NDR_ERR_SUCCESS
;
14985 _PUBLIC_
void ndr_print_srvsvc_NetSessEnum(struct ndr_print
*ndr
, const char *name
, int flags
, const struct srvsvc_NetSessEnum
*r
)
14987 ndr_print_struct(ndr
, name
, "srvsvc_NetSessEnum");
14989 if (flags
& NDR_SET_VALUES
) {
14990 ndr
->flags
|= LIBNDR_PRINT_SET_VALUES
;
14992 if (flags
& NDR_IN
) {
14993 ndr_print_struct(ndr
, "in", "srvsvc_NetSessEnum");
14995 ndr_print_ptr(ndr
, "server_unc", r
->in
.server_unc
);
14997 if (r
->in
.server_unc
) {
14998 ndr_print_string(ndr
, "server_unc", r
->in
.server_unc
);
15001 ndr_print_ptr(ndr
, "client", r
->in
.client
);
15003 if (r
->in
.client
) {
15004 ndr_print_string(ndr
, "client", r
->in
.client
);
15007 ndr_print_ptr(ndr
, "user", r
->in
.user
);
15010 ndr_print_string(ndr
, "user", r
->in
.user
);
15013 ndr_print_ptr(ndr
, "info_ctr", r
->in
.info_ctr
);
15015 ndr_print_srvsvc_NetSessInfoCtr(ndr
, "info_ctr", r
->in
.info_ctr
);
15017 ndr_print_uint32(ndr
, "max_buffer", r
->in
.max_buffer
);
15018 ndr_print_ptr(ndr
, "resume_handle", r
->in
.resume_handle
);
15020 if (r
->in
.resume_handle
) {
15021 ndr_print_uint32(ndr
, "resume_handle", *r
->in
.resume_handle
);
15026 if (flags
& NDR_OUT
) {
15027 ndr_print_struct(ndr
, "out", "srvsvc_NetSessEnum");
15029 ndr_print_ptr(ndr
, "info_ctr", r
->out
.info_ctr
);
15031 ndr_print_srvsvc_NetSessInfoCtr(ndr
, "info_ctr", r
->out
.info_ctr
);
15033 ndr_print_ptr(ndr
, "totalentries", r
->out
.totalentries
);
15035 ndr_print_uint32(ndr
, "totalentries", *r
->out
.totalentries
);
15037 ndr_print_ptr(ndr
, "resume_handle", r
->out
.resume_handle
);
15039 if (r
->out
.resume_handle
) {
15040 ndr_print_uint32(ndr
, "resume_handle", *r
->out
.resume_handle
);
15043 ndr_print_WERROR(ndr
, "result", r
->out
.result
);
15049 static enum ndr_err_code
ndr_push_srvsvc_NetSessDel(struct ndr_push
*ndr
, int flags
, const struct srvsvc_NetSessDel
*r
)
15051 if (flags
& NDR_IN
) {
15052 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->in
.server_unc
));
15053 if (r
->in
.server_unc
) {
15054 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.server_unc
, CH_UTF16
)));
15055 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
15056 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.server_unc
, CH_UTF16
)));
15057 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
));
15059 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->in
.client
));
15060 if (r
->in
.client
) {
15061 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.client
, CH_UTF16
)));
15062 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
15063 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.client
, CH_UTF16
)));
15064 NDR_CHECK(ndr_push_charset(ndr
, NDR_SCALARS
, r
->in
.client
, ndr_charset_length(r
->in
.client
, CH_UTF16
), sizeof(uint16_t), CH_UTF16
));
15066 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->in
.user
));
15068 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.user
, CH_UTF16
)));
15069 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
15070 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.user
, CH_UTF16
)));
15071 NDR_CHECK(ndr_push_charset(ndr
, NDR_SCALARS
, r
->in
.user
, ndr_charset_length(r
->in
.user
, CH_UTF16
), sizeof(uint16_t), CH_UTF16
));
15074 if (flags
& NDR_OUT
) {
15075 NDR_CHECK(ndr_push_WERROR(ndr
, NDR_SCALARS
, r
->out
.result
));
15077 return NDR_ERR_SUCCESS
;
15080 static enum ndr_err_code
ndr_pull_srvsvc_NetSessDel(struct ndr_pull
*ndr
, int flags
, struct srvsvc_NetSessDel
*r
)
15082 uint32_t _ptr_server_unc
;
15083 uint32_t _ptr_client
;
15084 uint32_t _ptr_user
;
15085 TALLOC_CTX
*_mem_save_server_unc_0
;
15086 TALLOC_CTX
*_mem_save_client_0
;
15087 TALLOC_CTX
*_mem_save_user_0
;
15088 if (flags
& NDR_IN
) {
15089 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_server_unc
));
15090 if (_ptr_server_unc
) {
15091 NDR_PULL_ALLOC(ndr
, r
->in
.server_unc
);
15093 r
->in
.server_unc
= NULL
;
15095 if (r
->in
.server_unc
) {
15096 _mem_save_server_unc_0
= NDR_PULL_GET_MEM_CTX(ndr
);
15097 NDR_PULL_SET_MEM_CTX(ndr
, r
->in
.server_unc
, 0);
15098 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->in
.server_unc
));
15099 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->in
.server_unc
));
15100 if (ndr_get_array_length(ndr
, &r
->in
.server_unc
) > ndr_get_array_size(ndr
, &r
->in
.server_unc
)) {
15101 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", ndr_get_array_size(ndr
, &r
->in
.server_unc
), ndr_get_array_length(ndr
, &r
->in
.server_unc
));
15103 NDR_CHECK(ndr_check_string_terminator(ndr
, ndr_get_array_length(ndr
, &r
->in
.server_unc
), sizeof(uint16_t)));
15104 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->in
.server_unc
, ndr_get_array_length(ndr
, &r
->in
.server_unc
), sizeof(uint16_t), CH_UTF16
));
15105 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_server_unc_0
, 0);
15107 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_client
));
15109 NDR_PULL_ALLOC(ndr
, r
->in
.client
);
15111 r
->in
.client
= NULL
;
15113 if (r
->in
.client
) {
15114 _mem_save_client_0
= NDR_PULL_GET_MEM_CTX(ndr
);
15115 NDR_PULL_SET_MEM_CTX(ndr
, r
->in
.client
, 0);
15116 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->in
.client
));
15117 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->in
.client
));
15118 if (ndr_get_array_length(ndr
, &r
->in
.client
) > ndr_get_array_size(ndr
, &r
->in
.client
)) {
15119 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", ndr_get_array_size(ndr
, &r
->in
.client
), ndr_get_array_length(ndr
, &r
->in
.client
));
15121 NDR_CHECK(ndr_check_string_terminator(ndr
, ndr_get_array_length(ndr
, &r
->in
.client
), sizeof(uint16_t)));
15122 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->in
.client
, ndr_get_array_length(ndr
, &r
->in
.client
), sizeof(uint16_t), CH_UTF16
));
15123 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_client_0
, 0);
15125 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_user
));
15127 NDR_PULL_ALLOC(ndr
, r
->in
.user
);
15132 _mem_save_user_0
= NDR_PULL_GET_MEM_CTX(ndr
);
15133 NDR_PULL_SET_MEM_CTX(ndr
, r
->in
.user
, 0);
15134 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->in
.user
));
15135 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->in
.user
));
15136 if (ndr_get_array_length(ndr
, &r
->in
.user
) > ndr_get_array_size(ndr
, &r
->in
.user
)) {
15137 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", ndr_get_array_size(ndr
, &r
->in
.user
), ndr_get_array_length(ndr
, &r
->in
.user
));
15139 NDR_CHECK(ndr_check_string_terminator(ndr
, ndr_get_array_length(ndr
, &r
->in
.user
), sizeof(uint16_t)));
15140 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->in
.user
, ndr_get_array_length(ndr
, &r
->in
.user
), sizeof(uint16_t), CH_UTF16
));
15141 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_user_0
, 0);
15144 if (flags
& NDR_OUT
) {
15145 NDR_CHECK(ndr_pull_WERROR(ndr
, NDR_SCALARS
, &r
->out
.result
));
15147 return NDR_ERR_SUCCESS
;
15150 _PUBLIC_
void ndr_print_srvsvc_NetSessDel(struct ndr_print
*ndr
, const char *name
, int flags
, const struct srvsvc_NetSessDel
*r
)
15152 ndr_print_struct(ndr
, name
, "srvsvc_NetSessDel");
15154 if (flags
& NDR_SET_VALUES
) {
15155 ndr
->flags
|= LIBNDR_PRINT_SET_VALUES
;
15157 if (flags
& NDR_IN
) {
15158 ndr_print_struct(ndr
, "in", "srvsvc_NetSessDel");
15160 ndr_print_ptr(ndr
, "server_unc", r
->in
.server_unc
);
15162 if (r
->in
.server_unc
) {
15163 ndr_print_string(ndr
, "server_unc", r
->in
.server_unc
);
15166 ndr_print_ptr(ndr
, "client", r
->in
.client
);
15168 if (r
->in
.client
) {
15169 ndr_print_string(ndr
, "client", r
->in
.client
);
15172 ndr_print_ptr(ndr
, "user", r
->in
.user
);
15175 ndr_print_string(ndr
, "user", r
->in
.user
);
15180 if (flags
& NDR_OUT
) {
15181 ndr_print_struct(ndr
, "out", "srvsvc_NetSessDel");
15183 ndr_print_WERROR(ndr
, "result", r
->out
.result
);
15189 static enum ndr_err_code
ndr_push_srvsvc_NetShareAdd(struct ndr_push
*ndr
, int flags
, const struct srvsvc_NetShareAdd
*r
)
15191 if (flags
& NDR_IN
) {
15192 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->in
.server_unc
));
15193 if (r
->in
.server_unc
) {
15194 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.server_unc
, CH_UTF16
)));
15195 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
15196 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.server_unc
, CH_UTF16
)));
15197 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
));
15199 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->in
.level
));
15200 if (r
->in
.info
== NULL
) {
15201 return ndr_push_error(ndr
, NDR_ERR_INVALID_POINTER
, "NULL [ref] pointer");
15203 NDR_CHECK(ndr_push_set_switch_value(ndr
, r
->in
.info
, r
->in
.level
));
15204 NDR_CHECK(ndr_push_srvsvc_NetShareInfo(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->in
.info
));
15205 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->in
.parm_error
));
15206 if (r
->in
.parm_error
) {
15207 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, *r
->in
.parm_error
));
15210 if (flags
& NDR_OUT
) {
15211 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->out
.parm_error
));
15212 if (r
->out
.parm_error
) {
15213 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, *r
->out
.parm_error
));
15215 NDR_CHECK(ndr_push_WERROR(ndr
, NDR_SCALARS
, r
->out
.result
));
15217 return NDR_ERR_SUCCESS
;
15220 static enum ndr_err_code
ndr_pull_srvsvc_NetShareAdd(struct ndr_pull
*ndr
, int flags
, struct srvsvc_NetShareAdd
*r
)
15222 uint32_t _ptr_server_unc
;
15223 uint32_t _ptr_parm_error
;
15224 TALLOC_CTX
*_mem_save_server_unc_0
;
15225 TALLOC_CTX
*_mem_save_info_0
;
15226 TALLOC_CTX
*_mem_save_parm_error_0
;
15227 if (flags
& NDR_IN
) {
15228 ZERO_STRUCT(r
->out
);
15230 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_server_unc
));
15231 if (_ptr_server_unc
) {
15232 NDR_PULL_ALLOC(ndr
, r
->in
.server_unc
);
15234 r
->in
.server_unc
= NULL
;
15236 if (r
->in
.server_unc
) {
15237 _mem_save_server_unc_0
= NDR_PULL_GET_MEM_CTX(ndr
);
15238 NDR_PULL_SET_MEM_CTX(ndr
, r
->in
.server_unc
, 0);
15239 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->in
.server_unc
));
15240 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->in
.server_unc
));
15241 if (ndr_get_array_length(ndr
, &r
->in
.server_unc
) > ndr_get_array_size(ndr
, &r
->in
.server_unc
)) {
15242 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", ndr_get_array_size(ndr
, &r
->in
.server_unc
), ndr_get_array_length(ndr
, &r
->in
.server_unc
));
15244 NDR_CHECK(ndr_check_string_terminator(ndr
, ndr_get_array_length(ndr
, &r
->in
.server_unc
), sizeof(uint16_t)));
15245 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->in
.server_unc
, ndr_get_array_length(ndr
, &r
->in
.server_unc
), sizeof(uint16_t), CH_UTF16
));
15246 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_server_unc_0
, 0);
15248 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->in
.level
));
15249 if (ndr
->flags
& LIBNDR_FLAG_REF_ALLOC
) {
15250 NDR_PULL_ALLOC(ndr
, r
->in
.info
);
15252 _mem_save_info_0
= NDR_PULL_GET_MEM_CTX(ndr
);
15253 NDR_PULL_SET_MEM_CTX(ndr
, r
->in
.info
, LIBNDR_FLAG_REF_ALLOC
);
15254 NDR_CHECK(ndr_pull_set_switch_value(ndr
, r
->in
.info
, r
->in
.level
));
15255 NDR_CHECK(ndr_pull_srvsvc_NetShareInfo(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->in
.info
));
15256 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_info_0
, LIBNDR_FLAG_REF_ALLOC
);
15257 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_parm_error
));
15258 if (_ptr_parm_error
) {
15259 NDR_PULL_ALLOC(ndr
, r
->in
.parm_error
);
15261 r
->in
.parm_error
= NULL
;
15263 if (r
->in
.parm_error
) {
15264 _mem_save_parm_error_0
= NDR_PULL_GET_MEM_CTX(ndr
);
15265 NDR_PULL_SET_MEM_CTX(ndr
, r
->in
.parm_error
, 0);
15266 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, r
->in
.parm_error
));
15267 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_parm_error_0
, 0);
15270 if (flags
& NDR_OUT
) {
15271 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_parm_error
));
15272 if (_ptr_parm_error
) {
15273 NDR_PULL_ALLOC(ndr
, r
->out
.parm_error
);
15275 r
->out
.parm_error
= NULL
;
15277 if (r
->out
.parm_error
) {
15278 _mem_save_parm_error_0
= NDR_PULL_GET_MEM_CTX(ndr
);
15279 NDR_PULL_SET_MEM_CTX(ndr
, r
->out
.parm_error
, 0);
15280 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, r
->out
.parm_error
));
15281 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_parm_error_0
, 0);
15283 NDR_CHECK(ndr_pull_WERROR(ndr
, NDR_SCALARS
, &r
->out
.result
));
15285 return NDR_ERR_SUCCESS
;
15288 _PUBLIC_
void ndr_print_srvsvc_NetShareAdd(struct ndr_print
*ndr
, const char *name
, int flags
, const struct srvsvc_NetShareAdd
*r
)
15290 ndr_print_struct(ndr
, name
, "srvsvc_NetShareAdd");
15292 if (flags
& NDR_SET_VALUES
) {
15293 ndr
->flags
|= LIBNDR_PRINT_SET_VALUES
;
15295 if (flags
& NDR_IN
) {
15296 ndr_print_struct(ndr
, "in", "srvsvc_NetShareAdd");
15298 ndr_print_ptr(ndr
, "server_unc", r
->in
.server_unc
);
15300 if (r
->in
.server_unc
) {
15301 ndr_print_string(ndr
, "server_unc", r
->in
.server_unc
);
15304 ndr_print_uint32(ndr
, "level", r
->in
.level
);
15305 ndr_print_ptr(ndr
, "info", r
->in
.info
);
15307 ndr_print_set_switch_value(ndr
, r
->in
.info
, r
->in
.level
);
15308 ndr_print_srvsvc_NetShareInfo(ndr
, "info", r
->in
.info
);
15310 ndr_print_ptr(ndr
, "parm_error", r
->in
.parm_error
);
15312 if (r
->in
.parm_error
) {
15313 ndr_print_uint32(ndr
, "parm_error", *r
->in
.parm_error
);
15318 if (flags
& NDR_OUT
) {
15319 ndr_print_struct(ndr
, "out", "srvsvc_NetShareAdd");
15321 ndr_print_ptr(ndr
, "parm_error", r
->out
.parm_error
);
15323 if (r
->out
.parm_error
) {
15324 ndr_print_uint32(ndr
, "parm_error", *r
->out
.parm_error
);
15327 ndr_print_WERROR(ndr
, "result", r
->out
.result
);
15333 static enum ndr_err_code
ndr_push_srvsvc_NetShareEnumAll(struct ndr_push
*ndr
, int flags
, const struct srvsvc_NetShareEnumAll
*r
)
15335 if (flags
& NDR_IN
) {
15336 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->in
.server_unc
));
15337 if (r
->in
.server_unc
) {
15338 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.server_unc
, CH_UTF16
)));
15339 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
15340 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.server_unc
, CH_UTF16
)));
15341 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
));
15343 if (r
->in
.info_ctr
== NULL
) {
15344 return ndr_push_error(ndr
, NDR_ERR_INVALID_POINTER
, "NULL [ref] pointer");
15346 NDR_CHECK(ndr_push_srvsvc_NetShareInfoCtr(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->in
.info_ctr
));
15347 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->in
.max_buffer
));
15348 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->in
.resume_handle
));
15349 if (r
->in
.resume_handle
) {
15350 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, *r
->in
.resume_handle
));
15353 if (flags
& NDR_OUT
) {
15354 if (r
->out
.info_ctr
== NULL
) {
15355 return ndr_push_error(ndr
, NDR_ERR_INVALID_POINTER
, "NULL [ref] pointer");
15357 NDR_CHECK(ndr_push_srvsvc_NetShareInfoCtr(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->out
.info_ctr
));
15358 if (r
->out
.totalentries
== NULL
) {
15359 return ndr_push_error(ndr
, NDR_ERR_INVALID_POINTER
, "NULL [ref] pointer");
15361 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, *r
->out
.totalentries
));
15362 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->out
.resume_handle
));
15363 if (r
->out
.resume_handle
) {
15364 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, *r
->out
.resume_handle
));
15366 NDR_CHECK(ndr_push_WERROR(ndr
, NDR_SCALARS
, r
->out
.result
));
15368 return NDR_ERR_SUCCESS
;
15371 static enum ndr_err_code
ndr_pull_srvsvc_NetShareEnumAll(struct ndr_pull
*ndr
, int flags
, struct srvsvc_NetShareEnumAll
*r
)
15373 uint32_t _ptr_server_unc
;
15374 uint32_t _ptr_resume_handle
;
15375 TALLOC_CTX
*_mem_save_server_unc_0
;
15376 TALLOC_CTX
*_mem_save_info_ctr_0
;
15377 TALLOC_CTX
*_mem_save_totalentries_0
;
15378 TALLOC_CTX
*_mem_save_resume_handle_0
;
15379 if (flags
& NDR_IN
) {
15380 ZERO_STRUCT(r
->out
);
15382 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_server_unc
));
15383 if (_ptr_server_unc
) {
15384 NDR_PULL_ALLOC(ndr
, r
->in
.server_unc
);
15386 r
->in
.server_unc
= NULL
;
15388 if (r
->in
.server_unc
) {
15389 _mem_save_server_unc_0
= NDR_PULL_GET_MEM_CTX(ndr
);
15390 NDR_PULL_SET_MEM_CTX(ndr
, r
->in
.server_unc
, 0);
15391 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->in
.server_unc
));
15392 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->in
.server_unc
));
15393 if (ndr_get_array_length(ndr
, &r
->in
.server_unc
) > ndr_get_array_size(ndr
, &r
->in
.server_unc
)) {
15394 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", ndr_get_array_size(ndr
, &r
->in
.server_unc
), ndr_get_array_length(ndr
, &r
->in
.server_unc
));
15396 NDR_CHECK(ndr_check_string_terminator(ndr
, ndr_get_array_length(ndr
, &r
->in
.server_unc
), sizeof(uint16_t)));
15397 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->in
.server_unc
, ndr_get_array_length(ndr
, &r
->in
.server_unc
), sizeof(uint16_t), CH_UTF16
));
15398 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_server_unc_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_NetShareInfoCtr(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_NetShareInfoCtr(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_NetShareEnumAll(struct ndr_print
*ndr
, const char *name
, int flags
, const struct srvsvc_NetShareEnumAll
*r
)
15459 ndr_print_struct(ndr
, name
, "srvsvc_NetShareEnumAll");
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_NetShareEnumAll");
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
, "info_ctr", r
->in
.info_ctr
);
15475 ndr_print_srvsvc_NetShareInfoCtr(ndr
, "info_ctr", r
->in
.info_ctr
);
15477 ndr_print_uint32(ndr
, "max_buffer", r
->in
.max_buffer
);
15478 ndr_print_ptr(ndr
, "resume_handle", r
->in
.resume_handle
);
15480 if (r
->in
.resume_handle
) {
15481 ndr_print_uint32(ndr
, "resume_handle", *r
->in
.resume_handle
);
15486 if (flags
& NDR_OUT
) {
15487 ndr_print_struct(ndr
, "out", "srvsvc_NetShareEnumAll");
15489 ndr_print_ptr(ndr
, "info_ctr", r
->out
.info_ctr
);
15491 ndr_print_srvsvc_NetShareInfoCtr(ndr
, "info_ctr", r
->out
.info_ctr
);
15493 ndr_print_ptr(ndr
, "totalentries", r
->out
.totalentries
);
15495 ndr_print_uint32(ndr
, "totalentries", *r
->out
.totalentries
);
15497 ndr_print_ptr(ndr
, "resume_handle", r
->out
.resume_handle
);
15499 if (r
->out
.resume_handle
) {
15500 ndr_print_uint32(ndr
, "resume_handle", *r
->out
.resume_handle
);
15503 ndr_print_WERROR(ndr
, "result", r
->out
.result
);
15509 static enum ndr_err_code
ndr_push_srvsvc_NetShareGetInfo(struct ndr_push
*ndr
, int flags
, const struct srvsvc_NetShareGetInfo
*r
)
15511 if (flags
& NDR_IN
) {
15512 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->in
.server_unc
));
15513 if (r
->in
.server_unc
) {
15514 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.server_unc
, CH_UTF16
)));
15515 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
15516 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.server_unc
, CH_UTF16
)));
15517 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
));
15519 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.share_name
, CH_UTF16
)));
15520 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
15521 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.share_name
, CH_UTF16
)));
15522 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
));
15523 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->in
.level
));
15525 if (flags
& NDR_OUT
) {
15526 if (r
->out
.info
== NULL
) {
15527 return ndr_push_error(ndr
, NDR_ERR_INVALID_POINTER
, "NULL [ref] pointer");
15529 NDR_CHECK(ndr_push_set_switch_value(ndr
, r
->out
.info
, r
->in
.level
));
15530 NDR_CHECK(ndr_push_srvsvc_NetShareInfo(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->out
.info
));
15531 NDR_CHECK(ndr_push_WERROR(ndr
, NDR_SCALARS
, r
->out
.result
));
15533 return NDR_ERR_SUCCESS
;
15536 static enum ndr_err_code
ndr_pull_srvsvc_NetShareGetInfo(struct ndr_pull
*ndr
, int flags
, struct srvsvc_NetShareGetInfo
*r
)
15538 uint32_t _ptr_server_unc
;
15539 TALLOC_CTX
*_mem_save_server_unc_0
;
15540 TALLOC_CTX
*_mem_save_info_0
;
15541 if (flags
& NDR_IN
) {
15542 ZERO_STRUCT(r
->out
);
15544 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_server_unc
));
15545 if (_ptr_server_unc
) {
15546 NDR_PULL_ALLOC(ndr
, r
->in
.server_unc
);
15548 r
->in
.server_unc
= NULL
;
15550 if (r
->in
.server_unc
) {
15551 _mem_save_server_unc_0
= NDR_PULL_GET_MEM_CTX(ndr
);
15552 NDR_PULL_SET_MEM_CTX(ndr
, r
->in
.server_unc
, 0);
15553 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->in
.server_unc
));
15554 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->in
.server_unc
));
15555 if (ndr_get_array_length(ndr
, &r
->in
.server_unc
) > ndr_get_array_size(ndr
, &r
->in
.server_unc
)) {
15556 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", ndr_get_array_size(ndr
, &r
->in
.server_unc
), ndr_get_array_length(ndr
, &r
->in
.server_unc
));
15558 NDR_CHECK(ndr_check_string_terminator(ndr
, ndr_get_array_length(ndr
, &r
->in
.server_unc
), sizeof(uint16_t)));
15559 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->in
.server_unc
, ndr_get_array_length(ndr
, &r
->in
.server_unc
), sizeof(uint16_t), CH_UTF16
));
15560 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_server_unc_0
, 0);
15562 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->in
.share_name
));
15563 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->in
.share_name
));
15564 if (ndr_get_array_length(ndr
, &r
->in
.share_name
) > ndr_get_array_size(ndr
, &r
->in
.share_name
)) {
15565 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", ndr_get_array_size(ndr
, &r
->in
.share_name
), ndr_get_array_length(ndr
, &r
->in
.share_name
));
15567 NDR_CHECK(ndr_check_string_terminator(ndr
, ndr_get_array_length(ndr
, &r
->in
.share_name
), sizeof(uint16_t)));
15568 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->in
.share_name
, ndr_get_array_length(ndr
, &r
->in
.share_name
), sizeof(uint16_t), CH_UTF16
));
15569 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->in
.level
));
15570 NDR_PULL_ALLOC(ndr
, r
->out
.info
);
15571 ZERO_STRUCTP(r
->out
.info
);
15573 if (flags
& NDR_OUT
) {
15574 if (ndr
->flags
& LIBNDR_FLAG_REF_ALLOC
) {
15575 NDR_PULL_ALLOC(ndr
, r
->out
.info
);
15577 _mem_save_info_0
= NDR_PULL_GET_MEM_CTX(ndr
);
15578 NDR_PULL_SET_MEM_CTX(ndr
, r
->out
.info
, LIBNDR_FLAG_REF_ALLOC
);
15579 NDR_CHECK(ndr_pull_set_switch_value(ndr
, r
->out
.info
, r
->in
.level
));
15580 NDR_CHECK(ndr_pull_srvsvc_NetShareInfo(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->out
.info
));
15581 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_info_0
, LIBNDR_FLAG_REF_ALLOC
);
15582 NDR_CHECK(ndr_pull_WERROR(ndr
, NDR_SCALARS
, &r
->out
.result
));
15584 return NDR_ERR_SUCCESS
;
15587 _PUBLIC_
void ndr_print_srvsvc_NetShareGetInfo(struct ndr_print
*ndr
, const char *name
, int flags
, const struct srvsvc_NetShareGetInfo
*r
)
15589 ndr_print_struct(ndr
, name
, "srvsvc_NetShareGetInfo");
15591 if (flags
& NDR_SET_VALUES
) {
15592 ndr
->flags
|= LIBNDR_PRINT_SET_VALUES
;
15594 if (flags
& NDR_IN
) {
15595 ndr_print_struct(ndr
, "in", "srvsvc_NetShareGetInfo");
15597 ndr_print_ptr(ndr
, "server_unc", r
->in
.server_unc
);
15599 if (r
->in
.server_unc
) {
15600 ndr_print_string(ndr
, "server_unc", r
->in
.server_unc
);
15603 ndr_print_string(ndr
, "share_name", r
->in
.share_name
);
15604 ndr_print_uint32(ndr
, "level", r
->in
.level
);
15607 if (flags
& NDR_OUT
) {
15608 ndr_print_struct(ndr
, "out", "srvsvc_NetShareGetInfo");
15610 ndr_print_ptr(ndr
, "info", r
->out
.info
);
15612 ndr_print_set_switch_value(ndr
, r
->out
.info
, r
->in
.level
);
15613 ndr_print_srvsvc_NetShareInfo(ndr
, "info", r
->out
.info
);
15615 ndr_print_WERROR(ndr
, "result", r
->out
.result
);
15621 static enum ndr_err_code
ndr_push_srvsvc_NetShareSetInfo(struct ndr_push
*ndr
, int flags
, const struct srvsvc_NetShareSetInfo
*r
)
15623 if (flags
& NDR_IN
) {
15624 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->in
.server_unc
));
15625 if (r
->in
.server_unc
) {
15626 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.server_unc
, CH_UTF16
)));
15627 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
15628 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.server_unc
, CH_UTF16
)));
15629 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
));
15631 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.share_name
, CH_UTF16
)));
15632 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
15633 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.share_name
, CH_UTF16
)));
15634 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
));
15635 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->in
.level
));
15636 if (r
->in
.info
== NULL
) {
15637 return ndr_push_error(ndr
, NDR_ERR_INVALID_POINTER
, "NULL [ref] pointer");
15639 NDR_CHECK(ndr_push_set_switch_value(ndr
, r
->in
.info
, r
->in
.level
));
15640 NDR_CHECK(ndr_push_srvsvc_NetShareInfo(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->in
.info
));
15641 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->in
.parm_error
));
15642 if (r
->in
.parm_error
) {
15643 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, *r
->in
.parm_error
));
15646 if (flags
& NDR_OUT
) {
15647 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->out
.parm_error
));
15648 if (r
->out
.parm_error
) {
15649 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, *r
->out
.parm_error
));
15651 NDR_CHECK(ndr_push_WERROR(ndr
, NDR_SCALARS
, r
->out
.result
));
15653 return NDR_ERR_SUCCESS
;
15656 static enum ndr_err_code
ndr_pull_srvsvc_NetShareSetInfo(struct ndr_pull
*ndr
, int flags
, struct srvsvc_NetShareSetInfo
*r
)
15658 uint32_t _ptr_server_unc
;
15659 uint32_t _ptr_parm_error
;
15660 TALLOC_CTX
*_mem_save_server_unc_0
;
15661 TALLOC_CTX
*_mem_save_info_0
;
15662 TALLOC_CTX
*_mem_save_parm_error_0
;
15663 if (flags
& NDR_IN
) {
15664 ZERO_STRUCT(r
->out
);
15666 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_server_unc
));
15667 if (_ptr_server_unc
) {
15668 NDR_PULL_ALLOC(ndr
, r
->in
.server_unc
);
15670 r
->in
.server_unc
= NULL
;
15672 if (r
->in
.server_unc
) {
15673 _mem_save_server_unc_0
= NDR_PULL_GET_MEM_CTX(ndr
);
15674 NDR_PULL_SET_MEM_CTX(ndr
, r
->in
.server_unc
, 0);
15675 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->in
.server_unc
));
15676 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->in
.server_unc
));
15677 if (ndr_get_array_length(ndr
, &r
->in
.server_unc
) > ndr_get_array_size(ndr
, &r
->in
.server_unc
)) {
15678 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", ndr_get_array_size(ndr
, &r
->in
.server_unc
), ndr_get_array_length(ndr
, &r
->in
.server_unc
));
15680 NDR_CHECK(ndr_check_string_terminator(ndr
, ndr_get_array_length(ndr
, &r
->in
.server_unc
), sizeof(uint16_t)));
15681 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->in
.server_unc
, ndr_get_array_length(ndr
, &r
->in
.server_unc
), sizeof(uint16_t), CH_UTF16
));
15682 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_server_unc_0
, 0);
15684 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->in
.share_name
));
15685 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->in
.share_name
));
15686 if (ndr_get_array_length(ndr
, &r
->in
.share_name
) > ndr_get_array_size(ndr
, &r
->in
.share_name
)) {
15687 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", ndr_get_array_size(ndr
, &r
->in
.share_name
), ndr_get_array_length(ndr
, &r
->in
.share_name
));
15689 NDR_CHECK(ndr_check_string_terminator(ndr
, ndr_get_array_length(ndr
, &r
->in
.share_name
), sizeof(uint16_t)));
15690 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->in
.share_name
, ndr_get_array_length(ndr
, &r
->in
.share_name
), sizeof(uint16_t), CH_UTF16
));
15691 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->in
.level
));
15692 if (ndr
->flags
& LIBNDR_FLAG_REF_ALLOC
) {
15693 NDR_PULL_ALLOC(ndr
, r
->in
.info
);
15695 _mem_save_info_0
= NDR_PULL_GET_MEM_CTX(ndr
);
15696 NDR_PULL_SET_MEM_CTX(ndr
, r
->in
.info
, LIBNDR_FLAG_REF_ALLOC
);
15697 NDR_CHECK(ndr_pull_set_switch_value(ndr
, r
->in
.info
, r
->in
.level
));
15698 NDR_CHECK(ndr_pull_srvsvc_NetShareInfo(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->in
.info
));
15699 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_info_0
, LIBNDR_FLAG_REF_ALLOC
);
15700 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_parm_error
));
15701 if (_ptr_parm_error
) {
15702 NDR_PULL_ALLOC(ndr
, r
->in
.parm_error
);
15704 r
->in
.parm_error
= NULL
;
15706 if (r
->in
.parm_error
) {
15707 _mem_save_parm_error_0
= NDR_PULL_GET_MEM_CTX(ndr
);
15708 NDR_PULL_SET_MEM_CTX(ndr
, r
->in
.parm_error
, 0);
15709 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, r
->in
.parm_error
));
15710 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_parm_error_0
, 0);
15713 if (flags
& NDR_OUT
) {
15714 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_parm_error
));
15715 if (_ptr_parm_error
) {
15716 NDR_PULL_ALLOC(ndr
, r
->out
.parm_error
);
15718 r
->out
.parm_error
= NULL
;
15720 if (r
->out
.parm_error
) {
15721 _mem_save_parm_error_0
= NDR_PULL_GET_MEM_CTX(ndr
);
15722 NDR_PULL_SET_MEM_CTX(ndr
, r
->out
.parm_error
, 0);
15723 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, r
->out
.parm_error
));
15724 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_parm_error_0
, 0);
15726 NDR_CHECK(ndr_pull_WERROR(ndr
, NDR_SCALARS
, &r
->out
.result
));
15728 return NDR_ERR_SUCCESS
;
15731 _PUBLIC_
void ndr_print_srvsvc_NetShareSetInfo(struct ndr_print
*ndr
, const char *name
, int flags
, const struct srvsvc_NetShareSetInfo
*r
)
15733 ndr_print_struct(ndr
, name
, "srvsvc_NetShareSetInfo");
15735 if (flags
& NDR_SET_VALUES
) {
15736 ndr
->flags
|= LIBNDR_PRINT_SET_VALUES
;
15738 if (flags
& NDR_IN
) {
15739 ndr_print_struct(ndr
, "in", "srvsvc_NetShareSetInfo");
15741 ndr_print_ptr(ndr
, "server_unc", r
->in
.server_unc
);
15743 if (r
->in
.server_unc
) {
15744 ndr_print_string(ndr
, "server_unc", r
->in
.server_unc
);
15747 ndr_print_string(ndr
, "share_name", r
->in
.share_name
);
15748 ndr_print_uint32(ndr
, "level", r
->in
.level
);
15749 ndr_print_ptr(ndr
, "info", r
->in
.info
);
15751 ndr_print_set_switch_value(ndr
, r
->in
.info
, r
->in
.level
);
15752 ndr_print_srvsvc_NetShareInfo(ndr
, "info", r
->in
.info
);
15754 ndr_print_ptr(ndr
, "parm_error", r
->in
.parm_error
);
15756 if (r
->in
.parm_error
) {
15757 ndr_print_uint32(ndr
, "parm_error", *r
->in
.parm_error
);
15762 if (flags
& NDR_OUT
) {
15763 ndr_print_struct(ndr
, "out", "srvsvc_NetShareSetInfo");
15765 ndr_print_ptr(ndr
, "parm_error", r
->out
.parm_error
);
15767 if (r
->out
.parm_error
) {
15768 ndr_print_uint32(ndr
, "parm_error", *r
->out
.parm_error
);
15771 ndr_print_WERROR(ndr
, "result", r
->out
.result
);
15777 static enum ndr_err_code
ndr_push_srvsvc_NetShareDel(struct ndr_push
*ndr
, int flags
, const struct srvsvc_NetShareDel
*r
)
15779 if (flags
& NDR_IN
) {
15780 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->in
.server_unc
));
15781 if (r
->in
.server_unc
) {
15782 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.server_unc
, CH_UTF16
)));
15783 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
15784 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.server_unc
, CH_UTF16
)));
15785 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
));
15787 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.share_name
, CH_UTF16
)));
15788 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
15789 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.share_name
, CH_UTF16
)));
15790 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
));
15791 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->in
.reserved
));
15793 if (flags
& NDR_OUT
) {
15794 NDR_CHECK(ndr_push_WERROR(ndr
, NDR_SCALARS
, r
->out
.result
));
15796 return NDR_ERR_SUCCESS
;
15799 static enum ndr_err_code
ndr_pull_srvsvc_NetShareDel(struct ndr_pull
*ndr
, int flags
, struct srvsvc_NetShareDel
*r
)
15801 uint32_t _ptr_server_unc
;
15802 TALLOC_CTX
*_mem_save_server_unc_0
;
15803 if (flags
& NDR_IN
) {
15804 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_server_unc
));
15805 if (_ptr_server_unc
) {
15806 NDR_PULL_ALLOC(ndr
, r
->in
.server_unc
);
15808 r
->in
.server_unc
= NULL
;
15810 if (r
->in
.server_unc
) {
15811 _mem_save_server_unc_0
= NDR_PULL_GET_MEM_CTX(ndr
);
15812 NDR_PULL_SET_MEM_CTX(ndr
, r
->in
.server_unc
, 0);
15813 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->in
.server_unc
));
15814 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->in
.server_unc
));
15815 if (ndr_get_array_length(ndr
, &r
->in
.server_unc
) > ndr_get_array_size(ndr
, &r
->in
.server_unc
)) {
15816 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", ndr_get_array_size(ndr
, &r
->in
.server_unc
), ndr_get_array_length(ndr
, &r
->in
.server_unc
));
15818 NDR_CHECK(ndr_check_string_terminator(ndr
, ndr_get_array_length(ndr
, &r
->in
.server_unc
), sizeof(uint16_t)));
15819 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->in
.server_unc
, ndr_get_array_length(ndr
, &r
->in
.server_unc
), sizeof(uint16_t), CH_UTF16
));
15820 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_server_unc_0
, 0);
15822 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->in
.share_name
));
15823 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->in
.share_name
));
15824 if (ndr_get_array_length(ndr
, &r
->in
.share_name
) > ndr_get_array_size(ndr
, &r
->in
.share_name
)) {
15825 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", ndr_get_array_size(ndr
, &r
->in
.share_name
), ndr_get_array_length(ndr
, &r
->in
.share_name
));
15827 NDR_CHECK(ndr_check_string_terminator(ndr
, ndr_get_array_length(ndr
, &r
->in
.share_name
), sizeof(uint16_t)));
15828 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->in
.share_name
, ndr_get_array_length(ndr
, &r
->in
.share_name
), sizeof(uint16_t), CH_UTF16
));
15829 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->in
.reserved
));
15831 if (flags
& NDR_OUT
) {
15832 NDR_CHECK(ndr_pull_WERROR(ndr
, NDR_SCALARS
, &r
->out
.result
));
15834 return NDR_ERR_SUCCESS
;
15837 _PUBLIC_
void ndr_print_srvsvc_NetShareDel(struct ndr_print
*ndr
, const char *name
, int flags
, const struct srvsvc_NetShareDel
*r
)
15839 ndr_print_struct(ndr
, name
, "srvsvc_NetShareDel");
15841 if (flags
& NDR_SET_VALUES
) {
15842 ndr
->flags
|= LIBNDR_PRINT_SET_VALUES
;
15844 if (flags
& NDR_IN
) {
15845 ndr_print_struct(ndr
, "in", "srvsvc_NetShareDel");
15847 ndr_print_ptr(ndr
, "server_unc", r
->in
.server_unc
);
15849 if (r
->in
.server_unc
) {
15850 ndr_print_string(ndr
, "server_unc", r
->in
.server_unc
);
15853 ndr_print_string(ndr
, "share_name", r
->in
.share_name
);
15854 ndr_print_uint32(ndr
, "reserved", r
->in
.reserved
);
15857 if (flags
& NDR_OUT
) {
15858 ndr_print_struct(ndr
, "out", "srvsvc_NetShareDel");
15860 ndr_print_WERROR(ndr
, "result", r
->out
.result
);
15866 static enum ndr_err_code
ndr_push_srvsvc_NetShareDelSticky(struct ndr_push
*ndr
, int flags
, const struct srvsvc_NetShareDelSticky
*r
)
15868 if (flags
& NDR_IN
) {
15869 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->in
.server_unc
));
15870 if (r
->in
.server_unc
) {
15871 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.server_unc
, CH_UTF16
)));
15872 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
15873 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.server_unc
, CH_UTF16
)));
15874 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
));
15876 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.share_name
, CH_UTF16
)));
15877 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
15878 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.share_name
, CH_UTF16
)));
15879 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
));
15880 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->in
.reserved
));
15882 if (flags
& NDR_OUT
) {
15883 NDR_CHECK(ndr_push_WERROR(ndr
, NDR_SCALARS
, r
->out
.result
));
15885 return NDR_ERR_SUCCESS
;
15888 static enum ndr_err_code
ndr_pull_srvsvc_NetShareDelSticky(struct ndr_pull
*ndr
, int flags
, struct srvsvc_NetShareDelSticky
*r
)
15890 uint32_t _ptr_server_unc
;
15891 TALLOC_CTX
*_mem_save_server_unc_0
;
15892 if (flags
& NDR_IN
) {
15893 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_server_unc
));
15894 if (_ptr_server_unc
) {
15895 NDR_PULL_ALLOC(ndr
, r
->in
.server_unc
);
15897 r
->in
.server_unc
= NULL
;
15899 if (r
->in
.server_unc
) {
15900 _mem_save_server_unc_0
= NDR_PULL_GET_MEM_CTX(ndr
);
15901 NDR_PULL_SET_MEM_CTX(ndr
, r
->in
.server_unc
, 0);
15902 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->in
.server_unc
));
15903 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->in
.server_unc
));
15904 if (ndr_get_array_length(ndr
, &r
->in
.server_unc
) > ndr_get_array_size(ndr
, &r
->in
.server_unc
)) {
15905 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", ndr_get_array_size(ndr
, &r
->in
.server_unc
), ndr_get_array_length(ndr
, &r
->in
.server_unc
));
15907 NDR_CHECK(ndr_check_string_terminator(ndr
, ndr_get_array_length(ndr
, &r
->in
.server_unc
), sizeof(uint16_t)));
15908 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->in
.server_unc
, ndr_get_array_length(ndr
, &r
->in
.server_unc
), sizeof(uint16_t), CH_UTF16
));
15909 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_server_unc_0
, 0);
15911 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->in
.share_name
));
15912 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->in
.share_name
));
15913 if (ndr_get_array_length(ndr
, &r
->in
.share_name
) > ndr_get_array_size(ndr
, &r
->in
.share_name
)) {
15914 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", ndr_get_array_size(ndr
, &r
->in
.share_name
), ndr_get_array_length(ndr
, &r
->in
.share_name
));
15916 NDR_CHECK(ndr_check_string_terminator(ndr
, ndr_get_array_length(ndr
, &r
->in
.share_name
), sizeof(uint16_t)));
15917 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->in
.share_name
, ndr_get_array_length(ndr
, &r
->in
.share_name
), sizeof(uint16_t), CH_UTF16
));
15918 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->in
.reserved
));
15920 if (flags
& NDR_OUT
) {
15921 NDR_CHECK(ndr_pull_WERROR(ndr
, NDR_SCALARS
, &r
->out
.result
));
15923 return NDR_ERR_SUCCESS
;
15926 _PUBLIC_
void ndr_print_srvsvc_NetShareDelSticky(struct ndr_print
*ndr
, const char *name
, int flags
, const struct srvsvc_NetShareDelSticky
*r
)
15928 ndr_print_struct(ndr
, name
, "srvsvc_NetShareDelSticky");
15930 if (flags
& NDR_SET_VALUES
) {
15931 ndr
->flags
|= LIBNDR_PRINT_SET_VALUES
;
15933 if (flags
& NDR_IN
) {
15934 ndr_print_struct(ndr
, "in", "srvsvc_NetShareDelSticky");
15936 ndr_print_ptr(ndr
, "server_unc", r
->in
.server_unc
);
15938 if (r
->in
.server_unc
) {
15939 ndr_print_string(ndr
, "server_unc", r
->in
.server_unc
);
15942 ndr_print_string(ndr
, "share_name", r
->in
.share_name
);
15943 ndr_print_uint32(ndr
, "reserved", r
->in
.reserved
);
15946 if (flags
& NDR_OUT
) {
15947 ndr_print_struct(ndr
, "out", "srvsvc_NetShareDelSticky");
15949 ndr_print_WERROR(ndr
, "result", r
->out
.result
);
15955 static enum ndr_err_code
ndr_push_srvsvc_NetShareCheck(struct ndr_push
*ndr
, int flags
, const struct srvsvc_NetShareCheck
*r
)
15957 if (flags
& NDR_IN
) {
15958 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->in
.server_unc
));
15959 if (r
->in
.server_unc
) {
15960 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.server_unc
, CH_UTF16
)));
15961 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
15962 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.server_unc
, CH_UTF16
)));
15963 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
));
15965 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.device_name
, CH_UTF16
)));
15966 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
15967 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.device_name
, CH_UTF16
)));
15968 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
));
15970 if (flags
& NDR_OUT
) {
15971 if (r
->out
.type
== NULL
) {
15972 return ndr_push_error(ndr
, NDR_ERR_INVALID_POINTER
, "NULL [ref] pointer");
15974 NDR_CHECK(ndr_push_srvsvc_ShareType(ndr
, NDR_SCALARS
, *r
->out
.type
));
15975 NDR_CHECK(ndr_push_WERROR(ndr
, NDR_SCALARS
, r
->out
.result
));
15977 return NDR_ERR_SUCCESS
;
15980 static enum ndr_err_code
ndr_pull_srvsvc_NetShareCheck(struct ndr_pull
*ndr
, int flags
, struct srvsvc_NetShareCheck
*r
)
15982 uint32_t _ptr_server_unc
;
15983 TALLOC_CTX
*_mem_save_server_unc_0
;
15984 TALLOC_CTX
*_mem_save_type_0
;
15985 if (flags
& NDR_IN
) {
15986 ZERO_STRUCT(r
->out
);
15988 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_server_unc
));
15989 if (_ptr_server_unc
) {
15990 NDR_PULL_ALLOC(ndr
, r
->in
.server_unc
);
15992 r
->in
.server_unc
= NULL
;
15994 if (r
->in
.server_unc
) {
15995 _mem_save_server_unc_0
= NDR_PULL_GET_MEM_CTX(ndr
);
15996 NDR_PULL_SET_MEM_CTX(ndr
, r
->in
.server_unc
, 0);
15997 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->in
.server_unc
));
15998 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->in
.server_unc
));
15999 if (ndr_get_array_length(ndr
, &r
->in
.server_unc
) > ndr_get_array_size(ndr
, &r
->in
.server_unc
)) {
16000 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", ndr_get_array_size(ndr
, &r
->in
.server_unc
), ndr_get_array_length(ndr
, &r
->in
.server_unc
));
16002 NDR_CHECK(ndr_check_string_terminator(ndr
, ndr_get_array_length(ndr
, &r
->in
.server_unc
), sizeof(uint16_t)));
16003 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->in
.server_unc
, ndr_get_array_length(ndr
, &r
->in
.server_unc
), sizeof(uint16_t), CH_UTF16
));
16004 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_server_unc_0
, 0);
16006 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->in
.device_name
));
16007 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->in
.device_name
));
16008 if (ndr_get_array_length(ndr
, &r
->in
.device_name
) > ndr_get_array_size(ndr
, &r
->in
.device_name
)) {
16009 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", ndr_get_array_size(ndr
, &r
->in
.device_name
), ndr_get_array_length(ndr
, &r
->in
.device_name
));
16011 NDR_CHECK(ndr_check_string_terminator(ndr
, ndr_get_array_length(ndr
, &r
->in
.device_name
), sizeof(uint16_t)));
16012 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->in
.device_name
, ndr_get_array_length(ndr
, &r
->in
.device_name
), sizeof(uint16_t), CH_UTF16
));
16013 NDR_PULL_ALLOC(ndr
, r
->out
.type
);
16014 ZERO_STRUCTP(r
->out
.type
);
16016 if (flags
& NDR_OUT
) {
16017 if (ndr
->flags
& LIBNDR_FLAG_REF_ALLOC
) {
16018 NDR_PULL_ALLOC(ndr
, r
->out
.type
);
16020 _mem_save_type_0
= NDR_PULL_GET_MEM_CTX(ndr
);
16021 NDR_PULL_SET_MEM_CTX(ndr
, r
->out
.type
, LIBNDR_FLAG_REF_ALLOC
);
16022 NDR_CHECK(ndr_pull_srvsvc_ShareType(ndr
, NDR_SCALARS
, r
->out
.type
));
16023 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_type_0
, LIBNDR_FLAG_REF_ALLOC
);
16024 NDR_CHECK(ndr_pull_WERROR(ndr
, NDR_SCALARS
, &r
->out
.result
));
16026 return NDR_ERR_SUCCESS
;
16029 _PUBLIC_
void ndr_print_srvsvc_NetShareCheck(struct ndr_print
*ndr
, const char *name
, int flags
, const struct srvsvc_NetShareCheck
*r
)
16031 ndr_print_struct(ndr
, name
, "srvsvc_NetShareCheck");
16033 if (flags
& NDR_SET_VALUES
) {
16034 ndr
->flags
|= LIBNDR_PRINT_SET_VALUES
;
16036 if (flags
& NDR_IN
) {
16037 ndr_print_struct(ndr
, "in", "srvsvc_NetShareCheck");
16039 ndr_print_ptr(ndr
, "server_unc", r
->in
.server_unc
);
16041 if (r
->in
.server_unc
) {
16042 ndr_print_string(ndr
, "server_unc", r
->in
.server_unc
);
16045 ndr_print_string(ndr
, "device_name", r
->in
.device_name
);
16048 if (flags
& NDR_OUT
) {
16049 ndr_print_struct(ndr
, "out", "srvsvc_NetShareCheck");
16051 ndr_print_ptr(ndr
, "type", r
->out
.type
);
16053 ndr_print_srvsvc_ShareType(ndr
, "type", *r
->out
.type
);
16055 ndr_print_WERROR(ndr
, "result", r
->out
.result
);
16061 static enum ndr_err_code
ndr_push_srvsvc_NetSrvGetInfo(struct ndr_push
*ndr
, int flags
, const struct srvsvc_NetSrvGetInfo
*r
)
16063 if (flags
& NDR_IN
) {
16064 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->in
.server_unc
));
16065 if (r
->in
.server_unc
) {
16066 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.server_unc
, CH_UTF16
)));
16067 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
16068 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.server_unc
, CH_UTF16
)));
16069 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
));
16071 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->in
.level
));
16073 if (flags
& NDR_OUT
) {
16074 if (r
->out
.info
== NULL
) {
16075 return ndr_push_error(ndr
, NDR_ERR_INVALID_POINTER
, "NULL [ref] pointer");
16077 NDR_CHECK(ndr_push_set_switch_value(ndr
, r
->out
.info
, r
->in
.level
));
16078 NDR_CHECK(ndr_push_srvsvc_NetSrvInfo(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->out
.info
));
16079 NDR_CHECK(ndr_push_WERROR(ndr
, NDR_SCALARS
, r
->out
.result
));
16081 return NDR_ERR_SUCCESS
;
16084 static enum ndr_err_code
ndr_pull_srvsvc_NetSrvGetInfo(struct ndr_pull
*ndr
, int flags
, struct srvsvc_NetSrvGetInfo
*r
)
16086 uint32_t _ptr_server_unc
;
16087 TALLOC_CTX
*_mem_save_server_unc_0
;
16088 TALLOC_CTX
*_mem_save_info_0
;
16089 if (flags
& NDR_IN
) {
16090 ZERO_STRUCT(r
->out
);
16092 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_server_unc
));
16093 if (_ptr_server_unc
) {
16094 NDR_PULL_ALLOC(ndr
, r
->in
.server_unc
);
16096 r
->in
.server_unc
= NULL
;
16098 if (r
->in
.server_unc
) {
16099 _mem_save_server_unc_0
= NDR_PULL_GET_MEM_CTX(ndr
);
16100 NDR_PULL_SET_MEM_CTX(ndr
, r
->in
.server_unc
, 0);
16101 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->in
.server_unc
));
16102 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->in
.server_unc
));
16103 if (ndr_get_array_length(ndr
, &r
->in
.server_unc
) > ndr_get_array_size(ndr
, &r
->in
.server_unc
)) {
16104 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", ndr_get_array_size(ndr
, &r
->in
.server_unc
), ndr_get_array_length(ndr
, &r
->in
.server_unc
));
16106 NDR_CHECK(ndr_check_string_terminator(ndr
, ndr_get_array_length(ndr
, &r
->in
.server_unc
), sizeof(uint16_t)));
16107 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->in
.server_unc
, ndr_get_array_length(ndr
, &r
->in
.server_unc
), sizeof(uint16_t), CH_UTF16
));
16108 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_server_unc_0
, 0);
16110 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->in
.level
));
16111 NDR_PULL_ALLOC(ndr
, r
->out
.info
);
16112 ZERO_STRUCTP(r
->out
.info
);
16114 if (flags
& NDR_OUT
) {
16115 if (ndr
->flags
& LIBNDR_FLAG_REF_ALLOC
) {
16116 NDR_PULL_ALLOC(ndr
, r
->out
.info
);
16118 _mem_save_info_0
= NDR_PULL_GET_MEM_CTX(ndr
);
16119 NDR_PULL_SET_MEM_CTX(ndr
, r
->out
.info
, LIBNDR_FLAG_REF_ALLOC
);
16120 NDR_CHECK(ndr_pull_set_switch_value(ndr
, r
->out
.info
, r
->in
.level
));
16121 NDR_CHECK(ndr_pull_srvsvc_NetSrvInfo(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->out
.info
));
16122 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_info_0
, LIBNDR_FLAG_REF_ALLOC
);
16123 NDR_CHECK(ndr_pull_WERROR(ndr
, NDR_SCALARS
, &r
->out
.result
));
16125 return NDR_ERR_SUCCESS
;
16128 _PUBLIC_
void ndr_print_srvsvc_NetSrvGetInfo(struct ndr_print
*ndr
, const char *name
, int flags
, const struct srvsvc_NetSrvGetInfo
*r
)
16130 ndr_print_struct(ndr
, name
, "srvsvc_NetSrvGetInfo");
16132 if (flags
& NDR_SET_VALUES
) {
16133 ndr
->flags
|= LIBNDR_PRINT_SET_VALUES
;
16135 if (flags
& NDR_IN
) {
16136 ndr_print_struct(ndr
, "in", "srvsvc_NetSrvGetInfo");
16138 ndr_print_ptr(ndr
, "server_unc", r
->in
.server_unc
);
16140 if (r
->in
.server_unc
) {
16141 ndr_print_string(ndr
, "server_unc", r
->in
.server_unc
);
16144 ndr_print_uint32(ndr
, "level", r
->in
.level
);
16147 if (flags
& NDR_OUT
) {
16148 ndr_print_struct(ndr
, "out", "srvsvc_NetSrvGetInfo");
16150 ndr_print_ptr(ndr
, "info", r
->out
.info
);
16152 ndr_print_set_switch_value(ndr
, r
->out
.info
, r
->in
.level
);
16153 ndr_print_srvsvc_NetSrvInfo(ndr
, "info", r
->out
.info
);
16155 ndr_print_WERROR(ndr
, "result", r
->out
.result
);
16161 static enum ndr_err_code
ndr_push_srvsvc_NetSrvSetInfo(struct ndr_push
*ndr
, int flags
, const struct srvsvc_NetSrvSetInfo
*r
)
16163 if (flags
& NDR_IN
) {
16164 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->in
.server_unc
));
16165 if (r
->in
.server_unc
) {
16166 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.server_unc
, CH_UTF16
)));
16167 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
16168 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.server_unc
, CH_UTF16
)));
16169 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
));
16171 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->in
.level
));
16172 if (r
->in
.info
== NULL
) {
16173 return ndr_push_error(ndr
, NDR_ERR_INVALID_POINTER
, "NULL [ref] pointer");
16175 NDR_CHECK(ndr_push_set_switch_value(ndr
, r
->in
.info
, r
->in
.level
));
16176 NDR_CHECK(ndr_push_srvsvc_NetSrvInfo(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->in
.info
));
16177 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->in
.parm_error
));
16178 if (r
->in
.parm_error
) {
16179 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, *r
->in
.parm_error
));
16182 if (flags
& NDR_OUT
) {
16183 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->out
.parm_error
));
16184 if (r
->out
.parm_error
) {
16185 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, *r
->out
.parm_error
));
16187 NDR_CHECK(ndr_push_WERROR(ndr
, NDR_SCALARS
, r
->out
.result
));
16189 return NDR_ERR_SUCCESS
;
16192 static enum ndr_err_code
ndr_pull_srvsvc_NetSrvSetInfo(struct ndr_pull
*ndr
, int flags
, struct srvsvc_NetSrvSetInfo
*r
)
16194 uint32_t _ptr_server_unc
;
16195 uint32_t _ptr_parm_error
;
16196 TALLOC_CTX
*_mem_save_server_unc_0
;
16197 TALLOC_CTX
*_mem_save_info_0
;
16198 TALLOC_CTX
*_mem_save_parm_error_0
;
16199 if (flags
& NDR_IN
) {
16200 ZERO_STRUCT(r
->out
);
16202 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_server_unc
));
16203 if (_ptr_server_unc
) {
16204 NDR_PULL_ALLOC(ndr
, r
->in
.server_unc
);
16206 r
->in
.server_unc
= NULL
;
16208 if (r
->in
.server_unc
) {
16209 _mem_save_server_unc_0
= NDR_PULL_GET_MEM_CTX(ndr
);
16210 NDR_PULL_SET_MEM_CTX(ndr
, r
->in
.server_unc
, 0);
16211 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->in
.server_unc
));
16212 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->in
.server_unc
));
16213 if (ndr_get_array_length(ndr
, &r
->in
.server_unc
) > ndr_get_array_size(ndr
, &r
->in
.server_unc
)) {
16214 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", ndr_get_array_size(ndr
, &r
->in
.server_unc
), ndr_get_array_length(ndr
, &r
->in
.server_unc
));
16216 NDR_CHECK(ndr_check_string_terminator(ndr
, ndr_get_array_length(ndr
, &r
->in
.server_unc
), sizeof(uint16_t)));
16217 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->in
.server_unc
, ndr_get_array_length(ndr
, &r
->in
.server_unc
), sizeof(uint16_t), CH_UTF16
));
16218 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_server_unc_0
, 0);
16220 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->in
.level
));
16221 if (ndr
->flags
& LIBNDR_FLAG_REF_ALLOC
) {
16222 NDR_PULL_ALLOC(ndr
, r
->in
.info
);
16224 _mem_save_info_0
= NDR_PULL_GET_MEM_CTX(ndr
);
16225 NDR_PULL_SET_MEM_CTX(ndr
, r
->in
.info
, LIBNDR_FLAG_REF_ALLOC
);
16226 NDR_CHECK(ndr_pull_set_switch_value(ndr
, r
->in
.info
, r
->in
.level
));
16227 NDR_CHECK(ndr_pull_srvsvc_NetSrvInfo(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->in
.info
));
16228 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_info_0
, LIBNDR_FLAG_REF_ALLOC
);
16229 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_parm_error
));
16230 if (_ptr_parm_error
) {
16231 NDR_PULL_ALLOC(ndr
, r
->in
.parm_error
);
16233 r
->in
.parm_error
= NULL
;
16235 if (r
->in
.parm_error
) {
16236 _mem_save_parm_error_0
= NDR_PULL_GET_MEM_CTX(ndr
);
16237 NDR_PULL_SET_MEM_CTX(ndr
, r
->in
.parm_error
, 0);
16238 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, r
->in
.parm_error
));
16239 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_parm_error_0
, 0);
16242 if (flags
& NDR_OUT
) {
16243 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_parm_error
));
16244 if (_ptr_parm_error
) {
16245 NDR_PULL_ALLOC(ndr
, r
->out
.parm_error
);
16247 r
->out
.parm_error
= NULL
;
16249 if (r
->out
.parm_error
) {
16250 _mem_save_parm_error_0
= NDR_PULL_GET_MEM_CTX(ndr
);
16251 NDR_PULL_SET_MEM_CTX(ndr
, r
->out
.parm_error
, 0);
16252 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, r
->out
.parm_error
));
16253 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_parm_error_0
, 0);
16255 NDR_CHECK(ndr_pull_WERROR(ndr
, NDR_SCALARS
, &r
->out
.result
));
16257 return NDR_ERR_SUCCESS
;
16260 _PUBLIC_
void ndr_print_srvsvc_NetSrvSetInfo(struct ndr_print
*ndr
, const char *name
, int flags
, const struct srvsvc_NetSrvSetInfo
*r
)
16262 ndr_print_struct(ndr
, name
, "srvsvc_NetSrvSetInfo");
16264 if (flags
& NDR_SET_VALUES
) {
16265 ndr
->flags
|= LIBNDR_PRINT_SET_VALUES
;
16267 if (flags
& NDR_IN
) {
16268 ndr_print_struct(ndr
, "in", "srvsvc_NetSrvSetInfo");
16270 ndr_print_ptr(ndr
, "server_unc", r
->in
.server_unc
);
16272 if (r
->in
.server_unc
) {
16273 ndr_print_string(ndr
, "server_unc", r
->in
.server_unc
);
16276 ndr_print_uint32(ndr
, "level", r
->in
.level
);
16277 ndr_print_ptr(ndr
, "info", r
->in
.info
);
16279 ndr_print_set_switch_value(ndr
, r
->in
.info
, r
->in
.level
);
16280 ndr_print_srvsvc_NetSrvInfo(ndr
, "info", r
->in
.info
);
16282 ndr_print_ptr(ndr
, "parm_error", r
->in
.parm_error
);
16284 if (r
->in
.parm_error
) {
16285 ndr_print_uint32(ndr
, "parm_error", *r
->in
.parm_error
);
16290 if (flags
& NDR_OUT
) {
16291 ndr_print_struct(ndr
, "out", "srvsvc_NetSrvSetInfo");
16293 ndr_print_ptr(ndr
, "parm_error", r
->out
.parm_error
);
16295 if (r
->out
.parm_error
) {
16296 ndr_print_uint32(ndr
, "parm_error", *r
->out
.parm_error
);
16299 ndr_print_WERROR(ndr
, "result", r
->out
.result
);
16305 static enum ndr_err_code
ndr_push_srvsvc_NetDiskEnum(struct ndr_push
*ndr
, int flags
, const struct srvsvc_NetDiskEnum
*r
)
16307 if (flags
& NDR_IN
) {
16308 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->in
.server_unc
));
16309 if (r
->in
.server_unc
) {
16310 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.server_unc
, CH_UTF16
)));
16311 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
16312 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.server_unc
, CH_UTF16
)));
16313 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
));
16315 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->in
.level
));
16316 if (r
->in
.info
== NULL
) {
16317 return ndr_push_error(ndr
, NDR_ERR_INVALID_POINTER
, "NULL [ref] pointer");
16319 NDR_CHECK(ndr_push_srvsvc_NetDiskInfo(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->in
.info
));
16320 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->in
.maxlen
));
16321 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->in
.resume_handle
));
16322 if (r
->in
.resume_handle
) {
16323 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, *r
->in
.resume_handle
));
16326 if (flags
& NDR_OUT
) {
16327 if (r
->out
.info
== NULL
) {
16328 return ndr_push_error(ndr
, NDR_ERR_INVALID_POINTER
, "NULL [ref] pointer");
16330 NDR_CHECK(ndr_push_srvsvc_NetDiskInfo(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->out
.info
));
16331 if (r
->out
.totalentries
== NULL
) {
16332 return ndr_push_error(ndr
, NDR_ERR_INVALID_POINTER
, "NULL [ref] pointer");
16334 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, *r
->out
.totalentries
));
16335 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->out
.resume_handle
));
16336 if (r
->out
.resume_handle
) {
16337 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, *r
->out
.resume_handle
));
16339 NDR_CHECK(ndr_push_WERROR(ndr
, NDR_SCALARS
, r
->out
.result
));
16341 return NDR_ERR_SUCCESS
;
16344 static enum ndr_err_code
ndr_pull_srvsvc_NetDiskEnum(struct ndr_pull
*ndr
, int flags
, struct srvsvc_NetDiskEnum
*r
)
16346 uint32_t _ptr_server_unc
;
16347 uint32_t _ptr_resume_handle
;
16348 TALLOC_CTX
*_mem_save_server_unc_0
;
16349 TALLOC_CTX
*_mem_save_info_0
;
16350 TALLOC_CTX
*_mem_save_totalentries_0
;
16351 TALLOC_CTX
*_mem_save_resume_handle_0
;
16352 if (flags
& NDR_IN
) {
16353 ZERO_STRUCT(r
->out
);
16355 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_server_unc
));
16356 if (_ptr_server_unc
) {
16357 NDR_PULL_ALLOC(ndr
, r
->in
.server_unc
);
16359 r
->in
.server_unc
= NULL
;
16361 if (r
->in
.server_unc
) {
16362 _mem_save_server_unc_0
= NDR_PULL_GET_MEM_CTX(ndr
);
16363 NDR_PULL_SET_MEM_CTX(ndr
, r
->in
.server_unc
, 0);
16364 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->in
.server_unc
));
16365 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->in
.server_unc
));
16366 if (ndr_get_array_length(ndr
, &r
->in
.server_unc
) > ndr_get_array_size(ndr
, &r
->in
.server_unc
)) {
16367 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", ndr_get_array_size(ndr
, &r
->in
.server_unc
), ndr_get_array_length(ndr
, &r
->in
.server_unc
));
16369 NDR_CHECK(ndr_check_string_terminator(ndr
, ndr_get_array_length(ndr
, &r
->in
.server_unc
), sizeof(uint16_t)));
16370 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->in
.server_unc
, ndr_get_array_length(ndr
, &r
->in
.server_unc
), sizeof(uint16_t), CH_UTF16
));
16371 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_server_unc_0
, 0);
16373 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->in
.level
));
16374 if (ndr
->flags
& LIBNDR_FLAG_REF_ALLOC
) {
16375 NDR_PULL_ALLOC(ndr
, r
->in
.info
);
16377 _mem_save_info_0
= NDR_PULL_GET_MEM_CTX(ndr
);
16378 NDR_PULL_SET_MEM_CTX(ndr
, r
->in
.info
, LIBNDR_FLAG_REF_ALLOC
);
16379 NDR_CHECK(ndr_pull_srvsvc_NetDiskInfo(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->in
.info
));
16380 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_info_0
, LIBNDR_FLAG_REF_ALLOC
);
16381 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->in
.maxlen
));
16382 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_resume_handle
));
16383 if (_ptr_resume_handle
) {
16384 NDR_PULL_ALLOC(ndr
, r
->in
.resume_handle
);
16386 r
->in
.resume_handle
= NULL
;
16388 if (r
->in
.resume_handle
) {
16389 _mem_save_resume_handle_0
= NDR_PULL_GET_MEM_CTX(ndr
);
16390 NDR_PULL_SET_MEM_CTX(ndr
, r
->in
.resume_handle
, 0);
16391 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, r
->in
.resume_handle
));
16392 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_resume_handle_0
, 0);
16394 NDR_PULL_ALLOC(ndr
, r
->out
.info
);
16395 *r
->out
.info
= *r
->in
.info
;
16396 NDR_PULL_ALLOC(ndr
, r
->out
.totalentries
);
16397 ZERO_STRUCTP(r
->out
.totalentries
);
16399 if (flags
& NDR_OUT
) {
16400 if (ndr
->flags
& LIBNDR_FLAG_REF_ALLOC
) {
16401 NDR_PULL_ALLOC(ndr
, r
->out
.info
);
16403 _mem_save_info_0
= NDR_PULL_GET_MEM_CTX(ndr
);
16404 NDR_PULL_SET_MEM_CTX(ndr
, r
->out
.info
, LIBNDR_FLAG_REF_ALLOC
);
16405 NDR_CHECK(ndr_pull_srvsvc_NetDiskInfo(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->out
.info
));
16406 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_info_0
, LIBNDR_FLAG_REF_ALLOC
);
16407 if (ndr
->flags
& LIBNDR_FLAG_REF_ALLOC
) {
16408 NDR_PULL_ALLOC(ndr
, r
->out
.totalentries
);
16410 _mem_save_totalentries_0
= NDR_PULL_GET_MEM_CTX(ndr
);
16411 NDR_PULL_SET_MEM_CTX(ndr
, r
->out
.totalentries
, LIBNDR_FLAG_REF_ALLOC
);
16412 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, r
->out
.totalentries
));
16413 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_totalentries_0
, LIBNDR_FLAG_REF_ALLOC
);
16414 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_resume_handle
));
16415 if (_ptr_resume_handle
) {
16416 NDR_PULL_ALLOC(ndr
, r
->out
.resume_handle
);
16418 r
->out
.resume_handle
= NULL
;
16420 if (r
->out
.resume_handle
) {
16421 _mem_save_resume_handle_0
= NDR_PULL_GET_MEM_CTX(ndr
);
16422 NDR_PULL_SET_MEM_CTX(ndr
, r
->out
.resume_handle
, 0);
16423 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, r
->out
.resume_handle
));
16424 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_resume_handle_0
, 0);
16426 NDR_CHECK(ndr_pull_WERROR(ndr
, NDR_SCALARS
, &r
->out
.result
));
16428 return NDR_ERR_SUCCESS
;
16431 _PUBLIC_
void ndr_print_srvsvc_NetDiskEnum(struct ndr_print
*ndr
, const char *name
, int flags
, const struct srvsvc_NetDiskEnum
*r
)
16433 ndr_print_struct(ndr
, name
, "srvsvc_NetDiskEnum");
16435 if (flags
& NDR_SET_VALUES
) {
16436 ndr
->flags
|= LIBNDR_PRINT_SET_VALUES
;
16438 if (flags
& NDR_IN
) {
16439 ndr_print_struct(ndr
, "in", "srvsvc_NetDiskEnum");
16441 ndr_print_ptr(ndr
, "server_unc", r
->in
.server_unc
);
16443 if (r
->in
.server_unc
) {
16444 ndr_print_string(ndr
, "server_unc", r
->in
.server_unc
);
16447 ndr_print_uint32(ndr
, "level", r
->in
.level
);
16448 ndr_print_ptr(ndr
, "info", r
->in
.info
);
16450 ndr_print_srvsvc_NetDiskInfo(ndr
, "info", r
->in
.info
);
16452 ndr_print_uint32(ndr
, "maxlen", r
->in
.maxlen
);
16453 ndr_print_ptr(ndr
, "resume_handle", r
->in
.resume_handle
);
16455 if (r
->in
.resume_handle
) {
16456 ndr_print_uint32(ndr
, "resume_handle", *r
->in
.resume_handle
);
16461 if (flags
& NDR_OUT
) {
16462 ndr_print_struct(ndr
, "out", "srvsvc_NetDiskEnum");
16464 ndr_print_ptr(ndr
, "info", r
->out
.info
);
16466 ndr_print_srvsvc_NetDiskInfo(ndr
, "info", r
->out
.info
);
16468 ndr_print_ptr(ndr
, "totalentries", r
->out
.totalentries
);
16470 ndr_print_uint32(ndr
, "totalentries", *r
->out
.totalentries
);
16472 ndr_print_ptr(ndr
, "resume_handle", r
->out
.resume_handle
);
16474 if (r
->out
.resume_handle
) {
16475 ndr_print_uint32(ndr
, "resume_handle", *r
->out
.resume_handle
);
16478 ndr_print_WERROR(ndr
, "result", r
->out
.result
);
16484 static enum ndr_err_code
ndr_push_srvsvc_NetServerStatisticsGet(struct ndr_push
*ndr
, int flags
, const struct srvsvc_NetServerStatisticsGet
*r
)
16486 if (flags
& NDR_IN
) {
16487 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->in
.server_unc
));
16488 if (r
->in
.server_unc
) {
16489 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.server_unc
, 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
.server_unc
, CH_UTF16
)));
16492 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
));
16494 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->in
.service
));
16495 if (r
->in
.service
) {
16496 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.service
, CH_UTF16
)));
16497 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
16498 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.service
, CH_UTF16
)));
16499 NDR_CHECK(ndr_push_charset(ndr
, NDR_SCALARS
, r
->in
.service
, ndr_charset_length(r
->in
.service
, CH_UTF16
), sizeof(uint16_t), CH_UTF16
));
16501 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->in
.level
));
16502 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->in
.options
));
16504 if (flags
& NDR_OUT
) {
16505 if (r
->out
.stats
== NULL
) {
16506 return ndr_push_error(ndr
, NDR_ERR_INVALID_POINTER
, "NULL [ref] pointer");
16508 NDR_CHECK(ndr_push_srvsvc_Statistics(ndr
, NDR_SCALARS
, r
->out
.stats
));
16509 NDR_CHECK(ndr_push_WERROR(ndr
, NDR_SCALARS
, r
->out
.result
));
16511 return NDR_ERR_SUCCESS
;
16514 static enum ndr_err_code
ndr_pull_srvsvc_NetServerStatisticsGet(struct ndr_pull
*ndr
, int flags
, struct srvsvc_NetServerStatisticsGet
*r
)
16516 uint32_t _ptr_server_unc
;
16517 uint32_t _ptr_service
;
16518 TALLOC_CTX
*_mem_save_server_unc_0
;
16519 TALLOC_CTX
*_mem_save_service_0
;
16520 TALLOC_CTX
*_mem_save_stats_0
;
16521 if (flags
& NDR_IN
) {
16522 ZERO_STRUCT(r
->out
);
16524 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_server_unc
));
16525 if (_ptr_server_unc
) {
16526 NDR_PULL_ALLOC(ndr
, r
->in
.server_unc
);
16528 r
->in
.server_unc
= NULL
;
16530 if (r
->in
.server_unc
) {
16531 _mem_save_server_unc_0
= NDR_PULL_GET_MEM_CTX(ndr
);
16532 NDR_PULL_SET_MEM_CTX(ndr
, r
->in
.server_unc
, 0);
16533 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->in
.server_unc
));
16534 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->in
.server_unc
));
16535 if (ndr_get_array_length(ndr
, &r
->in
.server_unc
) > ndr_get_array_size(ndr
, &r
->in
.server_unc
)) {
16536 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", ndr_get_array_size(ndr
, &r
->in
.server_unc
), ndr_get_array_length(ndr
, &r
->in
.server_unc
));
16538 NDR_CHECK(ndr_check_string_terminator(ndr
, ndr_get_array_length(ndr
, &r
->in
.server_unc
), sizeof(uint16_t)));
16539 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->in
.server_unc
, ndr_get_array_length(ndr
, &r
->in
.server_unc
), sizeof(uint16_t), CH_UTF16
));
16540 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_server_unc_0
, 0);
16542 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_service
));
16543 if (_ptr_service
) {
16544 NDR_PULL_ALLOC(ndr
, r
->in
.service
);
16546 r
->in
.service
= NULL
;
16548 if (r
->in
.service
) {
16549 _mem_save_service_0
= NDR_PULL_GET_MEM_CTX(ndr
);
16550 NDR_PULL_SET_MEM_CTX(ndr
, r
->in
.service
, 0);
16551 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->in
.service
));
16552 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->in
.service
));
16553 if (ndr_get_array_length(ndr
, &r
->in
.service
) > ndr_get_array_size(ndr
, &r
->in
.service
)) {
16554 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", ndr_get_array_size(ndr
, &r
->in
.service
), ndr_get_array_length(ndr
, &r
->in
.service
));
16556 NDR_CHECK(ndr_check_string_terminator(ndr
, ndr_get_array_length(ndr
, &r
->in
.service
), sizeof(uint16_t)));
16557 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->in
.service
, ndr_get_array_length(ndr
, &r
->in
.service
), sizeof(uint16_t), CH_UTF16
));
16558 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_service_0
, 0);
16560 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->in
.level
));
16561 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->in
.options
));
16562 NDR_PULL_ALLOC(ndr
, r
->out
.stats
);
16563 ZERO_STRUCTP(r
->out
.stats
);
16565 if (flags
& NDR_OUT
) {
16566 if (ndr
->flags
& LIBNDR_FLAG_REF_ALLOC
) {
16567 NDR_PULL_ALLOC(ndr
, r
->out
.stats
);
16569 _mem_save_stats_0
= NDR_PULL_GET_MEM_CTX(ndr
);
16570 NDR_PULL_SET_MEM_CTX(ndr
, r
->out
.stats
, LIBNDR_FLAG_REF_ALLOC
);
16571 NDR_CHECK(ndr_pull_srvsvc_Statistics(ndr
, NDR_SCALARS
, r
->out
.stats
));
16572 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_stats_0
, LIBNDR_FLAG_REF_ALLOC
);
16573 NDR_CHECK(ndr_pull_WERROR(ndr
, NDR_SCALARS
, &r
->out
.result
));
16575 return NDR_ERR_SUCCESS
;
16578 _PUBLIC_
void ndr_print_srvsvc_NetServerStatisticsGet(struct ndr_print
*ndr
, const char *name
, int flags
, const struct srvsvc_NetServerStatisticsGet
*r
)
16580 ndr_print_struct(ndr
, name
, "srvsvc_NetServerStatisticsGet");
16582 if (flags
& NDR_SET_VALUES
) {
16583 ndr
->flags
|= LIBNDR_PRINT_SET_VALUES
;
16585 if (flags
& NDR_IN
) {
16586 ndr_print_struct(ndr
, "in", "srvsvc_NetServerStatisticsGet");
16588 ndr_print_ptr(ndr
, "server_unc", r
->in
.server_unc
);
16590 if (r
->in
.server_unc
) {
16591 ndr_print_string(ndr
, "server_unc", r
->in
.server_unc
);
16594 ndr_print_ptr(ndr
, "service", r
->in
.service
);
16596 if (r
->in
.service
) {
16597 ndr_print_string(ndr
, "service", r
->in
.service
);
16600 ndr_print_uint32(ndr
, "level", r
->in
.level
);
16601 ndr_print_uint32(ndr
, "options", r
->in
.options
);
16604 if (flags
& NDR_OUT
) {
16605 ndr_print_struct(ndr
, "out", "srvsvc_NetServerStatisticsGet");
16607 ndr_print_ptr(ndr
, "stats", r
->out
.stats
);
16609 ndr_print_srvsvc_Statistics(ndr
, "stats", r
->out
.stats
);
16611 ndr_print_WERROR(ndr
, "result", r
->out
.result
);
16617 static enum ndr_err_code
ndr_push_srvsvc_NetTransportAdd(struct ndr_push
*ndr
, int flags
, const struct srvsvc_NetTransportAdd
*r
)
16619 if (flags
& NDR_IN
) {
16620 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->in
.server_unc
));
16621 if (r
->in
.server_unc
) {
16622 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.server_unc
, CH_UTF16
)));
16623 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
16624 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.server_unc
, CH_UTF16
)));
16625 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
));
16627 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->in
.level
));
16628 NDR_CHECK(ndr_push_set_switch_value(ndr
, &r
->in
.info
, r
->in
.level
));
16629 NDR_CHECK(ndr_push_srvsvc_NetTransportInfo(ndr
, NDR_SCALARS
|NDR_BUFFERS
, &r
->in
.info
));
16631 if (flags
& NDR_OUT
) {
16632 NDR_CHECK(ndr_push_WERROR(ndr
, NDR_SCALARS
, r
->out
.result
));
16634 return NDR_ERR_SUCCESS
;
16637 static enum ndr_err_code
ndr_pull_srvsvc_NetTransportAdd(struct ndr_pull
*ndr
, int flags
, struct srvsvc_NetTransportAdd
*r
)
16639 uint32_t _ptr_server_unc
;
16640 TALLOC_CTX
*_mem_save_server_unc_0
;
16641 if (flags
& NDR_IN
) {
16642 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_server_unc
));
16643 if (_ptr_server_unc
) {
16644 NDR_PULL_ALLOC(ndr
, r
->in
.server_unc
);
16646 r
->in
.server_unc
= NULL
;
16648 if (r
->in
.server_unc
) {
16649 _mem_save_server_unc_0
= NDR_PULL_GET_MEM_CTX(ndr
);
16650 NDR_PULL_SET_MEM_CTX(ndr
, r
->in
.server_unc
, 0);
16651 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->in
.server_unc
));
16652 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->in
.server_unc
));
16653 if (ndr_get_array_length(ndr
, &r
->in
.server_unc
) > ndr_get_array_size(ndr
, &r
->in
.server_unc
)) {
16654 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", ndr_get_array_size(ndr
, &r
->in
.server_unc
), ndr_get_array_length(ndr
, &r
->in
.server_unc
));
16656 NDR_CHECK(ndr_check_string_terminator(ndr
, ndr_get_array_length(ndr
, &r
->in
.server_unc
), sizeof(uint16_t)));
16657 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->in
.server_unc
, ndr_get_array_length(ndr
, &r
->in
.server_unc
), sizeof(uint16_t), CH_UTF16
));
16658 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_server_unc_0
, 0);
16660 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->in
.level
));
16661 NDR_CHECK(ndr_pull_set_switch_value(ndr
, &r
->in
.info
, r
->in
.level
));
16662 NDR_CHECK(ndr_pull_srvsvc_NetTransportInfo(ndr
, NDR_SCALARS
|NDR_BUFFERS
, &r
->in
.info
));
16664 if (flags
& NDR_OUT
) {
16665 NDR_CHECK(ndr_pull_WERROR(ndr
, NDR_SCALARS
, &r
->out
.result
));
16667 return NDR_ERR_SUCCESS
;
16670 _PUBLIC_
void ndr_print_srvsvc_NetTransportAdd(struct ndr_print
*ndr
, const char *name
, int flags
, const struct srvsvc_NetTransportAdd
*r
)
16672 ndr_print_struct(ndr
, name
, "srvsvc_NetTransportAdd");
16674 if (flags
& NDR_SET_VALUES
) {
16675 ndr
->flags
|= LIBNDR_PRINT_SET_VALUES
;
16677 if (flags
& NDR_IN
) {
16678 ndr_print_struct(ndr
, "in", "srvsvc_NetTransportAdd");
16680 ndr_print_ptr(ndr
, "server_unc", r
->in
.server_unc
);
16682 if (r
->in
.server_unc
) {
16683 ndr_print_string(ndr
, "server_unc", r
->in
.server_unc
);
16686 ndr_print_uint32(ndr
, "level", r
->in
.level
);
16687 ndr_print_set_switch_value(ndr
, &r
->in
.info
, r
->in
.level
);
16688 ndr_print_srvsvc_NetTransportInfo(ndr
, "info", &r
->in
.info
);
16691 if (flags
& NDR_OUT
) {
16692 ndr_print_struct(ndr
, "out", "srvsvc_NetTransportAdd");
16694 ndr_print_WERROR(ndr
, "result", r
->out
.result
);
16700 static enum ndr_err_code
ndr_push_srvsvc_NetTransportEnum(struct ndr_push
*ndr
, int flags
, const struct srvsvc_NetTransportEnum
*r
)
16702 if (flags
& NDR_IN
) {
16703 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->in
.server_unc
));
16704 if (r
->in
.server_unc
) {
16705 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.server_unc
, CH_UTF16
)));
16706 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
16707 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.server_unc
, CH_UTF16
)));
16708 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
));
16710 if (r
->in
.level
== NULL
) {
16711 return ndr_push_error(ndr
, NDR_ERR_INVALID_POINTER
, "NULL [ref] pointer");
16713 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, *r
->in
.level
));
16714 if (r
->in
.transports
== NULL
) {
16715 return ndr_push_error(ndr
, NDR_ERR_INVALID_POINTER
, "NULL [ref] pointer");
16717 NDR_CHECK(ndr_push_set_switch_value(ndr
, r
->in
.transports
, *r
->in
.level
));
16718 NDR_CHECK(ndr_push_srvsvc_NetTransportCtr(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->in
.transports
));
16719 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->in
.max_buffer
));
16720 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->in
.resume_handle
));
16721 if (r
->in
.resume_handle
) {
16722 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, *r
->in
.resume_handle
));
16725 if (flags
& NDR_OUT
) {
16726 if (r
->out
.level
== NULL
) {
16727 return ndr_push_error(ndr
, NDR_ERR_INVALID_POINTER
, "NULL [ref] pointer");
16729 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, *r
->out
.level
));
16730 if (r
->out
.transports
== NULL
) {
16731 return ndr_push_error(ndr
, NDR_ERR_INVALID_POINTER
, "NULL [ref] pointer");
16733 NDR_CHECK(ndr_push_set_switch_value(ndr
, r
->out
.transports
, *r
->out
.level
));
16734 NDR_CHECK(ndr_push_srvsvc_NetTransportCtr(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->out
.transports
));
16735 if (r
->out
.totalentries
== NULL
) {
16736 return ndr_push_error(ndr
, NDR_ERR_INVALID_POINTER
, "NULL [ref] pointer");
16738 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, *r
->out
.totalentries
));
16739 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->out
.resume_handle
));
16740 if (r
->out
.resume_handle
) {
16741 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, *r
->out
.resume_handle
));
16743 NDR_CHECK(ndr_push_WERROR(ndr
, NDR_SCALARS
, r
->out
.result
));
16745 return NDR_ERR_SUCCESS
;
16748 static enum ndr_err_code
ndr_pull_srvsvc_NetTransportEnum(struct ndr_pull
*ndr
, int flags
, struct srvsvc_NetTransportEnum
*r
)
16750 uint32_t _ptr_server_unc
;
16751 uint32_t _ptr_resume_handle
;
16752 TALLOC_CTX
*_mem_save_server_unc_0
;
16753 TALLOC_CTX
*_mem_save_level_0
;
16754 TALLOC_CTX
*_mem_save_transports_0
;
16755 TALLOC_CTX
*_mem_save_totalentries_0
;
16756 TALLOC_CTX
*_mem_save_resume_handle_0
;
16757 if (flags
& NDR_IN
) {
16758 ZERO_STRUCT(r
->out
);
16760 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_server_unc
));
16761 if (_ptr_server_unc
) {
16762 NDR_PULL_ALLOC(ndr
, r
->in
.server_unc
);
16764 r
->in
.server_unc
= NULL
;
16766 if (r
->in
.server_unc
) {
16767 _mem_save_server_unc_0
= NDR_PULL_GET_MEM_CTX(ndr
);
16768 NDR_PULL_SET_MEM_CTX(ndr
, r
->in
.server_unc
, 0);
16769 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->in
.server_unc
));
16770 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->in
.server_unc
));
16771 if (ndr_get_array_length(ndr
, &r
->in
.server_unc
) > ndr_get_array_size(ndr
, &r
->in
.server_unc
)) {
16772 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", ndr_get_array_size(ndr
, &r
->in
.server_unc
), ndr_get_array_length(ndr
, &r
->in
.server_unc
));
16774 NDR_CHECK(ndr_check_string_terminator(ndr
, ndr_get_array_length(ndr
, &r
->in
.server_unc
), sizeof(uint16_t)));
16775 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->in
.server_unc
, ndr_get_array_length(ndr
, &r
->in
.server_unc
), sizeof(uint16_t), CH_UTF16
));
16776 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_server_unc_0
, 0);
16778 if (ndr
->flags
& LIBNDR_FLAG_REF_ALLOC
) {
16779 NDR_PULL_ALLOC(ndr
, r
->in
.level
);
16781 _mem_save_level_0
= NDR_PULL_GET_MEM_CTX(ndr
);
16782 NDR_PULL_SET_MEM_CTX(ndr
, r
->in
.level
, LIBNDR_FLAG_REF_ALLOC
);
16783 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, r
->in
.level
));
16784 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_level_0
, LIBNDR_FLAG_REF_ALLOC
);
16785 if (ndr
->flags
& LIBNDR_FLAG_REF_ALLOC
) {
16786 NDR_PULL_ALLOC(ndr
, r
->in
.transports
);
16788 _mem_save_transports_0
= NDR_PULL_GET_MEM_CTX(ndr
);
16789 NDR_PULL_SET_MEM_CTX(ndr
, r
->in
.transports
, LIBNDR_FLAG_REF_ALLOC
);
16790 NDR_CHECK(ndr_pull_set_switch_value(ndr
, r
->in
.transports
, *r
->in
.level
));
16791 NDR_CHECK(ndr_pull_srvsvc_NetTransportCtr(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->in
.transports
));
16792 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_transports_0
, LIBNDR_FLAG_REF_ALLOC
);
16793 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->in
.max_buffer
));
16794 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_resume_handle
));
16795 if (_ptr_resume_handle
) {
16796 NDR_PULL_ALLOC(ndr
, r
->in
.resume_handle
);
16798 r
->in
.resume_handle
= NULL
;
16800 if (r
->in
.resume_handle
) {
16801 _mem_save_resume_handle_0
= NDR_PULL_GET_MEM_CTX(ndr
);
16802 NDR_PULL_SET_MEM_CTX(ndr
, r
->in
.resume_handle
, 0);
16803 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, r
->in
.resume_handle
));
16804 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_resume_handle_0
, 0);
16806 NDR_PULL_ALLOC(ndr
, r
->out
.level
);
16807 *r
->out
.level
= *r
->in
.level
;
16808 NDR_PULL_ALLOC(ndr
, r
->out
.transports
);
16809 *r
->out
.transports
= *r
->in
.transports
;
16810 NDR_PULL_ALLOC(ndr
, r
->out
.totalentries
);
16811 ZERO_STRUCTP(r
->out
.totalentries
);
16813 if (flags
& NDR_OUT
) {
16814 if (ndr
->flags
& LIBNDR_FLAG_REF_ALLOC
) {
16815 NDR_PULL_ALLOC(ndr
, r
->out
.level
);
16817 _mem_save_level_0
= NDR_PULL_GET_MEM_CTX(ndr
);
16818 NDR_PULL_SET_MEM_CTX(ndr
, r
->out
.level
, LIBNDR_FLAG_REF_ALLOC
);
16819 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, r
->out
.level
));
16820 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_level_0
, LIBNDR_FLAG_REF_ALLOC
);
16821 if (ndr
->flags
& LIBNDR_FLAG_REF_ALLOC
) {
16822 NDR_PULL_ALLOC(ndr
, r
->out
.transports
);
16824 _mem_save_transports_0
= NDR_PULL_GET_MEM_CTX(ndr
);
16825 NDR_PULL_SET_MEM_CTX(ndr
, r
->out
.transports
, LIBNDR_FLAG_REF_ALLOC
);
16826 NDR_CHECK(ndr_pull_set_switch_value(ndr
, r
->out
.transports
, *r
->out
.level
));
16827 NDR_CHECK(ndr_pull_srvsvc_NetTransportCtr(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->out
.transports
));
16828 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_transports_0
, LIBNDR_FLAG_REF_ALLOC
);
16829 if (ndr
->flags
& LIBNDR_FLAG_REF_ALLOC
) {
16830 NDR_PULL_ALLOC(ndr
, r
->out
.totalentries
);
16832 _mem_save_totalentries_0
= NDR_PULL_GET_MEM_CTX(ndr
);
16833 NDR_PULL_SET_MEM_CTX(ndr
, r
->out
.totalentries
, LIBNDR_FLAG_REF_ALLOC
);
16834 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, r
->out
.totalentries
));
16835 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_totalentries_0
, LIBNDR_FLAG_REF_ALLOC
);
16836 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_resume_handle
));
16837 if (_ptr_resume_handle
) {
16838 NDR_PULL_ALLOC(ndr
, r
->out
.resume_handle
);
16840 r
->out
.resume_handle
= NULL
;
16842 if (r
->out
.resume_handle
) {
16843 _mem_save_resume_handle_0
= NDR_PULL_GET_MEM_CTX(ndr
);
16844 NDR_PULL_SET_MEM_CTX(ndr
, r
->out
.resume_handle
, 0);
16845 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, r
->out
.resume_handle
));
16846 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_resume_handle_0
, 0);
16848 NDR_CHECK(ndr_pull_WERROR(ndr
, NDR_SCALARS
, &r
->out
.result
));
16850 return NDR_ERR_SUCCESS
;
16853 _PUBLIC_
void ndr_print_srvsvc_NetTransportEnum(struct ndr_print
*ndr
, const char *name
, int flags
, const struct srvsvc_NetTransportEnum
*r
)
16855 ndr_print_struct(ndr
, name
, "srvsvc_NetTransportEnum");
16857 if (flags
& NDR_SET_VALUES
) {
16858 ndr
->flags
|= LIBNDR_PRINT_SET_VALUES
;
16860 if (flags
& NDR_IN
) {
16861 ndr_print_struct(ndr
, "in", "srvsvc_NetTransportEnum");
16863 ndr_print_ptr(ndr
, "server_unc", r
->in
.server_unc
);
16865 if (r
->in
.server_unc
) {
16866 ndr_print_string(ndr
, "server_unc", r
->in
.server_unc
);
16869 ndr_print_ptr(ndr
, "level", r
->in
.level
);
16871 ndr_print_uint32(ndr
, "level", *r
->in
.level
);
16873 ndr_print_ptr(ndr
, "transports", r
->in
.transports
);
16875 ndr_print_set_switch_value(ndr
, r
->in
.transports
, *r
->in
.level
);
16876 ndr_print_srvsvc_NetTransportCtr(ndr
, "transports", r
->in
.transports
);
16878 ndr_print_uint32(ndr
, "max_buffer", r
->in
.max_buffer
);
16879 ndr_print_ptr(ndr
, "resume_handle", r
->in
.resume_handle
);
16881 if (r
->in
.resume_handle
) {
16882 ndr_print_uint32(ndr
, "resume_handle", *r
->in
.resume_handle
);
16887 if (flags
& NDR_OUT
) {
16888 ndr_print_struct(ndr
, "out", "srvsvc_NetTransportEnum");
16890 ndr_print_ptr(ndr
, "level", r
->out
.level
);
16892 ndr_print_uint32(ndr
, "level", *r
->out
.level
);
16894 ndr_print_ptr(ndr
, "transports", r
->out
.transports
);
16896 ndr_print_set_switch_value(ndr
, r
->out
.transports
, *r
->out
.level
);
16897 ndr_print_srvsvc_NetTransportCtr(ndr
, "transports", r
->out
.transports
);
16899 ndr_print_ptr(ndr
, "totalentries", r
->out
.totalentries
);
16901 ndr_print_uint32(ndr
, "totalentries", *r
->out
.totalentries
);
16903 ndr_print_ptr(ndr
, "resume_handle", r
->out
.resume_handle
);
16905 if (r
->out
.resume_handle
) {
16906 ndr_print_uint32(ndr
, "resume_handle", *r
->out
.resume_handle
);
16909 ndr_print_WERROR(ndr
, "result", r
->out
.result
);
16915 static enum ndr_err_code
ndr_push_srvsvc_NetTransportDel(struct ndr_push
*ndr
, int flags
, const struct srvsvc_NetTransportDel
*r
)
16917 if (flags
& NDR_IN
) {
16918 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->in
.server_unc
));
16919 if (r
->in
.server_unc
) {
16920 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.server_unc
, CH_UTF16
)));
16921 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
16922 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.server_unc
, CH_UTF16
)));
16923 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
));
16925 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->in
.unknown
));
16926 NDR_CHECK(ndr_push_srvsvc_NetTransportInfo0(ndr
, NDR_SCALARS
|NDR_BUFFERS
, &r
->in
.transport
));
16928 if (flags
& NDR_OUT
) {
16929 NDR_CHECK(ndr_push_WERROR(ndr
, NDR_SCALARS
, r
->out
.result
));
16931 return NDR_ERR_SUCCESS
;
16934 static enum ndr_err_code
ndr_pull_srvsvc_NetTransportDel(struct ndr_pull
*ndr
, int flags
, struct srvsvc_NetTransportDel
*r
)
16936 uint32_t _ptr_server_unc
;
16937 TALLOC_CTX
*_mem_save_server_unc_0
;
16938 if (flags
& NDR_IN
) {
16939 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_server_unc
));
16940 if (_ptr_server_unc
) {
16941 NDR_PULL_ALLOC(ndr
, r
->in
.server_unc
);
16943 r
->in
.server_unc
= NULL
;
16945 if (r
->in
.server_unc
) {
16946 _mem_save_server_unc_0
= NDR_PULL_GET_MEM_CTX(ndr
);
16947 NDR_PULL_SET_MEM_CTX(ndr
, r
->in
.server_unc
, 0);
16948 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->in
.server_unc
));
16949 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->in
.server_unc
));
16950 if (ndr_get_array_length(ndr
, &r
->in
.server_unc
) > ndr_get_array_size(ndr
, &r
->in
.server_unc
)) {
16951 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", ndr_get_array_size(ndr
, &r
->in
.server_unc
), ndr_get_array_length(ndr
, &r
->in
.server_unc
));
16953 NDR_CHECK(ndr_check_string_terminator(ndr
, ndr_get_array_length(ndr
, &r
->in
.server_unc
), sizeof(uint16_t)));
16954 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->in
.server_unc
, ndr_get_array_length(ndr
, &r
->in
.server_unc
), sizeof(uint16_t), CH_UTF16
));
16955 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_server_unc_0
, 0);
16957 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->in
.unknown
));
16958 NDR_CHECK(ndr_pull_srvsvc_NetTransportInfo0(ndr
, NDR_SCALARS
|NDR_BUFFERS
, &r
->in
.transport
));
16960 if (flags
& NDR_OUT
) {
16961 NDR_CHECK(ndr_pull_WERROR(ndr
, NDR_SCALARS
, &r
->out
.result
));
16963 return NDR_ERR_SUCCESS
;
16966 _PUBLIC_
void ndr_print_srvsvc_NetTransportDel(struct ndr_print
*ndr
, const char *name
, int flags
, const struct srvsvc_NetTransportDel
*r
)
16968 ndr_print_struct(ndr
, name
, "srvsvc_NetTransportDel");
16970 if (flags
& NDR_SET_VALUES
) {
16971 ndr
->flags
|= LIBNDR_PRINT_SET_VALUES
;
16973 if (flags
& NDR_IN
) {
16974 ndr_print_struct(ndr
, "in", "srvsvc_NetTransportDel");
16976 ndr_print_ptr(ndr
, "server_unc", r
->in
.server_unc
);
16978 if (r
->in
.server_unc
) {
16979 ndr_print_string(ndr
, "server_unc", r
->in
.server_unc
);
16982 ndr_print_uint32(ndr
, "unknown", r
->in
.unknown
);
16983 ndr_print_srvsvc_NetTransportInfo0(ndr
, "transport", &r
->in
.transport
);
16986 if (flags
& NDR_OUT
) {
16987 ndr_print_struct(ndr
, "out", "srvsvc_NetTransportDel");
16989 ndr_print_WERROR(ndr
, "result", r
->out
.result
);
16995 static enum ndr_err_code
ndr_push_srvsvc_NetRemoteTOD(struct ndr_push
*ndr
, int flags
, const struct srvsvc_NetRemoteTOD
*r
)
16997 if (flags
& NDR_IN
) {
16998 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->in
.server_unc
));
16999 if (r
->in
.server_unc
) {
17000 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.server_unc
, CH_UTF16
)));
17001 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
17002 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.server_unc
, CH_UTF16
)));
17003 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
));
17006 if (flags
& NDR_OUT
) {
17007 if (r
->out
.info
== NULL
) {
17008 return ndr_push_error(ndr
, NDR_ERR_INVALID_POINTER
, "NULL [ref] pointer");
17010 NDR_CHECK(ndr_push_unique_ptr(ndr
, *r
->out
.info
));
17011 if (*r
->out
.info
) {
17012 NDR_CHECK(ndr_push_srvsvc_NetRemoteTODInfo(ndr
, NDR_SCALARS
, *r
->out
.info
));
17014 NDR_CHECK(ndr_push_WERROR(ndr
, NDR_SCALARS
, r
->out
.result
));
17016 return NDR_ERR_SUCCESS
;
17019 static enum ndr_err_code
ndr_pull_srvsvc_NetRemoteTOD(struct ndr_pull
*ndr
, int flags
, struct srvsvc_NetRemoteTOD
*r
)
17021 uint32_t _ptr_server_unc
;
17022 uint32_t _ptr_info
;
17023 TALLOC_CTX
*_mem_save_server_unc_0
;
17024 TALLOC_CTX
*_mem_save_info_0
;
17025 TALLOC_CTX
*_mem_save_info_1
;
17026 if (flags
& NDR_IN
) {
17027 ZERO_STRUCT(r
->out
);
17029 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_server_unc
));
17030 if (_ptr_server_unc
) {
17031 NDR_PULL_ALLOC(ndr
, r
->in
.server_unc
);
17033 r
->in
.server_unc
= NULL
;
17035 if (r
->in
.server_unc
) {
17036 _mem_save_server_unc_0
= NDR_PULL_GET_MEM_CTX(ndr
);
17037 NDR_PULL_SET_MEM_CTX(ndr
, r
->in
.server_unc
, 0);
17038 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->in
.server_unc
));
17039 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->in
.server_unc
));
17040 if (ndr_get_array_length(ndr
, &r
->in
.server_unc
) > ndr_get_array_size(ndr
, &r
->in
.server_unc
)) {
17041 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", ndr_get_array_size(ndr
, &r
->in
.server_unc
), ndr_get_array_length(ndr
, &r
->in
.server_unc
));
17043 NDR_CHECK(ndr_check_string_terminator(ndr
, ndr_get_array_length(ndr
, &r
->in
.server_unc
), sizeof(uint16_t)));
17044 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->in
.server_unc
, ndr_get_array_length(ndr
, &r
->in
.server_unc
), sizeof(uint16_t), CH_UTF16
));
17045 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_server_unc_0
, 0);
17047 NDR_PULL_ALLOC(ndr
, r
->out
.info
);
17048 ZERO_STRUCTP(r
->out
.info
);
17050 if (flags
& NDR_OUT
) {
17051 if (ndr
->flags
& LIBNDR_FLAG_REF_ALLOC
) {
17052 NDR_PULL_ALLOC(ndr
, r
->out
.info
);
17054 _mem_save_info_0
= NDR_PULL_GET_MEM_CTX(ndr
);
17055 NDR_PULL_SET_MEM_CTX(ndr
, r
->out
.info
, LIBNDR_FLAG_REF_ALLOC
);
17056 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_info
));
17058 NDR_PULL_ALLOC(ndr
, *r
->out
.info
);
17060 *r
->out
.info
= NULL
;
17062 if (*r
->out
.info
) {
17063 _mem_save_info_1
= NDR_PULL_GET_MEM_CTX(ndr
);
17064 NDR_PULL_SET_MEM_CTX(ndr
, *r
->out
.info
, 0);
17065 NDR_CHECK(ndr_pull_srvsvc_NetRemoteTODInfo(ndr
, NDR_SCALARS
, *r
->out
.info
));
17066 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_info_1
, 0);
17068 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_info_0
, LIBNDR_FLAG_REF_ALLOC
);
17069 NDR_CHECK(ndr_pull_WERROR(ndr
, NDR_SCALARS
, &r
->out
.result
));
17071 return NDR_ERR_SUCCESS
;
17074 _PUBLIC_
void ndr_print_srvsvc_NetRemoteTOD(struct ndr_print
*ndr
, const char *name
, int flags
, const struct srvsvc_NetRemoteTOD
*r
)
17076 ndr_print_struct(ndr
, name
, "srvsvc_NetRemoteTOD");
17078 if (flags
& NDR_SET_VALUES
) {
17079 ndr
->flags
|= LIBNDR_PRINT_SET_VALUES
;
17081 if (flags
& NDR_IN
) {
17082 ndr_print_struct(ndr
, "in", "srvsvc_NetRemoteTOD");
17084 ndr_print_ptr(ndr
, "server_unc", r
->in
.server_unc
);
17086 if (r
->in
.server_unc
) {
17087 ndr_print_string(ndr
, "server_unc", r
->in
.server_unc
);
17092 if (flags
& NDR_OUT
) {
17093 ndr_print_struct(ndr
, "out", "srvsvc_NetRemoteTOD");
17095 ndr_print_ptr(ndr
, "info", r
->out
.info
);
17097 ndr_print_ptr(ndr
, "info", *r
->out
.info
);
17099 if (*r
->out
.info
) {
17100 ndr_print_srvsvc_NetRemoteTODInfo(ndr
, "info", *r
->out
.info
);
17104 ndr_print_WERROR(ndr
, "result", r
->out
.result
);
17110 static enum ndr_err_code
ndr_push_srvsvc_NetSetServiceBits(struct ndr_push
*ndr
, int flags
, const struct srvsvc_NetSetServiceBits
*r
)
17112 if (flags
& NDR_IN
) {
17113 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->in
.server_unc
));
17114 if (r
->in
.server_unc
) {
17115 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.server_unc
, CH_UTF16
)));
17116 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
17117 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.server_unc
, CH_UTF16
)));
17118 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
));
17120 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->in
.transport
));
17121 if (r
->in
.transport
) {
17122 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.transport
, CH_UTF16
)));
17123 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
17124 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.transport
, CH_UTF16
)));
17125 NDR_CHECK(ndr_push_charset(ndr
, NDR_SCALARS
, r
->in
.transport
, ndr_charset_length(r
->in
.transport
, CH_UTF16
), sizeof(uint16_t), CH_UTF16
));
17127 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->in
.servicebits
));
17128 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->in
.updateimmediately
));
17130 if (flags
& NDR_OUT
) {
17131 NDR_CHECK(ndr_push_WERROR(ndr
, NDR_SCALARS
, r
->out
.result
));
17133 return NDR_ERR_SUCCESS
;
17136 static enum ndr_err_code
ndr_pull_srvsvc_NetSetServiceBits(struct ndr_pull
*ndr
, int flags
, struct srvsvc_NetSetServiceBits
*r
)
17138 uint32_t _ptr_server_unc
;
17139 uint32_t _ptr_transport
;
17140 TALLOC_CTX
*_mem_save_server_unc_0
;
17141 TALLOC_CTX
*_mem_save_transport_0
;
17142 if (flags
& NDR_IN
) {
17143 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_server_unc
));
17144 if (_ptr_server_unc
) {
17145 NDR_PULL_ALLOC(ndr
, r
->in
.server_unc
);
17147 r
->in
.server_unc
= NULL
;
17149 if (r
->in
.server_unc
) {
17150 _mem_save_server_unc_0
= NDR_PULL_GET_MEM_CTX(ndr
);
17151 NDR_PULL_SET_MEM_CTX(ndr
, r
->in
.server_unc
, 0);
17152 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->in
.server_unc
));
17153 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->in
.server_unc
));
17154 if (ndr_get_array_length(ndr
, &r
->in
.server_unc
) > ndr_get_array_size(ndr
, &r
->in
.server_unc
)) {
17155 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", ndr_get_array_size(ndr
, &r
->in
.server_unc
), ndr_get_array_length(ndr
, &r
->in
.server_unc
));
17157 NDR_CHECK(ndr_check_string_terminator(ndr
, ndr_get_array_length(ndr
, &r
->in
.server_unc
), sizeof(uint16_t)));
17158 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->in
.server_unc
, ndr_get_array_length(ndr
, &r
->in
.server_unc
), sizeof(uint16_t), CH_UTF16
));
17159 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_server_unc_0
, 0);
17161 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_transport
));
17162 if (_ptr_transport
) {
17163 NDR_PULL_ALLOC(ndr
, r
->in
.transport
);
17165 r
->in
.transport
= NULL
;
17167 if (r
->in
.transport
) {
17168 _mem_save_transport_0
= NDR_PULL_GET_MEM_CTX(ndr
);
17169 NDR_PULL_SET_MEM_CTX(ndr
, r
->in
.transport
, 0);
17170 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->in
.transport
));
17171 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->in
.transport
));
17172 if (ndr_get_array_length(ndr
, &r
->in
.transport
) > ndr_get_array_size(ndr
, &r
->in
.transport
)) {
17173 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", ndr_get_array_size(ndr
, &r
->in
.transport
), ndr_get_array_length(ndr
, &r
->in
.transport
));
17175 NDR_CHECK(ndr_check_string_terminator(ndr
, ndr_get_array_length(ndr
, &r
->in
.transport
), sizeof(uint16_t)));
17176 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->in
.transport
, ndr_get_array_length(ndr
, &r
->in
.transport
), sizeof(uint16_t), CH_UTF16
));
17177 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_transport_0
, 0);
17179 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->in
.servicebits
));
17180 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->in
.updateimmediately
));
17182 if (flags
& NDR_OUT
) {
17183 NDR_CHECK(ndr_pull_WERROR(ndr
, NDR_SCALARS
, &r
->out
.result
));
17185 return NDR_ERR_SUCCESS
;
17188 _PUBLIC_
void ndr_print_srvsvc_NetSetServiceBits(struct ndr_print
*ndr
, const char *name
, int flags
, const struct srvsvc_NetSetServiceBits
*r
)
17190 ndr_print_struct(ndr
, name
, "srvsvc_NetSetServiceBits");
17192 if (flags
& NDR_SET_VALUES
) {
17193 ndr
->flags
|= LIBNDR_PRINT_SET_VALUES
;
17195 if (flags
& NDR_IN
) {
17196 ndr_print_struct(ndr
, "in", "srvsvc_NetSetServiceBits");
17198 ndr_print_ptr(ndr
, "server_unc", r
->in
.server_unc
);
17200 if (r
->in
.server_unc
) {
17201 ndr_print_string(ndr
, "server_unc", r
->in
.server_unc
);
17204 ndr_print_ptr(ndr
, "transport", r
->in
.transport
);
17206 if (r
->in
.transport
) {
17207 ndr_print_string(ndr
, "transport", r
->in
.transport
);
17210 ndr_print_uint32(ndr
, "servicebits", r
->in
.servicebits
);
17211 ndr_print_uint32(ndr
, "updateimmediately", r
->in
.updateimmediately
);
17214 if (flags
& NDR_OUT
) {
17215 ndr_print_struct(ndr
, "out", "srvsvc_NetSetServiceBits");
17217 ndr_print_WERROR(ndr
, "result", r
->out
.result
);
17223 static enum ndr_err_code
ndr_push_srvsvc_NetPathType(struct ndr_push
*ndr
, int flags
, const struct srvsvc_NetPathType
*r
)
17225 if (flags
& NDR_IN
) {
17226 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->in
.server_unc
));
17227 if (r
->in
.server_unc
) {
17228 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.server_unc
, CH_UTF16
)));
17229 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
17230 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.server_unc
, CH_UTF16
)));
17231 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
));
17233 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.path
, CH_UTF16
)));
17234 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
17235 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.path
, CH_UTF16
)));
17236 NDR_CHECK(ndr_push_charset(ndr
, NDR_SCALARS
, r
->in
.path
, ndr_charset_length(r
->in
.path
, CH_UTF16
), sizeof(uint16_t), CH_UTF16
));
17237 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->in
.pathflags
));
17239 if (flags
& NDR_OUT
) {
17240 if (r
->out
.pathtype
== NULL
) {
17241 return ndr_push_error(ndr
, NDR_ERR_INVALID_POINTER
, "NULL [ref] pointer");
17243 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, *r
->out
.pathtype
));
17244 NDR_CHECK(ndr_push_WERROR(ndr
, NDR_SCALARS
, r
->out
.result
));
17246 return NDR_ERR_SUCCESS
;
17249 static enum ndr_err_code
ndr_pull_srvsvc_NetPathType(struct ndr_pull
*ndr
, int flags
, struct srvsvc_NetPathType
*r
)
17251 uint32_t _ptr_server_unc
;
17252 TALLOC_CTX
*_mem_save_server_unc_0
;
17253 TALLOC_CTX
*_mem_save_pathtype_0
;
17254 if (flags
& NDR_IN
) {
17255 ZERO_STRUCT(r
->out
);
17257 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_server_unc
));
17258 if (_ptr_server_unc
) {
17259 NDR_PULL_ALLOC(ndr
, r
->in
.server_unc
);
17261 r
->in
.server_unc
= NULL
;
17263 if (r
->in
.server_unc
) {
17264 _mem_save_server_unc_0
= NDR_PULL_GET_MEM_CTX(ndr
);
17265 NDR_PULL_SET_MEM_CTX(ndr
, r
->in
.server_unc
, 0);
17266 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->in
.server_unc
));
17267 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->in
.server_unc
));
17268 if (ndr_get_array_length(ndr
, &r
->in
.server_unc
) > ndr_get_array_size(ndr
, &r
->in
.server_unc
)) {
17269 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", ndr_get_array_size(ndr
, &r
->in
.server_unc
), ndr_get_array_length(ndr
, &r
->in
.server_unc
));
17271 NDR_CHECK(ndr_check_string_terminator(ndr
, ndr_get_array_length(ndr
, &r
->in
.server_unc
), sizeof(uint16_t)));
17272 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->in
.server_unc
, ndr_get_array_length(ndr
, &r
->in
.server_unc
), sizeof(uint16_t), CH_UTF16
));
17273 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_server_unc_0
, 0);
17275 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->in
.path
));
17276 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->in
.path
));
17277 if (ndr_get_array_length(ndr
, &r
->in
.path
) > ndr_get_array_size(ndr
, &r
->in
.path
)) {
17278 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", ndr_get_array_size(ndr
, &r
->in
.path
), ndr_get_array_length(ndr
, &r
->in
.path
));
17280 NDR_CHECK(ndr_check_string_terminator(ndr
, ndr_get_array_length(ndr
, &r
->in
.path
), sizeof(uint16_t)));
17281 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->in
.path
, ndr_get_array_length(ndr
, &r
->in
.path
), sizeof(uint16_t), CH_UTF16
));
17282 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->in
.pathflags
));
17283 NDR_PULL_ALLOC(ndr
, r
->out
.pathtype
);
17284 ZERO_STRUCTP(r
->out
.pathtype
);
17286 if (flags
& NDR_OUT
) {
17287 if (ndr
->flags
& LIBNDR_FLAG_REF_ALLOC
) {
17288 NDR_PULL_ALLOC(ndr
, r
->out
.pathtype
);
17290 _mem_save_pathtype_0
= NDR_PULL_GET_MEM_CTX(ndr
);
17291 NDR_PULL_SET_MEM_CTX(ndr
, r
->out
.pathtype
, LIBNDR_FLAG_REF_ALLOC
);
17292 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, r
->out
.pathtype
));
17293 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_pathtype_0
, LIBNDR_FLAG_REF_ALLOC
);
17294 NDR_CHECK(ndr_pull_WERROR(ndr
, NDR_SCALARS
, &r
->out
.result
));
17296 return NDR_ERR_SUCCESS
;
17299 _PUBLIC_
void ndr_print_srvsvc_NetPathType(struct ndr_print
*ndr
, const char *name
, int flags
, const struct srvsvc_NetPathType
*r
)
17301 ndr_print_struct(ndr
, name
, "srvsvc_NetPathType");
17303 if (flags
& NDR_SET_VALUES
) {
17304 ndr
->flags
|= LIBNDR_PRINT_SET_VALUES
;
17306 if (flags
& NDR_IN
) {
17307 ndr_print_struct(ndr
, "in", "srvsvc_NetPathType");
17309 ndr_print_ptr(ndr
, "server_unc", r
->in
.server_unc
);
17311 if (r
->in
.server_unc
) {
17312 ndr_print_string(ndr
, "server_unc", r
->in
.server_unc
);
17315 ndr_print_string(ndr
, "path", r
->in
.path
);
17316 ndr_print_uint32(ndr
, "pathflags", r
->in
.pathflags
);
17319 if (flags
& NDR_OUT
) {
17320 ndr_print_struct(ndr
, "out", "srvsvc_NetPathType");
17322 ndr_print_ptr(ndr
, "pathtype", r
->out
.pathtype
);
17324 ndr_print_uint32(ndr
, "pathtype", *r
->out
.pathtype
);
17326 ndr_print_WERROR(ndr
, "result", r
->out
.result
);
17332 static enum ndr_err_code
ndr_push_srvsvc_NetPathCanonicalize(struct ndr_push
*ndr
, int flags
, const struct srvsvc_NetPathCanonicalize
*r
)
17334 if (flags
& NDR_IN
) {
17335 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->in
.server_unc
));
17336 if (r
->in
.server_unc
) {
17337 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.server_unc
, CH_UTF16
)));
17338 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
17339 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.server_unc
, CH_UTF16
)));
17340 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
));
17342 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.path
, CH_UTF16
)));
17343 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
17344 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.path
, CH_UTF16
)));
17345 NDR_CHECK(ndr_push_charset(ndr
, NDR_SCALARS
, r
->in
.path
, ndr_charset_length(r
->in
.path
, CH_UTF16
), sizeof(uint16_t), CH_UTF16
));
17346 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->in
.maxbuf
));
17347 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.prefix
, CH_UTF16
)));
17348 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
17349 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.prefix
, CH_UTF16
)));
17350 NDR_CHECK(ndr_push_charset(ndr
, NDR_SCALARS
, r
->in
.prefix
, ndr_charset_length(r
->in
.prefix
, CH_UTF16
), sizeof(uint16_t), CH_UTF16
));
17351 if (r
->in
.pathtype
== NULL
) {
17352 return ndr_push_error(ndr
, NDR_ERR_INVALID_POINTER
, "NULL [ref] pointer");
17354 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, *r
->in
.pathtype
));
17355 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->in
.pathflags
));
17357 if (flags
& NDR_OUT
) {
17358 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->in
.maxbuf
));
17359 NDR_CHECK(ndr_push_array_uint8(ndr
, NDR_SCALARS
, r
->out
.can_path
, r
->in
.maxbuf
));
17360 if (r
->out
.pathtype
== NULL
) {
17361 return ndr_push_error(ndr
, NDR_ERR_INVALID_POINTER
, "NULL [ref] pointer");
17363 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, *r
->out
.pathtype
));
17364 NDR_CHECK(ndr_push_WERROR(ndr
, NDR_SCALARS
, r
->out
.result
));
17366 return NDR_ERR_SUCCESS
;
17369 static enum ndr_err_code
ndr_pull_srvsvc_NetPathCanonicalize(struct ndr_pull
*ndr
, int flags
, struct srvsvc_NetPathCanonicalize
*r
)
17371 uint32_t _ptr_server_unc
;
17372 TALLOC_CTX
*_mem_save_server_unc_0
;
17373 TALLOC_CTX
*_mem_save_pathtype_0
;
17374 if (flags
& NDR_IN
) {
17375 ZERO_STRUCT(r
->out
);
17377 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_server_unc
));
17378 if (_ptr_server_unc
) {
17379 NDR_PULL_ALLOC(ndr
, r
->in
.server_unc
);
17381 r
->in
.server_unc
= NULL
;
17383 if (r
->in
.server_unc
) {
17384 _mem_save_server_unc_0
= NDR_PULL_GET_MEM_CTX(ndr
);
17385 NDR_PULL_SET_MEM_CTX(ndr
, r
->in
.server_unc
, 0);
17386 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->in
.server_unc
));
17387 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->in
.server_unc
));
17388 if (ndr_get_array_length(ndr
, &r
->in
.server_unc
) > ndr_get_array_size(ndr
, &r
->in
.server_unc
)) {
17389 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", ndr_get_array_size(ndr
, &r
->in
.server_unc
), ndr_get_array_length(ndr
, &r
->in
.server_unc
));
17391 NDR_CHECK(ndr_check_string_terminator(ndr
, ndr_get_array_length(ndr
, &r
->in
.server_unc
), sizeof(uint16_t)));
17392 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->in
.server_unc
, ndr_get_array_length(ndr
, &r
->in
.server_unc
), sizeof(uint16_t), CH_UTF16
));
17393 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_server_unc_0
, 0);
17395 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->in
.path
));
17396 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->in
.path
));
17397 if (ndr_get_array_length(ndr
, &r
->in
.path
) > ndr_get_array_size(ndr
, &r
->in
.path
)) {
17398 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", ndr_get_array_size(ndr
, &r
->in
.path
), ndr_get_array_length(ndr
, &r
->in
.path
));
17400 NDR_CHECK(ndr_check_string_terminator(ndr
, ndr_get_array_length(ndr
, &r
->in
.path
), sizeof(uint16_t)));
17401 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->in
.path
, ndr_get_array_length(ndr
, &r
->in
.path
), sizeof(uint16_t), CH_UTF16
));
17402 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->in
.maxbuf
));
17403 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->in
.prefix
));
17404 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->in
.prefix
));
17405 if (ndr_get_array_length(ndr
, &r
->in
.prefix
) > ndr_get_array_size(ndr
, &r
->in
.prefix
)) {
17406 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", ndr_get_array_size(ndr
, &r
->in
.prefix
), ndr_get_array_length(ndr
, &r
->in
.prefix
));
17408 NDR_CHECK(ndr_check_string_terminator(ndr
, ndr_get_array_length(ndr
, &r
->in
.prefix
), sizeof(uint16_t)));
17409 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->in
.prefix
, ndr_get_array_length(ndr
, &r
->in
.prefix
), sizeof(uint16_t), CH_UTF16
));
17410 if (ndr
->flags
& LIBNDR_FLAG_REF_ALLOC
) {
17411 NDR_PULL_ALLOC(ndr
, r
->in
.pathtype
);
17413 _mem_save_pathtype_0
= NDR_PULL_GET_MEM_CTX(ndr
);
17414 NDR_PULL_SET_MEM_CTX(ndr
, r
->in
.pathtype
, LIBNDR_FLAG_REF_ALLOC
);
17415 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, r
->in
.pathtype
));
17416 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_pathtype_0
, LIBNDR_FLAG_REF_ALLOC
);
17417 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->in
.pathflags
));
17418 NDR_PULL_ALLOC(ndr
, r
->out
.pathtype
);
17419 *r
->out
.pathtype
= *r
->in
.pathtype
;
17421 if (flags
& NDR_OUT
) {
17422 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->out
.can_path
));
17423 NDR_PULL_ALLOC_N(ndr
, r
->out
.can_path
, ndr_get_array_size(ndr
, &r
->out
.can_path
));
17424 NDR_CHECK(ndr_pull_array_uint8(ndr
, NDR_SCALARS
, r
->out
.can_path
, ndr_get_array_size(ndr
, &r
->out
.can_path
)));
17425 if (ndr
->flags
& LIBNDR_FLAG_REF_ALLOC
) {
17426 NDR_PULL_ALLOC(ndr
, r
->out
.pathtype
);
17428 _mem_save_pathtype_0
= NDR_PULL_GET_MEM_CTX(ndr
);
17429 NDR_PULL_SET_MEM_CTX(ndr
, r
->out
.pathtype
, LIBNDR_FLAG_REF_ALLOC
);
17430 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, r
->out
.pathtype
));
17431 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_pathtype_0
, LIBNDR_FLAG_REF_ALLOC
);
17432 NDR_CHECK(ndr_pull_WERROR(ndr
, NDR_SCALARS
, &r
->out
.result
));
17433 if (r
->out
.can_path
) {
17434 NDR_CHECK(ndr_check_array_size(ndr
, (void*)&r
->out
.can_path
, r
->in
.maxbuf
));
17437 return NDR_ERR_SUCCESS
;
17440 _PUBLIC_
void ndr_print_srvsvc_NetPathCanonicalize(struct ndr_print
*ndr
, const char *name
, int flags
, const struct srvsvc_NetPathCanonicalize
*r
)
17442 ndr_print_struct(ndr
, name
, "srvsvc_NetPathCanonicalize");
17444 if (flags
& NDR_SET_VALUES
) {
17445 ndr
->flags
|= LIBNDR_PRINT_SET_VALUES
;
17447 if (flags
& NDR_IN
) {
17448 ndr_print_struct(ndr
, "in", "srvsvc_NetPathCanonicalize");
17450 ndr_print_ptr(ndr
, "server_unc", r
->in
.server_unc
);
17452 if (r
->in
.server_unc
) {
17453 ndr_print_string(ndr
, "server_unc", r
->in
.server_unc
);
17456 ndr_print_string(ndr
, "path", r
->in
.path
);
17457 ndr_print_uint32(ndr
, "maxbuf", r
->in
.maxbuf
);
17458 ndr_print_string(ndr
, "prefix", r
->in
.prefix
);
17459 ndr_print_ptr(ndr
, "pathtype", r
->in
.pathtype
);
17461 ndr_print_uint32(ndr
, "pathtype", *r
->in
.pathtype
);
17463 ndr_print_uint32(ndr
, "pathflags", r
->in
.pathflags
);
17466 if (flags
& NDR_OUT
) {
17467 ndr_print_struct(ndr
, "out", "srvsvc_NetPathCanonicalize");
17469 ndr_print_array_uint8(ndr
, "can_path", r
->out
.can_path
, r
->in
.maxbuf
);
17470 ndr_print_ptr(ndr
, "pathtype", r
->out
.pathtype
);
17472 ndr_print_uint32(ndr
, "pathtype", *r
->out
.pathtype
);
17474 ndr_print_WERROR(ndr
, "result", r
->out
.result
);
17480 static enum ndr_err_code
ndr_push_srvsvc_NetPathCompare(struct ndr_push
*ndr
, int flags
, const struct srvsvc_NetPathCompare
*r
)
17482 if (flags
& NDR_IN
) {
17483 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->in
.server_unc
));
17484 if (r
->in
.server_unc
) {
17485 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.server_unc
, CH_UTF16
)));
17486 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
17487 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.server_unc
, CH_UTF16
)));
17488 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
));
17490 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.path1
, CH_UTF16
)));
17491 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
17492 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.path1
, CH_UTF16
)));
17493 NDR_CHECK(ndr_push_charset(ndr
, NDR_SCALARS
, r
->in
.path1
, ndr_charset_length(r
->in
.path1
, CH_UTF16
), sizeof(uint16_t), CH_UTF16
));
17494 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.path2
, CH_UTF16
)));
17495 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
17496 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.path2
, CH_UTF16
)));
17497 NDR_CHECK(ndr_push_charset(ndr
, NDR_SCALARS
, r
->in
.path2
, ndr_charset_length(r
->in
.path2
, CH_UTF16
), sizeof(uint16_t), CH_UTF16
));
17498 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->in
.pathtype
));
17499 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->in
.pathflags
));
17501 if (flags
& NDR_OUT
) {
17502 NDR_CHECK(ndr_push_WERROR(ndr
, NDR_SCALARS
, r
->out
.result
));
17504 return NDR_ERR_SUCCESS
;
17507 static enum ndr_err_code
ndr_pull_srvsvc_NetPathCompare(struct ndr_pull
*ndr
, int flags
, struct srvsvc_NetPathCompare
*r
)
17509 uint32_t _ptr_server_unc
;
17510 TALLOC_CTX
*_mem_save_server_unc_0
;
17511 if (flags
& NDR_IN
) {
17512 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_server_unc
));
17513 if (_ptr_server_unc
) {
17514 NDR_PULL_ALLOC(ndr
, r
->in
.server_unc
);
17516 r
->in
.server_unc
= NULL
;
17518 if (r
->in
.server_unc
) {
17519 _mem_save_server_unc_0
= NDR_PULL_GET_MEM_CTX(ndr
);
17520 NDR_PULL_SET_MEM_CTX(ndr
, r
->in
.server_unc
, 0);
17521 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->in
.server_unc
));
17522 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->in
.server_unc
));
17523 if (ndr_get_array_length(ndr
, &r
->in
.server_unc
) > ndr_get_array_size(ndr
, &r
->in
.server_unc
)) {
17524 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", ndr_get_array_size(ndr
, &r
->in
.server_unc
), ndr_get_array_length(ndr
, &r
->in
.server_unc
));
17526 NDR_CHECK(ndr_check_string_terminator(ndr
, ndr_get_array_length(ndr
, &r
->in
.server_unc
), sizeof(uint16_t)));
17527 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->in
.server_unc
, ndr_get_array_length(ndr
, &r
->in
.server_unc
), sizeof(uint16_t), CH_UTF16
));
17528 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_server_unc_0
, 0);
17530 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->in
.path1
));
17531 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->in
.path1
));
17532 if (ndr_get_array_length(ndr
, &r
->in
.path1
) > ndr_get_array_size(ndr
, &r
->in
.path1
)) {
17533 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", ndr_get_array_size(ndr
, &r
->in
.path1
), ndr_get_array_length(ndr
, &r
->in
.path1
));
17535 NDR_CHECK(ndr_check_string_terminator(ndr
, ndr_get_array_length(ndr
, &r
->in
.path1
), sizeof(uint16_t)));
17536 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->in
.path1
, ndr_get_array_length(ndr
, &r
->in
.path1
), sizeof(uint16_t), CH_UTF16
));
17537 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->in
.path2
));
17538 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->in
.path2
));
17539 if (ndr_get_array_length(ndr
, &r
->in
.path2
) > ndr_get_array_size(ndr
, &r
->in
.path2
)) {
17540 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", ndr_get_array_size(ndr
, &r
->in
.path2
), ndr_get_array_length(ndr
, &r
->in
.path2
));
17542 NDR_CHECK(ndr_check_string_terminator(ndr
, ndr_get_array_length(ndr
, &r
->in
.path2
), sizeof(uint16_t)));
17543 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->in
.path2
, ndr_get_array_length(ndr
, &r
->in
.path2
), sizeof(uint16_t), CH_UTF16
));
17544 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->in
.pathtype
));
17545 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->in
.pathflags
));
17547 if (flags
& NDR_OUT
) {
17548 NDR_CHECK(ndr_pull_WERROR(ndr
, NDR_SCALARS
, &r
->out
.result
));
17550 return NDR_ERR_SUCCESS
;
17553 _PUBLIC_
void ndr_print_srvsvc_NetPathCompare(struct ndr_print
*ndr
, const char *name
, int flags
, const struct srvsvc_NetPathCompare
*r
)
17555 ndr_print_struct(ndr
, name
, "srvsvc_NetPathCompare");
17557 if (flags
& NDR_SET_VALUES
) {
17558 ndr
->flags
|= LIBNDR_PRINT_SET_VALUES
;
17560 if (flags
& NDR_IN
) {
17561 ndr_print_struct(ndr
, "in", "srvsvc_NetPathCompare");
17563 ndr_print_ptr(ndr
, "server_unc", r
->in
.server_unc
);
17565 if (r
->in
.server_unc
) {
17566 ndr_print_string(ndr
, "server_unc", r
->in
.server_unc
);
17569 ndr_print_string(ndr
, "path1", r
->in
.path1
);
17570 ndr_print_string(ndr
, "path2", r
->in
.path2
);
17571 ndr_print_uint32(ndr
, "pathtype", r
->in
.pathtype
);
17572 ndr_print_uint32(ndr
, "pathflags", r
->in
.pathflags
);
17575 if (flags
& NDR_OUT
) {
17576 ndr_print_struct(ndr
, "out", "srvsvc_NetPathCompare");
17578 ndr_print_WERROR(ndr
, "result", r
->out
.result
);
17584 static enum ndr_err_code
ndr_push_srvsvc_NetNameValidate(struct ndr_push
*ndr
, int flags
, const struct srvsvc_NetNameValidate
*r
)
17586 if (flags
& NDR_IN
) {
17587 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->in
.server_unc
));
17588 if (r
->in
.server_unc
) {
17589 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.server_unc
, CH_UTF16
)));
17590 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
17591 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.server_unc
, CH_UTF16
)));
17592 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
));
17594 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.name
, CH_UTF16
)));
17595 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
17596 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.name
, CH_UTF16
)));
17597 NDR_CHECK(ndr_push_charset(ndr
, NDR_SCALARS
, r
->in
.name
, ndr_charset_length(r
->in
.name
, CH_UTF16
), sizeof(uint16_t), CH_UTF16
));
17598 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->in
.name_type
));
17599 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->in
.flags
));
17601 if (flags
& NDR_OUT
) {
17602 NDR_CHECK(ndr_push_WERROR(ndr
, NDR_SCALARS
, r
->out
.result
));
17604 return NDR_ERR_SUCCESS
;
17607 static enum ndr_err_code
ndr_pull_srvsvc_NetNameValidate(struct ndr_pull
*ndr
, int flags
, struct srvsvc_NetNameValidate
*r
)
17609 uint32_t _ptr_server_unc
;
17610 TALLOC_CTX
*_mem_save_server_unc_0
;
17611 if (flags
& NDR_IN
) {
17612 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_server_unc
));
17613 if (_ptr_server_unc
) {
17614 NDR_PULL_ALLOC(ndr
, r
->in
.server_unc
);
17616 r
->in
.server_unc
= NULL
;
17618 if (r
->in
.server_unc
) {
17619 _mem_save_server_unc_0
= NDR_PULL_GET_MEM_CTX(ndr
);
17620 NDR_PULL_SET_MEM_CTX(ndr
, r
->in
.server_unc
, 0);
17621 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->in
.server_unc
));
17622 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->in
.server_unc
));
17623 if (ndr_get_array_length(ndr
, &r
->in
.server_unc
) > ndr_get_array_size(ndr
, &r
->in
.server_unc
)) {
17624 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", ndr_get_array_size(ndr
, &r
->in
.server_unc
), ndr_get_array_length(ndr
, &r
->in
.server_unc
));
17626 NDR_CHECK(ndr_check_string_terminator(ndr
, ndr_get_array_length(ndr
, &r
->in
.server_unc
), sizeof(uint16_t)));
17627 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->in
.server_unc
, ndr_get_array_length(ndr
, &r
->in
.server_unc
), sizeof(uint16_t), CH_UTF16
));
17628 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_server_unc_0
, 0);
17630 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->in
.name
));
17631 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->in
.name
));
17632 if (ndr_get_array_length(ndr
, &r
->in
.name
) > ndr_get_array_size(ndr
, &r
->in
.name
)) {
17633 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", ndr_get_array_size(ndr
, &r
->in
.name
), ndr_get_array_length(ndr
, &r
->in
.name
));
17635 NDR_CHECK(ndr_check_string_terminator(ndr
, ndr_get_array_length(ndr
, &r
->in
.name
), sizeof(uint16_t)));
17636 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->in
.name
, ndr_get_array_length(ndr
, &r
->in
.name
), sizeof(uint16_t), CH_UTF16
));
17637 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->in
.name_type
));
17638 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->in
.flags
));
17640 if (flags
& NDR_OUT
) {
17641 NDR_CHECK(ndr_pull_WERROR(ndr
, NDR_SCALARS
, &r
->out
.result
));
17643 return NDR_ERR_SUCCESS
;
17646 _PUBLIC_
void ndr_print_srvsvc_NetNameValidate(struct ndr_print
*ndr
, const char *name
, int flags
, const struct srvsvc_NetNameValidate
*r
)
17648 ndr_print_struct(ndr
, name
, "srvsvc_NetNameValidate");
17650 if (flags
& NDR_SET_VALUES
) {
17651 ndr
->flags
|= LIBNDR_PRINT_SET_VALUES
;
17653 if (flags
& NDR_IN
) {
17654 ndr_print_struct(ndr
, "in", "srvsvc_NetNameValidate");
17656 ndr_print_ptr(ndr
, "server_unc", r
->in
.server_unc
);
17658 if (r
->in
.server_unc
) {
17659 ndr_print_string(ndr
, "server_unc", r
->in
.server_unc
);
17662 ndr_print_string(ndr
, "name", r
->in
.name
);
17663 ndr_print_uint32(ndr
, "name_type", r
->in
.name_type
);
17664 ndr_print_uint32(ndr
, "flags", r
->in
.flags
);
17667 if (flags
& NDR_OUT
) {
17668 ndr_print_struct(ndr
, "out", "srvsvc_NetNameValidate");
17670 ndr_print_WERROR(ndr
, "result", r
->out
.result
);
17676 static enum ndr_err_code
ndr_push_srvsvc_NETRPRNAMECANONICALIZE(struct ndr_push
*ndr
, int flags
, const struct srvsvc_NETRPRNAMECANONICALIZE
*r
)
17678 if (flags
& NDR_IN
) {
17680 if (flags
& NDR_OUT
) {
17681 NDR_CHECK(ndr_push_WERROR(ndr
, NDR_SCALARS
, r
->out
.result
));
17683 return NDR_ERR_SUCCESS
;
17686 static enum ndr_err_code
ndr_pull_srvsvc_NETRPRNAMECANONICALIZE(struct ndr_pull
*ndr
, int flags
, struct srvsvc_NETRPRNAMECANONICALIZE
*r
)
17688 if (flags
& NDR_IN
) {
17690 if (flags
& NDR_OUT
) {
17691 NDR_CHECK(ndr_pull_WERROR(ndr
, NDR_SCALARS
, &r
->out
.result
));
17693 return NDR_ERR_SUCCESS
;
17696 _PUBLIC_
void ndr_print_srvsvc_NETRPRNAMECANONICALIZE(struct ndr_print
*ndr
, const char *name
, int flags
, const struct srvsvc_NETRPRNAMECANONICALIZE
*r
)
17698 ndr_print_struct(ndr
, name
, "srvsvc_NETRPRNAMECANONICALIZE");
17700 if (flags
& NDR_SET_VALUES
) {
17701 ndr
->flags
|= LIBNDR_PRINT_SET_VALUES
;
17703 if (flags
& NDR_IN
) {
17704 ndr_print_struct(ndr
, "in", "srvsvc_NETRPRNAMECANONICALIZE");
17708 if (flags
& NDR_OUT
) {
17709 ndr_print_struct(ndr
, "out", "srvsvc_NETRPRNAMECANONICALIZE");
17711 ndr_print_WERROR(ndr
, "result", r
->out
.result
);
17717 static enum ndr_err_code
ndr_push_srvsvc_NetPRNameCompare(struct ndr_push
*ndr
, int flags
, const struct srvsvc_NetPRNameCompare
*r
)
17719 if (flags
& NDR_IN
) {
17720 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->in
.server_unc
));
17721 if (r
->in
.server_unc
) {
17722 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.server_unc
, CH_UTF16
)));
17723 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
17724 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.server_unc
, CH_UTF16
)));
17725 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
));
17727 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.name1
, CH_UTF16
)));
17728 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
17729 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.name1
, CH_UTF16
)));
17730 NDR_CHECK(ndr_push_charset(ndr
, NDR_SCALARS
, r
->in
.name1
, ndr_charset_length(r
->in
.name1
, CH_UTF16
), sizeof(uint16_t), CH_UTF16
));
17731 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.name2
, CH_UTF16
)));
17732 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
17733 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.name2
, CH_UTF16
)));
17734 NDR_CHECK(ndr_push_charset(ndr
, NDR_SCALARS
, r
->in
.name2
, ndr_charset_length(r
->in
.name2
, CH_UTF16
), sizeof(uint16_t), CH_UTF16
));
17735 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->in
.name_type
));
17736 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->in
.flags
));
17738 if (flags
& NDR_OUT
) {
17739 NDR_CHECK(ndr_push_WERROR(ndr
, NDR_SCALARS
, r
->out
.result
));
17741 return NDR_ERR_SUCCESS
;
17744 static enum ndr_err_code
ndr_pull_srvsvc_NetPRNameCompare(struct ndr_pull
*ndr
, int flags
, struct srvsvc_NetPRNameCompare
*r
)
17746 uint32_t _ptr_server_unc
;
17747 TALLOC_CTX
*_mem_save_server_unc_0
;
17748 if (flags
& NDR_IN
) {
17749 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_server_unc
));
17750 if (_ptr_server_unc
) {
17751 NDR_PULL_ALLOC(ndr
, r
->in
.server_unc
);
17753 r
->in
.server_unc
= NULL
;
17755 if (r
->in
.server_unc
) {
17756 _mem_save_server_unc_0
= NDR_PULL_GET_MEM_CTX(ndr
);
17757 NDR_PULL_SET_MEM_CTX(ndr
, r
->in
.server_unc
, 0);
17758 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->in
.server_unc
));
17759 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->in
.server_unc
));
17760 if (ndr_get_array_length(ndr
, &r
->in
.server_unc
) > ndr_get_array_size(ndr
, &r
->in
.server_unc
)) {
17761 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", ndr_get_array_size(ndr
, &r
->in
.server_unc
), ndr_get_array_length(ndr
, &r
->in
.server_unc
));
17763 NDR_CHECK(ndr_check_string_terminator(ndr
, ndr_get_array_length(ndr
, &r
->in
.server_unc
), sizeof(uint16_t)));
17764 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->in
.server_unc
, ndr_get_array_length(ndr
, &r
->in
.server_unc
), sizeof(uint16_t), CH_UTF16
));
17765 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_server_unc_0
, 0);
17767 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->in
.name1
));
17768 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->in
.name1
));
17769 if (ndr_get_array_length(ndr
, &r
->in
.name1
) > ndr_get_array_size(ndr
, &r
->in
.name1
)) {
17770 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", ndr_get_array_size(ndr
, &r
->in
.name1
), ndr_get_array_length(ndr
, &r
->in
.name1
));
17772 NDR_CHECK(ndr_check_string_terminator(ndr
, ndr_get_array_length(ndr
, &r
->in
.name1
), sizeof(uint16_t)));
17773 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->in
.name1
, ndr_get_array_length(ndr
, &r
->in
.name1
), sizeof(uint16_t), CH_UTF16
));
17774 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->in
.name2
));
17775 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->in
.name2
));
17776 if (ndr_get_array_length(ndr
, &r
->in
.name2
) > ndr_get_array_size(ndr
, &r
->in
.name2
)) {
17777 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", ndr_get_array_size(ndr
, &r
->in
.name2
), ndr_get_array_length(ndr
, &r
->in
.name2
));
17779 NDR_CHECK(ndr_check_string_terminator(ndr
, ndr_get_array_length(ndr
, &r
->in
.name2
), sizeof(uint16_t)));
17780 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->in
.name2
, ndr_get_array_length(ndr
, &r
->in
.name2
), sizeof(uint16_t), CH_UTF16
));
17781 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->in
.name_type
));
17782 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->in
.flags
));
17784 if (flags
& NDR_OUT
) {
17785 NDR_CHECK(ndr_pull_WERROR(ndr
, NDR_SCALARS
, &r
->out
.result
));
17787 return NDR_ERR_SUCCESS
;
17790 _PUBLIC_
void ndr_print_srvsvc_NetPRNameCompare(struct ndr_print
*ndr
, const char *name
, int flags
, const struct srvsvc_NetPRNameCompare
*r
)
17792 ndr_print_struct(ndr
, name
, "srvsvc_NetPRNameCompare");
17794 if (flags
& NDR_SET_VALUES
) {
17795 ndr
->flags
|= LIBNDR_PRINT_SET_VALUES
;
17797 if (flags
& NDR_IN
) {
17798 ndr_print_struct(ndr
, "in", "srvsvc_NetPRNameCompare");
17800 ndr_print_ptr(ndr
, "server_unc", r
->in
.server_unc
);
17802 if (r
->in
.server_unc
) {
17803 ndr_print_string(ndr
, "server_unc", r
->in
.server_unc
);
17806 ndr_print_string(ndr
, "name1", r
->in
.name1
);
17807 ndr_print_string(ndr
, "name2", r
->in
.name2
);
17808 ndr_print_uint32(ndr
, "name_type", r
->in
.name_type
);
17809 ndr_print_uint32(ndr
, "flags", r
->in
.flags
);
17812 if (flags
& NDR_OUT
) {
17813 ndr_print_struct(ndr
, "out", "srvsvc_NetPRNameCompare");
17815 ndr_print_WERROR(ndr
, "result", r
->out
.result
);
17821 static enum ndr_err_code
ndr_push_srvsvc_NetShareEnum(struct ndr_push
*ndr
, int flags
, const struct srvsvc_NetShareEnum
*r
)
17823 if (flags
& NDR_IN
) {
17824 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->in
.server_unc
));
17825 if (r
->in
.server_unc
) {
17826 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.server_unc
, CH_UTF16
)));
17827 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
17828 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.server_unc
, CH_UTF16
)));
17829 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
));
17831 if (r
->in
.info_ctr
== NULL
) {
17832 return ndr_push_error(ndr
, NDR_ERR_INVALID_POINTER
, "NULL [ref] pointer");
17834 NDR_CHECK(ndr_push_srvsvc_NetShareInfoCtr(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->in
.info_ctr
));
17835 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->in
.max_buffer
));
17836 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->in
.resume_handle
));
17837 if (r
->in
.resume_handle
) {
17838 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, *r
->in
.resume_handle
));
17841 if (flags
& NDR_OUT
) {
17842 if (r
->out
.info_ctr
== NULL
) {
17843 return ndr_push_error(ndr
, NDR_ERR_INVALID_POINTER
, "NULL [ref] pointer");
17845 NDR_CHECK(ndr_push_srvsvc_NetShareInfoCtr(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->out
.info_ctr
));
17846 if (r
->out
.totalentries
== NULL
) {
17847 return ndr_push_error(ndr
, NDR_ERR_INVALID_POINTER
, "NULL [ref] pointer");
17849 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, *r
->out
.totalentries
));
17850 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->out
.resume_handle
));
17851 if (r
->out
.resume_handle
) {
17852 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, *r
->out
.resume_handle
));
17854 NDR_CHECK(ndr_push_WERROR(ndr
, NDR_SCALARS
, r
->out
.result
));
17856 return NDR_ERR_SUCCESS
;
17859 static enum ndr_err_code
ndr_pull_srvsvc_NetShareEnum(struct ndr_pull
*ndr
, int flags
, struct srvsvc_NetShareEnum
*r
)
17861 uint32_t _ptr_server_unc
;
17862 uint32_t _ptr_resume_handle
;
17863 TALLOC_CTX
*_mem_save_server_unc_0
;
17864 TALLOC_CTX
*_mem_save_info_ctr_0
;
17865 TALLOC_CTX
*_mem_save_totalentries_0
;
17866 TALLOC_CTX
*_mem_save_resume_handle_0
;
17867 if (flags
& NDR_IN
) {
17868 ZERO_STRUCT(r
->out
);
17870 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_server_unc
));
17871 if (_ptr_server_unc
) {
17872 NDR_PULL_ALLOC(ndr
, r
->in
.server_unc
);
17874 r
->in
.server_unc
= NULL
;
17876 if (r
->in
.server_unc
) {
17877 _mem_save_server_unc_0
= NDR_PULL_GET_MEM_CTX(ndr
);
17878 NDR_PULL_SET_MEM_CTX(ndr
, r
->in
.server_unc
, 0);
17879 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->in
.server_unc
));
17880 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->in
.server_unc
));
17881 if (ndr_get_array_length(ndr
, &r
->in
.server_unc
) > ndr_get_array_size(ndr
, &r
->in
.server_unc
)) {
17882 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", ndr_get_array_size(ndr
, &r
->in
.server_unc
), ndr_get_array_length(ndr
, &r
->in
.server_unc
));
17884 NDR_CHECK(ndr_check_string_terminator(ndr
, ndr_get_array_length(ndr
, &r
->in
.server_unc
), sizeof(uint16_t)));
17885 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->in
.server_unc
, ndr_get_array_length(ndr
, &r
->in
.server_unc
), sizeof(uint16_t), CH_UTF16
));
17886 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_server_unc_0
, 0);
17888 if (ndr
->flags
& LIBNDR_FLAG_REF_ALLOC
) {
17889 NDR_PULL_ALLOC(ndr
, r
->in
.info_ctr
);
17891 _mem_save_info_ctr_0
= NDR_PULL_GET_MEM_CTX(ndr
);
17892 NDR_PULL_SET_MEM_CTX(ndr
, r
->in
.info_ctr
, LIBNDR_FLAG_REF_ALLOC
);
17893 NDR_CHECK(ndr_pull_srvsvc_NetShareInfoCtr(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->in
.info_ctr
));
17894 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_info_ctr_0
, LIBNDR_FLAG_REF_ALLOC
);
17895 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->in
.max_buffer
));
17896 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_resume_handle
));
17897 if (_ptr_resume_handle
) {
17898 NDR_PULL_ALLOC(ndr
, r
->in
.resume_handle
);
17900 r
->in
.resume_handle
= NULL
;
17902 if (r
->in
.resume_handle
) {
17903 _mem_save_resume_handle_0
= NDR_PULL_GET_MEM_CTX(ndr
);
17904 NDR_PULL_SET_MEM_CTX(ndr
, r
->in
.resume_handle
, 0);
17905 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, r
->in
.resume_handle
));
17906 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_resume_handle_0
, 0);
17908 NDR_PULL_ALLOC(ndr
, r
->out
.info_ctr
);
17909 *r
->out
.info_ctr
= *r
->in
.info_ctr
;
17910 NDR_PULL_ALLOC(ndr
, r
->out
.totalentries
);
17911 ZERO_STRUCTP(r
->out
.totalentries
);
17913 if (flags
& NDR_OUT
) {
17914 if (ndr
->flags
& LIBNDR_FLAG_REF_ALLOC
) {
17915 NDR_PULL_ALLOC(ndr
, r
->out
.info_ctr
);
17917 _mem_save_info_ctr_0
= NDR_PULL_GET_MEM_CTX(ndr
);
17918 NDR_PULL_SET_MEM_CTX(ndr
, r
->out
.info_ctr
, LIBNDR_FLAG_REF_ALLOC
);
17919 NDR_CHECK(ndr_pull_srvsvc_NetShareInfoCtr(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->out
.info_ctr
));
17920 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_info_ctr_0
, LIBNDR_FLAG_REF_ALLOC
);
17921 if (ndr
->flags
& LIBNDR_FLAG_REF_ALLOC
) {
17922 NDR_PULL_ALLOC(ndr
, r
->out
.totalentries
);
17924 _mem_save_totalentries_0
= NDR_PULL_GET_MEM_CTX(ndr
);
17925 NDR_PULL_SET_MEM_CTX(ndr
, r
->out
.totalentries
, LIBNDR_FLAG_REF_ALLOC
);
17926 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, r
->out
.totalentries
));
17927 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_totalentries_0
, LIBNDR_FLAG_REF_ALLOC
);
17928 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_resume_handle
));
17929 if (_ptr_resume_handle
) {
17930 NDR_PULL_ALLOC(ndr
, r
->out
.resume_handle
);
17932 r
->out
.resume_handle
= NULL
;
17934 if (r
->out
.resume_handle
) {
17935 _mem_save_resume_handle_0
= NDR_PULL_GET_MEM_CTX(ndr
);
17936 NDR_PULL_SET_MEM_CTX(ndr
, r
->out
.resume_handle
, 0);
17937 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, r
->out
.resume_handle
));
17938 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_resume_handle_0
, 0);
17940 NDR_CHECK(ndr_pull_WERROR(ndr
, NDR_SCALARS
, &r
->out
.result
));
17942 return NDR_ERR_SUCCESS
;
17945 _PUBLIC_
void ndr_print_srvsvc_NetShareEnum(struct ndr_print
*ndr
, const char *name
, int flags
, const struct srvsvc_NetShareEnum
*r
)
17947 ndr_print_struct(ndr
, name
, "srvsvc_NetShareEnum");
17949 if (flags
& NDR_SET_VALUES
) {
17950 ndr
->flags
|= LIBNDR_PRINT_SET_VALUES
;
17952 if (flags
& NDR_IN
) {
17953 ndr_print_struct(ndr
, "in", "srvsvc_NetShareEnum");
17955 ndr_print_ptr(ndr
, "server_unc", r
->in
.server_unc
);
17957 if (r
->in
.server_unc
) {
17958 ndr_print_string(ndr
, "server_unc", r
->in
.server_unc
);
17961 ndr_print_ptr(ndr
, "info_ctr", r
->in
.info_ctr
);
17963 ndr_print_srvsvc_NetShareInfoCtr(ndr
, "info_ctr", r
->in
.info_ctr
);
17965 ndr_print_uint32(ndr
, "max_buffer", r
->in
.max_buffer
);
17966 ndr_print_ptr(ndr
, "resume_handle", r
->in
.resume_handle
);
17968 if (r
->in
.resume_handle
) {
17969 ndr_print_uint32(ndr
, "resume_handle", *r
->in
.resume_handle
);
17974 if (flags
& NDR_OUT
) {
17975 ndr_print_struct(ndr
, "out", "srvsvc_NetShareEnum");
17977 ndr_print_ptr(ndr
, "info_ctr", r
->out
.info_ctr
);
17979 ndr_print_srvsvc_NetShareInfoCtr(ndr
, "info_ctr", r
->out
.info_ctr
);
17981 ndr_print_ptr(ndr
, "totalentries", r
->out
.totalentries
);
17983 ndr_print_uint32(ndr
, "totalentries", *r
->out
.totalentries
);
17985 ndr_print_ptr(ndr
, "resume_handle", r
->out
.resume_handle
);
17987 if (r
->out
.resume_handle
) {
17988 ndr_print_uint32(ndr
, "resume_handle", *r
->out
.resume_handle
);
17991 ndr_print_WERROR(ndr
, "result", r
->out
.result
);
17997 static enum ndr_err_code
ndr_push_srvsvc_NetShareDelStart(struct ndr_push
*ndr
, int flags
, const struct srvsvc_NetShareDelStart
*r
)
17999 if (flags
& NDR_IN
) {
18000 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->in
.server_unc
));
18001 if (r
->in
.server_unc
) {
18002 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.server_unc
, CH_UTF16
)));
18003 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
18004 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.server_unc
, CH_UTF16
)));
18005 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
));
18007 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.share
, CH_UTF16
)));
18008 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
18009 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.share
, CH_UTF16
)));
18010 NDR_CHECK(ndr_push_charset(ndr
, NDR_SCALARS
, r
->in
.share
, ndr_charset_length(r
->in
.share
, CH_UTF16
), sizeof(uint16_t), CH_UTF16
));
18011 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->in
.reserved
));
18013 if (flags
& NDR_OUT
) {
18014 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->out
.hnd
));
18016 NDR_CHECK(ndr_push_policy_handle(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->out
.hnd
));
18018 NDR_CHECK(ndr_push_WERROR(ndr
, NDR_SCALARS
, r
->out
.result
));
18020 return NDR_ERR_SUCCESS
;
18023 static enum ndr_err_code
ndr_pull_srvsvc_NetShareDelStart(struct ndr_pull
*ndr
, int flags
, struct srvsvc_NetShareDelStart
*r
)
18025 uint32_t _ptr_server_unc
;
18027 TALLOC_CTX
*_mem_save_server_unc_0
;
18028 TALLOC_CTX
*_mem_save_hnd_0
;
18029 if (flags
& NDR_IN
) {
18030 ZERO_STRUCT(r
->out
);
18032 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_server_unc
));
18033 if (_ptr_server_unc
) {
18034 NDR_PULL_ALLOC(ndr
, r
->in
.server_unc
);
18036 r
->in
.server_unc
= NULL
;
18038 if (r
->in
.server_unc
) {
18039 _mem_save_server_unc_0
= NDR_PULL_GET_MEM_CTX(ndr
);
18040 NDR_PULL_SET_MEM_CTX(ndr
, r
->in
.server_unc
, 0);
18041 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->in
.server_unc
));
18042 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->in
.server_unc
));
18043 if (ndr_get_array_length(ndr
, &r
->in
.server_unc
) > ndr_get_array_size(ndr
, &r
->in
.server_unc
)) {
18044 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", ndr_get_array_size(ndr
, &r
->in
.server_unc
), ndr_get_array_length(ndr
, &r
->in
.server_unc
));
18046 NDR_CHECK(ndr_check_string_terminator(ndr
, ndr_get_array_length(ndr
, &r
->in
.server_unc
), sizeof(uint16_t)));
18047 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->in
.server_unc
, ndr_get_array_length(ndr
, &r
->in
.server_unc
), sizeof(uint16_t), CH_UTF16
));
18048 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_server_unc_0
, 0);
18050 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->in
.share
));
18051 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->in
.share
));
18052 if (ndr_get_array_length(ndr
, &r
->in
.share
) > ndr_get_array_size(ndr
, &r
->in
.share
)) {
18053 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", ndr_get_array_size(ndr
, &r
->in
.share
), ndr_get_array_length(ndr
, &r
->in
.share
));
18055 NDR_CHECK(ndr_check_string_terminator(ndr
, ndr_get_array_length(ndr
, &r
->in
.share
), sizeof(uint16_t)));
18056 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->in
.share
, ndr_get_array_length(ndr
, &r
->in
.share
), sizeof(uint16_t), CH_UTF16
));
18057 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->in
.reserved
));
18059 if (flags
& NDR_OUT
) {
18060 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_hnd
));
18062 NDR_PULL_ALLOC(ndr
, r
->out
.hnd
);
18067 _mem_save_hnd_0
= NDR_PULL_GET_MEM_CTX(ndr
);
18068 NDR_PULL_SET_MEM_CTX(ndr
, r
->out
.hnd
, 0);
18069 NDR_CHECK(ndr_pull_policy_handle(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->out
.hnd
));
18070 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_hnd_0
, 0);
18072 NDR_CHECK(ndr_pull_WERROR(ndr
, NDR_SCALARS
, &r
->out
.result
));
18074 return NDR_ERR_SUCCESS
;
18077 _PUBLIC_
void ndr_print_srvsvc_NetShareDelStart(struct ndr_print
*ndr
, const char *name
, int flags
, const struct srvsvc_NetShareDelStart
*r
)
18079 ndr_print_struct(ndr
, name
, "srvsvc_NetShareDelStart");
18081 if (flags
& NDR_SET_VALUES
) {
18082 ndr
->flags
|= LIBNDR_PRINT_SET_VALUES
;
18084 if (flags
& NDR_IN
) {
18085 ndr_print_struct(ndr
, "in", "srvsvc_NetShareDelStart");
18087 ndr_print_ptr(ndr
, "server_unc", r
->in
.server_unc
);
18089 if (r
->in
.server_unc
) {
18090 ndr_print_string(ndr
, "server_unc", r
->in
.server_unc
);
18093 ndr_print_string(ndr
, "share", r
->in
.share
);
18094 ndr_print_uint32(ndr
, "reserved", r
->in
.reserved
);
18097 if (flags
& NDR_OUT
) {
18098 ndr_print_struct(ndr
, "out", "srvsvc_NetShareDelStart");
18100 ndr_print_ptr(ndr
, "hnd", r
->out
.hnd
);
18103 ndr_print_policy_handle(ndr
, "hnd", r
->out
.hnd
);
18106 ndr_print_WERROR(ndr
, "result", r
->out
.result
);
18112 static enum ndr_err_code
ndr_push_srvsvc_NetShareDelCommit(struct ndr_push
*ndr
, int flags
, const struct srvsvc_NetShareDelCommit
*r
)
18114 if (flags
& NDR_IN
) {
18115 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->in
.hnd
));
18117 NDR_CHECK(ndr_push_policy_handle(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->in
.hnd
));
18120 if (flags
& NDR_OUT
) {
18121 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->out
.hnd
));
18123 NDR_CHECK(ndr_push_policy_handle(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->out
.hnd
));
18125 NDR_CHECK(ndr_push_WERROR(ndr
, NDR_SCALARS
, r
->out
.result
));
18127 return NDR_ERR_SUCCESS
;
18130 static enum ndr_err_code
ndr_pull_srvsvc_NetShareDelCommit(struct ndr_pull
*ndr
, int flags
, struct srvsvc_NetShareDelCommit
*r
)
18133 TALLOC_CTX
*_mem_save_hnd_0
;
18134 if (flags
& NDR_IN
) {
18135 ZERO_STRUCT(r
->out
);
18137 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_hnd
));
18139 NDR_PULL_ALLOC(ndr
, r
->in
.hnd
);
18144 _mem_save_hnd_0
= NDR_PULL_GET_MEM_CTX(ndr
);
18145 NDR_PULL_SET_MEM_CTX(ndr
, r
->in
.hnd
, 0);
18146 NDR_CHECK(ndr_pull_policy_handle(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->in
.hnd
));
18147 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_hnd_0
, 0);
18150 if (flags
& NDR_OUT
) {
18151 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_hnd
));
18153 NDR_PULL_ALLOC(ndr
, r
->out
.hnd
);
18158 _mem_save_hnd_0
= NDR_PULL_GET_MEM_CTX(ndr
);
18159 NDR_PULL_SET_MEM_CTX(ndr
, r
->out
.hnd
, 0);
18160 NDR_CHECK(ndr_pull_policy_handle(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->out
.hnd
));
18161 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_hnd_0
, 0);
18163 NDR_CHECK(ndr_pull_WERROR(ndr
, NDR_SCALARS
, &r
->out
.result
));
18165 return NDR_ERR_SUCCESS
;
18168 _PUBLIC_
void ndr_print_srvsvc_NetShareDelCommit(struct ndr_print
*ndr
, const char *name
, int flags
, const struct srvsvc_NetShareDelCommit
*r
)
18170 ndr_print_struct(ndr
, name
, "srvsvc_NetShareDelCommit");
18172 if (flags
& NDR_SET_VALUES
) {
18173 ndr
->flags
|= LIBNDR_PRINT_SET_VALUES
;
18175 if (flags
& NDR_IN
) {
18176 ndr_print_struct(ndr
, "in", "srvsvc_NetShareDelCommit");
18178 ndr_print_ptr(ndr
, "hnd", r
->in
.hnd
);
18181 ndr_print_policy_handle(ndr
, "hnd", r
->in
.hnd
);
18186 if (flags
& NDR_OUT
) {
18187 ndr_print_struct(ndr
, "out", "srvsvc_NetShareDelCommit");
18189 ndr_print_ptr(ndr
, "hnd", r
->out
.hnd
);
18192 ndr_print_policy_handle(ndr
, "hnd", r
->out
.hnd
);
18195 ndr_print_WERROR(ndr
, "result", r
->out
.result
);
18201 static enum ndr_err_code
ndr_push_srvsvc_NetGetFileSecurity(struct ndr_push
*ndr
, int flags
, const struct srvsvc_NetGetFileSecurity
*r
)
18203 if (flags
& NDR_IN
) {
18204 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->in
.server_unc
));
18205 if (r
->in
.server_unc
) {
18206 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.server_unc
, CH_UTF16
)));
18207 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
18208 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.server_unc
, CH_UTF16
)));
18209 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
));
18211 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->in
.share
));
18213 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.share
, CH_UTF16
)));
18214 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
18215 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.share
, CH_UTF16
)));
18216 NDR_CHECK(ndr_push_charset(ndr
, NDR_SCALARS
, r
->in
.share
, ndr_charset_length(r
->in
.share
, CH_UTF16
), sizeof(uint16_t), CH_UTF16
));
18218 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.file
, CH_UTF16
)));
18219 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
18220 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.file
, CH_UTF16
)));
18221 NDR_CHECK(ndr_push_charset(ndr
, NDR_SCALARS
, r
->in
.file
, ndr_charset_length(r
->in
.file
, CH_UTF16
), sizeof(uint16_t), CH_UTF16
));
18222 NDR_CHECK(ndr_push_security_secinfo(ndr
, NDR_SCALARS
, r
->in
.securityinformation
));
18224 if (flags
& NDR_OUT
) {
18225 if (r
->out
.sd_buf
== NULL
) {
18226 return ndr_push_error(ndr
, NDR_ERR_INVALID_POINTER
, "NULL [ref] pointer");
18228 NDR_CHECK(ndr_push_unique_ptr(ndr
, *r
->out
.sd_buf
));
18229 if (*r
->out
.sd_buf
) {
18230 NDR_CHECK(ndr_push_sec_desc_buf(ndr
, NDR_SCALARS
|NDR_BUFFERS
, *r
->out
.sd_buf
));
18232 NDR_CHECK(ndr_push_WERROR(ndr
, NDR_SCALARS
, r
->out
.result
));
18234 return NDR_ERR_SUCCESS
;
18237 static enum ndr_err_code
ndr_pull_srvsvc_NetGetFileSecurity(struct ndr_pull
*ndr
, int flags
, struct srvsvc_NetGetFileSecurity
*r
)
18239 uint32_t _ptr_server_unc
;
18240 uint32_t _ptr_share
;
18241 uint32_t _ptr_sd_buf
;
18242 TALLOC_CTX
*_mem_save_server_unc_0
;
18243 TALLOC_CTX
*_mem_save_share_0
;
18244 TALLOC_CTX
*_mem_save_sd_buf_0
;
18245 TALLOC_CTX
*_mem_save_sd_buf_1
;
18246 if (flags
& NDR_IN
) {
18247 ZERO_STRUCT(r
->out
);
18249 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_server_unc
));
18250 if (_ptr_server_unc
) {
18251 NDR_PULL_ALLOC(ndr
, r
->in
.server_unc
);
18253 r
->in
.server_unc
= NULL
;
18255 if (r
->in
.server_unc
) {
18256 _mem_save_server_unc_0
= NDR_PULL_GET_MEM_CTX(ndr
);
18257 NDR_PULL_SET_MEM_CTX(ndr
, r
->in
.server_unc
, 0);
18258 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->in
.server_unc
));
18259 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->in
.server_unc
));
18260 if (ndr_get_array_length(ndr
, &r
->in
.server_unc
) > ndr_get_array_size(ndr
, &r
->in
.server_unc
)) {
18261 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", ndr_get_array_size(ndr
, &r
->in
.server_unc
), ndr_get_array_length(ndr
, &r
->in
.server_unc
));
18263 NDR_CHECK(ndr_check_string_terminator(ndr
, ndr_get_array_length(ndr
, &r
->in
.server_unc
), sizeof(uint16_t)));
18264 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->in
.server_unc
, ndr_get_array_length(ndr
, &r
->in
.server_unc
), sizeof(uint16_t), CH_UTF16
));
18265 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_server_unc_0
, 0);
18267 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_share
));
18269 NDR_PULL_ALLOC(ndr
, r
->in
.share
);
18271 r
->in
.share
= NULL
;
18274 _mem_save_share_0
= NDR_PULL_GET_MEM_CTX(ndr
);
18275 NDR_PULL_SET_MEM_CTX(ndr
, r
->in
.share
, 0);
18276 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->in
.share
));
18277 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->in
.share
));
18278 if (ndr_get_array_length(ndr
, &r
->in
.share
) > ndr_get_array_size(ndr
, &r
->in
.share
)) {
18279 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", ndr_get_array_size(ndr
, &r
->in
.share
), ndr_get_array_length(ndr
, &r
->in
.share
));
18281 NDR_CHECK(ndr_check_string_terminator(ndr
, ndr_get_array_length(ndr
, &r
->in
.share
), sizeof(uint16_t)));
18282 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->in
.share
, ndr_get_array_length(ndr
, &r
->in
.share
), sizeof(uint16_t), CH_UTF16
));
18283 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_share_0
, 0);
18285 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->in
.file
));
18286 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->in
.file
));
18287 if (ndr_get_array_length(ndr
, &r
->in
.file
) > ndr_get_array_size(ndr
, &r
->in
.file
)) {
18288 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", ndr_get_array_size(ndr
, &r
->in
.file
), ndr_get_array_length(ndr
, &r
->in
.file
));
18290 NDR_CHECK(ndr_check_string_terminator(ndr
, ndr_get_array_length(ndr
, &r
->in
.file
), sizeof(uint16_t)));
18291 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->in
.file
, ndr_get_array_length(ndr
, &r
->in
.file
), sizeof(uint16_t), CH_UTF16
));
18292 NDR_CHECK(ndr_pull_security_secinfo(ndr
, NDR_SCALARS
, &r
->in
.securityinformation
));
18293 NDR_PULL_ALLOC(ndr
, r
->out
.sd_buf
);
18294 ZERO_STRUCTP(r
->out
.sd_buf
);
18296 if (flags
& NDR_OUT
) {
18297 if (ndr
->flags
& LIBNDR_FLAG_REF_ALLOC
) {
18298 NDR_PULL_ALLOC(ndr
, r
->out
.sd_buf
);
18300 _mem_save_sd_buf_0
= NDR_PULL_GET_MEM_CTX(ndr
);
18301 NDR_PULL_SET_MEM_CTX(ndr
, r
->out
.sd_buf
, LIBNDR_FLAG_REF_ALLOC
);
18302 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_sd_buf
));
18304 NDR_PULL_ALLOC(ndr
, *r
->out
.sd_buf
);
18306 *r
->out
.sd_buf
= NULL
;
18308 if (*r
->out
.sd_buf
) {
18309 _mem_save_sd_buf_1
= NDR_PULL_GET_MEM_CTX(ndr
);
18310 NDR_PULL_SET_MEM_CTX(ndr
, *r
->out
.sd_buf
, 0);
18311 NDR_CHECK(ndr_pull_sec_desc_buf(ndr
, NDR_SCALARS
|NDR_BUFFERS
, *r
->out
.sd_buf
));
18312 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_sd_buf_1
, 0);
18314 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_sd_buf_0
, LIBNDR_FLAG_REF_ALLOC
);
18315 NDR_CHECK(ndr_pull_WERROR(ndr
, NDR_SCALARS
, &r
->out
.result
));
18317 return NDR_ERR_SUCCESS
;
18320 _PUBLIC_
void ndr_print_srvsvc_NetGetFileSecurity(struct ndr_print
*ndr
, const char *name
, int flags
, const struct srvsvc_NetGetFileSecurity
*r
)
18322 ndr_print_struct(ndr
, name
, "srvsvc_NetGetFileSecurity");
18324 if (flags
& NDR_SET_VALUES
) {
18325 ndr
->flags
|= LIBNDR_PRINT_SET_VALUES
;
18327 if (flags
& NDR_IN
) {
18328 ndr_print_struct(ndr
, "in", "srvsvc_NetGetFileSecurity");
18330 ndr_print_ptr(ndr
, "server_unc", r
->in
.server_unc
);
18332 if (r
->in
.server_unc
) {
18333 ndr_print_string(ndr
, "server_unc", r
->in
.server_unc
);
18336 ndr_print_ptr(ndr
, "share", r
->in
.share
);
18339 ndr_print_string(ndr
, "share", r
->in
.share
);
18342 ndr_print_string(ndr
, "file", r
->in
.file
);
18343 ndr_print_security_secinfo(ndr
, "securityinformation", r
->in
.securityinformation
);
18346 if (flags
& NDR_OUT
) {
18347 ndr_print_struct(ndr
, "out", "srvsvc_NetGetFileSecurity");
18349 ndr_print_ptr(ndr
, "sd_buf", r
->out
.sd_buf
);
18351 ndr_print_ptr(ndr
, "sd_buf", *r
->out
.sd_buf
);
18353 if (*r
->out
.sd_buf
) {
18354 ndr_print_sec_desc_buf(ndr
, "sd_buf", *r
->out
.sd_buf
);
18358 ndr_print_WERROR(ndr
, "result", r
->out
.result
);
18364 static enum ndr_err_code
ndr_push_srvsvc_NetSetFileSecurity(struct ndr_push
*ndr
, int flags
, const struct srvsvc_NetSetFileSecurity
*r
)
18366 if (flags
& NDR_IN
) {
18367 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->in
.server_unc
));
18368 if (r
->in
.server_unc
) {
18369 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.server_unc
, CH_UTF16
)));
18370 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
18371 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.server_unc
, CH_UTF16
)));
18372 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
));
18374 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->in
.share
));
18376 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.share
, CH_UTF16
)));
18377 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
18378 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.share
, CH_UTF16
)));
18379 NDR_CHECK(ndr_push_charset(ndr
, NDR_SCALARS
, r
->in
.share
, ndr_charset_length(r
->in
.share
, CH_UTF16
), sizeof(uint16_t), CH_UTF16
));
18381 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.file
, CH_UTF16
)));
18382 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
18383 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.file
, CH_UTF16
)));
18384 NDR_CHECK(ndr_push_charset(ndr
, NDR_SCALARS
, r
->in
.file
, ndr_charset_length(r
->in
.file
, CH_UTF16
), sizeof(uint16_t), CH_UTF16
));
18385 NDR_CHECK(ndr_push_security_secinfo(ndr
, NDR_SCALARS
, r
->in
.securityinformation
));
18386 if (r
->in
.sd_buf
== NULL
) {
18387 return ndr_push_error(ndr
, NDR_ERR_INVALID_POINTER
, "NULL [ref] pointer");
18389 NDR_CHECK(ndr_push_sec_desc_buf(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->in
.sd_buf
));
18391 if (flags
& NDR_OUT
) {
18392 NDR_CHECK(ndr_push_WERROR(ndr
, NDR_SCALARS
, r
->out
.result
));
18394 return NDR_ERR_SUCCESS
;
18397 static enum ndr_err_code
ndr_pull_srvsvc_NetSetFileSecurity(struct ndr_pull
*ndr
, int flags
, struct srvsvc_NetSetFileSecurity
*r
)
18399 uint32_t _ptr_server_unc
;
18400 uint32_t _ptr_share
;
18401 TALLOC_CTX
*_mem_save_server_unc_0
;
18402 TALLOC_CTX
*_mem_save_share_0
;
18403 TALLOC_CTX
*_mem_save_sd_buf_0
;
18404 if (flags
& NDR_IN
) {
18405 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_server_unc
));
18406 if (_ptr_server_unc
) {
18407 NDR_PULL_ALLOC(ndr
, r
->in
.server_unc
);
18409 r
->in
.server_unc
= NULL
;
18411 if (r
->in
.server_unc
) {
18412 _mem_save_server_unc_0
= NDR_PULL_GET_MEM_CTX(ndr
);
18413 NDR_PULL_SET_MEM_CTX(ndr
, r
->in
.server_unc
, 0);
18414 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->in
.server_unc
));
18415 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->in
.server_unc
));
18416 if (ndr_get_array_length(ndr
, &r
->in
.server_unc
) > ndr_get_array_size(ndr
, &r
->in
.server_unc
)) {
18417 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", ndr_get_array_size(ndr
, &r
->in
.server_unc
), ndr_get_array_length(ndr
, &r
->in
.server_unc
));
18419 NDR_CHECK(ndr_check_string_terminator(ndr
, ndr_get_array_length(ndr
, &r
->in
.server_unc
), sizeof(uint16_t)));
18420 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->in
.server_unc
, ndr_get_array_length(ndr
, &r
->in
.server_unc
), sizeof(uint16_t), CH_UTF16
));
18421 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_server_unc_0
, 0);
18423 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_share
));
18425 NDR_PULL_ALLOC(ndr
, r
->in
.share
);
18427 r
->in
.share
= NULL
;
18430 _mem_save_share_0
= NDR_PULL_GET_MEM_CTX(ndr
);
18431 NDR_PULL_SET_MEM_CTX(ndr
, r
->in
.share
, 0);
18432 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->in
.share
));
18433 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->in
.share
));
18434 if (ndr_get_array_length(ndr
, &r
->in
.share
) > ndr_get_array_size(ndr
, &r
->in
.share
)) {
18435 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", ndr_get_array_size(ndr
, &r
->in
.share
), ndr_get_array_length(ndr
, &r
->in
.share
));
18437 NDR_CHECK(ndr_check_string_terminator(ndr
, ndr_get_array_length(ndr
, &r
->in
.share
), sizeof(uint16_t)));
18438 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->in
.share
, ndr_get_array_length(ndr
, &r
->in
.share
), sizeof(uint16_t), CH_UTF16
));
18439 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_share_0
, 0);
18441 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->in
.file
));
18442 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->in
.file
));
18443 if (ndr_get_array_length(ndr
, &r
->in
.file
) > ndr_get_array_size(ndr
, &r
->in
.file
)) {
18444 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", ndr_get_array_size(ndr
, &r
->in
.file
), ndr_get_array_length(ndr
, &r
->in
.file
));
18446 NDR_CHECK(ndr_check_string_terminator(ndr
, ndr_get_array_length(ndr
, &r
->in
.file
), sizeof(uint16_t)));
18447 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->in
.file
, ndr_get_array_length(ndr
, &r
->in
.file
), sizeof(uint16_t), CH_UTF16
));
18448 NDR_CHECK(ndr_pull_security_secinfo(ndr
, NDR_SCALARS
, &r
->in
.securityinformation
));
18449 if (ndr
->flags
& LIBNDR_FLAG_REF_ALLOC
) {
18450 NDR_PULL_ALLOC(ndr
, r
->in
.sd_buf
);
18452 _mem_save_sd_buf_0
= NDR_PULL_GET_MEM_CTX(ndr
);
18453 NDR_PULL_SET_MEM_CTX(ndr
, r
->in
.sd_buf
, LIBNDR_FLAG_REF_ALLOC
);
18454 NDR_CHECK(ndr_pull_sec_desc_buf(ndr
, NDR_SCALARS
|NDR_BUFFERS
, r
->in
.sd_buf
));
18455 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_sd_buf_0
, LIBNDR_FLAG_REF_ALLOC
);
18457 if (flags
& NDR_OUT
) {
18458 NDR_CHECK(ndr_pull_WERROR(ndr
, NDR_SCALARS
, &r
->out
.result
));
18460 return NDR_ERR_SUCCESS
;
18463 _PUBLIC_
void ndr_print_srvsvc_NetSetFileSecurity(struct ndr_print
*ndr
, const char *name
, int flags
, const struct srvsvc_NetSetFileSecurity
*r
)
18465 ndr_print_struct(ndr
, name
, "srvsvc_NetSetFileSecurity");
18467 if (flags
& NDR_SET_VALUES
) {
18468 ndr
->flags
|= LIBNDR_PRINT_SET_VALUES
;
18470 if (flags
& NDR_IN
) {
18471 ndr_print_struct(ndr
, "in", "srvsvc_NetSetFileSecurity");
18473 ndr_print_ptr(ndr
, "server_unc", r
->in
.server_unc
);
18475 if (r
->in
.server_unc
) {
18476 ndr_print_string(ndr
, "server_unc", r
->in
.server_unc
);
18479 ndr_print_ptr(ndr
, "share", r
->in
.share
);
18482 ndr_print_string(ndr
, "share", r
->in
.share
);
18485 ndr_print_string(ndr
, "file", r
->in
.file
);
18486 ndr_print_security_secinfo(ndr
, "securityinformation", r
->in
.securityinformation
);
18487 ndr_print_ptr(ndr
, "sd_buf", r
->in
.sd_buf
);
18489 ndr_print_sec_desc_buf(ndr
, "sd_buf", r
->in
.sd_buf
);
18493 if (flags
& NDR_OUT
) {
18494 ndr_print_struct(ndr
, "out", "srvsvc_NetSetFileSecurity");
18496 ndr_print_WERROR(ndr
, "result", r
->out
.result
);
18502 static enum ndr_err_code
ndr_push_srvsvc_NetServerTransportAddEx(struct ndr_push
*ndr
, int flags
, const struct srvsvc_NetServerTransportAddEx
*r
)
18504 if (flags
& NDR_IN
) {
18505 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->in
.server_unc
));
18506 if (r
->in
.server_unc
) {
18507 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.server_unc
, CH_UTF16
)));
18508 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
18509 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.server_unc
, CH_UTF16
)));
18510 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
));
18512 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->in
.level
));
18513 NDR_CHECK(ndr_push_set_switch_value(ndr
, &r
->in
.info
, r
->in
.level
));
18514 NDR_CHECK(ndr_push_srvsvc_NetTransportInfo(ndr
, NDR_SCALARS
|NDR_BUFFERS
, &r
->in
.info
));
18516 if (flags
& NDR_OUT
) {
18517 NDR_CHECK(ndr_push_WERROR(ndr
, NDR_SCALARS
, r
->out
.result
));
18519 return NDR_ERR_SUCCESS
;
18522 static enum ndr_err_code
ndr_pull_srvsvc_NetServerTransportAddEx(struct ndr_pull
*ndr
, int flags
, struct srvsvc_NetServerTransportAddEx
*r
)
18524 uint32_t _ptr_server_unc
;
18525 TALLOC_CTX
*_mem_save_server_unc_0
;
18526 if (flags
& NDR_IN
) {
18527 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_server_unc
));
18528 if (_ptr_server_unc
) {
18529 NDR_PULL_ALLOC(ndr
, r
->in
.server_unc
);
18531 r
->in
.server_unc
= NULL
;
18533 if (r
->in
.server_unc
) {
18534 _mem_save_server_unc_0
= NDR_PULL_GET_MEM_CTX(ndr
);
18535 NDR_PULL_SET_MEM_CTX(ndr
, r
->in
.server_unc
, 0);
18536 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->in
.server_unc
));
18537 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->in
.server_unc
));
18538 if (ndr_get_array_length(ndr
, &r
->in
.server_unc
) > ndr_get_array_size(ndr
, &r
->in
.server_unc
)) {
18539 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", ndr_get_array_size(ndr
, &r
->in
.server_unc
), ndr_get_array_length(ndr
, &r
->in
.server_unc
));
18541 NDR_CHECK(ndr_check_string_terminator(ndr
, ndr_get_array_length(ndr
, &r
->in
.server_unc
), sizeof(uint16_t)));
18542 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->in
.server_unc
, ndr_get_array_length(ndr
, &r
->in
.server_unc
), sizeof(uint16_t), CH_UTF16
));
18543 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_server_unc_0
, 0);
18545 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->in
.level
));
18546 NDR_CHECK(ndr_pull_set_switch_value(ndr
, &r
->in
.info
, r
->in
.level
));
18547 NDR_CHECK(ndr_pull_srvsvc_NetTransportInfo(ndr
, NDR_SCALARS
|NDR_BUFFERS
, &r
->in
.info
));
18549 if (flags
& NDR_OUT
) {
18550 NDR_CHECK(ndr_pull_WERROR(ndr
, NDR_SCALARS
, &r
->out
.result
));
18552 return NDR_ERR_SUCCESS
;
18555 _PUBLIC_
void ndr_print_srvsvc_NetServerTransportAddEx(struct ndr_print
*ndr
, const char *name
, int flags
, const struct srvsvc_NetServerTransportAddEx
*r
)
18557 ndr_print_struct(ndr
, name
, "srvsvc_NetServerTransportAddEx");
18559 if (flags
& NDR_SET_VALUES
) {
18560 ndr
->flags
|= LIBNDR_PRINT_SET_VALUES
;
18562 if (flags
& NDR_IN
) {
18563 ndr_print_struct(ndr
, "in", "srvsvc_NetServerTransportAddEx");
18565 ndr_print_ptr(ndr
, "server_unc", r
->in
.server_unc
);
18567 if (r
->in
.server_unc
) {
18568 ndr_print_string(ndr
, "server_unc", r
->in
.server_unc
);
18571 ndr_print_uint32(ndr
, "level", r
->in
.level
);
18572 ndr_print_set_switch_value(ndr
, &r
->in
.info
, r
->in
.level
);
18573 ndr_print_srvsvc_NetTransportInfo(ndr
, "info", &r
->in
.info
);
18576 if (flags
& NDR_OUT
) {
18577 ndr_print_struct(ndr
, "out", "srvsvc_NetServerTransportAddEx");
18579 ndr_print_WERROR(ndr
, "result", r
->out
.result
);
18585 static enum ndr_err_code
ndr_push_srvsvc_NetServerSetServiceBitsEx(struct ndr_push
*ndr
, int flags
, const struct srvsvc_NetServerSetServiceBitsEx
*r
)
18587 if (flags
& NDR_IN
) {
18588 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->in
.server_unc
));
18589 if (r
->in
.server_unc
) {
18590 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.server_unc
, CH_UTF16
)));
18591 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
18592 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.server_unc
, CH_UTF16
)));
18593 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
));
18595 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->in
.emulated_server_unc
));
18596 if (r
->in
.emulated_server_unc
) {
18597 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.emulated_server_unc
, CH_UTF16
)));
18598 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
18599 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.emulated_server_unc
, CH_UTF16
)));
18600 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
));
18602 NDR_CHECK(ndr_push_unique_ptr(ndr
, r
->in
.transport
));
18603 if (r
->in
.transport
) {
18604 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.transport
, CH_UTF16
)));
18605 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, 0));
18606 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, ndr_charset_length(r
->in
.transport
, CH_UTF16
)));
18607 NDR_CHECK(ndr_push_charset(ndr
, NDR_SCALARS
, r
->in
.transport
, ndr_charset_length(r
->in
.transport
, CH_UTF16
), sizeof(uint16_t), CH_UTF16
));
18609 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->in
.servicebitsofinterest
));
18610 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->in
.servicebits
));
18611 NDR_CHECK(ndr_push_uint32(ndr
, NDR_SCALARS
, r
->in
.updateimmediately
));
18613 if (flags
& NDR_OUT
) {
18614 NDR_CHECK(ndr_push_WERROR(ndr
, NDR_SCALARS
, r
->out
.result
));
18616 return NDR_ERR_SUCCESS
;
18619 static enum ndr_err_code
ndr_pull_srvsvc_NetServerSetServiceBitsEx(struct ndr_pull
*ndr
, int flags
, struct srvsvc_NetServerSetServiceBitsEx
*r
)
18621 uint32_t _ptr_server_unc
;
18622 uint32_t _ptr_emulated_server_unc
;
18623 uint32_t _ptr_transport
;
18624 TALLOC_CTX
*_mem_save_server_unc_0
;
18625 TALLOC_CTX
*_mem_save_emulated_server_unc_0
;
18626 TALLOC_CTX
*_mem_save_transport_0
;
18627 if (flags
& NDR_IN
) {
18628 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_server_unc
));
18629 if (_ptr_server_unc
) {
18630 NDR_PULL_ALLOC(ndr
, r
->in
.server_unc
);
18632 r
->in
.server_unc
= NULL
;
18634 if (r
->in
.server_unc
) {
18635 _mem_save_server_unc_0
= NDR_PULL_GET_MEM_CTX(ndr
);
18636 NDR_PULL_SET_MEM_CTX(ndr
, r
->in
.server_unc
, 0);
18637 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->in
.server_unc
));
18638 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->in
.server_unc
));
18639 if (ndr_get_array_length(ndr
, &r
->in
.server_unc
) > ndr_get_array_size(ndr
, &r
->in
.server_unc
)) {
18640 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", ndr_get_array_size(ndr
, &r
->in
.server_unc
), ndr_get_array_length(ndr
, &r
->in
.server_unc
));
18642 NDR_CHECK(ndr_check_string_terminator(ndr
, ndr_get_array_length(ndr
, &r
->in
.server_unc
), sizeof(uint16_t)));
18643 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->in
.server_unc
, ndr_get_array_length(ndr
, &r
->in
.server_unc
), sizeof(uint16_t), CH_UTF16
));
18644 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_server_unc_0
, 0);
18646 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_emulated_server_unc
));
18647 if (_ptr_emulated_server_unc
) {
18648 NDR_PULL_ALLOC(ndr
, r
->in
.emulated_server_unc
);
18650 r
->in
.emulated_server_unc
= NULL
;
18652 if (r
->in
.emulated_server_unc
) {
18653 _mem_save_emulated_server_unc_0
= NDR_PULL_GET_MEM_CTX(ndr
);
18654 NDR_PULL_SET_MEM_CTX(ndr
, r
->in
.emulated_server_unc
, 0);
18655 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->in
.emulated_server_unc
));
18656 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->in
.emulated_server_unc
));
18657 if (ndr_get_array_length(ndr
, &r
->in
.emulated_server_unc
) > ndr_get_array_size(ndr
, &r
->in
.emulated_server_unc
)) {
18658 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", ndr_get_array_size(ndr
, &r
->in
.emulated_server_unc
), ndr_get_array_length(ndr
, &r
->in
.emulated_server_unc
));
18660 NDR_CHECK(ndr_check_string_terminator(ndr
, ndr_get_array_length(ndr
, &r
->in
.emulated_server_unc
), sizeof(uint16_t)));
18661 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->in
.emulated_server_unc
, ndr_get_array_length(ndr
, &r
->in
.emulated_server_unc
), sizeof(uint16_t), CH_UTF16
));
18662 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_emulated_server_unc_0
, 0);
18664 NDR_CHECK(ndr_pull_generic_ptr(ndr
, &_ptr_transport
));
18665 if (_ptr_transport
) {
18666 NDR_PULL_ALLOC(ndr
, r
->in
.transport
);
18668 r
->in
.transport
= NULL
;
18670 if (r
->in
.transport
) {
18671 _mem_save_transport_0
= NDR_PULL_GET_MEM_CTX(ndr
);
18672 NDR_PULL_SET_MEM_CTX(ndr
, r
->in
.transport
, 0);
18673 NDR_CHECK(ndr_pull_array_size(ndr
, &r
->in
.transport
));
18674 NDR_CHECK(ndr_pull_array_length(ndr
, &r
->in
.transport
));
18675 if (ndr_get_array_length(ndr
, &r
->in
.transport
) > ndr_get_array_size(ndr
, &r
->in
.transport
)) {
18676 return ndr_pull_error(ndr
, NDR_ERR_ARRAY_SIZE
, "Bad array size %u should exceed array length %u", ndr_get_array_size(ndr
, &r
->in
.transport
), ndr_get_array_length(ndr
, &r
->in
.transport
));
18678 NDR_CHECK(ndr_check_string_terminator(ndr
, ndr_get_array_length(ndr
, &r
->in
.transport
), sizeof(uint16_t)));
18679 NDR_CHECK(ndr_pull_charset(ndr
, NDR_SCALARS
, &r
->in
.transport
, ndr_get_array_length(ndr
, &r
->in
.transport
), sizeof(uint16_t), CH_UTF16
));
18680 NDR_PULL_SET_MEM_CTX(ndr
, _mem_save_transport_0
, 0);
18682 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->in
.servicebitsofinterest
));
18683 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->in
.servicebits
));
18684 NDR_CHECK(ndr_pull_uint32(ndr
, NDR_SCALARS
, &r
->in
.updateimmediately
));
18686 if (flags
& NDR_OUT
) {
18687 NDR_CHECK(ndr_pull_WERROR(ndr
, NDR_SCALARS
, &r
->out
.result
));
18689 return NDR_ERR_SUCCESS
;
18692 _PUBLIC_
void ndr_print_srvsvc_NetServerSetServiceBitsEx(struct ndr_print
*ndr
, const char *name
, int flags
, const struct srvsvc_NetServerSetServiceBitsEx
*r
)
18694 ndr_print_struct(ndr
, name
, "srvsvc_NetServerSetServiceBitsEx");
18696 if (flags
& NDR_SET_VALUES
) {
18697 ndr
->flags
|= LIBNDR_PRINT_SET_VALUES
;
18699 if (flags
& NDR_IN
) {
18700 ndr_print_struct(ndr
, "in", "srvsvc_NetServerSetServiceBitsEx");
18702 ndr_print_ptr(ndr
, "server_unc", r
->in
.server_unc
);
18704 if (r
->in
.server_unc
) {
18705 ndr_print_string(ndr
, "server_unc", r
->in
.server_unc
);
18708 ndr_print_ptr(ndr
, "emulated_server_unc", r
->in
.emulated_server_unc
);
18710 if (r
->in
.emulated_server_unc
) {
18711 ndr_print_string(ndr
, "emulated_server_unc", r
->in
.emulated_server_unc
);
18714 ndr_print_ptr(ndr
, "transport", r
->in
.transport
);
18716 if (r
->in
.transport
) {
18717 ndr_print_string(ndr
, "transport", r
->in
.transport
);
18720 ndr_print_uint32(ndr
, "servicebitsofinterest", r
->in
.servicebitsofinterest
);
18721 ndr_print_uint32(ndr
, "servicebits", r
->in
.servicebits
);
18722 ndr_print_uint32(ndr
, "updateimmediately", r
->in
.updateimmediately
);
18725 if (flags
& NDR_OUT
) {
18726 ndr_print_struct(ndr
, "out", "srvsvc_NetServerSetServiceBitsEx");
18728 ndr_print_WERROR(ndr
, "result", r
->out
.result
);
18734 static enum ndr_err_code
ndr_push_srvsvc_NETRDFSGETVERSION(struct ndr_push
*ndr
, int flags
, const struct srvsvc_NETRDFSGETVERSION
*r
)
18736 if (flags
& NDR_IN
) {
18738 if (flags
& NDR_OUT
) {
18739 NDR_CHECK(ndr_push_WERROR(ndr
, NDR_SCALARS
, r
->out
.result
));
18741 return NDR_ERR_SUCCESS
;
18744 static enum ndr_err_code
ndr_pull_srvsvc_NETRDFSGETVERSION(struct ndr_pull
*ndr
, int flags
, struct srvsvc_NETRDFSGETVERSION
*r
)
18746 if (flags
& NDR_IN
) {
18748 if (flags
& NDR_OUT
) {
18749 NDR_CHECK(ndr_pull_WERROR(ndr
, NDR_SCALARS
, &r
->out
.result
));
18751 return NDR_ERR_SUCCESS
;
18754 _PUBLIC_
void ndr_print_srvsvc_NETRDFSGETVERSION(struct ndr_print
*ndr
, const char *name
, int flags
, const struct srvsvc_NETRDFSGETVERSION
*r
)
18756 ndr_print_struct(ndr
, name
, "srvsvc_NETRDFSGETVERSION");
18758 if (flags
& NDR_SET_VALUES
) {
18759 ndr
->flags
|= LIBNDR_PRINT_SET_VALUES
;
18761 if (flags
& NDR_IN
) {
18762 ndr_print_struct(ndr
, "in", "srvsvc_NETRDFSGETVERSION");
18766 if (flags
& NDR_OUT
) {
18767 ndr_print_struct(ndr
, "out", "srvsvc_NETRDFSGETVERSION");
18769 ndr_print_WERROR(ndr
, "result", r
->out
.result
);
18775 static enum ndr_err_code
ndr_push_srvsvc_NETRDFSCREATELOCALPARTITION(struct ndr_push
*ndr
, int flags
, const struct srvsvc_NETRDFSCREATELOCALPARTITION
*r
)
18777 if (flags
& NDR_IN
) {
18779 if (flags
& NDR_OUT
) {
18780 NDR_CHECK(ndr_push_WERROR(ndr
, NDR_SCALARS
, r
->out
.result
));
18782 return NDR_ERR_SUCCESS
;
18785 static enum ndr_err_code
ndr_pull_srvsvc_NETRDFSCREATELOCALPARTITION(struct ndr_pull
*ndr
, int flags
, struct srvsvc_NETRDFSCREATELOCALPARTITION
*r
)
18787 if (flags
& NDR_IN
) {
18789 if (flags
& NDR_OUT
) {
18790 NDR_CHECK(ndr_pull_WERROR(ndr
, NDR_SCALARS
, &r
->out
.result
));
18792 return NDR_ERR_SUCCESS
;
18795 _PUBLIC_
void ndr_print_srvsvc_NETRDFSCREATELOCALPARTITION(struct ndr_print
*ndr
, const char *name
, int flags
, const struct srvsvc_NETRDFSCREATELOCALPARTITION
*r
)
18797 ndr_print_struct(ndr
, name
, "srvsvc_NETRDFSCREATELOCALPARTITION");
18799 if (flags
& NDR_SET_VALUES
) {
18800 ndr
->flags
|= LIBNDR_PRINT_SET_VALUES
;
18802 if (flags
& NDR_IN
) {
18803 ndr_print_struct(ndr
, "in", "srvsvc_NETRDFSCREATELOCALPARTITION");
18807 if (flags
& NDR_OUT
) {
18808 ndr_print_struct(ndr
, "out", "srvsvc_NETRDFSCREATELOCALPARTITION");
18810 ndr_print_WERROR(ndr
, "result", r
->out
.result
);
18816 static enum ndr_err_code
ndr_push_srvsvc_NETRDFSDELETELOCALPARTITION(struct ndr_push
*ndr
, int flags
, const struct srvsvc_NETRDFSDELETELOCALPARTITION
*r
)
18818 if (flags
& NDR_IN
) {
18820 if (flags
& NDR_OUT
) {
18821 NDR_CHECK(ndr_push_WERROR(ndr
, NDR_SCALARS
, r
->out
.result
));
18823 return NDR_ERR_SUCCESS
;
18826 static enum ndr_err_code
ndr_pull_srvsvc_NETRDFSDELETELOCALPARTITION(struct ndr_pull
*ndr
, int flags
, struct srvsvc_NETRDFSDELETELOCALPARTITION
*r
)
18828 if (flags
& NDR_IN
) {
18830 if (flags
& NDR_OUT
) {
18831 NDR_CHECK(ndr_pull_WERROR(ndr
, NDR_SCALARS
, &r
->out
.result
));
18833 return NDR_ERR_SUCCESS
;
18836 _PUBLIC_
void ndr_print_srvsvc_NETRDFSDELETELOCALPARTITION(struct ndr_print
*ndr
, const char *name
, int flags
, const struct srvsvc_NETRDFSDELETELOCALPARTITION
*r
)
18838 ndr_print_struct(ndr
, name
, "srvsvc_NETRDFSDELETELOCALPARTITION");
18840 if (flags
& NDR_SET_VALUES
) {
18841 ndr
->flags
|= LIBNDR_PRINT_SET_VALUES
;
18843 if (flags
& NDR_IN
) {
18844 ndr_print_struct(ndr
, "in", "srvsvc_NETRDFSDELETELOCALPARTITION");
18848 if (flags
& NDR_OUT
) {
18849 ndr_print_struct(ndr
, "out", "srvsvc_NETRDFSDELETELOCALPARTITION");
18851 ndr_print_WERROR(ndr
, "result", r
->out
.result
);
18857 static enum ndr_err_code
ndr_push_srvsvc_NETRDFSSETLOCALVOLUMESTATE(struct ndr_push
*ndr
, int flags
, const struct srvsvc_NETRDFSSETLOCALVOLUMESTATE
*r
)
18859 if (flags
& NDR_IN
) {
18861 if (flags
& NDR_OUT
) {
18862 NDR_CHECK(ndr_push_WERROR(ndr
, NDR_SCALARS
, r
->out
.result
));
18864 return NDR_ERR_SUCCESS
;
18867 static enum ndr_err_code
ndr_pull_srvsvc_NETRDFSSETLOCALVOLUMESTATE(struct ndr_pull
*ndr
, int flags
, struct srvsvc_NETRDFSSETLOCALVOLUMESTATE
*r
)
18869 if (flags
& NDR_IN
) {
18871 if (flags
& NDR_OUT
) {
18872 NDR_CHECK(ndr_pull_WERROR(ndr
, NDR_SCALARS
, &r
->out
.result
));
18874 return NDR_ERR_SUCCESS
;
18877 _PUBLIC_
void ndr_print_srvsvc_NETRDFSSETLOCALVOLUMESTATE(struct ndr_print
*ndr
, const char *name
, int flags
, const struct srvsvc_NETRDFSSETLOCALVOLUMESTATE
*r
)
18879 ndr_print_struct(ndr
, name
, "srvsvc_NETRDFSSETLOCALVOLUMESTATE");
18881 if (flags
& NDR_SET_VALUES
) {
18882 ndr
->flags
|= LIBNDR_PRINT_SET_VALUES
;
18884 if (flags
& NDR_IN
) {
18885 ndr_print_struct(ndr
, "in", "srvsvc_NETRDFSSETLOCALVOLUMESTATE");
18889 if (flags
& NDR_OUT
) {
18890 ndr_print_struct(ndr
, "out", "srvsvc_NETRDFSSETLOCALVOLUMESTATE");
18892 ndr_print_WERROR(ndr
, "result", r
->out
.result
);
18898 static enum ndr_err_code
ndr_push_srvsvc_NETRDFSSETSERVERINFO(struct ndr_push
*ndr
, int flags
, const struct srvsvc_NETRDFSSETSERVERINFO
*r
)
18900 if (flags
& NDR_IN
) {
18902 if (flags
& NDR_OUT
) {
18903 NDR_CHECK(ndr_push_WERROR(ndr
, NDR_SCALARS
, r
->out
.result
));
18905 return NDR_ERR_SUCCESS
;
18908 static enum ndr_err_code
ndr_pull_srvsvc_NETRDFSSETSERVERINFO(struct ndr_pull
*ndr
, int flags
, struct srvsvc_NETRDFSSETSERVERINFO
*r
)
18910 if (flags
& NDR_IN
) {
18912 if (flags
& NDR_OUT
) {
18913 NDR_CHECK(ndr_pull_WERROR(ndr
, NDR_SCALARS
, &r
->out
.result
));
18915 return NDR_ERR_SUCCESS
;
18918 _PUBLIC_
void ndr_print_srvsvc_NETRDFSSETSERVERINFO(struct ndr_print
*ndr
, const char *name
, int flags
, const struct srvsvc_NETRDFSSETSERVERINFO
*r
)
18920 ndr_print_struct(ndr
, name
, "srvsvc_NETRDFSSETSERVERINFO");
18922 if (flags
& NDR_SET_VALUES
) {
18923 ndr
->flags
|= LIBNDR_PRINT_SET_VALUES
;
18925 if (flags
& NDR_IN
) {
18926 ndr_print_struct(ndr
, "in", "srvsvc_NETRDFSSETSERVERINFO");
18930 if (flags
& NDR_OUT
) {
18931 ndr_print_struct(ndr
, "out", "srvsvc_NETRDFSSETSERVERINFO");
18933 ndr_print_WERROR(ndr
, "result", r
->out
.result
);
18939 static enum ndr_err_code
ndr_push_srvsvc_NETRDFSCREATEEXITPOINT(struct ndr_push
*ndr
, int flags
, const struct srvsvc_NETRDFSCREATEEXITPOINT
*r
)
18941 if (flags
& NDR_IN
) {
18943 if (flags
& NDR_OUT
) {
18944 NDR_CHECK(ndr_push_WERROR(ndr
, NDR_SCALARS
, r
->out
.result
));
18946 return NDR_ERR_SUCCESS
;
18949 static enum ndr_err_code
ndr_pull_srvsvc_NETRDFSCREATEEXITPOINT(struct ndr_pull
*ndr
, int flags
, struct srvsvc_NETRDFSCREATEEXITPOINT
*r
)
18951 if (flags
& NDR_IN
) {
18953 if (flags
& NDR_OUT
) {
18954 NDR_CHECK(ndr_pull_WERROR(ndr
, NDR_SCALARS
, &r
->out
.result
));
18956 return NDR_ERR_SUCCESS
;
18959 _PUBLIC_
void ndr_print_srvsvc_NETRDFSCREATEEXITPOINT(struct ndr_print
*ndr
, const char *name
, int flags
, const struct srvsvc_NETRDFSCREATEEXITPOINT
*r
)
18961 ndr_print_struct(ndr
, name
, "srvsvc_NETRDFSCREATEEXITPOINT");
18963 if (flags
& NDR_SET_VALUES
) {
18964 ndr
->flags
|= LIBNDR_PRINT_SET_VALUES
;
18966 if (flags
& NDR_IN
) {
18967 ndr_print_struct(ndr
, "in", "srvsvc_NETRDFSCREATEEXITPOINT");
18971 if (flags
& NDR_OUT
) {
18972 ndr_print_struct(ndr
, "out", "srvsvc_NETRDFSCREATEEXITPOINT");
18974 ndr_print_WERROR(ndr
, "result", r
->out
.result
);
18980 static enum ndr_err_code
ndr_push_srvsvc_NETRDFSDELETEEXITPOINT(struct ndr_push
*ndr
, int flags
, const struct srvsvc_NETRDFSDELETEEXITPOINT
*r
)
18982 if (flags
& NDR_IN
) {
18984 if (flags
& NDR_OUT
) {
18985 NDR_CHECK(ndr_push_WERROR(ndr
, NDR_SCALARS
, r
->out
.result
));
18987 return NDR_ERR_SUCCESS
;
18990 static enum ndr_err_code
ndr_pull_srvsvc_NETRDFSDELETEEXITPOINT(struct ndr_pull
*ndr
, int flags
, struct srvsvc_NETRDFSDELETEEXITPOINT
*r
)
18992 if (flags
& NDR_IN
) {
18994 if (flags
& NDR_OUT
) {
18995 NDR_CHECK(ndr_pull_WERROR(ndr
, NDR_SCALARS
, &r
->out
.result
));
18997 return NDR_ERR_SUCCESS
;
19000 _PUBLIC_
void ndr_print_srvsvc_NETRDFSDELETEEXITPOINT(struct ndr_print
*ndr
, const char *name
, int flags
, const struct srvsvc_NETRDFSDELETEEXITPOINT
*r
)
19002 ndr_print_struct(ndr
, name
, "srvsvc_NETRDFSDELETEEXITPOINT");
19004 if (flags
& NDR_SET_VALUES
) {
19005 ndr
->flags
|= LIBNDR_PRINT_SET_VALUES
;
19007 if (flags
& NDR_IN
) {
19008 ndr_print_struct(ndr
, "in", "srvsvc_NETRDFSDELETEEXITPOINT");
19012 if (flags
& NDR_OUT
) {
19013 ndr_print_struct(ndr
, "out", "srvsvc_NETRDFSDELETEEXITPOINT");
19015 ndr_print_WERROR(ndr
, "result", r
->out
.result
);
19021 static enum ndr_err_code
ndr_push_srvsvc_NETRDFSMODIFYPREFIX(struct ndr_push
*ndr
, int flags
, const struct srvsvc_NETRDFSMODIFYPREFIX
*r
)
19023 if (flags
& NDR_IN
) {
19025 if (flags
& NDR_OUT
) {
19026 NDR_CHECK(ndr_push_WERROR(ndr
, NDR_SCALARS
, r
->out
.result
));
19028 return NDR_ERR_SUCCESS
;
19031 static enum ndr_err_code
ndr_pull_srvsvc_NETRDFSMODIFYPREFIX(struct ndr_pull
*ndr
, int flags
, struct srvsvc_NETRDFSMODIFYPREFIX
*r
)
19033 if (flags
& NDR_IN
) {
19035 if (flags
& NDR_OUT
) {
19036 NDR_CHECK(ndr_pull_WERROR(ndr
, NDR_SCALARS
, &r
->out
.result
));
19038 return NDR_ERR_SUCCESS
;
19041 _PUBLIC_
void ndr_print_srvsvc_NETRDFSMODIFYPREFIX(struct ndr_print
*ndr
, const char *name
, int flags
, const struct srvsvc_NETRDFSMODIFYPREFIX
*r
)
19043 ndr_print_struct(ndr
, name
, "srvsvc_NETRDFSMODIFYPREFIX");
19045 if (flags
& NDR_SET_VALUES
) {
19046 ndr
->flags
|= LIBNDR_PRINT_SET_VALUES
;
19048 if (flags
& NDR_IN
) {
19049 ndr_print_struct(ndr
, "in", "srvsvc_NETRDFSMODIFYPREFIX");
19053 if (flags
& NDR_OUT
) {
19054 ndr_print_struct(ndr
, "out", "srvsvc_NETRDFSMODIFYPREFIX");
19056 ndr_print_WERROR(ndr
, "result", r
->out
.result
);
19062 static enum ndr_err_code
ndr_push_srvsvc_NETRDFSFIXLOCALVOLUME(struct ndr_push
*ndr
, int flags
, const struct srvsvc_NETRDFSFIXLOCALVOLUME
*r
)
19064 if (flags
& NDR_IN
) {
19066 if (flags
& NDR_OUT
) {
19067 NDR_CHECK(ndr_push_WERROR(ndr
, NDR_SCALARS
, r
->out
.result
));
19069 return NDR_ERR_SUCCESS
;
19072 static enum ndr_err_code
ndr_pull_srvsvc_NETRDFSFIXLOCALVOLUME(struct ndr_pull
*ndr
, int flags
, struct srvsvc_NETRDFSFIXLOCALVOLUME
*r
)
19074 if (flags
& NDR_IN
) {
19076 if (flags
& NDR_OUT
) {
19077 NDR_CHECK(ndr_pull_WERROR(ndr
, NDR_SCALARS
, &r
->out
.result
));
19079 return NDR_ERR_SUCCESS
;
19082 _PUBLIC_
void ndr_print_srvsvc_NETRDFSFIXLOCALVOLUME(struct ndr_print
*ndr
, const char *name
, int flags
, const struct srvsvc_NETRDFSFIXLOCALVOLUME
*r
)
19084 ndr_print_struct(ndr
, name
, "srvsvc_NETRDFSFIXLOCALVOLUME");
19086 if (flags
& NDR_SET_VALUES
) {
19087 ndr
->flags
|= LIBNDR_PRINT_SET_VALUES
;
19089 if (flags
& NDR_IN
) {
19090 ndr_print_struct(ndr
, "in", "srvsvc_NETRDFSFIXLOCALVOLUME");
19094 if (flags
& NDR_OUT
) {
19095 ndr_print_struct(ndr
, "out", "srvsvc_NETRDFSFIXLOCALVOLUME");
19097 ndr_print_WERROR(ndr
, "result", r
->out
.result
);
19103 static enum ndr_err_code
ndr_push_srvsvc_NETRDFSMANAGERREPORTSITEINFO(struct ndr_push
*ndr
, int flags
, const struct srvsvc_NETRDFSMANAGERREPORTSITEINFO
*r
)
19105 if (flags
& NDR_IN
) {
19107 if (flags
& NDR_OUT
) {
19108 NDR_CHECK(ndr_push_WERROR(ndr
, NDR_SCALARS
, r
->out
.result
));
19110 return NDR_ERR_SUCCESS
;
19113 static enum ndr_err_code
ndr_pull_srvsvc_NETRDFSMANAGERREPORTSITEINFO(struct ndr_pull
*ndr
, int flags
, struct srvsvc_NETRDFSMANAGERREPORTSITEINFO
*r
)
19115 if (flags
& NDR_IN
) {
19117 if (flags
& NDR_OUT
) {
19118 NDR_CHECK(ndr_pull_WERROR(ndr
, NDR_SCALARS
, &r
->out
.result
));
19120 return NDR_ERR_SUCCESS
;
19123 _PUBLIC_
void ndr_print_srvsvc_NETRDFSMANAGERREPORTSITEINFO(struct ndr_print
*ndr
, const char *name
, int flags
, const struct srvsvc_NETRDFSMANAGERREPORTSITEINFO
*r
)
19125 ndr_print_struct(ndr
, name
, "srvsvc_NETRDFSMANAGERREPORTSITEINFO");
19127 if (flags
& NDR_SET_VALUES
) {
19128 ndr
->flags
|= LIBNDR_PRINT_SET_VALUES
;
19130 if (flags
& NDR_IN
) {
19131 ndr_print_struct(ndr
, "in", "srvsvc_NETRDFSMANAGERREPORTSITEINFO");
19135 if (flags
& NDR_OUT
) {
19136 ndr_print_struct(ndr
, "out", "srvsvc_NETRDFSMANAGERREPORTSITEINFO");
19138 ndr_print_WERROR(ndr
, "result", r
->out
.result
);
19144 static enum ndr_err_code
ndr_push_srvsvc_NETRSERVERTRANSPORTDELEX(struct ndr_push
*ndr
, int flags
, const struct srvsvc_NETRSERVERTRANSPORTDELEX
*r
)
19146 if (flags
& NDR_IN
) {
19148 if (flags
& NDR_OUT
) {
19149 NDR_CHECK(ndr_push_WERROR(ndr
, NDR_SCALARS
, r
->out
.result
));
19151 return NDR_ERR_SUCCESS
;
19154 static enum ndr_err_code
ndr_pull_srvsvc_NETRSERVERTRANSPORTDELEX(struct ndr_pull
*ndr
, int flags
, struct srvsvc_NETRSERVERTRANSPORTDELEX
*r
)
19156 if (flags
& NDR_IN
) {
19158 if (flags
& NDR_OUT
) {
19159 NDR_CHECK(ndr_pull_WERROR(ndr
, NDR_SCALARS
, &r
->out
.result
));
19161 return NDR_ERR_SUCCESS
;
19164 _PUBLIC_
void ndr_print_srvsvc_NETRSERVERTRANSPORTDELEX(struct ndr_print
*ndr
, const char *name
, int flags
, const struct srvsvc_NETRSERVERTRANSPORTDELEX
*r
)
19166 ndr_print_struct(ndr
, name
, "srvsvc_NETRSERVERTRANSPORTDELEX");
19168 if (flags
& NDR_SET_VALUES
) {
19169 ndr
->flags
|= LIBNDR_PRINT_SET_VALUES
;
19171 if (flags
& NDR_IN
) {
19172 ndr_print_struct(ndr
, "in", "srvsvc_NETRSERVERTRANSPORTDELEX");
19176 if (flags
& NDR_OUT
) {
19177 ndr_print_struct(ndr
, "out", "srvsvc_NETRSERVERTRANSPORTDELEX");
19179 ndr_print_WERROR(ndr
, "result", r
->out
.result
);
19185 static const struct ndr_interface_call srvsvc_calls
[] = {
19187 "srvsvc_NetCharDevEnum",
19188 sizeof(struct srvsvc_NetCharDevEnum
),
19189 (ndr_push_flags_fn_t
) ndr_push_srvsvc_NetCharDevEnum
,
19190 (ndr_pull_flags_fn_t
) ndr_pull_srvsvc_NetCharDevEnum
,
19191 (ndr_print_function_t
) ndr_print_srvsvc_NetCharDevEnum
,
19195 "srvsvc_NetCharDevGetInfo",
19196 sizeof(struct srvsvc_NetCharDevGetInfo
),
19197 (ndr_push_flags_fn_t
) ndr_push_srvsvc_NetCharDevGetInfo
,
19198 (ndr_pull_flags_fn_t
) ndr_pull_srvsvc_NetCharDevGetInfo
,
19199 (ndr_print_function_t
) ndr_print_srvsvc_NetCharDevGetInfo
,
19203 "srvsvc_NetCharDevControl",
19204 sizeof(struct srvsvc_NetCharDevControl
),
19205 (ndr_push_flags_fn_t
) ndr_push_srvsvc_NetCharDevControl
,
19206 (ndr_pull_flags_fn_t
) ndr_pull_srvsvc_NetCharDevControl
,
19207 (ndr_print_function_t
) ndr_print_srvsvc_NetCharDevControl
,
19211 "srvsvc_NetCharDevQEnum",
19212 sizeof(struct srvsvc_NetCharDevQEnum
),
19213 (ndr_push_flags_fn_t
) ndr_push_srvsvc_NetCharDevQEnum
,
19214 (ndr_pull_flags_fn_t
) ndr_pull_srvsvc_NetCharDevQEnum
,
19215 (ndr_print_function_t
) ndr_print_srvsvc_NetCharDevQEnum
,
19219 "srvsvc_NetCharDevQGetInfo",
19220 sizeof(struct srvsvc_NetCharDevQGetInfo
),
19221 (ndr_push_flags_fn_t
) ndr_push_srvsvc_NetCharDevQGetInfo
,
19222 (ndr_pull_flags_fn_t
) ndr_pull_srvsvc_NetCharDevQGetInfo
,
19223 (ndr_print_function_t
) ndr_print_srvsvc_NetCharDevQGetInfo
,
19227 "srvsvc_NetCharDevQSetInfo",
19228 sizeof(struct srvsvc_NetCharDevQSetInfo
),
19229 (ndr_push_flags_fn_t
) ndr_push_srvsvc_NetCharDevQSetInfo
,
19230 (ndr_pull_flags_fn_t
) ndr_pull_srvsvc_NetCharDevQSetInfo
,
19231 (ndr_print_function_t
) ndr_print_srvsvc_NetCharDevQSetInfo
,
19235 "srvsvc_NetCharDevQPurge",
19236 sizeof(struct srvsvc_NetCharDevQPurge
),
19237 (ndr_push_flags_fn_t
) ndr_push_srvsvc_NetCharDevQPurge
,
19238 (ndr_pull_flags_fn_t
) ndr_pull_srvsvc_NetCharDevQPurge
,
19239 (ndr_print_function_t
) ndr_print_srvsvc_NetCharDevQPurge
,
19243 "srvsvc_NetCharDevQPurgeSelf",
19244 sizeof(struct srvsvc_NetCharDevQPurgeSelf
),
19245 (ndr_push_flags_fn_t
) ndr_push_srvsvc_NetCharDevQPurgeSelf
,
19246 (ndr_pull_flags_fn_t
) ndr_pull_srvsvc_NetCharDevQPurgeSelf
,
19247 (ndr_print_function_t
) ndr_print_srvsvc_NetCharDevQPurgeSelf
,
19251 "srvsvc_NetConnEnum",
19252 sizeof(struct srvsvc_NetConnEnum
),
19253 (ndr_push_flags_fn_t
) ndr_push_srvsvc_NetConnEnum
,
19254 (ndr_pull_flags_fn_t
) ndr_pull_srvsvc_NetConnEnum
,
19255 (ndr_print_function_t
) ndr_print_srvsvc_NetConnEnum
,
19259 "srvsvc_NetFileEnum",
19260 sizeof(struct srvsvc_NetFileEnum
),
19261 (ndr_push_flags_fn_t
) ndr_push_srvsvc_NetFileEnum
,
19262 (ndr_pull_flags_fn_t
) ndr_pull_srvsvc_NetFileEnum
,
19263 (ndr_print_function_t
) ndr_print_srvsvc_NetFileEnum
,
19267 "srvsvc_NetFileGetInfo",
19268 sizeof(struct srvsvc_NetFileGetInfo
),
19269 (ndr_push_flags_fn_t
) ndr_push_srvsvc_NetFileGetInfo
,
19270 (ndr_pull_flags_fn_t
) ndr_pull_srvsvc_NetFileGetInfo
,
19271 (ndr_print_function_t
) ndr_print_srvsvc_NetFileGetInfo
,
19275 "srvsvc_NetFileClose",
19276 sizeof(struct srvsvc_NetFileClose
),
19277 (ndr_push_flags_fn_t
) ndr_push_srvsvc_NetFileClose
,
19278 (ndr_pull_flags_fn_t
) ndr_pull_srvsvc_NetFileClose
,
19279 (ndr_print_function_t
) ndr_print_srvsvc_NetFileClose
,
19283 "srvsvc_NetSessEnum",
19284 sizeof(struct srvsvc_NetSessEnum
),
19285 (ndr_push_flags_fn_t
) ndr_push_srvsvc_NetSessEnum
,
19286 (ndr_pull_flags_fn_t
) ndr_pull_srvsvc_NetSessEnum
,
19287 (ndr_print_function_t
) ndr_print_srvsvc_NetSessEnum
,
19291 "srvsvc_NetSessDel",
19292 sizeof(struct srvsvc_NetSessDel
),
19293 (ndr_push_flags_fn_t
) ndr_push_srvsvc_NetSessDel
,
19294 (ndr_pull_flags_fn_t
) ndr_pull_srvsvc_NetSessDel
,
19295 (ndr_print_function_t
) ndr_print_srvsvc_NetSessDel
,
19299 "srvsvc_NetShareAdd",
19300 sizeof(struct srvsvc_NetShareAdd
),
19301 (ndr_push_flags_fn_t
) ndr_push_srvsvc_NetShareAdd
,
19302 (ndr_pull_flags_fn_t
) ndr_pull_srvsvc_NetShareAdd
,
19303 (ndr_print_function_t
) ndr_print_srvsvc_NetShareAdd
,
19307 "srvsvc_NetShareEnumAll",
19308 sizeof(struct srvsvc_NetShareEnumAll
),
19309 (ndr_push_flags_fn_t
) ndr_push_srvsvc_NetShareEnumAll
,
19310 (ndr_pull_flags_fn_t
) ndr_pull_srvsvc_NetShareEnumAll
,
19311 (ndr_print_function_t
) ndr_print_srvsvc_NetShareEnumAll
,
19315 "srvsvc_NetShareGetInfo",
19316 sizeof(struct srvsvc_NetShareGetInfo
),
19317 (ndr_push_flags_fn_t
) ndr_push_srvsvc_NetShareGetInfo
,
19318 (ndr_pull_flags_fn_t
) ndr_pull_srvsvc_NetShareGetInfo
,
19319 (ndr_print_function_t
) ndr_print_srvsvc_NetShareGetInfo
,
19323 "srvsvc_NetShareSetInfo",
19324 sizeof(struct srvsvc_NetShareSetInfo
),
19325 (ndr_push_flags_fn_t
) ndr_push_srvsvc_NetShareSetInfo
,
19326 (ndr_pull_flags_fn_t
) ndr_pull_srvsvc_NetShareSetInfo
,
19327 (ndr_print_function_t
) ndr_print_srvsvc_NetShareSetInfo
,
19331 "srvsvc_NetShareDel",
19332 sizeof(struct srvsvc_NetShareDel
),
19333 (ndr_push_flags_fn_t
) ndr_push_srvsvc_NetShareDel
,
19334 (ndr_pull_flags_fn_t
) ndr_pull_srvsvc_NetShareDel
,
19335 (ndr_print_function_t
) ndr_print_srvsvc_NetShareDel
,
19339 "srvsvc_NetShareDelSticky",
19340 sizeof(struct srvsvc_NetShareDelSticky
),
19341 (ndr_push_flags_fn_t
) ndr_push_srvsvc_NetShareDelSticky
,
19342 (ndr_pull_flags_fn_t
) ndr_pull_srvsvc_NetShareDelSticky
,
19343 (ndr_print_function_t
) ndr_print_srvsvc_NetShareDelSticky
,
19347 "srvsvc_NetShareCheck",
19348 sizeof(struct srvsvc_NetShareCheck
),
19349 (ndr_push_flags_fn_t
) ndr_push_srvsvc_NetShareCheck
,
19350 (ndr_pull_flags_fn_t
) ndr_pull_srvsvc_NetShareCheck
,
19351 (ndr_print_function_t
) ndr_print_srvsvc_NetShareCheck
,
19355 "srvsvc_NetSrvGetInfo",
19356 sizeof(struct srvsvc_NetSrvGetInfo
),
19357 (ndr_push_flags_fn_t
) ndr_push_srvsvc_NetSrvGetInfo
,
19358 (ndr_pull_flags_fn_t
) ndr_pull_srvsvc_NetSrvGetInfo
,
19359 (ndr_print_function_t
) ndr_print_srvsvc_NetSrvGetInfo
,
19363 "srvsvc_NetSrvSetInfo",
19364 sizeof(struct srvsvc_NetSrvSetInfo
),
19365 (ndr_push_flags_fn_t
) ndr_push_srvsvc_NetSrvSetInfo
,
19366 (ndr_pull_flags_fn_t
) ndr_pull_srvsvc_NetSrvSetInfo
,
19367 (ndr_print_function_t
) ndr_print_srvsvc_NetSrvSetInfo
,
19371 "srvsvc_NetDiskEnum",
19372 sizeof(struct srvsvc_NetDiskEnum
),
19373 (ndr_push_flags_fn_t
) ndr_push_srvsvc_NetDiskEnum
,
19374 (ndr_pull_flags_fn_t
) ndr_pull_srvsvc_NetDiskEnum
,
19375 (ndr_print_function_t
) ndr_print_srvsvc_NetDiskEnum
,
19379 "srvsvc_NetServerStatisticsGet",
19380 sizeof(struct srvsvc_NetServerStatisticsGet
),
19381 (ndr_push_flags_fn_t
) ndr_push_srvsvc_NetServerStatisticsGet
,
19382 (ndr_pull_flags_fn_t
) ndr_pull_srvsvc_NetServerStatisticsGet
,
19383 (ndr_print_function_t
) ndr_print_srvsvc_NetServerStatisticsGet
,
19387 "srvsvc_NetTransportAdd",
19388 sizeof(struct srvsvc_NetTransportAdd
),
19389 (ndr_push_flags_fn_t
) ndr_push_srvsvc_NetTransportAdd
,
19390 (ndr_pull_flags_fn_t
) ndr_pull_srvsvc_NetTransportAdd
,
19391 (ndr_print_function_t
) ndr_print_srvsvc_NetTransportAdd
,
19395 "srvsvc_NetTransportEnum",
19396 sizeof(struct srvsvc_NetTransportEnum
),
19397 (ndr_push_flags_fn_t
) ndr_push_srvsvc_NetTransportEnum
,
19398 (ndr_pull_flags_fn_t
) ndr_pull_srvsvc_NetTransportEnum
,
19399 (ndr_print_function_t
) ndr_print_srvsvc_NetTransportEnum
,
19403 "srvsvc_NetTransportDel",
19404 sizeof(struct srvsvc_NetTransportDel
),
19405 (ndr_push_flags_fn_t
) ndr_push_srvsvc_NetTransportDel
,
19406 (ndr_pull_flags_fn_t
) ndr_pull_srvsvc_NetTransportDel
,
19407 (ndr_print_function_t
) ndr_print_srvsvc_NetTransportDel
,
19411 "srvsvc_NetRemoteTOD",
19412 sizeof(struct srvsvc_NetRemoteTOD
),
19413 (ndr_push_flags_fn_t
) ndr_push_srvsvc_NetRemoteTOD
,
19414 (ndr_pull_flags_fn_t
) ndr_pull_srvsvc_NetRemoteTOD
,
19415 (ndr_print_function_t
) ndr_print_srvsvc_NetRemoteTOD
,
19419 "srvsvc_NetSetServiceBits",
19420 sizeof(struct srvsvc_NetSetServiceBits
),
19421 (ndr_push_flags_fn_t
) ndr_push_srvsvc_NetSetServiceBits
,
19422 (ndr_pull_flags_fn_t
) ndr_pull_srvsvc_NetSetServiceBits
,
19423 (ndr_print_function_t
) ndr_print_srvsvc_NetSetServiceBits
,
19427 "srvsvc_NetPathType",
19428 sizeof(struct srvsvc_NetPathType
),
19429 (ndr_push_flags_fn_t
) ndr_push_srvsvc_NetPathType
,
19430 (ndr_pull_flags_fn_t
) ndr_pull_srvsvc_NetPathType
,
19431 (ndr_print_function_t
) ndr_print_srvsvc_NetPathType
,
19435 "srvsvc_NetPathCanonicalize",
19436 sizeof(struct srvsvc_NetPathCanonicalize
),
19437 (ndr_push_flags_fn_t
) ndr_push_srvsvc_NetPathCanonicalize
,
19438 (ndr_pull_flags_fn_t
) ndr_pull_srvsvc_NetPathCanonicalize
,
19439 (ndr_print_function_t
) ndr_print_srvsvc_NetPathCanonicalize
,
19443 "srvsvc_NetPathCompare",
19444 sizeof(struct srvsvc_NetPathCompare
),
19445 (ndr_push_flags_fn_t
) ndr_push_srvsvc_NetPathCompare
,
19446 (ndr_pull_flags_fn_t
) ndr_pull_srvsvc_NetPathCompare
,
19447 (ndr_print_function_t
) ndr_print_srvsvc_NetPathCompare
,
19451 "srvsvc_NetNameValidate",
19452 sizeof(struct srvsvc_NetNameValidate
),
19453 (ndr_push_flags_fn_t
) ndr_push_srvsvc_NetNameValidate
,
19454 (ndr_pull_flags_fn_t
) ndr_pull_srvsvc_NetNameValidate
,
19455 (ndr_print_function_t
) ndr_print_srvsvc_NetNameValidate
,
19459 "srvsvc_NETRPRNAMECANONICALIZE",
19460 sizeof(struct srvsvc_NETRPRNAMECANONICALIZE
),
19461 (ndr_push_flags_fn_t
) ndr_push_srvsvc_NETRPRNAMECANONICALIZE
,
19462 (ndr_pull_flags_fn_t
) ndr_pull_srvsvc_NETRPRNAMECANONICALIZE
,
19463 (ndr_print_function_t
) ndr_print_srvsvc_NETRPRNAMECANONICALIZE
,
19467 "srvsvc_NetPRNameCompare",
19468 sizeof(struct srvsvc_NetPRNameCompare
),
19469 (ndr_push_flags_fn_t
) ndr_push_srvsvc_NetPRNameCompare
,
19470 (ndr_pull_flags_fn_t
) ndr_pull_srvsvc_NetPRNameCompare
,
19471 (ndr_print_function_t
) ndr_print_srvsvc_NetPRNameCompare
,
19475 "srvsvc_NetShareEnum",
19476 sizeof(struct srvsvc_NetShareEnum
),
19477 (ndr_push_flags_fn_t
) ndr_push_srvsvc_NetShareEnum
,
19478 (ndr_pull_flags_fn_t
) ndr_pull_srvsvc_NetShareEnum
,
19479 (ndr_print_function_t
) ndr_print_srvsvc_NetShareEnum
,
19483 "srvsvc_NetShareDelStart",
19484 sizeof(struct srvsvc_NetShareDelStart
),
19485 (ndr_push_flags_fn_t
) ndr_push_srvsvc_NetShareDelStart
,
19486 (ndr_pull_flags_fn_t
) ndr_pull_srvsvc_NetShareDelStart
,
19487 (ndr_print_function_t
) ndr_print_srvsvc_NetShareDelStart
,
19491 "srvsvc_NetShareDelCommit",
19492 sizeof(struct srvsvc_NetShareDelCommit
),
19493 (ndr_push_flags_fn_t
) ndr_push_srvsvc_NetShareDelCommit
,
19494 (ndr_pull_flags_fn_t
) ndr_pull_srvsvc_NetShareDelCommit
,
19495 (ndr_print_function_t
) ndr_print_srvsvc_NetShareDelCommit
,
19499 "srvsvc_NetGetFileSecurity",
19500 sizeof(struct srvsvc_NetGetFileSecurity
),
19501 (ndr_push_flags_fn_t
) ndr_push_srvsvc_NetGetFileSecurity
,
19502 (ndr_pull_flags_fn_t
) ndr_pull_srvsvc_NetGetFileSecurity
,
19503 (ndr_print_function_t
) ndr_print_srvsvc_NetGetFileSecurity
,
19507 "srvsvc_NetSetFileSecurity",
19508 sizeof(struct srvsvc_NetSetFileSecurity
),
19509 (ndr_push_flags_fn_t
) ndr_push_srvsvc_NetSetFileSecurity
,
19510 (ndr_pull_flags_fn_t
) ndr_pull_srvsvc_NetSetFileSecurity
,
19511 (ndr_print_function_t
) ndr_print_srvsvc_NetSetFileSecurity
,
19515 "srvsvc_NetServerTransportAddEx",
19516 sizeof(struct srvsvc_NetServerTransportAddEx
),
19517 (ndr_push_flags_fn_t
) ndr_push_srvsvc_NetServerTransportAddEx
,
19518 (ndr_pull_flags_fn_t
) ndr_pull_srvsvc_NetServerTransportAddEx
,
19519 (ndr_print_function_t
) ndr_print_srvsvc_NetServerTransportAddEx
,
19523 "srvsvc_NetServerSetServiceBitsEx",
19524 sizeof(struct srvsvc_NetServerSetServiceBitsEx
),
19525 (ndr_push_flags_fn_t
) ndr_push_srvsvc_NetServerSetServiceBitsEx
,
19526 (ndr_pull_flags_fn_t
) ndr_pull_srvsvc_NetServerSetServiceBitsEx
,
19527 (ndr_print_function_t
) ndr_print_srvsvc_NetServerSetServiceBitsEx
,
19531 "srvsvc_NETRDFSGETVERSION",
19532 sizeof(struct srvsvc_NETRDFSGETVERSION
),
19533 (ndr_push_flags_fn_t
) ndr_push_srvsvc_NETRDFSGETVERSION
,
19534 (ndr_pull_flags_fn_t
) ndr_pull_srvsvc_NETRDFSGETVERSION
,
19535 (ndr_print_function_t
) ndr_print_srvsvc_NETRDFSGETVERSION
,
19539 "srvsvc_NETRDFSCREATELOCALPARTITION",
19540 sizeof(struct srvsvc_NETRDFSCREATELOCALPARTITION
),
19541 (ndr_push_flags_fn_t
) ndr_push_srvsvc_NETRDFSCREATELOCALPARTITION
,
19542 (ndr_pull_flags_fn_t
) ndr_pull_srvsvc_NETRDFSCREATELOCALPARTITION
,
19543 (ndr_print_function_t
) ndr_print_srvsvc_NETRDFSCREATELOCALPARTITION
,
19547 "srvsvc_NETRDFSDELETELOCALPARTITION",
19548 sizeof(struct srvsvc_NETRDFSDELETELOCALPARTITION
),
19549 (ndr_push_flags_fn_t
) ndr_push_srvsvc_NETRDFSDELETELOCALPARTITION
,
19550 (ndr_pull_flags_fn_t
) ndr_pull_srvsvc_NETRDFSDELETELOCALPARTITION
,
19551 (ndr_print_function_t
) ndr_print_srvsvc_NETRDFSDELETELOCALPARTITION
,
19555 "srvsvc_NETRDFSSETLOCALVOLUMESTATE",
19556 sizeof(struct srvsvc_NETRDFSSETLOCALVOLUMESTATE
),
19557 (ndr_push_flags_fn_t
) ndr_push_srvsvc_NETRDFSSETLOCALVOLUMESTATE
,
19558 (ndr_pull_flags_fn_t
) ndr_pull_srvsvc_NETRDFSSETLOCALVOLUMESTATE
,
19559 (ndr_print_function_t
) ndr_print_srvsvc_NETRDFSSETLOCALVOLUMESTATE
,
19563 "srvsvc_NETRDFSSETSERVERINFO",
19564 sizeof(struct srvsvc_NETRDFSSETSERVERINFO
),
19565 (ndr_push_flags_fn_t
) ndr_push_srvsvc_NETRDFSSETSERVERINFO
,
19566 (ndr_pull_flags_fn_t
) ndr_pull_srvsvc_NETRDFSSETSERVERINFO
,
19567 (ndr_print_function_t
) ndr_print_srvsvc_NETRDFSSETSERVERINFO
,
19571 "srvsvc_NETRDFSCREATEEXITPOINT",
19572 sizeof(struct srvsvc_NETRDFSCREATEEXITPOINT
),
19573 (ndr_push_flags_fn_t
) ndr_push_srvsvc_NETRDFSCREATEEXITPOINT
,
19574 (ndr_pull_flags_fn_t
) ndr_pull_srvsvc_NETRDFSCREATEEXITPOINT
,
19575 (ndr_print_function_t
) ndr_print_srvsvc_NETRDFSCREATEEXITPOINT
,
19579 "srvsvc_NETRDFSDELETEEXITPOINT",
19580 sizeof(struct srvsvc_NETRDFSDELETEEXITPOINT
),
19581 (ndr_push_flags_fn_t
) ndr_push_srvsvc_NETRDFSDELETEEXITPOINT
,
19582 (ndr_pull_flags_fn_t
) ndr_pull_srvsvc_NETRDFSDELETEEXITPOINT
,
19583 (ndr_print_function_t
) ndr_print_srvsvc_NETRDFSDELETEEXITPOINT
,
19587 "srvsvc_NETRDFSMODIFYPREFIX",
19588 sizeof(struct srvsvc_NETRDFSMODIFYPREFIX
),
19589 (ndr_push_flags_fn_t
) ndr_push_srvsvc_NETRDFSMODIFYPREFIX
,
19590 (ndr_pull_flags_fn_t
) ndr_pull_srvsvc_NETRDFSMODIFYPREFIX
,
19591 (ndr_print_function_t
) ndr_print_srvsvc_NETRDFSMODIFYPREFIX
,
19595 "srvsvc_NETRDFSFIXLOCALVOLUME",
19596 sizeof(struct srvsvc_NETRDFSFIXLOCALVOLUME
),
19597 (ndr_push_flags_fn_t
) ndr_push_srvsvc_NETRDFSFIXLOCALVOLUME
,
19598 (ndr_pull_flags_fn_t
) ndr_pull_srvsvc_NETRDFSFIXLOCALVOLUME
,
19599 (ndr_print_function_t
) ndr_print_srvsvc_NETRDFSFIXLOCALVOLUME
,
19603 "srvsvc_NETRDFSMANAGERREPORTSITEINFO",
19604 sizeof(struct srvsvc_NETRDFSMANAGERREPORTSITEINFO
),
19605 (ndr_push_flags_fn_t
) ndr_push_srvsvc_NETRDFSMANAGERREPORTSITEINFO
,
19606 (ndr_pull_flags_fn_t
) ndr_pull_srvsvc_NETRDFSMANAGERREPORTSITEINFO
,
19607 (ndr_print_function_t
) ndr_print_srvsvc_NETRDFSMANAGERREPORTSITEINFO
,
19611 "srvsvc_NETRSERVERTRANSPORTDELEX",
19612 sizeof(struct srvsvc_NETRSERVERTRANSPORTDELEX
),
19613 (ndr_push_flags_fn_t
) ndr_push_srvsvc_NETRSERVERTRANSPORTDELEX
,
19614 (ndr_pull_flags_fn_t
) ndr_pull_srvsvc_NETRSERVERTRANSPORTDELEX
,
19615 (ndr_print_function_t
) ndr_print_srvsvc_NETRSERVERTRANSPORTDELEX
,
19618 { NULL
, 0, NULL
, NULL
, NULL
, false }
19621 static const char * const srvsvc_endpoint_strings
[] = {
19622 "ncacn_np:[\\pipe\\srvsvc]",
19627 static const struct ndr_interface_string_array srvsvc_endpoints
= {
19629 .names
= srvsvc_endpoint_strings
19632 static const char * const srvsvc_authservice_strings
[] = {
19636 static const struct ndr_interface_string_array srvsvc_authservices
= {
19638 .names
= srvsvc_authservice_strings
19642 const struct ndr_interface_table ndr_table_srvsvc
= {
19645 {0x4b324fc8,0x1670,0x01d3,{0x12,0x78},{0x5a,0x47,0xbf,0x6e,0xe1,0x88}},
19648 .helpstring
= NDR_SRVSVC_HELPSTRING
,
19650 .calls
= srvsvc_calls
,
19651 .endpoints
= &srvsvc_endpoints
,
19652 .authservices
= &srvsvc_authservices