source: vendor/current/source3/librpc/gen_ndr/ndr_eventlog6.c@ 746

Last change on this file since 746 was 746, checked in by Silvan Scherrer, 12 years ago

Samba Server: updated vendor to 3.6.9

File size: 237.6 KB
Line 
1/* parser auto-generated by pidl */
2
3#include "includes.h"
4#include "librpc/gen_ndr/ndr_eventlog6.h"
5
6#include "librpc/gen_ndr/ndr_misc.h"
7static enum ndr_err_code ndr_push_eventlog6_RpcInfo(struct ndr_push *ndr, int ndr_flags, const struct eventlog6_RpcInfo *r)
8{
9 if (ndr_flags & NDR_SCALARS) {
10 NDR_CHECK(ndr_push_align(ndr, 4));
11 NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->error));
12 NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->sub_err));
13 NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->sub_err_param));
14 NDR_CHECK(ndr_push_trailer_align(ndr, 4));
15 }
16 if (ndr_flags & NDR_BUFFERS) {
17 }
18 return NDR_ERR_SUCCESS;
19}
20
21static enum ndr_err_code ndr_pull_eventlog6_RpcInfo(struct ndr_pull *ndr, int ndr_flags, struct eventlog6_RpcInfo *r)
22{
23 if (ndr_flags & NDR_SCALARS) {
24 NDR_CHECK(ndr_pull_align(ndr, 4));
25 NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->error));
26 NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->sub_err));
27 NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->sub_err_param));
28 NDR_CHECK(ndr_pull_trailer_align(ndr, 4));
29 }
30 if (ndr_flags & NDR_BUFFERS) {
31 }
32 return NDR_ERR_SUCCESS;
33}
34
35_PUBLIC_ void ndr_print_eventlog6_RpcInfo(struct ndr_print *ndr, const char *name, const struct eventlog6_RpcInfo *r)
36{
37 ndr_print_struct(ndr, name, "eventlog6_RpcInfo");
38 if (r == NULL) { ndr_print_null(ndr); return; }
39 ndr->depth++;
40 ndr_print_uint32(ndr, "error", r->error);
41 ndr_print_uint32(ndr, "sub_err", r->sub_err);
42 ndr_print_uint32(ndr, "sub_err_param", r->sub_err_param);
43 ndr->depth--;
44}
45
46static enum ndr_err_code ndr_push_eventlog6_boolean8Array(struct ndr_push *ndr, int ndr_flags, const struct eventlog6_boolean8Array *r)
47{
48 if (ndr_flags & NDR_SCALARS) {
49 NDR_CHECK(ndr_push_align(ndr, 5));
50 NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->count));
51 NDR_CHECK(ndr_push_unique_ptr(ndr, r->ptr));
52 NDR_CHECK(ndr_push_trailer_align(ndr, 5));
53 }
54 if (ndr_flags & NDR_BUFFERS) {
55 if (r->ptr) {
56 NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, r->count));
57 NDR_CHECK(ndr_push_array_uint8(ndr, NDR_SCALARS, r->ptr, r->count));
58 }
59 }
60 return NDR_ERR_SUCCESS;
61}
62
63static enum ndr_err_code ndr_pull_eventlog6_boolean8Array(struct ndr_pull *ndr, int ndr_flags, struct eventlog6_boolean8Array *r)
64{
65 uint32_t _ptr_ptr;
66 uint32_t size_ptr_1 = 0;
67 TALLOC_CTX *_mem_save_ptr_0;
68 if (ndr_flags & NDR_SCALARS) {
69 NDR_CHECK(ndr_pull_align(ndr, 5));
70 NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->count));
71 if (r->count > MAX_RPC_BOOLEAN8_ARRAY_COUNT) {
72 return ndr_pull_error(ndr, NDR_ERR_RANGE, "value out of range");
73 }
74 NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_ptr));
75 if (_ptr_ptr) {
76 NDR_PULL_ALLOC(ndr, r->ptr);
77 } else {
78 r->ptr = NULL;
79 }
80 NDR_CHECK(ndr_pull_trailer_align(ndr, 5));
81 }
82 if (ndr_flags & NDR_BUFFERS) {
83 if (r->ptr) {
84 _mem_save_ptr_0 = NDR_PULL_GET_MEM_CTX(ndr);
85 NDR_PULL_SET_MEM_CTX(ndr, r->ptr, 0);
86 NDR_CHECK(ndr_pull_array_size(ndr, &r->ptr));
87 size_ptr_1 = ndr_get_array_size(ndr, &r->ptr);
88 NDR_PULL_ALLOC_N(ndr, r->ptr, size_ptr_1);
89 NDR_CHECK(ndr_pull_array_uint8(ndr, NDR_SCALARS, r->ptr, size_ptr_1));
90 NDR_PULL_SET_MEM_CTX(ndr, _mem_save_ptr_0, 0);
91 }
92 if (r->ptr) {
93 NDR_CHECK(ndr_check_array_size(ndr, (void*)&r->ptr, r->count));
94 }
95 }
96 return NDR_ERR_SUCCESS;
97}
98
99_PUBLIC_ void ndr_print_eventlog6_boolean8Array(struct ndr_print *ndr, const char *name, const struct eventlog6_boolean8Array *r)
100{
101 ndr_print_struct(ndr, name, "eventlog6_boolean8Array");
102 if (r == NULL) { ndr_print_null(ndr); return; }
103 ndr->depth++;
104 ndr_print_uint32(ndr, "count", r->count);
105 ndr_print_ptr(ndr, "ptr", r->ptr);
106 ndr->depth++;
107 if (r->ptr) {
108 ndr_print_array_uint8(ndr, "ptr", r->ptr, r->count);
109 }
110 ndr->depth--;
111 ndr->depth--;
112}
113
114static enum ndr_err_code ndr_push_eventlog6_UInt32Array(struct ndr_push *ndr, int ndr_flags, const struct eventlog6_UInt32Array *r)
115{
116 uint32_t cntr_ptr_1;
117 if (ndr_flags & NDR_SCALARS) {
118 NDR_CHECK(ndr_push_align(ndr, 5));
119 NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->count));
120 NDR_CHECK(ndr_push_unique_ptr(ndr, r->ptr));
121 NDR_CHECK(ndr_push_trailer_align(ndr, 5));
122 }
123 if (ndr_flags & NDR_BUFFERS) {
124 if (r->ptr) {
125 NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, r->count));
126 for (cntr_ptr_1 = 0; cntr_ptr_1 < r->count; cntr_ptr_1++) {
127 NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->ptr[cntr_ptr_1]));
128 }
129 }
130 }
131 return NDR_ERR_SUCCESS;
132}
133
134static enum ndr_err_code ndr_pull_eventlog6_UInt32Array(struct ndr_pull *ndr, int ndr_flags, struct eventlog6_UInt32Array *r)
135{
136 uint32_t _ptr_ptr;
137 uint32_t size_ptr_1 = 0;
138 uint32_t cntr_ptr_1;
139 TALLOC_CTX *_mem_save_ptr_0;
140 TALLOC_CTX *_mem_save_ptr_1;
141 if (ndr_flags & NDR_SCALARS) {
142 NDR_CHECK(ndr_pull_align(ndr, 5));
143 NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->count));
144 if (r->count > MAX_RPC_UINT32_ARRAY_COUNT) {
145 return ndr_pull_error(ndr, NDR_ERR_RANGE, "value out of range");
146 }
147 NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_ptr));
148 if (_ptr_ptr) {
149 NDR_PULL_ALLOC(ndr, r->ptr);
150 } else {
151 r->ptr = NULL;
152 }
153 NDR_CHECK(ndr_pull_trailer_align(ndr, 5));
154 }
155 if (ndr_flags & NDR_BUFFERS) {
156 if (r->ptr) {
157 _mem_save_ptr_0 = NDR_PULL_GET_MEM_CTX(ndr);
158 NDR_PULL_SET_MEM_CTX(ndr, r->ptr, 0);
159 NDR_CHECK(ndr_pull_array_size(ndr, &r->ptr));
160 size_ptr_1 = ndr_get_array_size(ndr, &r->ptr);
161 NDR_PULL_ALLOC_N(ndr, r->ptr, size_ptr_1);
162 _mem_save_ptr_1 = NDR_PULL_GET_MEM_CTX(ndr);
163 NDR_PULL_SET_MEM_CTX(ndr, r->ptr, 0);
164 for (cntr_ptr_1 = 0; cntr_ptr_1 < size_ptr_1; cntr_ptr_1++) {
165 NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->ptr[cntr_ptr_1]));
166 }
167 NDR_PULL_SET_MEM_CTX(ndr, _mem_save_ptr_1, 0);
168 NDR_PULL_SET_MEM_CTX(ndr, _mem_save_ptr_0, 0);
169 }
170 if (r->ptr) {
171 NDR_CHECK(ndr_check_array_size(ndr, (void*)&r->ptr, r->count));
172 }
173 }
174 return NDR_ERR_SUCCESS;
175}
176
177_PUBLIC_ void ndr_print_eventlog6_UInt32Array(struct ndr_print *ndr, const char *name, const struct eventlog6_UInt32Array *r)
178{
179 uint32_t cntr_ptr_1;
180 ndr_print_struct(ndr, name, "eventlog6_UInt32Array");
181 if (r == NULL) { ndr_print_null(ndr); return; }
182 ndr->depth++;
183 ndr_print_uint32(ndr, "count", r->count);
184 ndr_print_ptr(ndr, "ptr", r->ptr);
185 ndr->depth++;
186 if (r->ptr) {
187 ndr->print(ndr, "%s: ARRAY(%d)", "ptr", (int)r->count);
188 ndr->depth++;
189 for (cntr_ptr_1=0;cntr_ptr_1<r->count;cntr_ptr_1++) {
190 ndr_print_uint32(ndr, "ptr", r->ptr[cntr_ptr_1]);
191 }
192 ndr->depth--;
193 }
194 ndr->depth--;
195 ndr->depth--;
196}
197
198static enum ndr_err_code ndr_push_eventlog6_UInt64Array(struct ndr_push *ndr, int ndr_flags, const struct eventlog6_UInt64Array *r)
199{
200 uint32_t cntr_ptr_1;
201 if (ndr_flags & NDR_SCALARS) {
202 NDR_CHECK(ndr_push_align(ndr, 5));
203 NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->count));
204 NDR_CHECK(ndr_push_unique_ptr(ndr, r->ptr));
205 NDR_CHECK(ndr_push_trailer_align(ndr, 5));
206 }
207 if (ndr_flags & NDR_BUFFERS) {
208 if (r->ptr) {
209 NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, r->count));
210 for (cntr_ptr_1 = 0; cntr_ptr_1 < r->count; cntr_ptr_1++) {
211 NDR_CHECK(ndr_push_hyper(ndr, NDR_SCALARS, r->ptr[cntr_ptr_1]));
212 }
213 }
214 }
215 return NDR_ERR_SUCCESS;
216}
217
218static enum ndr_err_code ndr_pull_eventlog6_UInt64Array(struct ndr_pull *ndr, int ndr_flags, struct eventlog6_UInt64Array *r)
219{
220 uint32_t _ptr_ptr;
221 uint32_t size_ptr_1 = 0;
222 uint32_t cntr_ptr_1;
223 TALLOC_CTX *_mem_save_ptr_0;
224 TALLOC_CTX *_mem_save_ptr_1;
225 if (ndr_flags & NDR_SCALARS) {
226 NDR_CHECK(ndr_pull_align(ndr, 5));
227 NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->count));
228 if (r->count > MAX_RPC_UINT64_ARRAY_COUNT) {
229 return ndr_pull_error(ndr, NDR_ERR_RANGE, "value out of range");
230 }
231 NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_ptr));
232 if (_ptr_ptr) {
233 NDR_PULL_ALLOC(ndr, r->ptr);
234 } else {
235 r->ptr = NULL;
236 }
237 NDR_CHECK(ndr_pull_trailer_align(ndr, 5));
238 }
239 if (ndr_flags & NDR_BUFFERS) {
240 if (r->ptr) {
241 _mem_save_ptr_0 = NDR_PULL_GET_MEM_CTX(ndr);
242 NDR_PULL_SET_MEM_CTX(ndr, r->ptr, 0);
243 NDR_CHECK(ndr_pull_array_size(ndr, &r->ptr));
244 size_ptr_1 = ndr_get_array_size(ndr, &r->ptr);
245 NDR_PULL_ALLOC_N(ndr, r->ptr, size_ptr_1);
246 _mem_save_ptr_1 = NDR_PULL_GET_MEM_CTX(ndr);
247 NDR_PULL_SET_MEM_CTX(ndr, r->ptr, 0);
248 for (cntr_ptr_1 = 0; cntr_ptr_1 < size_ptr_1; cntr_ptr_1++) {
249 NDR_CHECK(ndr_pull_hyper(ndr, NDR_SCALARS, &r->ptr[cntr_ptr_1]));
250 }
251 NDR_PULL_SET_MEM_CTX(ndr, _mem_save_ptr_1, 0);
252 NDR_PULL_SET_MEM_CTX(ndr, _mem_save_ptr_0, 0);
253 }
254 if (r->ptr) {
255 NDR_CHECK(ndr_check_array_size(ndr, (void*)&r->ptr, r->count));
256 }
257 }
258 return NDR_ERR_SUCCESS;
259}
260
261_PUBLIC_ void ndr_print_eventlog6_UInt64Array(struct ndr_print *ndr, const char *name, const struct eventlog6_UInt64Array *r)
262{
263 uint32_t cntr_ptr_1;
264 ndr_print_struct(ndr, name, "eventlog6_UInt64Array");
265 if (r == NULL) { ndr_print_null(ndr); return; }
266 ndr->depth++;
267 ndr_print_uint32(ndr, "count", r->count);
268 ndr_print_ptr(ndr, "ptr", r->ptr);
269 ndr->depth++;
270 if (r->ptr) {
271 ndr->print(ndr, "%s: ARRAY(%d)", "ptr", (int)r->count);
272 ndr->depth++;
273 for (cntr_ptr_1=0;cntr_ptr_1<r->count;cntr_ptr_1++) {
274 ndr_print_hyper(ndr, "ptr", r->ptr[cntr_ptr_1]);
275 }
276 ndr->depth--;
277 }
278 ndr->depth--;
279 ndr->depth--;
280}
281
282static enum ndr_err_code ndr_push_eventlog6_StringArray(struct ndr_push *ndr, int ndr_flags, const struct eventlog6_StringArray *r)
283{
284 if (ndr_flags & NDR_SCALARS) {
285 NDR_CHECK(ndr_push_align(ndr, 5));
286 NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->count));
287 NDR_CHECK(ndr_push_unique_ptr(ndr, r->ptr));
288 NDR_CHECK(ndr_push_trailer_align(ndr, 5));
289 }
290 if (ndr_flags & NDR_BUFFERS) {
291 if (r->ptr) {
292 NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->ptr, CH_UTF16)));
293 NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, 0));
294 NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->ptr, CH_UTF16)));
295 NDR_CHECK(ndr_push_charset(ndr, NDR_SCALARS, r->ptr, ndr_charset_length(r->ptr, CH_UTF16), sizeof(uint16_t), CH_UTF16));
296 }
297 }
298 return NDR_ERR_SUCCESS;
299}
300
301static enum ndr_err_code ndr_pull_eventlog6_StringArray(struct ndr_pull *ndr, int ndr_flags, struct eventlog6_StringArray *r)
302{
303 uint32_t _ptr_ptr;
304 uint32_t size_ptr_1 = 0;
305 uint32_t length_ptr_1 = 0;
306 TALLOC_CTX *_mem_save_ptr_0;
307 if (ndr_flags & NDR_SCALARS) {
308 NDR_CHECK(ndr_pull_align(ndr, 5));
309 NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->count));
310 if (r->count > MAX_RPC_STRING_ARRAY_COUNT) {
311 return ndr_pull_error(ndr, NDR_ERR_RANGE, "value out of range");
312 }
313 NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_ptr));
314 if (_ptr_ptr) {
315 NDR_PULL_ALLOC(ndr, r->ptr);
316 } else {
317 r->ptr = NULL;
318 }
319 NDR_CHECK(ndr_pull_trailer_align(ndr, 5));
320 }
321 if (ndr_flags & NDR_BUFFERS) {
322 if (r->ptr) {
323 _mem_save_ptr_0 = NDR_PULL_GET_MEM_CTX(ndr);
324 NDR_PULL_SET_MEM_CTX(ndr, r->ptr, 0);
325 NDR_CHECK(ndr_pull_array_size(ndr, &r->ptr));
326 NDR_CHECK(ndr_pull_array_length(ndr, &r->ptr));
327 size_ptr_1 = ndr_get_array_size(ndr, &r->ptr);
328 length_ptr_1 = ndr_get_array_length(ndr, &r->ptr);
329 if (length_ptr_1 > size_ptr_1) {
330 return ndr_pull_error(ndr, NDR_ERR_ARRAY_SIZE, "Bad array size %u should exceed array length %u", size_ptr_1, length_ptr_1);
331 }
332 NDR_CHECK(ndr_check_string_terminator(ndr, length_ptr_1, sizeof(uint16_t)));
333 NDR_CHECK(ndr_pull_charset(ndr, NDR_SCALARS, &r->ptr, length_ptr_1, sizeof(uint16_t), CH_UTF16));
334 NDR_PULL_SET_MEM_CTX(ndr, _mem_save_ptr_0, 0);
335 }
336 }
337 return NDR_ERR_SUCCESS;
338}
339
340_PUBLIC_ void ndr_print_eventlog6_StringArray(struct ndr_print *ndr, const char *name, const struct eventlog6_StringArray *r)
341{
342 ndr_print_struct(ndr, name, "eventlog6_StringArray");
343 if (r == NULL) { ndr_print_null(ndr); return; }
344 ndr->depth++;
345 ndr_print_uint32(ndr, "count", r->count);
346 ndr_print_ptr(ndr, "ptr", r->ptr);
347 ndr->depth++;
348 if (r->ptr) {
349 ndr_print_string(ndr, "ptr", r->ptr);
350 }
351 ndr->depth--;
352 ndr->depth--;
353}
354
355static enum ndr_err_code ndr_push_eventlog6_GuidArray(struct ndr_push *ndr, int ndr_flags, const struct eventlog6_GuidArray *r)
356{
357 uint32_t cntr_ptr_1;
358 if (ndr_flags & NDR_SCALARS) {
359 NDR_CHECK(ndr_push_align(ndr, 5));
360 NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->count));
361 NDR_CHECK(ndr_push_unique_ptr(ndr, r->ptr));
362 NDR_CHECK(ndr_push_trailer_align(ndr, 5));
363 }
364 if (ndr_flags & NDR_BUFFERS) {
365 if (r->ptr) {
366 NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, r->count));
367 for (cntr_ptr_1 = 0; cntr_ptr_1 < r->count; cntr_ptr_1++) {
368 NDR_CHECK(ndr_push_GUID(ndr, NDR_SCALARS, &r->ptr[cntr_ptr_1]));
369 }
370 }
371 }
372 return NDR_ERR_SUCCESS;
373}
374
375static enum ndr_err_code ndr_pull_eventlog6_GuidArray(struct ndr_pull *ndr, int ndr_flags, struct eventlog6_GuidArray *r)
376{
377 uint32_t _ptr_ptr;
378 uint32_t size_ptr_1 = 0;
379 uint32_t cntr_ptr_1;
380 TALLOC_CTX *_mem_save_ptr_0;
381 TALLOC_CTX *_mem_save_ptr_1;
382 if (ndr_flags & NDR_SCALARS) {
383 NDR_CHECK(ndr_pull_align(ndr, 5));
384 NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->count));
385 if (r->count > MAX_RPC_GUID_ARRAY_COUNT) {
386 return ndr_pull_error(ndr, NDR_ERR_RANGE, "value out of range");
387 }
388 NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_ptr));
389 if (_ptr_ptr) {
390 NDR_PULL_ALLOC(ndr, r->ptr);
391 } else {
392 r->ptr = NULL;
393 }
394 NDR_CHECK(ndr_pull_trailer_align(ndr, 5));
395 }
396 if (ndr_flags & NDR_BUFFERS) {
397 if (r->ptr) {
398 _mem_save_ptr_0 = NDR_PULL_GET_MEM_CTX(ndr);
399 NDR_PULL_SET_MEM_CTX(ndr, r->ptr, 0);
400 NDR_CHECK(ndr_pull_array_size(ndr, &r->ptr));
401 size_ptr_1 = ndr_get_array_size(ndr, &r->ptr);
402 NDR_PULL_ALLOC_N(ndr, r->ptr, size_ptr_1);
403 _mem_save_ptr_1 = NDR_PULL_GET_MEM_CTX(ndr);
404 NDR_PULL_SET_MEM_CTX(ndr, r->ptr, 0);
405 for (cntr_ptr_1 = 0; cntr_ptr_1 < size_ptr_1; cntr_ptr_1++) {
406 NDR_CHECK(ndr_pull_GUID(ndr, NDR_SCALARS, &r->ptr[cntr_ptr_1]));
407 }
408 NDR_PULL_SET_MEM_CTX(ndr, _mem_save_ptr_1, 0);
409 NDR_PULL_SET_MEM_CTX(ndr, _mem_save_ptr_0, 0);
410 }
411 if (r->ptr) {
412 NDR_CHECK(ndr_check_array_size(ndr, (void*)&r->ptr, r->count));
413 }
414 }
415 return NDR_ERR_SUCCESS;
416}
417
418_PUBLIC_ void ndr_print_eventlog6_GuidArray(struct ndr_print *ndr, const char *name, const struct eventlog6_GuidArray *r)
419{
420 uint32_t cntr_ptr_1;
421 ndr_print_struct(ndr, name, "eventlog6_GuidArray");
422 if (r == NULL) { ndr_print_null(ndr); return; }
423 ndr->depth++;
424 ndr_print_uint32(ndr, "count", r->count);
425 ndr_print_ptr(ndr, "ptr", r->ptr);
426 ndr->depth++;
427 if (r->ptr) {
428 ndr->print(ndr, "%s: ARRAY(%d)", "ptr", (int)r->count);
429 ndr->depth++;
430 for (cntr_ptr_1=0;cntr_ptr_1<r->count;cntr_ptr_1++) {
431 ndr_print_GUID(ndr, "ptr", &r->ptr[cntr_ptr_1]);
432 }
433 ndr->depth--;
434 }
435 ndr->depth--;
436 ndr->depth--;
437}
438
439static enum ndr_err_code ndr_push_eventlog6_EvtRpcVariantType(struct ndr_push *ndr, int ndr_flags, enum eventlog6_EvtRpcVariantType r)
440{
441 NDR_CHECK(ndr_push_enum_uint32(ndr, NDR_SCALARS, r));
442 return NDR_ERR_SUCCESS;
443}
444
445static enum ndr_err_code ndr_pull_eventlog6_EvtRpcVariantType(struct ndr_pull *ndr, int ndr_flags, enum eventlog6_EvtRpcVariantType *r)
446{
447 uint32_t v;
448 NDR_CHECK(ndr_pull_enum_uint32(ndr, NDR_SCALARS, &v));
449 *r = v;
450 return NDR_ERR_SUCCESS;
451}
452
453_PUBLIC_ void ndr_print_eventlog6_EvtRpcVariantType(struct ndr_print *ndr, const char *name, enum eventlog6_EvtRpcVariantType r)
454{
455 const char *val = NULL;
456
457 switch (r) {
458 case EvtRpcVarTypeNull: val = "EvtRpcVarTypeNull"; break;
459 case EvtRpcVarTypeboolean8: val = "EvtRpcVarTypeboolean8"; break;
460 case EvtRpcVarTypeUInt32: val = "EvtRpcVarTypeUInt32"; break;
461 case EvtRpcVarTypeUInt64: val = "EvtRpcVarTypeUInt64"; break;
462 case EvtRpcVarTypeString: val = "EvtRpcVarTypeString"; break;
463 case EvtRpcVarTypeGuid: val = "EvtRpcVarTypeGuid"; break;
464 case EvtRpcVarTypeboolean8Array: val = "EvtRpcVarTypeboolean8Array"; break;
465 case EvtRpcVarTypeUInt32Array: val = "EvtRpcVarTypeUInt32Array"; break;
466 case EvtRpcVarTypeUInt64Array: val = "EvtRpcVarTypeUInt64Array"; break;
467 case EvtRpcVarTypeStringArray: val = "EvtRpcVarTypeStringArray"; break;
468 case EvtRpcVarTypeGuidArray: val = "EvtRpcVarTypeGuidArray"; break;
469 }
470 ndr_print_enum(ndr, name, "ENUM", val, r);
471}
472
473static enum ndr_err_code ndr_push_eventlog6_EvtRpcVariantUnion(struct ndr_push *ndr, int ndr_flags, const union eventlog6_EvtRpcVariantUnion *r)
474{
475 if (ndr_flags & NDR_SCALARS) {
476 uint32_t level = ndr_push_get_switch_value(ndr, r);
477 NDR_CHECK(ndr_push_union_align(ndr, 8));
478 NDR_CHECK(ndr_push_eventlog6_EvtRpcVariantType(ndr, NDR_SCALARS, level));
479 NDR_CHECK(ndr_push_union_align(ndr, 8));
480 switch (level) {
481 case EvtRpcVarTypeNull: {
482 NDR_CHECK(ndr_push_int32(ndr, NDR_SCALARS, r->nullVal));
483 break; }
484
485 case EvtRpcVarTypeboolean8: {
486 NDR_CHECK(ndr_push_uint8(ndr, NDR_SCALARS, r->boolean8Val));
487 break; }
488
489 case EvtRpcVarTypeUInt32: {
490 NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->uint32Val));
491 break; }
492
493 case EvtRpcVarTypeUInt64: {
494 NDR_CHECK(ndr_push_hyper(ndr, NDR_SCALARS, r->uint64Val));
495 break; }
496
497 case EvtRpcVarTypeString: {
498 NDR_CHECK(ndr_push_unique_ptr(ndr, r->stringVal));
499 break; }
500
501 case EvtRpcVarTypeGuid: {
502 NDR_CHECK(ndr_push_unique_ptr(ndr, r->guidVal));
503 break; }
504
505 case EvtRpcVarTypeboolean8Array: {
506 NDR_CHECK(ndr_push_eventlog6_boolean8Array(ndr, NDR_SCALARS, &r->boolean8Array));
507 break; }
508
509 case EvtRpcVarTypeUInt32Array: {
510 NDR_CHECK(ndr_push_eventlog6_UInt32Array(ndr, NDR_SCALARS, &r->uint32Array));
511 break; }
512
513 case EvtRpcVarTypeUInt64Array: {
514 NDR_CHECK(ndr_push_eventlog6_UInt64Array(ndr, NDR_SCALARS, &r->uint64Array));
515 break; }
516
517 case EvtRpcVarTypeStringArray: {
518 NDR_CHECK(ndr_push_eventlog6_StringArray(ndr, NDR_SCALARS, &r->stringArray));
519 break; }
520
521 case EvtRpcVarTypeGuidArray: {
522 NDR_CHECK(ndr_push_eventlog6_GuidArray(ndr, NDR_SCALARS, &r->guidArray));
523 break; }
524
525 default:
526 return ndr_push_error(ndr, NDR_ERR_BAD_SWITCH, "Bad switch value %u at %s", level, __location__);
527 }
528 }
529 if (ndr_flags & NDR_BUFFERS) {
530 uint32_t level = ndr_push_get_switch_value(ndr, r);
531 switch (level) {
532 case EvtRpcVarTypeNull:
533 break;
534
535 case EvtRpcVarTypeboolean8:
536 break;
537
538 case EvtRpcVarTypeUInt32:
539 break;
540
541 case EvtRpcVarTypeUInt64:
542 break;
543
544 case EvtRpcVarTypeString:
545 if (r->stringVal) {
546 NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->stringVal, CH_UTF16)));
547 NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, 0));
548 NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->stringVal, CH_UTF16)));
549 NDR_CHECK(ndr_push_charset(ndr, NDR_SCALARS, r->stringVal, ndr_charset_length(r->stringVal, CH_UTF16), sizeof(uint16_t), CH_UTF16));
550 }
551 break;
552
553 case EvtRpcVarTypeGuid:
554 if (r->guidVal) {
555 NDR_CHECK(ndr_push_GUID(ndr, NDR_SCALARS, r->guidVal));
556 }
557 break;
558
559 case EvtRpcVarTypeboolean8Array:
560 NDR_CHECK(ndr_push_eventlog6_boolean8Array(ndr, NDR_BUFFERS, &r->boolean8Array));
561 break;
562
563 case EvtRpcVarTypeUInt32Array:
564 NDR_CHECK(ndr_push_eventlog6_UInt32Array(ndr, NDR_BUFFERS, &r->uint32Array));
565 break;
566
567 case EvtRpcVarTypeUInt64Array:
568 NDR_CHECK(ndr_push_eventlog6_UInt64Array(ndr, NDR_BUFFERS, &r->uint64Array));
569 break;
570
571 case EvtRpcVarTypeStringArray:
572 NDR_CHECK(ndr_push_eventlog6_StringArray(ndr, NDR_BUFFERS, &r->stringArray));
573 break;
574
575 case EvtRpcVarTypeGuidArray:
576 NDR_CHECK(ndr_push_eventlog6_GuidArray(ndr, NDR_BUFFERS, &r->guidArray));
577 break;
578
579 default:
580 return ndr_push_error(ndr, NDR_ERR_BAD_SWITCH, "Bad switch value %u at %s", level, __location__);
581 }
582 }
583 return NDR_ERR_SUCCESS;
584}
585
586static enum ndr_err_code ndr_pull_eventlog6_EvtRpcVariantUnion(struct ndr_pull *ndr, int ndr_flags, union eventlog6_EvtRpcVariantUnion *r)
587{
588 uint32_t level;
589 uint32_t _level;
590 TALLOC_CTX *_mem_save_stringVal_0;
591 uint32_t _ptr_stringVal;
592 uint32_t size_stringVal_1 = 0;
593 uint32_t length_stringVal_1 = 0;
594 TALLOC_CTX *_mem_save_guidVal_0;
595 uint32_t _ptr_guidVal;
596 level = ndr_pull_get_switch_value(ndr, r);
597 if (ndr_flags & NDR_SCALARS) {
598 NDR_CHECK(ndr_pull_union_align(ndr, 8));
599 NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &_level));
600 if (_level != level) {
601 return ndr_pull_error(ndr, NDR_ERR_BAD_SWITCH, "Bad switch value %u for r at %s", _level, __location__);
602 }
603 NDR_CHECK(ndr_pull_union_align(ndr, 8));
604 switch (level) {
605 case EvtRpcVarTypeNull: {
606 NDR_CHECK(ndr_pull_int32(ndr, NDR_SCALARS, &r->nullVal));
607 break; }
608
609 case EvtRpcVarTypeboolean8: {
610 NDR_CHECK(ndr_pull_uint8(ndr, NDR_SCALARS, &r->boolean8Val));
611 break; }
612
613 case EvtRpcVarTypeUInt32: {
614 NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->uint32Val));
615 break; }
616
617 case EvtRpcVarTypeUInt64: {
618 NDR_CHECK(ndr_pull_hyper(ndr, NDR_SCALARS, &r->uint64Val));
619 break; }
620
621 case EvtRpcVarTypeString: {
622 NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_stringVal));
623 if (_ptr_stringVal) {
624 NDR_PULL_ALLOC(ndr, r->stringVal);
625 } else {
626 r->stringVal = NULL;
627 }
628 break; }
629
630 case EvtRpcVarTypeGuid: {
631 NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_guidVal));
632 if (_ptr_guidVal) {
633 NDR_PULL_ALLOC(ndr, r->guidVal);
634 } else {
635 r->guidVal = NULL;
636 }
637 break; }
638
639 case EvtRpcVarTypeboolean8Array: {
640 NDR_CHECK(ndr_pull_eventlog6_boolean8Array(ndr, NDR_SCALARS, &r->boolean8Array));
641 break; }
642
643 case EvtRpcVarTypeUInt32Array: {
644 NDR_CHECK(ndr_pull_eventlog6_UInt32Array(ndr, NDR_SCALARS, &r->uint32Array));
645 break; }
646
647 case EvtRpcVarTypeUInt64Array: {
648 NDR_CHECK(ndr_pull_eventlog6_UInt64Array(ndr, NDR_SCALARS, &r->uint64Array));
649 break; }
650
651 case EvtRpcVarTypeStringArray: {
652 NDR_CHECK(ndr_pull_eventlog6_StringArray(ndr, NDR_SCALARS, &r->stringArray));
653 break; }
654
655 case EvtRpcVarTypeGuidArray: {
656 NDR_CHECK(ndr_pull_eventlog6_GuidArray(ndr, NDR_SCALARS, &r->guidArray));
657 break; }
658
659 default:
660 return ndr_pull_error(ndr, NDR_ERR_BAD_SWITCH, "Bad switch value %u at %s", level, __location__);
661 }
662 }
663 if (ndr_flags & NDR_BUFFERS) {
664 switch (level) {
665 case EvtRpcVarTypeNull:
666 break;
667
668 case EvtRpcVarTypeboolean8:
669 break;
670
671 case EvtRpcVarTypeUInt32:
672 break;
673
674 case EvtRpcVarTypeUInt64:
675 break;
676
677 case EvtRpcVarTypeString:
678 if (r->stringVal) {
679 _mem_save_stringVal_0 = NDR_PULL_GET_MEM_CTX(ndr);
680 NDR_PULL_SET_MEM_CTX(ndr, r->stringVal, 0);
681 NDR_CHECK(ndr_pull_array_size(ndr, &r->stringVal));
682 NDR_CHECK(ndr_pull_array_length(ndr, &r->stringVal));
683 size_stringVal_1 = ndr_get_array_size(ndr, &r->stringVal);
684 length_stringVal_1 = ndr_get_array_length(ndr, &r->stringVal);
685 if (length_stringVal_1 > size_stringVal_1) {
686 return ndr_pull_error(ndr, NDR_ERR_ARRAY_SIZE, "Bad array size %u should exceed array length %u", size_stringVal_1, length_stringVal_1);
687 }
688 NDR_CHECK(ndr_check_string_terminator(ndr, length_stringVal_1, sizeof(uint16_t)));
689 NDR_CHECK(ndr_pull_charset(ndr, NDR_SCALARS, &r->stringVal, length_stringVal_1, sizeof(uint16_t), CH_UTF16));
690 NDR_PULL_SET_MEM_CTX(ndr, _mem_save_stringVal_0, 0);
691 }
692 break;
693
694 case EvtRpcVarTypeGuid:
695 if (r->guidVal) {
696 _mem_save_guidVal_0 = NDR_PULL_GET_MEM_CTX(ndr);
697 NDR_PULL_SET_MEM_CTX(ndr, r->guidVal, 0);
698 NDR_CHECK(ndr_pull_GUID(ndr, NDR_SCALARS, r->guidVal));
699 NDR_PULL_SET_MEM_CTX(ndr, _mem_save_guidVal_0, 0);
700 }
701 break;
702
703 case EvtRpcVarTypeboolean8Array:
704 NDR_CHECK(ndr_pull_eventlog6_boolean8Array(ndr, NDR_BUFFERS, &r->boolean8Array));
705 break;
706
707 case EvtRpcVarTypeUInt32Array:
708 NDR_CHECK(ndr_pull_eventlog6_UInt32Array(ndr, NDR_BUFFERS, &r->uint32Array));
709 break;
710
711 case EvtRpcVarTypeUInt64Array:
712 NDR_CHECK(ndr_pull_eventlog6_UInt64Array(ndr, NDR_BUFFERS, &r->uint64Array));
713 break;
714
715 case EvtRpcVarTypeStringArray:
716 NDR_CHECK(ndr_pull_eventlog6_StringArray(ndr, NDR_BUFFERS, &r->stringArray));
717 break;
718
719 case EvtRpcVarTypeGuidArray:
720 NDR_CHECK(ndr_pull_eventlog6_GuidArray(ndr, NDR_BUFFERS, &r->guidArray));
721 break;
722
723 default:
724 return ndr_pull_error(ndr, NDR_ERR_BAD_SWITCH, "Bad switch value %u at %s", level, __location__);
725 }
726 }
727 return NDR_ERR_SUCCESS;
728}
729
730_PUBLIC_ void ndr_print_eventlog6_EvtRpcVariantUnion(struct ndr_print *ndr, const char *name, const union eventlog6_EvtRpcVariantUnion *r)
731{
732 uint32_t level;
733 level = ndr_print_get_switch_value(ndr, r);
734 ndr_print_union(ndr, name, level, "eventlog6_EvtRpcVariantUnion");
735 switch (level) {
736 case EvtRpcVarTypeNull:
737 ndr_print_int32(ndr, "nullVal", r->nullVal);
738 break;
739
740 case EvtRpcVarTypeboolean8:
741 ndr_print_uint8(ndr, "boolean8Val", r->boolean8Val);
742 break;
743
744 case EvtRpcVarTypeUInt32:
745 ndr_print_uint32(ndr, "uint32Val", r->uint32Val);
746 break;
747
748 case EvtRpcVarTypeUInt64:
749 ndr_print_hyper(ndr, "uint64Val", r->uint64Val);
750 break;
751
752 case EvtRpcVarTypeString:
753 ndr_print_ptr(ndr, "stringVal", r->stringVal);
754 ndr->depth++;
755 if (r->stringVal) {
756 ndr_print_string(ndr, "stringVal", r->stringVal);
757 }
758 ndr->depth--;
759 break;
760
761 case EvtRpcVarTypeGuid:
762 ndr_print_ptr(ndr, "guidVal", r->guidVal);
763 ndr->depth++;
764 if (r->guidVal) {
765 ndr_print_GUID(ndr, "guidVal", r->guidVal);
766 }
767 ndr->depth--;
768 break;
769
770 case EvtRpcVarTypeboolean8Array:
771 ndr_print_eventlog6_boolean8Array(ndr, "boolean8Array", &r->boolean8Array);
772 break;
773
774 case EvtRpcVarTypeUInt32Array:
775 ndr_print_eventlog6_UInt32Array(ndr, "uint32Array", &r->uint32Array);
776 break;
777
778 case EvtRpcVarTypeUInt64Array:
779 ndr_print_eventlog6_UInt64Array(ndr, "uint64Array", &r->uint64Array);
780 break;
781
782 case EvtRpcVarTypeStringArray:
783 ndr_print_eventlog6_StringArray(ndr, "stringArray", &r->stringArray);
784 break;
785
786 case EvtRpcVarTypeGuidArray:
787 ndr_print_eventlog6_GuidArray(ndr, "guidArray", &r->guidArray);
788 break;
789
790 default:
791 ndr_print_bad_level(ndr, name, level);
792 }
793}
794
795static enum ndr_err_code ndr_push_eventlog6_EvtRpcVariant(struct ndr_push *ndr, int ndr_flags, const struct eventlog6_EvtRpcVariant *r)
796{
797 if (ndr_flags & NDR_SCALARS) {
798 NDR_CHECK(ndr_push_align(ndr, 5));
799 NDR_CHECK(ndr_push_eventlog6_EvtRpcVariantType(ndr, NDR_SCALARS, r->type));
800 NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->flags));
801 if (r->var == NULL) {
802 return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
803 }
804 NDR_CHECK(ndr_push_ref_ptr(ndr));
805 NDR_CHECK(ndr_push_trailer_align(ndr, 5));
806 }
807 if (ndr_flags & NDR_BUFFERS) {
808 NDR_CHECK(ndr_push_set_switch_value(ndr, r->var, r->type));
809 NDR_CHECK(ndr_push_eventlog6_EvtRpcVariantUnion(ndr, NDR_SCALARS|NDR_BUFFERS, r->var));
810 }
811 return NDR_ERR_SUCCESS;
812}
813
814static enum ndr_err_code ndr_pull_eventlog6_EvtRpcVariant(struct ndr_pull *ndr, int ndr_flags, struct eventlog6_EvtRpcVariant *r)
815{
816 uint32_t _ptr_var;
817 TALLOC_CTX *_mem_save_var_0;
818 if (ndr_flags & NDR_SCALARS) {
819 NDR_CHECK(ndr_pull_align(ndr, 5));
820 NDR_CHECK(ndr_pull_eventlog6_EvtRpcVariantType(ndr, NDR_SCALARS, &r->type));
821 NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->flags));
822 NDR_CHECK(ndr_pull_ref_ptr(ndr, &_ptr_var));
823 if (_ptr_var) {
824 NDR_PULL_ALLOC(ndr, r->var);
825 } else {
826 r->var = NULL;
827 }
828 NDR_CHECK(ndr_pull_trailer_align(ndr, 5));
829 }
830 if (ndr_flags & NDR_BUFFERS) {
831 _mem_save_var_0 = NDR_PULL_GET_MEM_CTX(ndr);
832 NDR_PULL_SET_MEM_CTX(ndr, r->var, 0);
833 NDR_CHECK(ndr_pull_set_switch_value(ndr, r->var, r->type));
834 NDR_CHECK(ndr_pull_eventlog6_EvtRpcVariantUnion(ndr, NDR_SCALARS|NDR_BUFFERS, r->var));
835 NDR_PULL_SET_MEM_CTX(ndr, _mem_save_var_0, 0);
836 }
837 return NDR_ERR_SUCCESS;
838}
839
840_PUBLIC_ void ndr_print_eventlog6_EvtRpcVariant(struct ndr_print *ndr, const char *name, const struct eventlog6_EvtRpcVariant *r)
841{
842 ndr_print_struct(ndr, name, "eventlog6_EvtRpcVariant");
843 if (r == NULL) { ndr_print_null(ndr); return; }
844 ndr->depth++;
845 ndr_print_eventlog6_EvtRpcVariantType(ndr, "type", r->type);
846 ndr_print_uint32(ndr, "flags", r->flags);
847 ndr_print_ptr(ndr, "var", r->var);
848 ndr->depth++;
849 ndr_print_set_switch_value(ndr, r->var, r->type);
850 ndr_print_eventlog6_EvtRpcVariantUnion(ndr, "var", r->var);
851 ndr->depth--;
852 ndr->depth--;
853}
854
855static enum ndr_err_code ndr_push_eventlog6_EvtRpcVariantList(struct ndr_push *ndr, int ndr_flags, const struct eventlog6_EvtRpcVariantList *r)
856{
857 uint32_t cntr_props_1;
858 if (ndr_flags & NDR_SCALARS) {
859 NDR_CHECK(ndr_push_align(ndr, 5));
860 NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->count));
861 NDR_CHECK(ndr_push_unique_ptr(ndr, r->props));
862 NDR_CHECK(ndr_push_trailer_align(ndr, 5));
863 }
864 if (ndr_flags & NDR_BUFFERS) {
865 if (r->props) {
866 NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, r->count));
867 for (cntr_props_1 = 0; cntr_props_1 < r->count; cntr_props_1++) {
868 NDR_CHECK(ndr_push_eventlog6_EvtRpcVariant(ndr, NDR_SCALARS, &r->props[cntr_props_1]));
869 }
870 for (cntr_props_1 = 0; cntr_props_1 < r->count; cntr_props_1++) {
871 NDR_CHECK(ndr_push_eventlog6_EvtRpcVariant(ndr, NDR_BUFFERS, &r->props[cntr_props_1]));
872 }
873 }
874 }
875 return NDR_ERR_SUCCESS;
876}
877
878static enum ndr_err_code ndr_pull_eventlog6_EvtRpcVariantList(struct ndr_pull *ndr, int ndr_flags, struct eventlog6_EvtRpcVariantList *r)
879{
880 uint32_t _ptr_props;
881 uint32_t size_props_1 = 0;
882 uint32_t cntr_props_1;
883 TALLOC_CTX *_mem_save_props_0;
884 TALLOC_CTX *_mem_save_props_1;
885 if (ndr_flags & NDR_SCALARS) {
886 NDR_CHECK(ndr_pull_align(ndr, 5));
887 NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->count));
888 if (r->count > MAX_RPC_VARIANT_LIST_COUNT) {
889 return ndr_pull_error(ndr, NDR_ERR_RANGE, "value out of range");
890 }
891 NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_props));
892 if (_ptr_props) {
893 NDR_PULL_ALLOC(ndr, r->props);
894 } else {
895 r->props = NULL;
896 }
897 NDR_CHECK(ndr_pull_trailer_align(ndr, 5));
898 }
899 if (ndr_flags & NDR_BUFFERS) {
900 if (r->props) {
901 _mem_save_props_0 = NDR_PULL_GET_MEM_CTX(ndr);
902 NDR_PULL_SET_MEM_CTX(ndr, r->props, 0);
903 NDR_CHECK(ndr_pull_array_size(ndr, &r->props));
904 size_props_1 = ndr_get_array_size(ndr, &r->props);
905 NDR_PULL_ALLOC_N(ndr, r->props, size_props_1);
906 _mem_save_props_1 = NDR_PULL_GET_MEM_CTX(ndr);
907 NDR_PULL_SET_MEM_CTX(ndr, r->props, 0);
908 for (cntr_props_1 = 0; cntr_props_1 < size_props_1; cntr_props_1++) {
909 NDR_CHECK(ndr_pull_eventlog6_EvtRpcVariant(ndr, NDR_SCALARS, &r->props[cntr_props_1]));
910 }
911 for (cntr_props_1 = 0; cntr_props_1 < size_props_1; cntr_props_1++) {
912 NDR_CHECK(ndr_pull_eventlog6_EvtRpcVariant(ndr, NDR_BUFFERS, &r->props[cntr_props_1]));
913 }
914 NDR_PULL_SET_MEM_CTX(ndr, _mem_save_props_1, 0);
915 NDR_PULL_SET_MEM_CTX(ndr, _mem_save_props_0, 0);
916 }
917 if (r->props) {
918 NDR_CHECK(ndr_check_array_size(ndr, (void*)&r->props, r->count));
919 }
920 }
921 return NDR_ERR_SUCCESS;
922}
923
924_PUBLIC_ void ndr_print_eventlog6_EvtRpcVariantList(struct ndr_print *ndr, const char *name, const struct eventlog6_EvtRpcVariantList *r)
925{
926 uint32_t cntr_props_1;
927 ndr_print_struct(ndr, name, "eventlog6_EvtRpcVariantList");
928 if (r == NULL) { ndr_print_null(ndr); return; }
929 ndr->depth++;
930 ndr_print_uint32(ndr, "count", r->count);
931 ndr_print_ptr(ndr, "props", r->props);
932 ndr->depth++;
933 if (r->props) {
934 ndr->print(ndr, "%s: ARRAY(%d)", "props", (int)r->count);
935 ndr->depth++;
936 for (cntr_props_1=0;cntr_props_1<r->count;cntr_props_1++) {
937 ndr_print_eventlog6_EvtRpcVariant(ndr, "props", &r->props[cntr_props_1]);
938 }
939 ndr->depth--;
940 }
941 ndr->depth--;
942 ndr->depth--;
943}
944
945static enum ndr_err_code ndr_push_eventlog6_EvtRpcQueryChannelInfo(struct ndr_push *ndr, int ndr_flags, const struct eventlog6_EvtRpcQueryChannelInfo *r)
946{
947 if (ndr_flags & NDR_SCALARS) {
948 NDR_CHECK(ndr_push_align(ndr, 5));
949 NDR_CHECK(ndr_push_unique_ptr(ndr, r->name));
950 NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->status));
951 NDR_CHECK(ndr_push_trailer_align(ndr, 5));
952 }
953 if (ndr_flags & NDR_BUFFERS) {
954 if (r->name) {
955 NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->name, CH_UTF16)));
956 NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, 0));
957 NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->name, CH_UTF16)));
958 NDR_CHECK(ndr_push_charset(ndr, NDR_SCALARS, r->name, ndr_charset_length(r->name, CH_UTF16), sizeof(uint16_t), CH_UTF16));
959 }
960 }
961 return NDR_ERR_SUCCESS;
962}
963
964static enum ndr_err_code ndr_pull_eventlog6_EvtRpcQueryChannelInfo(struct ndr_pull *ndr, int ndr_flags, struct eventlog6_EvtRpcQueryChannelInfo *r)
965{
966 uint32_t _ptr_name;
967 uint32_t size_name_1 = 0;
968 uint32_t length_name_1 = 0;
969 TALLOC_CTX *_mem_save_name_0;
970 if (ndr_flags & NDR_SCALARS) {
971 NDR_CHECK(ndr_pull_align(ndr, 5));
972 NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_name));
973 if (_ptr_name) {
974 NDR_PULL_ALLOC(ndr, r->name);
975 } else {
976 r->name = NULL;
977 }
978 NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->status));
979 NDR_CHECK(ndr_pull_trailer_align(ndr, 5));
980 }
981 if (ndr_flags & NDR_BUFFERS) {
982 if (r->name) {
983 _mem_save_name_0 = NDR_PULL_GET_MEM_CTX(ndr);
984 NDR_PULL_SET_MEM_CTX(ndr, r->name, 0);
985 NDR_CHECK(ndr_pull_array_size(ndr, &r->name));
986 NDR_CHECK(ndr_pull_array_length(ndr, &r->name));
987 size_name_1 = ndr_get_array_size(ndr, &r->name);
988 length_name_1 = ndr_get_array_length(ndr, &r->name);
989 if (length_name_1 > size_name_1) {
990 return ndr_pull_error(ndr, NDR_ERR_ARRAY_SIZE, "Bad array size %u should exceed array length %u", size_name_1, length_name_1);
991 }
992 NDR_CHECK(ndr_check_string_terminator(ndr, length_name_1, sizeof(uint16_t)));
993 NDR_CHECK(ndr_pull_charset(ndr, NDR_SCALARS, &r->name, length_name_1, sizeof(uint16_t), CH_UTF16));
994 NDR_PULL_SET_MEM_CTX(ndr, _mem_save_name_0, 0);
995 }
996 }
997 return NDR_ERR_SUCCESS;
998}
999
1000_PUBLIC_ void ndr_print_eventlog6_EvtRpcQueryChannelInfo(struct ndr_print *ndr, const char *name, const struct eventlog6_EvtRpcQueryChannelInfo *r)
1001{
1002 ndr_print_struct(ndr, name, "eventlog6_EvtRpcQueryChannelInfo");
1003 if (r == NULL) { ndr_print_null(ndr); return; }
1004 ndr->depth++;
1005 ndr_print_ptr(ndr, "name", r->name);
1006 ndr->depth++;
1007 if (r->name) {
1008 ndr_print_string(ndr, "name", r->name);
1009 }
1010 ndr->depth--;
1011 ndr_print_uint32(ndr, "status", r->status);
1012 ndr->depth--;
1013}
1014
1015static enum ndr_err_code ndr_push_eventlog6_EvtRpcRegisterRemoteSubscription(struct ndr_push *ndr, int flags, const struct eventlog6_EvtRpcRegisterRemoteSubscription *r)
1016{
1017 uint32_t cntr_queryChannelInfo_2;
1018 if (flags & NDR_IN) {
1019 NDR_CHECK(ndr_push_unique_ptr(ndr, r->in.channelPath));
1020 if (r->in.channelPath) {
1021 NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->in.channelPath, CH_UTF16)));
1022 NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, 0));
1023 NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->in.channelPath, CH_UTF16)));
1024 NDR_CHECK(ndr_push_charset(ndr, NDR_SCALARS, r->in.channelPath, ndr_charset_length(r->in.channelPath, CH_UTF16), sizeof(uint16_t), CH_UTF16));
1025 }
1026 if (r->in.query == NULL) {
1027 return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
1028 }
1029 NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->in.query, CH_UTF16)));
1030 NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, 0));
1031 NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->in.query, CH_UTF16)));
1032 NDR_CHECK(ndr_push_charset(ndr, NDR_SCALARS, r->in.query, ndr_charset_length(r->in.query, CH_UTF16), sizeof(uint16_t), CH_UTF16));
1033 NDR_CHECK(ndr_push_unique_ptr(ndr, r->in.bookmarkXml));
1034 if (r->in.bookmarkXml) {
1035 NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->in.bookmarkXml, CH_UTF16)));
1036 NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, 0));
1037 NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->in.bookmarkXml, CH_UTF16)));
1038 NDR_CHECK(ndr_push_charset(ndr, NDR_SCALARS, r->in.bookmarkXml, ndr_charset_length(r->in.bookmarkXml, CH_UTF16), sizeof(uint16_t), CH_UTF16));
1039 }
1040 NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->in.flags));
1041 }
1042 if (flags & NDR_OUT) {
1043 if (r->out.handle == NULL) {
1044 return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
1045 }
1046 NDR_CHECK(ndr_push_policy_handle(ndr, NDR_SCALARS, r->out.handle));
1047 if (r->out.control == NULL) {
1048 return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
1049 }
1050 NDR_CHECK(ndr_push_policy_handle(ndr, NDR_SCALARS, r->out.control));
1051 if (r->out.queryChannelInfoSize == NULL) {
1052 return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
1053 }
1054 NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, *r->out.queryChannelInfoSize));
1055 if (r->out.queryChannelInfo == NULL) {
1056 return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
1057 }
1058 NDR_CHECK(ndr_push_unique_ptr(ndr, *r->out.queryChannelInfo));
1059 if (*r->out.queryChannelInfo) {
1060 NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, *r->out.queryChannelInfoSize));
1061 for (cntr_queryChannelInfo_2 = 0; cntr_queryChannelInfo_2 < *r->out.queryChannelInfoSize; cntr_queryChannelInfo_2++) {
1062 NDR_CHECK(ndr_push_eventlog6_EvtRpcQueryChannelInfo(ndr, NDR_SCALARS, &(*r->out.queryChannelInfo)[cntr_queryChannelInfo_2]));
1063 }
1064 for (cntr_queryChannelInfo_2 = 0; cntr_queryChannelInfo_2 < *r->out.queryChannelInfoSize; cntr_queryChannelInfo_2++) {
1065 NDR_CHECK(ndr_push_eventlog6_EvtRpcQueryChannelInfo(ndr, NDR_BUFFERS, &(*r->out.queryChannelInfo)[cntr_queryChannelInfo_2]));
1066 }
1067 }
1068 if (r->out.error == NULL) {
1069 return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
1070 }
1071 NDR_CHECK(ndr_push_eventlog6_RpcInfo(ndr, NDR_SCALARS, r->out.error));
1072 NDR_CHECK(ndr_push_WERROR(ndr, NDR_SCALARS, r->out.result));
1073 }
1074 return NDR_ERR_SUCCESS;
1075}
1076
1077static enum ndr_err_code ndr_pull_eventlog6_EvtRpcRegisterRemoteSubscription(struct ndr_pull *ndr, int flags, struct eventlog6_EvtRpcRegisterRemoteSubscription *r)
1078{
1079 uint32_t _ptr_channelPath;
1080 uint32_t size_channelPath_1 = 0;
1081 uint32_t length_channelPath_1 = 0;
1082 uint32_t size_query_1 = 0;
1083 uint32_t length_query_1 = 0;
1084 uint32_t _ptr_bookmarkXml;
1085 uint32_t size_bookmarkXml_1 = 0;
1086 uint32_t length_bookmarkXml_1 = 0;
1087 uint32_t _ptr_queryChannelInfo;
1088 uint32_t size_queryChannelInfo_2 = 0;
1089 uint32_t cntr_queryChannelInfo_2;
1090 TALLOC_CTX *_mem_save_channelPath_0;
1091 TALLOC_CTX *_mem_save_bookmarkXml_0;
1092 TALLOC_CTX *_mem_save_handle_0;
1093 TALLOC_CTX *_mem_save_control_0;
1094 TALLOC_CTX *_mem_save_queryChannelInfoSize_0;
1095 TALLOC_CTX *_mem_save_queryChannelInfo_0;
1096 TALLOC_CTX *_mem_save_queryChannelInfo_1;
1097 TALLOC_CTX *_mem_save_queryChannelInfo_2;
1098 TALLOC_CTX *_mem_save_error_0;
1099 if (flags & NDR_IN) {
1100 ZERO_STRUCT(r->out);
1101
1102 NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_channelPath));
1103 if (_ptr_channelPath) {
1104 NDR_PULL_ALLOC(ndr, r->in.channelPath);
1105 } else {
1106 r->in.channelPath = NULL;
1107 }
1108 if (r->in.channelPath) {
1109 _mem_save_channelPath_0 = NDR_PULL_GET_MEM_CTX(ndr);
1110 NDR_PULL_SET_MEM_CTX(ndr, r->in.channelPath, 0);
1111 NDR_CHECK(ndr_pull_array_size(ndr, &r->in.channelPath));
1112 NDR_CHECK(ndr_pull_array_length(ndr, &r->in.channelPath));
1113 size_channelPath_1 = ndr_get_array_size(ndr, &r->in.channelPath);
1114 if (size_channelPath_1 > MAX_RPC_CHANNEL_NAME_LENGTH) {
1115 return ndr_pull_error(ndr, NDR_ERR_RANGE, "value out of range");
1116 }
1117 length_channelPath_1 = ndr_get_array_length(ndr, &r->in.channelPath);
1118 if (length_channelPath_1 > MAX_RPC_CHANNEL_NAME_LENGTH) {
1119 return ndr_pull_error(ndr, NDR_ERR_RANGE, "value out of range");
1120 }
1121 if (length_channelPath_1 > size_channelPath_1) {
1122 return ndr_pull_error(ndr, NDR_ERR_ARRAY_SIZE, "Bad array size %u should exceed array length %u", size_channelPath_1, length_channelPath_1);
1123 }
1124 NDR_CHECK(ndr_check_string_terminator(ndr, length_channelPath_1, sizeof(uint16_t)));
1125 NDR_CHECK(ndr_pull_charset(ndr, NDR_SCALARS, &r->in.channelPath, length_channelPath_1, sizeof(uint16_t), CH_UTF16));
1126 NDR_PULL_SET_MEM_CTX(ndr, _mem_save_channelPath_0, 0);
1127 }
1128 NDR_CHECK(ndr_pull_array_size(ndr, &r->in.query));
1129 NDR_CHECK(ndr_pull_array_length(ndr, &r->in.query));
1130 size_query_1 = ndr_get_array_size(ndr, &r->in.query);
1131 if (size_query_1 < 1 || size_query_1 > MAX_RPC_QUERY_LENGTH) {
1132 return ndr_pull_error(ndr, NDR_ERR_RANGE, "value out of range");
1133 }
1134 length_query_1 = ndr_get_array_length(ndr, &r->in.query);
1135 if (length_query_1 < 1 || length_query_1 > MAX_RPC_QUERY_LENGTH) {
1136 return ndr_pull_error(ndr, NDR_ERR_RANGE, "value out of range");
1137 }
1138 if (length_query_1 > size_query_1) {
1139 return ndr_pull_error(ndr, NDR_ERR_ARRAY_SIZE, "Bad array size %u should exceed array length %u", size_query_1, length_query_1);
1140 }
1141 NDR_CHECK(ndr_check_string_terminator(ndr, length_query_1, sizeof(uint16_t)));
1142 NDR_CHECK(ndr_pull_charset(ndr, NDR_SCALARS, &r->in.query, length_query_1, sizeof(uint16_t), CH_UTF16));
1143 NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_bookmarkXml));
1144 if (_ptr_bookmarkXml) {
1145 NDR_PULL_ALLOC(ndr, r->in.bookmarkXml);
1146 } else {
1147 r->in.bookmarkXml = NULL;
1148 }
1149 if (r->in.bookmarkXml) {
1150 _mem_save_bookmarkXml_0 = NDR_PULL_GET_MEM_CTX(ndr);
1151 NDR_PULL_SET_MEM_CTX(ndr, r->in.bookmarkXml, 0);
1152 NDR_CHECK(ndr_pull_array_size(ndr, &r->in.bookmarkXml));
1153 NDR_CHECK(ndr_pull_array_length(ndr, &r->in.bookmarkXml));
1154 size_bookmarkXml_1 = ndr_get_array_size(ndr, &r->in.bookmarkXml);
1155 if (size_bookmarkXml_1 > MAX_RPC_BOOKMARK_LENGTH) {
1156 return ndr_pull_error(ndr, NDR_ERR_RANGE, "value out of range");
1157 }
1158 length_bookmarkXml_1 = ndr_get_array_length(ndr, &r->in.bookmarkXml);
1159 if (length_bookmarkXml_1 > MAX_RPC_BOOKMARK_LENGTH) {
1160 return ndr_pull_error(ndr, NDR_ERR_RANGE, "value out of range");
1161 }
1162 if (length_bookmarkXml_1 > size_bookmarkXml_1) {
1163 return ndr_pull_error(ndr, NDR_ERR_ARRAY_SIZE, "Bad array size %u should exceed array length %u", size_bookmarkXml_1, length_bookmarkXml_1);
1164 }
1165 NDR_CHECK(ndr_check_string_terminator(ndr, length_bookmarkXml_1, sizeof(uint16_t)));
1166 NDR_CHECK(ndr_pull_charset(ndr, NDR_SCALARS, &r->in.bookmarkXml, length_bookmarkXml_1, sizeof(uint16_t), CH_UTF16));
1167 NDR_PULL_SET_MEM_CTX(ndr, _mem_save_bookmarkXml_0, 0);
1168 }
1169 NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->in.flags));
1170 NDR_PULL_ALLOC(ndr, r->out.handle);
1171 ZERO_STRUCTP(r->out.handle);
1172 NDR_PULL_ALLOC(ndr, r->out.control);
1173 ZERO_STRUCTP(r->out.control);
1174 NDR_PULL_ALLOC(ndr, r->out.queryChannelInfoSize);
1175 ZERO_STRUCTP(r->out.queryChannelInfoSize);
1176 NDR_PULL_ALLOC(ndr, r->out.queryChannelInfo);
1177 ZERO_STRUCTP(r->out.queryChannelInfo);
1178 NDR_PULL_ALLOC(ndr, r->out.error);
1179 ZERO_STRUCTP(r->out.error);
1180 }
1181 if (flags & NDR_OUT) {
1182 if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
1183 NDR_PULL_ALLOC(ndr, r->out.handle);
1184 }
1185 _mem_save_handle_0 = NDR_PULL_GET_MEM_CTX(ndr);
1186 NDR_PULL_SET_MEM_CTX(ndr, r->out.handle, LIBNDR_FLAG_REF_ALLOC);
1187 NDR_CHECK(ndr_pull_policy_handle(ndr, NDR_SCALARS, r->out.handle));
1188 NDR_PULL_SET_MEM_CTX(ndr, _mem_save_handle_0, LIBNDR_FLAG_REF_ALLOC);
1189 if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
1190 NDR_PULL_ALLOC(ndr, r->out.control);
1191 }
1192 _mem_save_control_0 = NDR_PULL_GET_MEM_CTX(ndr);
1193 NDR_PULL_SET_MEM_CTX(ndr, r->out.control, LIBNDR_FLAG_REF_ALLOC);
1194 NDR_CHECK(ndr_pull_policy_handle(ndr, NDR_SCALARS, r->out.control));
1195 NDR_PULL_SET_MEM_CTX(ndr, _mem_save_control_0, LIBNDR_FLAG_REF_ALLOC);
1196 if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
1197 NDR_PULL_ALLOC(ndr, r->out.queryChannelInfoSize);
1198 }
1199 _mem_save_queryChannelInfoSize_0 = NDR_PULL_GET_MEM_CTX(ndr);
1200 NDR_PULL_SET_MEM_CTX(ndr, r->out.queryChannelInfoSize, LIBNDR_FLAG_REF_ALLOC);
1201 NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, r->out.queryChannelInfoSize));
1202 NDR_PULL_SET_MEM_CTX(ndr, _mem_save_queryChannelInfoSize_0, LIBNDR_FLAG_REF_ALLOC);
1203 if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
1204 NDR_PULL_ALLOC(ndr, r->out.queryChannelInfo);
1205 }
1206 _mem_save_queryChannelInfo_0 = NDR_PULL_GET_MEM_CTX(ndr);
1207 NDR_PULL_SET_MEM_CTX(ndr, r->out.queryChannelInfo, LIBNDR_FLAG_REF_ALLOC);
1208 NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_queryChannelInfo));
1209 if (_ptr_queryChannelInfo) {
1210 NDR_PULL_ALLOC(ndr, *r->out.queryChannelInfo);
1211 } else {
1212 *r->out.queryChannelInfo = NULL;
1213 }
1214 if (*r->out.queryChannelInfo) {
1215 _mem_save_queryChannelInfo_1 = NDR_PULL_GET_MEM_CTX(ndr);
1216 NDR_PULL_SET_MEM_CTX(ndr, *r->out.queryChannelInfo, 0);
1217 NDR_CHECK(ndr_pull_array_size(ndr, r->out.queryChannelInfo));
1218 size_queryChannelInfo_2 = ndr_get_array_size(ndr, r->out.queryChannelInfo);
1219 if (size_queryChannelInfo_2 > MAX_RPC_QUERY_CHANNEL_SIZE) {
1220 return ndr_pull_error(ndr, NDR_ERR_RANGE, "value out of range");
1221 }
1222 NDR_PULL_ALLOC_N(ndr, *r->out.queryChannelInfo, size_queryChannelInfo_2);
1223 _mem_save_queryChannelInfo_2 = NDR_PULL_GET_MEM_CTX(ndr);
1224 NDR_PULL_SET_MEM_CTX(ndr, *r->out.queryChannelInfo, 0);
1225 for (cntr_queryChannelInfo_2 = 0; cntr_queryChannelInfo_2 < size_queryChannelInfo_2; cntr_queryChannelInfo_2++) {
1226 NDR_CHECK(ndr_pull_eventlog6_EvtRpcQueryChannelInfo(ndr, NDR_SCALARS, &(*r->out.queryChannelInfo)[cntr_queryChannelInfo_2]));
1227 }
1228 for (cntr_queryChannelInfo_2 = 0; cntr_queryChannelInfo_2 < size_queryChannelInfo_2; cntr_queryChannelInfo_2++) {
1229 NDR_CHECK(ndr_pull_eventlog6_EvtRpcQueryChannelInfo(ndr, NDR_BUFFERS, &(*r->out.queryChannelInfo)[cntr_queryChannelInfo_2]));
1230 }
1231 NDR_PULL_SET_MEM_CTX(ndr, _mem_save_queryChannelInfo_2, 0);
1232 NDR_PULL_SET_MEM_CTX(ndr, _mem_save_queryChannelInfo_1, 0);
1233 }
1234 NDR_PULL_SET_MEM_CTX(ndr, _mem_save_queryChannelInfo_0, LIBNDR_FLAG_REF_ALLOC);
1235 if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
1236 NDR_PULL_ALLOC(ndr, r->out.error);
1237 }
1238 _mem_save_error_0 = NDR_PULL_GET_MEM_CTX(ndr);
1239 NDR_PULL_SET_MEM_CTX(ndr, r->out.error, LIBNDR_FLAG_REF_ALLOC);
1240 NDR_CHECK(ndr_pull_eventlog6_RpcInfo(ndr, NDR_SCALARS, r->out.error));
1241 NDR_PULL_SET_MEM_CTX(ndr, _mem_save_error_0, LIBNDR_FLAG_REF_ALLOC);
1242 NDR_CHECK(ndr_pull_WERROR(ndr, NDR_SCALARS, &r->out.result));
1243 if (*r->out.queryChannelInfo) {
1244 NDR_CHECK(ndr_check_array_size(ndr, (void*)r->out.queryChannelInfo, *r->out.queryChannelInfoSize));
1245 }
1246 }
1247 return NDR_ERR_SUCCESS;
1248}
1249
1250_PUBLIC_ void ndr_print_eventlog6_EvtRpcRegisterRemoteSubscription(struct ndr_print *ndr, const char *name, int flags, const struct eventlog6_EvtRpcRegisterRemoteSubscription *r)
1251{
1252 uint32_t cntr_queryChannelInfo_2;
1253 ndr_print_struct(ndr, name, "eventlog6_EvtRpcRegisterRemoteSubscription");
1254 if (r == NULL) { ndr_print_null(ndr); return; }
1255 ndr->depth++;
1256 if (flags & NDR_SET_VALUES) {
1257 ndr->flags |= LIBNDR_PRINT_SET_VALUES;
1258 }
1259 if (flags & NDR_IN) {
1260 ndr_print_struct(ndr, "in", "eventlog6_EvtRpcRegisterRemoteSubscription");
1261 ndr->depth++;
1262 ndr_print_ptr(ndr, "channelPath", r->in.channelPath);
1263 ndr->depth++;
1264 if (r->in.channelPath) {
1265 ndr_print_string(ndr, "channelPath", r->in.channelPath);
1266 }
1267 ndr->depth--;
1268 ndr_print_ptr(ndr, "query", r->in.query);
1269 ndr->depth++;
1270 ndr_print_string(ndr, "query", r->in.query);
1271 ndr->depth--;
1272 ndr_print_ptr(ndr, "bookmarkXml", r->in.bookmarkXml);
1273 ndr->depth++;
1274 if (r->in.bookmarkXml) {
1275 ndr_print_string(ndr, "bookmarkXml", r->in.bookmarkXml);
1276 }
1277 ndr->depth--;
1278 ndr_print_uint32(ndr, "flags", r->in.flags);
1279 ndr->depth--;
1280 }
1281 if (flags & NDR_OUT) {
1282 ndr_print_struct(ndr, "out", "eventlog6_EvtRpcRegisterRemoteSubscription");
1283 ndr->depth++;
1284 ndr_print_ptr(ndr, "handle", r->out.handle);
1285 ndr->depth++;
1286 ndr_print_policy_handle(ndr, "handle", r->out.handle);
1287 ndr->depth--;
1288 ndr_print_ptr(ndr, "control", r->out.control);
1289 ndr->depth++;
1290 ndr_print_policy_handle(ndr, "control", r->out.control);
1291 ndr->depth--;
1292 ndr_print_ptr(ndr, "queryChannelInfoSize", r->out.queryChannelInfoSize);
1293 ndr->depth++;
1294 ndr_print_uint32(ndr, "queryChannelInfoSize", *r->out.queryChannelInfoSize);
1295 ndr->depth--;
1296 ndr_print_ptr(ndr, "queryChannelInfo", r->out.queryChannelInfo);
1297 ndr->depth++;
1298 ndr_print_ptr(ndr, "queryChannelInfo", *r->out.queryChannelInfo);
1299 ndr->depth++;
1300 if (*r->out.queryChannelInfo) {
1301 ndr->print(ndr, "%s: ARRAY(%d)", "queryChannelInfo", (int)*r->out.queryChannelInfoSize);
1302 ndr->depth++;
1303 for (cntr_queryChannelInfo_2=0;cntr_queryChannelInfo_2<*r->out.queryChannelInfoSize;cntr_queryChannelInfo_2++) {
1304 ndr_print_eventlog6_EvtRpcQueryChannelInfo(ndr, "queryChannelInfo", &(*r->out.queryChannelInfo)[cntr_queryChannelInfo_2]);
1305 }
1306 ndr->depth--;
1307 }
1308 ndr->depth--;
1309 ndr->depth--;
1310 ndr_print_ptr(ndr, "error", r->out.error);
1311 ndr->depth++;
1312 ndr_print_eventlog6_RpcInfo(ndr, "error", r->out.error);
1313 ndr->depth--;
1314 ndr_print_WERROR(ndr, "result", r->out.result);
1315 ndr->depth--;
1316 }
1317 ndr->depth--;
1318}
1319
1320static enum ndr_err_code ndr_push_eventlog6_EvtRpcRemoteSubscriptionNextAsync(struct ndr_push *ndr, int flags, const struct eventlog6_EvtRpcRemoteSubscriptionNextAsync *r)
1321{
1322 uint32_t cntr_eventDataIndices_2;
1323 uint32_t cntr_eventDataSizes_2;
1324 if (flags & NDR_IN) {
1325 if (r->in.handle == NULL) {
1326 return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
1327 }
1328 NDR_CHECK(ndr_push_policy_handle(ndr, NDR_SCALARS, r->in.handle));
1329 NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->in.numRequestedRecords));
1330 NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->in.flags));
1331 }
1332 if (flags & NDR_OUT) {
1333 if (r->out.numActualRecords == NULL) {
1334 return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
1335 }
1336 NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, *r->out.numActualRecords));
1337 if (r->out.eventDataIndices == NULL) {
1338 return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
1339 }
1340 NDR_CHECK(ndr_push_unique_ptr(ndr, *r->out.eventDataIndices));
1341 if (*r->out.eventDataIndices) {
1342 NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, *r->out.numActualRecords));
1343 for (cntr_eventDataIndices_2 = 0; cntr_eventDataIndices_2 < *r->out.numActualRecords; cntr_eventDataIndices_2++) {
1344 NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, (*r->out.eventDataIndices)[cntr_eventDataIndices_2]));
1345 }
1346 }
1347 if (r->out.eventDataSizes == NULL) {
1348 return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
1349 }
1350 NDR_CHECK(ndr_push_unique_ptr(ndr, *r->out.eventDataSizes));
1351 if (*r->out.eventDataSizes) {
1352 NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, *r->out.numActualRecords));
1353 for (cntr_eventDataSizes_2 = 0; cntr_eventDataSizes_2 < *r->out.numActualRecords; cntr_eventDataSizes_2++) {
1354 NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, (*r->out.eventDataSizes)[cntr_eventDataSizes_2]));
1355 }
1356 }
1357 if (r->out.resultBufferSize == NULL) {
1358 return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
1359 }
1360 NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, *r->out.resultBufferSize));
1361 if (r->out.resultBuffer == NULL) {
1362 return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
1363 }
1364 NDR_CHECK(ndr_push_unique_ptr(ndr, *r->out.resultBuffer));
1365 if (*r->out.resultBuffer) {
1366 NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, *r->out.resultBufferSize));
1367 NDR_CHECK(ndr_push_array_uint8(ndr, NDR_SCALARS, *r->out.resultBuffer, *r->out.resultBufferSize));
1368 }
1369 NDR_CHECK(ndr_push_WERROR(ndr, NDR_SCALARS, r->out.result));
1370 }
1371 return NDR_ERR_SUCCESS;
1372}
1373
1374static enum ndr_err_code ndr_pull_eventlog6_EvtRpcRemoteSubscriptionNextAsync(struct ndr_pull *ndr, int flags, struct eventlog6_EvtRpcRemoteSubscriptionNextAsync *r)
1375{
1376 uint32_t _ptr_eventDataIndices;
1377 uint32_t size_eventDataIndices_2 = 0;
1378 uint32_t cntr_eventDataIndices_2;
1379 uint32_t _ptr_eventDataSizes;
1380 uint32_t size_eventDataSizes_2 = 0;
1381 uint32_t cntr_eventDataSizes_2;
1382 uint32_t _ptr_resultBuffer;
1383 uint32_t size_resultBuffer_2 = 0;
1384 TALLOC_CTX *_mem_save_handle_0;
1385 TALLOC_CTX *_mem_save_numActualRecords_0;
1386 TALLOC_CTX *_mem_save_eventDataIndices_0;
1387 TALLOC_CTX *_mem_save_eventDataIndices_1;
1388 TALLOC_CTX *_mem_save_eventDataIndices_2;
1389 TALLOC_CTX *_mem_save_eventDataSizes_0;
1390 TALLOC_CTX *_mem_save_eventDataSizes_1;
1391 TALLOC_CTX *_mem_save_eventDataSizes_2;
1392 TALLOC_CTX *_mem_save_resultBufferSize_0;
1393 TALLOC_CTX *_mem_save_resultBuffer_0;
1394 TALLOC_CTX *_mem_save_resultBuffer_1;
1395 if (flags & NDR_IN) {
1396 ZERO_STRUCT(r->out);
1397
1398 if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
1399 NDR_PULL_ALLOC(ndr, r->in.handle);
1400 }
1401 _mem_save_handle_0 = NDR_PULL_GET_MEM_CTX(ndr);
1402 NDR_PULL_SET_MEM_CTX(ndr, r->in.handle, LIBNDR_FLAG_REF_ALLOC);
1403 NDR_CHECK(ndr_pull_policy_handle(ndr, NDR_SCALARS, r->in.handle));
1404 NDR_PULL_SET_MEM_CTX(ndr, _mem_save_handle_0, LIBNDR_FLAG_REF_ALLOC);
1405 NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->in.numRequestedRecords));
1406 NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->in.flags));
1407 NDR_PULL_ALLOC(ndr, r->out.numActualRecords);
1408 ZERO_STRUCTP(r->out.numActualRecords);
1409 NDR_PULL_ALLOC(ndr, r->out.eventDataIndices);
1410 ZERO_STRUCTP(r->out.eventDataIndices);
1411 NDR_PULL_ALLOC(ndr, r->out.eventDataSizes);
1412 ZERO_STRUCTP(r->out.eventDataSizes);
1413 NDR_PULL_ALLOC(ndr, r->out.resultBufferSize);
1414 ZERO_STRUCTP(r->out.resultBufferSize);
1415 NDR_PULL_ALLOC(ndr, r->out.resultBuffer);
1416 ZERO_STRUCTP(r->out.resultBuffer);
1417 }
1418 if (flags & NDR_OUT) {
1419 if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
1420 NDR_PULL_ALLOC(ndr, r->out.numActualRecords);
1421 }
1422 _mem_save_numActualRecords_0 = NDR_PULL_GET_MEM_CTX(ndr);
1423 NDR_PULL_SET_MEM_CTX(ndr, r->out.numActualRecords, LIBNDR_FLAG_REF_ALLOC);
1424 NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, r->out.numActualRecords));
1425 NDR_PULL_SET_MEM_CTX(ndr, _mem_save_numActualRecords_0, LIBNDR_FLAG_REF_ALLOC);
1426 if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
1427 NDR_PULL_ALLOC(ndr, r->out.eventDataIndices);
1428 }
1429 _mem_save_eventDataIndices_0 = NDR_PULL_GET_MEM_CTX(ndr);
1430 NDR_PULL_SET_MEM_CTX(ndr, r->out.eventDataIndices, LIBNDR_FLAG_REF_ALLOC);
1431 NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_eventDataIndices));
1432 if (_ptr_eventDataIndices) {
1433 NDR_PULL_ALLOC(ndr, *r->out.eventDataIndices);
1434 } else {
1435 *r->out.eventDataIndices = NULL;
1436 }
1437 if (*r->out.eventDataIndices) {
1438 _mem_save_eventDataIndices_1 = NDR_PULL_GET_MEM_CTX(ndr);
1439 NDR_PULL_SET_MEM_CTX(ndr, *r->out.eventDataIndices, 0);
1440 NDR_CHECK(ndr_pull_array_size(ndr, r->out.eventDataIndices));
1441 size_eventDataIndices_2 = ndr_get_array_size(ndr, r->out.eventDataIndices);
1442 if (size_eventDataIndices_2 > MAX_RPC_RECORD_COUNT) {
1443 return ndr_pull_error(ndr, NDR_ERR_RANGE, "value out of range");
1444 }
1445 NDR_PULL_ALLOC_N(ndr, *r->out.eventDataIndices, size_eventDataIndices_2);
1446 _mem_save_eventDataIndices_2 = NDR_PULL_GET_MEM_CTX(ndr);
1447 NDR_PULL_SET_MEM_CTX(ndr, *r->out.eventDataIndices, 0);
1448 for (cntr_eventDataIndices_2 = 0; cntr_eventDataIndices_2 < size_eventDataIndices_2; cntr_eventDataIndices_2++) {
1449 NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &(*r->out.eventDataIndices)[cntr_eventDataIndices_2]));
1450 }
1451 NDR_PULL_SET_MEM_CTX(ndr, _mem_save_eventDataIndices_2, 0);
1452 NDR_PULL_SET_MEM_CTX(ndr, _mem_save_eventDataIndices_1, 0);
1453 }
1454 NDR_PULL_SET_MEM_CTX(ndr, _mem_save_eventDataIndices_0, LIBNDR_FLAG_REF_ALLOC);
1455 if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
1456 NDR_PULL_ALLOC(ndr, r->out.eventDataSizes);
1457 }
1458 _mem_save_eventDataSizes_0 = NDR_PULL_GET_MEM_CTX(ndr);
1459 NDR_PULL_SET_MEM_CTX(ndr, r->out.eventDataSizes, LIBNDR_FLAG_REF_ALLOC);
1460 NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_eventDataSizes));
1461 if (_ptr_eventDataSizes) {
1462 NDR_PULL_ALLOC(ndr, *r->out.eventDataSizes);
1463 } else {
1464 *r->out.eventDataSizes = NULL;
1465 }
1466 if (*r->out.eventDataSizes) {
1467 _mem_save_eventDataSizes_1 = NDR_PULL_GET_MEM_CTX(ndr);
1468 NDR_PULL_SET_MEM_CTX(ndr, *r->out.eventDataSizes, 0);
1469 NDR_CHECK(ndr_pull_array_size(ndr, r->out.eventDataSizes));
1470 size_eventDataSizes_2 = ndr_get_array_size(ndr, r->out.eventDataSizes);
1471 if (size_eventDataSizes_2 > MAX_RPC_RECORD_COUNT) {
1472 return ndr_pull_error(ndr, NDR_ERR_RANGE, "value out of range");
1473 }
1474 NDR_PULL_ALLOC_N(ndr, *r->out.eventDataSizes, size_eventDataSizes_2);
1475 _mem_save_eventDataSizes_2 = NDR_PULL_GET_MEM_CTX(ndr);
1476 NDR_PULL_SET_MEM_CTX(ndr, *r->out.eventDataSizes, 0);
1477 for (cntr_eventDataSizes_2 = 0; cntr_eventDataSizes_2 < size_eventDataSizes_2; cntr_eventDataSizes_2++) {
1478 NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &(*r->out.eventDataSizes)[cntr_eventDataSizes_2]));
1479 }
1480 NDR_PULL_SET_MEM_CTX(ndr, _mem_save_eventDataSizes_2, 0);
1481 NDR_PULL_SET_MEM_CTX(ndr, _mem_save_eventDataSizes_1, 0);
1482 }
1483 NDR_PULL_SET_MEM_CTX(ndr, _mem_save_eventDataSizes_0, LIBNDR_FLAG_REF_ALLOC);
1484 if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
1485 NDR_PULL_ALLOC(ndr, r->out.resultBufferSize);
1486 }
1487 _mem_save_resultBufferSize_0 = NDR_PULL_GET_MEM_CTX(ndr);
1488 NDR_PULL_SET_MEM_CTX(ndr, r->out.resultBufferSize, LIBNDR_FLAG_REF_ALLOC);
1489 NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, r->out.resultBufferSize));
1490 NDR_PULL_SET_MEM_CTX(ndr, _mem_save_resultBufferSize_0, LIBNDR_FLAG_REF_ALLOC);
1491 if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
1492 NDR_PULL_ALLOC(ndr, r->out.resultBuffer);
1493 }
1494 _mem_save_resultBuffer_0 = NDR_PULL_GET_MEM_CTX(ndr);
1495 NDR_PULL_SET_MEM_CTX(ndr, r->out.resultBuffer, LIBNDR_FLAG_REF_ALLOC);
1496 NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_resultBuffer));
1497 if (_ptr_resultBuffer) {
1498 NDR_PULL_ALLOC(ndr, *r->out.resultBuffer);
1499 } else {
1500 *r->out.resultBuffer = NULL;
1501 }
1502 if (*r->out.resultBuffer) {
1503 _mem_save_resultBuffer_1 = NDR_PULL_GET_MEM_CTX(ndr);
1504 NDR_PULL_SET_MEM_CTX(ndr, *r->out.resultBuffer, 0);
1505 NDR_CHECK(ndr_pull_array_size(ndr, r->out.resultBuffer));
1506 size_resultBuffer_2 = ndr_get_array_size(ndr, r->out.resultBuffer);
1507 if (size_resultBuffer_2 > MAX_RPC_BATCH_SIZE) {
1508 return ndr_pull_error(ndr, NDR_ERR_RANGE, "value out of range");
1509 }
1510 NDR_PULL_ALLOC_N(ndr, *r->out.resultBuffer, size_resultBuffer_2);
1511 NDR_CHECK(ndr_pull_array_uint8(ndr, NDR_SCALARS, *r->out.resultBuffer, size_resultBuffer_2));
1512 NDR_PULL_SET_MEM_CTX(ndr, _mem_save_resultBuffer_1, 0);
1513 }
1514 NDR_PULL_SET_MEM_CTX(ndr, _mem_save_resultBuffer_0, LIBNDR_FLAG_REF_ALLOC);
1515 NDR_CHECK(ndr_pull_WERROR(ndr, NDR_SCALARS, &r->out.result));
1516 if (*r->out.eventDataIndices) {
1517 NDR_CHECK(ndr_check_array_size(ndr, (void*)r->out.eventDataIndices, *r->out.numActualRecords));
1518 }
1519 if (*r->out.eventDataSizes) {
1520 NDR_CHECK(ndr_check_array_size(ndr, (void*)r->out.eventDataSizes, *r->out.numActualRecords));
1521 }
1522 if (*r->out.resultBuffer) {
1523 NDR_CHECK(ndr_check_array_size(ndr, (void*)r->out.resultBuffer, *r->out.resultBufferSize));
1524 }
1525 }
1526 return NDR_ERR_SUCCESS;
1527}
1528
1529_PUBLIC_ void ndr_print_eventlog6_EvtRpcRemoteSubscriptionNextAsync(struct ndr_print *ndr, const char *name, int flags, const struct eventlog6_EvtRpcRemoteSubscriptionNextAsync *r)
1530{
1531 uint32_t cntr_eventDataIndices_2;
1532 uint32_t cntr_eventDataSizes_2;
1533 ndr_print_struct(ndr, name, "eventlog6_EvtRpcRemoteSubscriptionNextAsync");
1534 if (r == NULL) { ndr_print_null(ndr); return; }
1535 ndr->depth++;
1536 if (flags & NDR_SET_VALUES) {
1537 ndr->flags |= LIBNDR_PRINT_SET_VALUES;
1538 }
1539 if (flags & NDR_IN) {
1540 ndr_print_struct(ndr, "in", "eventlog6_EvtRpcRemoteSubscriptionNextAsync");
1541 ndr->depth++;
1542 ndr_print_ptr(ndr, "handle", r->in.handle);
1543 ndr->depth++;
1544 ndr_print_policy_handle(ndr, "handle", r->in.handle);
1545 ndr->depth--;
1546 ndr_print_uint32(ndr, "numRequestedRecords", r->in.numRequestedRecords);
1547 ndr_print_uint32(ndr, "flags", r->in.flags);
1548 ndr->depth--;
1549 }
1550 if (flags & NDR_OUT) {
1551 ndr_print_struct(ndr, "out", "eventlog6_EvtRpcRemoteSubscriptionNextAsync");
1552 ndr->depth++;
1553 ndr_print_ptr(ndr, "numActualRecords", r->out.numActualRecords);
1554 ndr->depth++;
1555 ndr_print_uint32(ndr, "numActualRecords", *r->out.numActualRecords);
1556 ndr->depth--;
1557 ndr_print_ptr(ndr, "eventDataIndices", r->out.eventDataIndices);
1558 ndr->depth++;
1559 ndr_print_ptr(ndr, "eventDataIndices", *r->out.eventDataIndices);
1560 ndr->depth++;
1561 if (*r->out.eventDataIndices) {
1562 ndr->print(ndr, "%s: ARRAY(%d)", "eventDataIndices", (int)*r->out.numActualRecords);
1563 ndr->depth++;
1564 for (cntr_eventDataIndices_2=0;cntr_eventDataIndices_2<*r->out.numActualRecords;cntr_eventDataIndices_2++) {
1565 ndr_print_uint32(ndr, "eventDataIndices", (*r->out.eventDataIndices)[cntr_eventDataIndices_2]);
1566 }
1567 ndr->depth--;
1568 }
1569 ndr->depth--;
1570 ndr->depth--;
1571 ndr_print_ptr(ndr, "eventDataSizes", r->out.eventDataSizes);
1572 ndr->depth++;
1573 ndr_print_ptr(ndr, "eventDataSizes", *r->out.eventDataSizes);
1574 ndr->depth++;
1575 if (*r->out.eventDataSizes) {
1576 ndr->print(ndr, "%s: ARRAY(%d)", "eventDataSizes", (int)*r->out.numActualRecords);
1577 ndr->depth++;
1578 for (cntr_eventDataSizes_2=0;cntr_eventDataSizes_2<*r->out.numActualRecords;cntr_eventDataSizes_2++) {
1579 ndr_print_uint32(ndr, "eventDataSizes", (*r->out.eventDataSizes)[cntr_eventDataSizes_2]);
1580 }
1581 ndr->depth--;
1582 }
1583 ndr->depth--;
1584 ndr->depth--;
1585 ndr_print_ptr(ndr, "resultBufferSize", r->out.resultBufferSize);
1586 ndr->depth++;
1587 ndr_print_uint32(ndr, "resultBufferSize", *r->out.resultBufferSize);
1588 ndr->depth--;
1589 ndr_print_ptr(ndr, "resultBuffer", r->out.resultBuffer);
1590 ndr->depth++;
1591 ndr_print_ptr(ndr, "resultBuffer", *r->out.resultBuffer);
1592 ndr->depth++;
1593 if (*r->out.resultBuffer) {
1594 ndr_print_array_uint8(ndr, "resultBuffer", *r->out.resultBuffer, *r->out.resultBufferSize);
1595 }
1596 ndr->depth--;
1597 ndr->depth--;
1598 ndr_print_WERROR(ndr, "result", r->out.result);
1599 ndr->depth--;
1600 }
1601 ndr->depth--;
1602}
1603
1604static enum ndr_err_code ndr_push_eventlog6_EvtRpcRemoteSubscriptionNext(struct ndr_push *ndr, int flags, const struct eventlog6_EvtRpcRemoteSubscriptionNext *r)
1605{
1606 uint32_t cntr_eventDataIndices_2;
1607 uint32_t cntr_eventDataSizes_2;
1608 if (flags & NDR_IN) {
1609 if (r->in.handle == NULL) {
1610 return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
1611 }
1612 NDR_CHECK(ndr_push_policy_handle(ndr, NDR_SCALARS, r->in.handle));
1613 NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->in.numRequestedRecords));
1614 NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->in.timeOut));
1615 NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->in.flags));
1616 }
1617 if (flags & NDR_OUT) {
1618 if (r->out.numActualRecords == NULL) {
1619 return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
1620 }
1621 NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, *r->out.numActualRecords));
1622 if (r->out.eventDataIndices == NULL) {
1623 return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
1624 }
1625 NDR_CHECK(ndr_push_unique_ptr(ndr, *r->out.eventDataIndices));
1626 if (*r->out.eventDataIndices) {
1627 NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, *r->out.numActualRecords));
1628 for (cntr_eventDataIndices_2 = 0; cntr_eventDataIndices_2 < *r->out.numActualRecords; cntr_eventDataIndices_2++) {
1629 NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, (*r->out.eventDataIndices)[cntr_eventDataIndices_2]));
1630 }
1631 }
1632 if (r->out.eventDataSizes == NULL) {
1633 return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
1634 }
1635 NDR_CHECK(ndr_push_unique_ptr(ndr, *r->out.eventDataSizes));
1636 if (*r->out.eventDataSizes) {
1637 NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, *r->out.numActualRecords));
1638 for (cntr_eventDataSizes_2 = 0; cntr_eventDataSizes_2 < *r->out.numActualRecords; cntr_eventDataSizes_2++) {
1639 NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, (*r->out.eventDataSizes)[cntr_eventDataSizes_2]));
1640 }
1641 }
1642 if (r->out.resultBufferSize == NULL) {
1643 return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
1644 }
1645 NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, *r->out.resultBufferSize));
1646 if (r->out.resultBuffer == NULL) {
1647 return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
1648 }
1649 NDR_CHECK(ndr_push_unique_ptr(ndr, *r->out.resultBuffer));
1650 if (*r->out.resultBuffer) {
1651 NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, *r->out.resultBufferSize));
1652 NDR_CHECK(ndr_push_array_uint8(ndr, NDR_SCALARS, *r->out.resultBuffer, *r->out.resultBufferSize));
1653 }
1654 NDR_CHECK(ndr_push_WERROR(ndr, NDR_SCALARS, r->out.result));
1655 }
1656 return NDR_ERR_SUCCESS;
1657}
1658
1659static enum ndr_err_code ndr_pull_eventlog6_EvtRpcRemoteSubscriptionNext(struct ndr_pull *ndr, int flags, struct eventlog6_EvtRpcRemoteSubscriptionNext *r)
1660{
1661 uint32_t _ptr_eventDataIndices;
1662 uint32_t size_eventDataIndices_2 = 0;
1663 uint32_t cntr_eventDataIndices_2;
1664 uint32_t _ptr_eventDataSizes;
1665 uint32_t size_eventDataSizes_2 = 0;
1666 uint32_t cntr_eventDataSizes_2;
1667 uint32_t _ptr_resultBuffer;
1668 uint32_t size_resultBuffer_2 = 0;
1669 TALLOC_CTX *_mem_save_handle_0;
1670 TALLOC_CTX *_mem_save_numActualRecords_0;
1671 TALLOC_CTX *_mem_save_eventDataIndices_0;
1672 TALLOC_CTX *_mem_save_eventDataIndices_1;
1673 TALLOC_CTX *_mem_save_eventDataIndices_2;
1674 TALLOC_CTX *_mem_save_eventDataSizes_0;
1675 TALLOC_CTX *_mem_save_eventDataSizes_1;
1676 TALLOC_CTX *_mem_save_eventDataSizes_2;
1677 TALLOC_CTX *_mem_save_resultBufferSize_0;
1678 TALLOC_CTX *_mem_save_resultBuffer_0;
1679 TALLOC_CTX *_mem_save_resultBuffer_1;
1680 if (flags & NDR_IN) {
1681 ZERO_STRUCT(r->out);
1682
1683 if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
1684 NDR_PULL_ALLOC(ndr, r->in.handle);
1685 }
1686 _mem_save_handle_0 = NDR_PULL_GET_MEM_CTX(ndr);
1687 NDR_PULL_SET_MEM_CTX(ndr, r->in.handle, LIBNDR_FLAG_REF_ALLOC);
1688 NDR_CHECK(ndr_pull_policy_handle(ndr, NDR_SCALARS, r->in.handle));
1689 NDR_PULL_SET_MEM_CTX(ndr, _mem_save_handle_0, LIBNDR_FLAG_REF_ALLOC);
1690 NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->in.numRequestedRecords));
1691 NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->in.timeOut));
1692 NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->in.flags));
1693 NDR_PULL_ALLOC(ndr, r->out.numActualRecords);
1694 ZERO_STRUCTP(r->out.numActualRecords);
1695 NDR_PULL_ALLOC(ndr, r->out.eventDataIndices);
1696 ZERO_STRUCTP(r->out.eventDataIndices);
1697 NDR_PULL_ALLOC(ndr, r->out.eventDataSizes);
1698 ZERO_STRUCTP(r->out.eventDataSizes);
1699 NDR_PULL_ALLOC(ndr, r->out.resultBufferSize);
1700 ZERO_STRUCTP(r->out.resultBufferSize);
1701 NDR_PULL_ALLOC(ndr, r->out.resultBuffer);
1702 ZERO_STRUCTP(r->out.resultBuffer);
1703 }
1704 if (flags & NDR_OUT) {
1705 if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
1706 NDR_PULL_ALLOC(ndr, r->out.numActualRecords);
1707 }
1708 _mem_save_numActualRecords_0 = NDR_PULL_GET_MEM_CTX(ndr);
1709 NDR_PULL_SET_MEM_CTX(ndr, r->out.numActualRecords, LIBNDR_FLAG_REF_ALLOC);
1710 NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, r->out.numActualRecords));
1711 NDR_PULL_SET_MEM_CTX(ndr, _mem_save_numActualRecords_0, LIBNDR_FLAG_REF_ALLOC);
1712 if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
1713 NDR_PULL_ALLOC(ndr, r->out.eventDataIndices);
1714 }
1715 _mem_save_eventDataIndices_0 = NDR_PULL_GET_MEM_CTX(ndr);
1716 NDR_PULL_SET_MEM_CTX(ndr, r->out.eventDataIndices, LIBNDR_FLAG_REF_ALLOC);
1717 NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_eventDataIndices));
1718 if (_ptr_eventDataIndices) {
1719 NDR_PULL_ALLOC(ndr, *r->out.eventDataIndices);
1720 } else {
1721 *r->out.eventDataIndices = NULL;
1722 }
1723 if (*r->out.eventDataIndices) {
1724 _mem_save_eventDataIndices_1 = NDR_PULL_GET_MEM_CTX(ndr);
1725 NDR_PULL_SET_MEM_CTX(ndr, *r->out.eventDataIndices, 0);
1726 NDR_CHECK(ndr_pull_array_size(ndr, r->out.eventDataIndices));
1727 size_eventDataIndices_2 = ndr_get_array_size(ndr, r->out.eventDataIndices);
1728 if (size_eventDataIndices_2 > MAX_RPC_RECORD_COUNT) {
1729 return ndr_pull_error(ndr, NDR_ERR_RANGE, "value out of range");
1730 }
1731 NDR_PULL_ALLOC_N(ndr, *r->out.eventDataIndices, size_eventDataIndices_2);
1732 _mem_save_eventDataIndices_2 = NDR_PULL_GET_MEM_CTX(ndr);
1733 NDR_PULL_SET_MEM_CTX(ndr, *r->out.eventDataIndices, 0);
1734 for (cntr_eventDataIndices_2 = 0; cntr_eventDataIndices_2 < size_eventDataIndices_2; cntr_eventDataIndices_2++) {
1735 NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &(*r->out.eventDataIndices)[cntr_eventDataIndices_2]));
1736 }
1737 NDR_PULL_SET_MEM_CTX(ndr, _mem_save_eventDataIndices_2, 0);
1738 NDR_PULL_SET_MEM_CTX(ndr, _mem_save_eventDataIndices_1, 0);
1739 }
1740 NDR_PULL_SET_MEM_CTX(ndr, _mem_save_eventDataIndices_0, LIBNDR_FLAG_REF_ALLOC);
1741 if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
1742 NDR_PULL_ALLOC(ndr, r->out.eventDataSizes);
1743 }
1744 _mem_save_eventDataSizes_0 = NDR_PULL_GET_MEM_CTX(ndr);
1745 NDR_PULL_SET_MEM_CTX(ndr, r->out.eventDataSizes, LIBNDR_FLAG_REF_ALLOC);
1746 NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_eventDataSizes));
1747 if (_ptr_eventDataSizes) {
1748 NDR_PULL_ALLOC(ndr, *r->out.eventDataSizes);
1749 } else {
1750 *r->out.eventDataSizes = NULL;
1751 }
1752 if (*r->out.eventDataSizes) {
1753 _mem_save_eventDataSizes_1 = NDR_PULL_GET_MEM_CTX(ndr);
1754 NDR_PULL_SET_MEM_CTX(ndr, *r->out.eventDataSizes, 0);
1755 NDR_CHECK(ndr_pull_array_size(ndr, r->out.eventDataSizes));
1756 size_eventDataSizes_2 = ndr_get_array_size(ndr, r->out.eventDataSizes);
1757 if (size_eventDataSizes_2 > MAX_RPC_RECORD_COUNT) {
1758 return ndr_pull_error(ndr, NDR_ERR_RANGE, "value out of range");
1759 }
1760 NDR_PULL_ALLOC_N(ndr, *r->out.eventDataSizes, size_eventDataSizes_2);
1761 _mem_save_eventDataSizes_2 = NDR_PULL_GET_MEM_CTX(ndr);
1762 NDR_PULL_SET_MEM_CTX(ndr, *r->out.eventDataSizes, 0);
1763 for (cntr_eventDataSizes_2 = 0; cntr_eventDataSizes_2 < size_eventDataSizes_2; cntr_eventDataSizes_2++) {
1764 NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &(*r->out.eventDataSizes)[cntr_eventDataSizes_2]));
1765 }
1766 NDR_PULL_SET_MEM_CTX(ndr, _mem_save_eventDataSizes_2, 0);
1767 NDR_PULL_SET_MEM_CTX(ndr, _mem_save_eventDataSizes_1, 0);
1768 }
1769 NDR_PULL_SET_MEM_CTX(ndr, _mem_save_eventDataSizes_0, LIBNDR_FLAG_REF_ALLOC);
1770 if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
1771 NDR_PULL_ALLOC(ndr, r->out.resultBufferSize);
1772 }
1773 _mem_save_resultBufferSize_0 = NDR_PULL_GET_MEM_CTX(ndr);
1774 NDR_PULL_SET_MEM_CTX(ndr, r->out.resultBufferSize, LIBNDR_FLAG_REF_ALLOC);
1775 NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, r->out.resultBufferSize));
1776 NDR_PULL_SET_MEM_CTX(ndr, _mem_save_resultBufferSize_0, LIBNDR_FLAG_REF_ALLOC);
1777 if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
1778 NDR_PULL_ALLOC(ndr, r->out.resultBuffer);
1779 }
1780 _mem_save_resultBuffer_0 = NDR_PULL_GET_MEM_CTX(ndr);
1781 NDR_PULL_SET_MEM_CTX(ndr, r->out.resultBuffer, LIBNDR_FLAG_REF_ALLOC);
1782 NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_resultBuffer));
1783 if (_ptr_resultBuffer) {
1784 NDR_PULL_ALLOC(ndr, *r->out.resultBuffer);
1785 } else {
1786 *r->out.resultBuffer = NULL;
1787 }
1788 if (*r->out.resultBuffer) {
1789 _mem_save_resultBuffer_1 = NDR_PULL_GET_MEM_CTX(ndr);
1790 NDR_PULL_SET_MEM_CTX(ndr, *r->out.resultBuffer, 0);
1791 NDR_CHECK(ndr_pull_array_size(ndr, r->out.resultBuffer));
1792 size_resultBuffer_2 = ndr_get_array_size(ndr, r->out.resultBuffer);
1793 if (size_resultBuffer_2 > MAX_RPC_BATCH_SIZE) {
1794 return ndr_pull_error(ndr, NDR_ERR_RANGE, "value out of range");
1795 }
1796 NDR_PULL_ALLOC_N(ndr, *r->out.resultBuffer, size_resultBuffer_2);
1797 NDR_CHECK(ndr_pull_array_uint8(ndr, NDR_SCALARS, *r->out.resultBuffer, size_resultBuffer_2));
1798 NDR_PULL_SET_MEM_CTX(ndr, _mem_save_resultBuffer_1, 0);
1799 }
1800 NDR_PULL_SET_MEM_CTX(ndr, _mem_save_resultBuffer_0, LIBNDR_FLAG_REF_ALLOC);
1801 NDR_CHECK(ndr_pull_WERROR(ndr, NDR_SCALARS, &r->out.result));
1802 if (*r->out.eventDataIndices) {
1803 NDR_CHECK(ndr_check_array_size(ndr, (void*)r->out.eventDataIndices, *r->out.numActualRecords));
1804 }
1805 if (*r->out.eventDataSizes) {
1806 NDR_CHECK(ndr_check_array_size(ndr, (void*)r->out.eventDataSizes, *r->out.numActualRecords));
1807 }
1808 if (*r->out.resultBuffer) {
1809 NDR_CHECK(ndr_check_array_size(ndr, (void*)r->out.resultBuffer, *r->out.resultBufferSize));
1810 }
1811 }
1812 return NDR_ERR_SUCCESS;
1813}
1814
1815_PUBLIC_ void ndr_print_eventlog6_EvtRpcRemoteSubscriptionNext(struct ndr_print *ndr, const char *name, int flags, const struct eventlog6_EvtRpcRemoteSubscriptionNext *r)
1816{
1817 uint32_t cntr_eventDataIndices_2;
1818 uint32_t cntr_eventDataSizes_2;
1819 ndr_print_struct(ndr, name, "eventlog6_EvtRpcRemoteSubscriptionNext");
1820 if (r == NULL) { ndr_print_null(ndr); return; }
1821 ndr->depth++;
1822 if (flags & NDR_SET_VALUES) {
1823 ndr->flags |= LIBNDR_PRINT_SET_VALUES;
1824 }
1825 if (flags & NDR_IN) {
1826 ndr_print_struct(ndr, "in", "eventlog6_EvtRpcRemoteSubscriptionNext");
1827 ndr->depth++;
1828 ndr_print_ptr(ndr, "handle", r->in.handle);
1829 ndr->depth++;
1830 ndr_print_policy_handle(ndr, "handle", r->in.handle);
1831 ndr->depth--;
1832 ndr_print_uint32(ndr, "numRequestedRecords", r->in.numRequestedRecords);
1833 ndr_print_uint32(ndr, "timeOut", r->in.timeOut);
1834 ndr_print_uint32(ndr, "flags", r->in.flags);
1835 ndr->depth--;
1836 }
1837 if (flags & NDR_OUT) {
1838 ndr_print_struct(ndr, "out", "eventlog6_EvtRpcRemoteSubscriptionNext");
1839 ndr->depth++;
1840 ndr_print_ptr(ndr, "numActualRecords", r->out.numActualRecords);
1841 ndr->depth++;
1842 ndr_print_uint32(ndr, "numActualRecords", *r->out.numActualRecords);
1843 ndr->depth--;
1844 ndr_print_ptr(ndr, "eventDataIndices", r->out.eventDataIndices);
1845 ndr->depth++;
1846 ndr_print_ptr(ndr, "eventDataIndices", *r->out.eventDataIndices);
1847 ndr->depth++;
1848 if (*r->out.eventDataIndices) {
1849 ndr->print(ndr, "%s: ARRAY(%d)", "eventDataIndices", (int)*r->out.numActualRecords);
1850 ndr->depth++;
1851 for (cntr_eventDataIndices_2=0;cntr_eventDataIndices_2<*r->out.numActualRecords;cntr_eventDataIndices_2++) {
1852 ndr_print_uint32(ndr, "eventDataIndices", (*r->out.eventDataIndices)[cntr_eventDataIndices_2]);
1853 }
1854 ndr->depth--;
1855 }
1856 ndr->depth--;
1857 ndr->depth--;
1858 ndr_print_ptr(ndr, "eventDataSizes", r->out.eventDataSizes);
1859 ndr->depth++;
1860 ndr_print_ptr(ndr, "eventDataSizes", *r->out.eventDataSizes);
1861 ndr->depth++;
1862 if (*r->out.eventDataSizes) {
1863 ndr->print(ndr, "%s: ARRAY(%d)", "eventDataSizes", (int)*r->out.numActualRecords);
1864 ndr->depth++;
1865 for (cntr_eventDataSizes_2=0;cntr_eventDataSizes_2<*r->out.numActualRecords;cntr_eventDataSizes_2++) {
1866 ndr_print_uint32(ndr, "eventDataSizes", (*r->out.eventDataSizes)[cntr_eventDataSizes_2]);
1867 }
1868 ndr->depth--;
1869 }
1870 ndr->depth--;
1871 ndr->depth--;
1872 ndr_print_ptr(ndr, "resultBufferSize", r->out.resultBufferSize);
1873 ndr->depth++;
1874 ndr_print_uint32(ndr, "resultBufferSize", *r->out.resultBufferSize);
1875 ndr->depth--;
1876 ndr_print_ptr(ndr, "resultBuffer", r->out.resultBuffer);
1877 ndr->depth++;
1878 ndr_print_ptr(ndr, "resultBuffer", *r->out.resultBuffer);
1879 ndr->depth++;
1880 if (*r->out.resultBuffer) {
1881 ndr_print_array_uint8(ndr, "resultBuffer", *r->out.resultBuffer, *r->out.resultBufferSize);
1882 }
1883 ndr->depth--;
1884 ndr->depth--;
1885 ndr_print_WERROR(ndr, "result", r->out.result);
1886 ndr->depth--;
1887 }
1888 ndr->depth--;
1889}
1890
1891static enum ndr_err_code ndr_push_eventlog6_EvtRpcRemoteSubscriptionWaitAsync(struct ndr_push *ndr, int flags, const struct eventlog6_EvtRpcRemoteSubscriptionWaitAsync *r)
1892{
1893 if (flags & NDR_IN) {
1894 if (r->in.handle == NULL) {
1895 return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
1896 }
1897 NDR_CHECK(ndr_push_policy_handle(ndr, NDR_SCALARS, r->in.handle));
1898 }
1899 if (flags & NDR_OUT) {
1900 NDR_CHECK(ndr_push_WERROR(ndr, NDR_SCALARS, r->out.result));
1901 }
1902 return NDR_ERR_SUCCESS;
1903}
1904
1905static enum ndr_err_code ndr_pull_eventlog6_EvtRpcRemoteSubscriptionWaitAsync(struct ndr_pull *ndr, int flags, struct eventlog6_EvtRpcRemoteSubscriptionWaitAsync *r)
1906{
1907 TALLOC_CTX *_mem_save_handle_0;
1908 if (flags & NDR_IN) {
1909 if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
1910 NDR_PULL_ALLOC(ndr, r->in.handle);
1911 }
1912 _mem_save_handle_0 = NDR_PULL_GET_MEM_CTX(ndr);
1913 NDR_PULL_SET_MEM_CTX(ndr, r->in.handle, LIBNDR_FLAG_REF_ALLOC);
1914 NDR_CHECK(ndr_pull_policy_handle(ndr, NDR_SCALARS, r->in.handle));
1915 NDR_PULL_SET_MEM_CTX(ndr, _mem_save_handle_0, LIBNDR_FLAG_REF_ALLOC);
1916 }
1917 if (flags & NDR_OUT) {
1918 NDR_CHECK(ndr_pull_WERROR(ndr, NDR_SCALARS, &r->out.result));
1919 }
1920 return NDR_ERR_SUCCESS;
1921}
1922
1923_PUBLIC_ void ndr_print_eventlog6_EvtRpcRemoteSubscriptionWaitAsync(struct ndr_print *ndr, const char *name, int flags, const struct eventlog6_EvtRpcRemoteSubscriptionWaitAsync *r)
1924{
1925 ndr_print_struct(ndr, name, "eventlog6_EvtRpcRemoteSubscriptionWaitAsync");
1926 if (r == NULL) { ndr_print_null(ndr); return; }
1927 ndr->depth++;
1928 if (flags & NDR_SET_VALUES) {
1929 ndr->flags |= LIBNDR_PRINT_SET_VALUES;
1930 }
1931 if (flags & NDR_IN) {
1932 ndr_print_struct(ndr, "in", "eventlog6_EvtRpcRemoteSubscriptionWaitAsync");
1933 ndr->depth++;
1934 ndr_print_ptr(ndr, "handle", r->in.handle);
1935 ndr->depth++;
1936 ndr_print_policy_handle(ndr, "handle", r->in.handle);
1937 ndr->depth--;
1938 ndr->depth--;
1939 }
1940 if (flags & NDR_OUT) {
1941 ndr_print_struct(ndr, "out", "eventlog6_EvtRpcRemoteSubscriptionWaitAsync");
1942 ndr->depth++;
1943 ndr_print_WERROR(ndr, "result", r->out.result);
1944 ndr->depth--;
1945 }
1946 ndr->depth--;
1947}
1948
1949static enum ndr_err_code ndr_push_eventlog6_EvtRpcRegisterControllableOperation(struct ndr_push *ndr, int flags, const struct eventlog6_EvtRpcRegisterControllableOperation *r)
1950{
1951 if (flags & NDR_IN) {
1952 }
1953 if (flags & NDR_OUT) {
1954 if (r->out.handle == NULL) {
1955 return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
1956 }
1957 NDR_CHECK(ndr_push_policy_handle(ndr, NDR_SCALARS, r->out.handle));
1958 NDR_CHECK(ndr_push_WERROR(ndr, NDR_SCALARS, r->out.result));
1959 }
1960 return NDR_ERR_SUCCESS;
1961}
1962
1963static enum ndr_err_code ndr_pull_eventlog6_EvtRpcRegisterControllableOperation(struct ndr_pull *ndr, int flags, struct eventlog6_EvtRpcRegisterControllableOperation *r)
1964{
1965 TALLOC_CTX *_mem_save_handle_0;
1966 if (flags & NDR_IN) {
1967 ZERO_STRUCT(r->out);
1968
1969 NDR_PULL_ALLOC(ndr, r->out.handle);
1970 ZERO_STRUCTP(r->out.handle);
1971 }
1972 if (flags & NDR_OUT) {
1973 if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
1974 NDR_PULL_ALLOC(ndr, r->out.handle);
1975 }
1976 _mem_save_handle_0 = NDR_PULL_GET_MEM_CTX(ndr);
1977 NDR_PULL_SET_MEM_CTX(ndr, r->out.handle, LIBNDR_FLAG_REF_ALLOC);
1978 NDR_CHECK(ndr_pull_policy_handle(ndr, NDR_SCALARS, r->out.handle));
1979 NDR_PULL_SET_MEM_CTX(ndr, _mem_save_handle_0, LIBNDR_FLAG_REF_ALLOC);
1980 NDR_CHECK(ndr_pull_WERROR(ndr, NDR_SCALARS, &r->out.result));
1981 }
1982 return NDR_ERR_SUCCESS;
1983}
1984
1985_PUBLIC_ void ndr_print_eventlog6_EvtRpcRegisterControllableOperation(struct ndr_print *ndr, const char *name, int flags, const struct eventlog6_EvtRpcRegisterControllableOperation *r)
1986{
1987 ndr_print_struct(ndr, name, "eventlog6_EvtRpcRegisterControllableOperation");
1988 if (r == NULL) { ndr_print_null(ndr); return; }
1989 ndr->depth++;
1990 if (flags & NDR_SET_VALUES) {
1991 ndr->flags |= LIBNDR_PRINT_SET_VALUES;
1992 }
1993 if (flags & NDR_IN) {
1994 ndr_print_struct(ndr, "in", "eventlog6_EvtRpcRegisterControllableOperation");
1995 ndr->depth++;
1996 ndr->depth--;
1997 }
1998 if (flags & NDR_OUT) {
1999 ndr_print_struct(ndr, "out", "eventlog6_EvtRpcRegisterControllableOperation");
2000 ndr->depth++;
2001 ndr_print_ptr(ndr, "handle", r->out.handle);
2002 ndr->depth++;
2003 ndr_print_policy_handle(ndr, "handle", r->out.handle);
2004 ndr->depth--;
2005 ndr_print_WERROR(ndr, "result", r->out.result);
2006 ndr->depth--;
2007 }
2008 ndr->depth--;
2009}
2010
2011static enum ndr_err_code ndr_push_eventlog6_EvtRpcRegisterLogQuery(struct ndr_push *ndr, int flags, const struct eventlog6_EvtRpcRegisterLogQuery *r)
2012{
2013 uint32_t cntr_queryChannelInfo_2;
2014 if (flags & NDR_IN) {
2015 NDR_CHECK(ndr_push_unique_ptr(ndr, r->in.path));
2016 if (r->in.path) {
2017 NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->in.path, CH_UTF16)));
2018 NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, 0));
2019 NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->in.path, CH_UTF16)));
2020 NDR_CHECK(ndr_push_charset(ndr, NDR_SCALARS, r->in.path, ndr_charset_length(r->in.path, CH_UTF16), sizeof(uint16_t), CH_UTF16));
2021 }
2022 if (r->in.query == NULL) {
2023 return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
2024 }
2025 NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->in.query, CH_UTF16)));
2026 NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, 0));
2027 NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->in.query, CH_UTF16)));
2028 NDR_CHECK(ndr_push_charset(ndr, NDR_SCALARS, r->in.query, ndr_charset_length(r->in.query, CH_UTF16), sizeof(uint16_t), CH_UTF16));
2029 NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->in.flags));
2030 }
2031 if (flags & NDR_OUT) {
2032 if (r->out.handle == NULL) {
2033 return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
2034 }
2035 NDR_CHECK(ndr_push_policy_handle(ndr, NDR_SCALARS, r->out.handle));
2036 if (r->out.opControl == NULL) {
2037 return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
2038 }
2039 NDR_CHECK(ndr_push_policy_handle(ndr, NDR_SCALARS, r->out.opControl));
2040 if (r->out.queryChannelInfoSize == NULL) {
2041 return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
2042 }
2043 NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, *r->out.queryChannelInfoSize));
2044 if (r->out.queryChannelInfo == NULL) {
2045 return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
2046 }
2047 NDR_CHECK(ndr_push_unique_ptr(ndr, *r->out.queryChannelInfo));
2048 if (*r->out.queryChannelInfo) {
2049 NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, *r->out.queryChannelInfoSize));
2050 for (cntr_queryChannelInfo_2 = 0; cntr_queryChannelInfo_2 < *r->out.queryChannelInfoSize; cntr_queryChannelInfo_2++) {
2051 NDR_CHECK(ndr_push_eventlog6_EvtRpcQueryChannelInfo(ndr, NDR_SCALARS, &(*r->out.queryChannelInfo)[cntr_queryChannelInfo_2]));
2052 }
2053 for (cntr_queryChannelInfo_2 = 0; cntr_queryChannelInfo_2 < *r->out.queryChannelInfoSize; cntr_queryChannelInfo_2++) {
2054 NDR_CHECK(ndr_push_eventlog6_EvtRpcQueryChannelInfo(ndr, NDR_BUFFERS, &(*r->out.queryChannelInfo)[cntr_queryChannelInfo_2]));
2055 }
2056 }
2057 if (r->out.error == NULL) {
2058 return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
2059 }
2060 NDR_CHECK(ndr_push_eventlog6_RpcInfo(ndr, NDR_SCALARS, r->out.error));
2061 NDR_CHECK(ndr_push_WERROR(ndr, NDR_SCALARS, r->out.result));
2062 }
2063 return NDR_ERR_SUCCESS;
2064}
2065
2066static enum ndr_err_code ndr_pull_eventlog6_EvtRpcRegisterLogQuery(struct ndr_pull *ndr, int flags, struct eventlog6_EvtRpcRegisterLogQuery *r)
2067{
2068 uint32_t _ptr_path;
2069 uint32_t size_path_1 = 0;
2070 uint32_t length_path_1 = 0;
2071 uint32_t size_query_1 = 0;
2072 uint32_t length_query_1 = 0;
2073 uint32_t _ptr_queryChannelInfo;
2074 uint32_t size_queryChannelInfo_2 = 0;
2075 uint32_t cntr_queryChannelInfo_2;
2076 TALLOC_CTX *_mem_save_path_0;
2077 TALLOC_CTX *_mem_save_handle_0;
2078 TALLOC_CTX *_mem_save_opControl_0;
2079 TALLOC_CTX *_mem_save_queryChannelInfoSize_0;
2080 TALLOC_CTX *_mem_save_queryChannelInfo_0;
2081 TALLOC_CTX *_mem_save_queryChannelInfo_1;
2082 TALLOC_CTX *_mem_save_queryChannelInfo_2;
2083 TALLOC_CTX *_mem_save_error_0;
2084 if (flags & NDR_IN) {
2085 ZERO_STRUCT(r->out);
2086
2087 NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_path));
2088 if (_ptr_path) {
2089 NDR_PULL_ALLOC(ndr, r->in.path);
2090 } else {
2091 r->in.path = NULL;
2092 }
2093 if (r->in.path) {
2094 _mem_save_path_0 = NDR_PULL_GET_MEM_CTX(ndr);
2095 NDR_PULL_SET_MEM_CTX(ndr, r->in.path, 0);
2096 NDR_CHECK(ndr_pull_array_size(ndr, &r->in.path));
2097 NDR_CHECK(ndr_pull_array_length(ndr, &r->in.path));
2098 size_path_1 = ndr_get_array_size(ndr, &r->in.path);
2099 if (size_path_1 > MAX_RPC_CHANNEL_PATH_LENGTH) {
2100 return ndr_pull_error(ndr, NDR_ERR_RANGE, "value out of range");
2101 }
2102 length_path_1 = ndr_get_array_length(ndr, &r->in.path);
2103 if (length_path_1 > MAX_RPC_CHANNEL_PATH_LENGTH) {
2104 return ndr_pull_error(ndr, NDR_ERR_RANGE, "value out of range");
2105 }
2106 if (length_path_1 > size_path_1) {
2107 return ndr_pull_error(ndr, NDR_ERR_ARRAY_SIZE, "Bad array size %u should exceed array length %u", size_path_1, length_path_1);
2108 }
2109 NDR_CHECK(ndr_check_string_terminator(ndr, length_path_1, sizeof(uint16_t)));
2110 NDR_CHECK(ndr_pull_charset(ndr, NDR_SCALARS, &r->in.path, length_path_1, sizeof(uint16_t), CH_UTF16));
2111 NDR_PULL_SET_MEM_CTX(ndr, _mem_save_path_0, 0);
2112 }
2113 NDR_CHECK(ndr_pull_array_size(ndr, &r->in.query));
2114 NDR_CHECK(ndr_pull_array_length(ndr, &r->in.query));
2115 size_query_1 = ndr_get_array_size(ndr, &r->in.query);
2116 if (size_query_1 < 1 || size_query_1 > MAX_RPC_QUERY_LENGTH) {
2117 return ndr_pull_error(ndr, NDR_ERR_RANGE, "value out of range");
2118 }
2119 length_query_1 = ndr_get_array_length(ndr, &r->in.query);
2120 if (length_query_1 < 1 || length_query_1 > MAX_RPC_QUERY_LENGTH) {
2121 return ndr_pull_error(ndr, NDR_ERR_RANGE, "value out of range");
2122 }
2123 if (length_query_1 > size_query_1) {
2124 return ndr_pull_error(ndr, NDR_ERR_ARRAY_SIZE, "Bad array size %u should exceed array length %u", size_query_1, length_query_1);
2125 }
2126 NDR_CHECK(ndr_check_string_terminator(ndr, length_query_1, sizeof(uint16_t)));
2127 NDR_CHECK(ndr_pull_charset(ndr, NDR_SCALARS, &r->in.query, length_query_1, sizeof(uint16_t), CH_UTF16));
2128 NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->in.flags));
2129 NDR_PULL_ALLOC(ndr, r->out.handle);
2130 ZERO_STRUCTP(r->out.handle);
2131 NDR_PULL_ALLOC(ndr, r->out.opControl);
2132 ZERO_STRUCTP(r->out.opControl);
2133 NDR_PULL_ALLOC(ndr, r->out.queryChannelInfoSize);
2134 ZERO_STRUCTP(r->out.queryChannelInfoSize);
2135 NDR_PULL_ALLOC(ndr, r->out.queryChannelInfo);
2136 ZERO_STRUCTP(r->out.queryChannelInfo);
2137 NDR_PULL_ALLOC(ndr, r->out.error);
2138 ZERO_STRUCTP(r->out.error);
2139 }
2140 if (flags & NDR_OUT) {
2141 if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
2142 NDR_PULL_ALLOC(ndr, r->out.handle);
2143 }
2144 _mem_save_handle_0 = NDR_PULL_GET_MEM_CTX(ndr);
2145 NDR_PULL_SET_MEM_CTX(ndr, r->out.handle, LIBNDR_FLAG_REF_ALLOC);
2146 NDR_CHECK(ndr_pull_policy_handle(ndr, NDR_SCALARS, r->out.handle));
2147 NDR_PULL_SET_MEM_CTX(ndr, _mem_save_handle_0, LIBNDR_FLAG_REF_ALLOC);
2148 if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
2149 NDR_PULL_ALLOC(ndr, r->out.opControl);
2150 }
2151 _mem_save_opControl_0 = NDR_PULL_GET_MEM_CTX(ndr);
2152 NDR_PULL_SET_MEM_CTX(ndr, r->out.opControl, LIBNDR_FLAG_REF_ALLOC);
2153 NDR_CHECK(ndr_pull_policy_handle(ndr, NDR_SCALARS, r->out.opControl));
2154 NDR_PULL_SET_MEM_CTX(ndr, _mem_save_opControl_0, LIBNDR_FLAG_REF_ALLOC);
2155 if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
2156 NDR_PULL_ALLOC(ndr, r->out.queryChannelInfoSize);
2157 }
2158 _mem_save_queryChannelInfoSize_0 = NDR_PULL_GET_MEM_CTX(ndr);
2159 NDR_PULL_SET_MEM_CTX(ndr, r->out.queryChannelInfoSize, LIBNDR_FLAG_REF_ALLOC);
2160 NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, r->out.queryChannelInfoSize));
2161 NDR_PULL_SET_MEM_CTX(ndr, _mem_save_queryChannelInfoSize_0, LIBNDR_FLAG_REF_ALLOC);
2162 if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
2163 NDR_PULL_ALLOC(ndr, r->out.queryChannelInfo);
2164 }
2165 _mem_save_queryChannelInfo_0 = NDR_PULL_GET_MEM_CTX(ndr);
2166 NDR_PULL_SET_MEM_CTX(ndr, r->out.queryChannelInfo, LIBNDR_FLAG_REF_ALLOC);
2167 NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_queryChannelInfo));
2168 if (_ptr_queryChannelInfo) {
2169 NDR_PULL_ALLOC(ndr, *r->out.queryChannelInfo);
2170 } else {
2171 *r->out.queryChannelInfo = NULL;
2172 }
2173 if (*r->out.queryChannelInfo) {
2174 _mem_save_queryChannelInfo_1 = NDR_PULL_GET_MEM_CTX(ndr);
2175 NDR_PULL_SET_MEM_CTX(ndr, *r->out.queryChannelInfo, 0);
2176 NDR_CHECK(ndr_pull_array_size(ndr, r->out.queryChannelInfo));
2177 size_queryChannelInfo_2 = ndr_get_array_size(ndr, r->out.queryChannelInfo);
2178 if (size_queryChannelInfo_2 > MAX_RPC_QUERY_CHANNEL_SIZE) {
2179 return ndr_pull_error(ndr, NDR_ERR_RANGE, "value out of range");
2180 }
2181 NDR_PULL_ALLOC_N(ndr, *r->out.queryChannelInfo, size_queryChannelInfo_2);
2182 _mem_save_queryChannelInfo_2 = NDR_PULL_GET_MEM_CTX(ndr);
2183 NDR_PULL_SET_MEM_CTX(ndr, *r->out.queryChannelInfo, 0);
2184 for (cntr_queryChannelInfo_2 = 0; cntr_queryChannelInfo_2 < size_queryChannelInfo_2; cntr_queryChannelInfo_2++) {
2185 NDR_CHECK(ndr_pull_eventlog6_EvtRpcQueryChannelInfo(ndr, NDR_SCALARS, &(*r->out.queryChannelInfo)[cntr_queryChannelInfo_2]));
2186 }
2187 for (cntr_queryChannelInfo_2 = 0; cntr_queryChannelInfo_2 < size_queryChannelInfo_2; cntr_queryChannelInfo_2++) {
2188 NDR_CHECK(ndr_pull_eventlog6_EvtRpcQueryChannelInfo(ndr, NDR_BUFFERS, &(*r->out.queryChannelInfo)[cntr_queryChannelInfo_2]));
2189 }
2190 NDR_PULL_SET_MEM_CTX(ndr, _mem_save_queryChannelInfo_2, 0);
2191 NDR_PULL_SET_MEM_CTX(ndr, _mem_save_queryChannelInfo_1, 0);
2192 }
2193 NDR_PULL_SET_MEM_CTX(ndr, _mem_save_queryChannelInfo_0, LIBNDR_FLAG_REF_ALLOC);
2194 if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
2195 NDR_PULL_ALLOC(ndr, r->out.error);
2196 }
2197 _mem_save_error_0 = NDR_PULL_GET_MEM_CTX(ndr);
2198 NDR_PULL_SET_MEM_CTX(ndr, r->out.error, LIBNDR_FLAG_REF_ALLOC);
2199 NDR_CHECK(ndr_pull_eventlog6_RpcInfo(ndr, NDR_SCALARS, r->out.error));
2200 NDR_PULL_SET_MEM_CTX(ndr, _mem_save_error_0, LIBNDR_FLAG_REF_ALLOC);
2201 NDR_CHECK(ndr_pull_WERROR(ndr, NDR_SCALARS, &r->out.result));
2202 if (*r->out.queryChannelInfo) {
2203 NDR_CHECK(ndr_check_array_size(ndr, (void*)r->out.queryChannelInfo, *r->out.queryChannelInfoSize));
2204 }
2205 }
2206 return NDR_ERR_SUCCESS;
2207}
2208
2209_PUBLIC_ void ndr_print_eventlog6_EvtRpcRegisterLogQuery(struct ndr_print *ndr, const char *name, int flags, const struct eventlog6_EvtRpcRegisterLogQuery *r)
2210{
2211 uint32_t cntr_queryChannelInfo_2;
2212 ndr_print_struct(ndr, name, "eventlog6_EvtRpcRegisterLogQuery");
2213 if (r == NULL) { ndr_print_null(ndr); return; }
2214 ndr->depth++;
2215 if (flags & NDR_SET_VALUES) {
2216 ndr->flags |= LIBNDR_PRINT_SET_VALUES;
2217 }
2218 if (flags & NDR_IN) {
2219 ndr_print_struct(ndr, "in", "eventlog6_EvtRpcRegisterLogQuery");
2220 ndr->depth++;
2221 ndr_print_ptr(ndr, "path", r->in.path);
2222 ndr->depth++;
2223 if (r->in.path) {
2224 ndr_print_string(ndr, "path", r->in.path);
2225 }
2226 ndr->depth--;
2227 ndr_print_ptr(ndr, "query", r->in.query);
2228 ndr->depth++;
2229 ndr_print_string(ndr, "query", r->in.query);
2230 ndr->depth--;
2231 ndr_print_uint32(ndr, "flags", r->in.flags);
2232 ndr->depth--;
2233 }
2234 if (flags & NDR_OUT) {
2235 ndr_print_struct(ndr, "out", "eventlog6_EvtRpcRegisterLogQuery");
2236 ndr->depth++;
2237 ndr_print_ptr(ndr, "handle", r->out.handle);
2238 ndr->depth++;
2239 ndr_print_policy_handle(ndr, "handle", r->out.handle);
2240 ndr->depth--;
2241 ndr_print_ptr(ndr, "opControl", r->out.opControl);
2242 ndr->depth++;
2243 ndr_print_policy_handle(ndr, "opControl", r->out.opControl);
2244 ndr->depth--;
2245 ndr_print_ptr(ndr, "queryChannelInfoSize", r->out.queryChannelInfoSize);
2246 ndr->depth++;
2247 ndr_print_uint32(ndr, "queryChannelInfoSize", *r->out.queryChannelInfoSize);
2248 ndr->depth--;
2249 ndr_print_ptr(ndr, "queryChannelInfo", r->out.queryChannelInfo);
2250 ndr->depth++;
2251 ndr_print_ptr(ndr, "queryChannelInfo", *r->out.queryChannelInfo);
2252 ndr->depth++;
2253 if (*r->out.queryChannelInfo) {
2254 ndr->print(ndr, "%s: ARRAY(%d)", "queryChannelInfo", (int)*r->out.queryChannelInfoSize);
2255 ndr->depth++;
2256 for (cntr_queryChannelInfo_2=0;cntr_queryChannelInfo_2<*r->out.queryChannelInfoSize;cntr_queryChannelInfo_2++) {
2257 ndr_print_eventlog6_EvtRpcQueryChannelInfo(ndr, "queryChannelInfo", &(*r->out.queryChannelInfo)[cntr_queryChannelInfo_2]);
2258 }
2259 ndr->depth--;
2260 }
2261 ndr->depth--;
2262 ndr->depth--;
2263 ndr_print_ptr(ndr, "error", r->out.error);
2264 ndr->depth++;
2265 ndr_print_eventlog6_RpcInfo(ndr, "error", r->out.error);
2266 ndr->depth--;
2267 ndr_print_WERROR(ndr, "result", r->out.result);
2268 ndr->depth--;
2269 }
2270 ndr->depth--;
2271}
2272
2273static enum ndr_err_code ndr_push_eventlog6_EvtRpcClearLog(struct ndr_push *ndr, int flags, const struct eventlog6_EvtRpcClearLog *r)
2274{
2275 if (flags & NDR_IN) {
2276 if (r->in.control == NULL) {
2277 return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
2278 }
2279 NDR_CHECK(ndr_push_policy_handle(ndr, NDR_SCALARS, r->in.control));
2280 if (r->in.channelPath == NULL) {
2281 return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
2282 }
2283 NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->in.channelPath, CH_UTF16)));
2284 NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, 0));
2285 NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->in.channelPath, CH_UTF16)));
2286 NDR_CHECK(ndr_push_charset(ndr, NDR_SCALARS, r->in.channelPath, ndr_charset_length(r->in.channelPath, CH_UTF16), sizeof(uint16_t), CH_UTF16));
2287 NDR_CHECK(ndr_push_unique_ptr(ndr, r->in.backupPath));
2288 if (r->in.backupPath) {
2289 NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->in.backupPath, CH_UTF16)));
2290 NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, 0));
2291 NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->in.backupPath, CH_UTF16)));
2292 NDR_CHECK(ndr_push_charset(ndr, NDR_SCALARS, r->in.backupPath, ndr_charset_length(r->in.backupPath, CH_UTF16), sizeof(uint16_t), CH_UTF16));
2293 }
2294 NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->in.flags));
2295 }
2296 if (flags & NDR_OUT) {
2297 if (r->out.error == NULL) {
2298 return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
2299 }
2300 NDR_CHECK(ndr_push_eventlog6_RpcInfo(ndr, NDR_SCALARS, r->out.error));
2301 NDR_CHECK(ndr_push_WERROR(ndr, NDR_SCALARS, r->out.result));
2302 }
2303 return NDR_ERR_SUCCESS;
2304}
2305
2306static enum ndr_err_code ndr_pull_eventlog6_EvtRpcClearLog(struct ndr_pull *ndr, int flags, struct eventlog6_EvtRpcClearLog *r)
2307{
2308 uint32_t size_channelPath_1 = 0;
2309 uint32_t length_channelPath_1 = 0;
2310 uint32_t _ptr_backupPath;
2311 uint32_t size_backupPath_1 = 0;
2312 uint32_t length_backupPath_1 = 0;
2313 TALLOC_CTX *_mem_save_control_0;
2314 TALLOC_CTX *_mem_save_backupPath_0;
2315 TALLOC_CTX *_mem_save_error_0;
2316 if (flags & NDR_IN) {
2317 ZERO_STRUCT(r->out);
2318
2319 if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
2320 NDR_PULL_ALLOC(ndr, r->in.control);
2321 }
2322 _mem_save_control_0 = NDR_PULL_GET_MEM_CTX(ndr);
2323 NDR_PULL_SET_MEM_CTX(ndr, r->in.control, LIBNDR_FLAG_REF_ALLOC);
2324 NDR_CHECK(ndr_pull_policy_handle(ndr, NDR_SCALARS, r->in.control));
2325 NDR_PULL_SET_MEM_CTX(ndr, _mem_save_control_0, LIBNDR_FLAG_REF_ALLOC);
2326 NDR_CHECK(ndr_pull_array_size(ndr, &r->in.channelPath));
2327 NDR_CHECK(ndr_pull_array_length(ndr, &r->in.channelPath));
2328 size_channelPath_1 = ndr_get_array_size(ndr, &r->in.channelPath);
2329 if (size_channelPath_1 > MAX_RPC_CHANNEL_NAME_LENGTH) {
2330 return ndr_pull_error(ndr, NDR_ERR_RANGE, "value out of range");
2331 }
2332 length_channelPath_1 = ndr_get_array_length(ndr, &r->in.channelPath);
2333 if (length_channelPath_1 > MAX_RPC_CHANNEL_NAME_LENGTH) {
2334 return ndr_pull_error(ndr, NDR_ERR_RANGE, "value out of range");
2335 }
2336 if (length_channelPath_1 > size_channelPath_1) {
2337 return ndr_pull_error(ndr, NDR_ERR_ARRAY_SIZE, "Bad array size %u should exceed array length %u", size_channelPath_1, length_channelPath_1);
2338 }
2339 NDR_CHECK(ndr_check_string_terminator(ndr, length_channelPath_1, sizeof(uint16_t)));
2340 NDR_CHECK(ndr_pull_charset(ndr, NDR_SCALARS, &r->in.channelPath, length_channelPath_1, sizeof(uint16_t), CH_UTF16));
2341 NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_backupPath));
2342 if (_ptr_backupPath) {
2343 NDR_PULL_ALLOC(ndr, r->in.backupPath);
2344 } else {
2345 r->in.backupPath = NULL;
2346 }
2347 if (r->in.backupPath) {
2348 _mem_save_backupPath_0 = NDR_PULL_GET_MEM_CTX(ndr);
2349 NDR_PULL_SET_MEM_CTX(ndr, r->in.backupPath, 0);
2350 NDR_CHECK(ndr_pull_array_size(ndr, &r->in.backupPath));
2351 NDR_CHECK(ndr_pull_array_length(ndr, &r->in.backupPath));
2352 size_backupPath_1 = ndr_get_array_size(ndr, &r->in.backupPath);
2353 if (size_backupPath_1 > MAX_RPC_FILE_PATH_LENGTH) {
2354 return ndr_pull_error(ndr, NDR_ERR_RANGE, "value out of range");
2355 }
2356 length_backupPath_1 = ndr_get_array_length(ndr, &r->in.backupPath);
2357 if (length_backupPath_1 > MAX_RPC_FILE_PATH_LENGTH) {
2358 return ndr_pull_error(ndr, NDR_ERR_RANGE, "value out of range");
2359 }
2360 if (length_backupPath_1 > size_backupPath_1) {
2361 return ndr_pull_error(ndr, NDR_ERR_ARRAY_SIZE, "Bad array size %u should exceed array length %u", size_backupPath_1, length_backupPath_1);
2362 }
2363 NDR_CHECK(ndr_check_string_terminator(ndr, length_backupPath_1, sizeof(uint16_t)));
2364 NDR_CHECK(ndr_pull_charset(ndr, NDR_SCALARS, &r->in.backupPath, length_backupPath_1, sizeof(uint16_t), CH_UTF16));
2365 NDR_PULL_SET_MEM_CTX(ndr, _mem_save_backupPath_0, 0);
2366 }
2367 NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->in.flags));
2368 NDR_PULL_ALLOC(ndr, r->out.error);
2369 ZERO_STRUCTP(r->out.error);
2370 }
2371 if (flags & NDR_OUT) {
2372 if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
2373 NDR_PULL_ALLOC(ndr, r->out.error);
2374 }
2375 _mem_save_error_0 = NDR_PULL_GET_MEM_CTX(ndr);
2376 NDR_PULL_SET_MEM_CTX(ndr, r->out.error, LIBNDR_FLAG_REF_ALLOC);
2377 NDR_CHECK(ndr_pull_eventlog6_RpcInfo(ndr, NDR_SCALARS, r->out.error));
2378 NDR_PULL_SET_MEM_CTX(ndr, _mem_save_error_0, LIBNDR_FLAG_REF_ALLOC);
2379 NDR_CHECK(ndr_pull_WERROR(ndr, NDR_SCALARS, &r->out.result));
2380 }
2381 return NDR_ERR_SUCCESS;
2382}
2383
2384_PUBLIC_ void ndr_print_eventlog6_EvtRpcClearLog(struct ndr_print *ndr, const char *name, int flags, const struct eventlog6_EvtRpcClearLog *r)
2385{
2386 ndr_print_struct(ndr, name, "eventlog6_EvtRpcClearLog");
2387 if (r == NULL) { ndr_print_null(ndr); return; }
2388 ndr->depth++;
2389 if (flags & NDR_SET_VALUES) {
2390 ndr->flags |= LIBNDR_PRINT_SET_VALUES;
2391 }
2392 if (flags & NDR_IN) {
2393 ndr_print_struct(ndr, "in", "eventlog6_EvtRpcClearLog");
2394 ndr->depth++;
2395 ndr_print_ptr(ndr, "control", r->in.control);
2396 ndr->depth++;
2397 ndr_print_policy_handle(ndr, "control", r->in.control);
2398 ndr->depth--;
2399 ndr_print_ptr(ndr, "channelPath", r->in.channelPath);
2400 ndr->depth++;
2401 ndr_print_string(ndr, "channelPath", r->in.channelPath);
2402 ndr->depth--;
2403 ndr_print_ptr(ndr, "backupPath", r->in.backupPath);
2404 ndr->depth++;
2405 if (r->in.backupPath) {
2406 ndr_print_string(ndr, "backupPath", r->in.backupPath);
2407 }
2408 ndr->depth--;
2409 ndr_print_uint32(ndr, "flags", r->in.flags);
2410 ndr->depth--;
2411 }
2412 if (flags & NDR_OUT) {
2413 ndr_print_struct(ndr, "out", "eventlog6_EvtRpcClearLog");
2414 ndr->depth++;
2415 ndr_print_ptr(ndr, "error", r->out.error);
2416 ndr->depth++;
2417 ndr_print_eventlog6_RpcInfo(ndr, "error", r->out.error);
2418 ndr->depth--;
2419 ndr_print_WERROR(ndr, "result", r->out.result);
2420 ndr->depth--;
2421 }
2422 ndr->depth--;
2423}
2424
2425static enum ndr_err_code ndr_push_eventlog6_EvtRpcExportLog(struct ndr_push *ndr, int flags, const struct eventlog6_EvtRpcExportLog *r)
2426{
2427 if (flags & NDR_IN) {
2428 if (r->in.control == NULL) {
2429 return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
2430 }
2431 NDR_CHECK(ndr_push_policy_handle(ndr, NDR_SCALARS, r->in.control));
2432 NDR_CHECK(ndr_push_unique_ptr(ndr, r->in.channelPath));
2433 if (r->in.channelPath) {
2434 NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->in.channelPath, CH_UTF16)));
2435 NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, 0));
2436 NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->in.channelPath, CH_UTF16)));
2437 NDR_CHECK(ndr_push_charset(ndr, NDR_SCALARS, r->in.channelPath, ndr_charset_length(r->in.channelPath, CH_UTF16), sizeof(uint16_t), CH_UTF16));
2438 }
2439 if (r->in.query == NULL) {
2440 return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
2441 }
2442 NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->in.query, CH_UTF16)));
2443 NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, 0));
2444 NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->in.query, CH_UTF16)));
2445 NDR_CHECK(ndr_push_charset(ndr, NDR_SCALARS, r->in.query, ndr_charset_length(r->in.query, CH_UTF16), sizeof(uint16_t), CH_UTF16));
2446 if (r->in.backupPath == NULL) {
2447 return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
2448 }
2449 NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->in.backupPath, CH_UTF16)));
2450 NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, 0));
2451 NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->in.backupPath, CH_UTF16)));
2452 NDR_CHECK(ndr_push_charset(ndr, NDR_SCALARS, r->in.backupPath, ndr_charset_length(r->in.backupPath, CH_UTF16), sizeof(uint16_t), CH_UTF16));
2453 NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->in.flags));
2454 }
2455 if (flags & NDR_OUT) {
2456 if (r->out.error == NULL) {
2457 return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
2458 }
2459 NDR_CHECK(ndr_push_eventlog6_RpcInfo(ndr, NDR_SCALARS, r->out.error));
2460 NDR_CHECK(ndr_push_WERROR(ndr, NDR_SCALARS, r->out.result));
2461 }
2462 return NDR_ERR_SUCCESS;
2463}
2464
2465static enum ndr_err_code ndr_pull_eventlog6_EvtRpcExportLog(struct ndr_pull *ndr, int flags, struct eventlog6_EvtRpcExportLog *r)
2466{
2467 uint32_t _ptr_channelPath;
2468 uint32_t size_channelPath_1 = 0;
2469 uint32_t length_channelPath_1 = 0;
2470 uint32_t size_query_1 = 0;
2471 uint32_t length_query_1 = 0;
2472 uint32_t size_backupPath_1 = 0;
2473 uint32_t length_backupPath_1 = 0;
2474 TALLOC_CTX *_mem_save_control_0;
2475 TALLOC_CTX *_mem_save_channelPath_0;
2476 TALLOC_CTX *_mem_save_error_0;
2477 if (flags & NDR_IN) {
2478 ZERO_STRUCT(r->out);
2479
2480 if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
2481 NDR_PULL_ALLOC(ndr, r->in.control);
2482 }
2483 _mem_save_control_0 = NDR_PULL_GET_MEM_CTX(ndr);
2484 NDR_PULL_SET_MEM_CTX(ndr, r->in.control, LIBNDR_FLAG_REF_ALLOC);
2485 NDR_CHECK(ndr_pull_policy_handle(ndr, NDR_SCALARS, r->in.control));
2486 NDR_PULL_SET_MEM_CTX(ndr, _mem_save_control_0, LIBNDR_FLAG_REF_ALLOC);
2487 NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_channelPath));
2488 if (_ptr_channelPath) {
2489 NDR_PULL_ALLOC(ndr, r->in.channelPath);
2490 } else {
2491 r->in.channelPath = NULL;
2492 }
2493 if (r->in.channelPath) {
2494 _mem_save_channelPath_0 = NDR_PULL_GET_MEM_CTX(ndr);
2495 NDR_PULL_SET_MEM_CTX(ndr, r->in.channelPath, 0);
2496 NDR_CHECK(ndr_pull_array_size(ndr, &r->in.channelPath));
2497 NDR_CHECK(ndr_pull_array_length(ndr, &r->in.channelPath));
2498 size_channelPath_1 = ndr_get_array_size(ndr, &r->in.channelPath);
2499 if (size_channelPath_1 > MAX_RPC_CHANNEL_NAME_LENGTH) {
2500 return ndr_pull_error(ndr, NDR_ERR_RANGE, "value out of range");
2501 }
2502 length_channelPath_1 = ndr_get_array_length(ndr, &r->in.channelPath);
2503 if (length_channelPath_1 > MAX_RPC_CHANNEL_NAME_LENGTH) {
2504 return ndr_pull_error(ndr, NDR_ERR_RANGE, "value out of range");
2505 }
2506 if (length_channelPath_1 > size_channelPath_1) {
2507 return ndr_pull_error(ndr, NDR_ERR_ARRAY_SIZE, "Bad array size %u should exceed array length %u", size_channelPath_1, length_channelPath_1);
2508 }
2509 NDR_CHECK(ndr_check_string_terminator(ndr, length_channelPath_1, sizeof(uint16_t)));
2510 NDR_CHECK(ndr_pull_charset(ndr, NDR_SCALARS, &r->in.channelPath, length_channelPath_1, sizeof(uint16_t), CH_UTF16));
2511 NDR_PULL_SET_MEM_CTX(ndr, _mem_save_channelPath_0, 0);
2512 }
2513 NDR_CHECK(ndr_pull_array_size(ndr, &r->in.query));
2514 NDR_CHECK(ndr_pull_array_length(ndr, &r->in.query));
2515 size_query_1 = ndr_get_array_size(ndr, &r->in.query);
2516 if (size_query_1 < 1 || size_query_1 > MAX_RPC_QUERY_LENGTH) {
2517 return ndr_pull_error(ndr, NDR_ERR_RANGE, "value out of range");
2518 }
2519 length_query_1 = ndr_get_array_length(ndr, &r->in.query);
2520 if (length_query_1 < 1 || length_query_1 > MAX_RPC_QUERY_LENGTH) {
2521 return ndr_pull_error(ndr, NDR_ERR_RANGE, "value out of range");
2522 }
2523 if (length_query_1 > size_query_1) {
2524 return ndr_pull_error(ndr, NDR_ERR_ARRAY_SIZE, "Bad array size %u should exceed array length %u", size_query_1, length_query_1);
2525 }
2526 NDR_CHECK(ndr_check_string_terminator(ndr, length_query_1, sizeof(uint16_t)));
2527 NDR_CHECK(ndr_pull_charset(ndr, NDR_SCALARS, &r->in.query, length_query_1, sizeof(uint16_t), CH_UTF16));
2528 NDR_CHECK(ndr_pull_array_size(ndr, &r->in.backupPath));
2529 NDR_CHECK(ndr_pull_array_length(ndr, &r->in.backupPath));
2530 size_backupPath_1 = ndr_get_array_size(ndr, &r->in.backupPath);
2531 if (size_backupPath_1 < 1 || size_backupPath_1 > MAX_RPC_FILE_PATH_LENGTH) {
2532 return ndr_pull_error(ndr, NDR_ERR_RANGE, "value out of range");
2533 }
2534 length_backupPath_1 = ndr_get_array_length(ndr, &r->in.backupPath);
2535 if (length_backupPath_1 < 1 || length_backupPath_1 > MAX_RPC_FILE_PATH_LENGTH) {
2536 return ndr_pull_error(ndr, NDR_ERR_RANGE, "value out of range");
2537 }
2538 if (length_backupPath_1 > size_backupPath_1) {
2539 return ndr_pull_error(ndr, NDR_ERR_ARRAY_SIZE, "Bad array size %u should exceed array length %u", size_backupPath_1, length_backupPath_1);
2540 }
2541 NDR_CHECK(ndr_check_string_terminator(ndr, length_backupPath_1, sizeof(uint16_t)));
2542 NDR_CHECK(ndr_pull_charset(ndr, NDR_SCALARS, &r->in.backupPath, length_backupPath_1, sizeof(uint16_t), CH_UTF16));
2543 NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->in.flags));
2544 NDR_PULL_ALLOC(ndr, r->out.error);
2545 ZERO_STRUCTP(r->out.error);
2546 }
2547 if (flags & NDR_OUT) {
2548 if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
2549 NDR_PULL_ALLOC(ndr, r->out.error);
2550 }
2551 _mem_save_error_0 = NDR_PULL_GET_MEM_CTX(ndr);
2552 NDR_PULL_SET_MEM_CTX(ndr, r->out.error, LIBNDR_FLAG_REF_ALLOC);
2553 NDR_CHECK(ndr_pull_eventlog6_RpcInfo(ndr, NDR_SCALARS, r->out.error));
2554 NDR_PULL_SET_MEM_CTX(ndr, _mem_save_error_0, LIBNDR_FLAG_REF_ALLOC);
2555 NDR_CHECK(ndr_pull_WERROR(ndr, NDR_SCALARS, &r->out.result));
2556 }
2557 return NDR_ERR_SUCCESS;
2558}
2559
2560_PUBLIC_ void ndr_print_eventlog6_EvtRpcExportLog(struct ndr_print *ndr, const char *name, int flags, const struct eventlog6_EvtRpcExportLog *r)
2561{
2562 ndr_print_struct(ndr, name, "eventlog6_EvtRpcExportLog");
2563 if (r == NULL) { ndr_print_null(ndr); return; }
2564 ndr->depth++;
2565 if (flags & NDR_SET_VALUES) {
2566 ndr->flags |= LIBNDR_PRINT_SET_VALUES;
2567 }
2568 if (flags & NDR_IN) {
2569 ndr_print_struct(ndr, "in", "eventlog6_EvtRpcExportLog");
2570 ndr->depth++;
2571 ndr_print_ptr(ndr, "control", r->in.control);
2572 ndr->depth++;
2573 ndr_print_policy_handle(ndr, "control", r->in.control);
2574 ndr->depth--;
2575 ndr_print_ptr(ndr, "channelPath", r->in.channelPath);
2576 ndr->depth++;
2577 if (r->in.channelPath) {
2578 ndr_print_string(ndr, "channelPath", r->in.channelPath);
2579 }
2580 ndr->depth--;
2581 ndr_print_ptr(ndr, "query", r->in.query);
2582 ndr->depth++;
2583 ndr_print_string(ndr, "query", r->in.query);
2584 ndr->depth--;
2585 ndr_print_ptr(ndr, "backupPath", r->in.backupPath);
2586 ndr->depth++;
2587 ndr_print_string(ndr, "backupPath", r->in.backupPath);
2588 ndr->depth--;
2589 ndr_print_uint32(ndr, "flags", r->in.flags);
2590 ndr->depth--;
2591 }
2592 if (flags & NDR_OUT) {
2593 ndr_print_struct(ndr, "out", "eventlog6_EvtRpcExportLog");
2594 ndr->depth++;
2595 ndr_print_ptr(ndr, "error", r->out.error);
2596 ndr->depth++;
2597 ndr_print_eventlog6_RpcInfo(ndr, "error", r->out.error);
2598 ndr->depth--;
2599 ndr_print_WERROR(ndr, "result", r->out.result);
2600 ndr->depth--;
2601 }
2602 ndr->depth--;
2603}
2604
2605static enum ndr_err_code ndr_push_eventlog6_EvtRpcLocalizeExportLog(struct ndr_push *ndr, int flags, const struct eventlog6_EvtRpcLocalizeExportLog *r)
2606{
2607 if (flags & NDR_IN) {
2608 if (r->in.control == NULL) {
2609 return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
2610 }
2611 NDR_CHECK(ndr_push_policy_handle(ndr, NDR_SCALARS, r->in.control));
2612 if (r->in.logFilePath == NULL) {
2613 return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
2614 }
2615 NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->in.logFilePath, CH_UTF16)));
2616 NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, 0));
2617 NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->in.logFilePath, CH_UTF16)));
2618 NDR_CHECK(ndr_push_charset(ndr, NDR_SCALARS, r->in.logFilePath, ndr_charset_length(r->in.logFilePath, CH_UTF16), sizeof(uint16_t), CH_UTF16));
2619 NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->in.locale));
2620 NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->in.flags));
2621 }
2622 if (flags & NDR_OUT) {
2623 if (r->out.error == NULL) {
2624 return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
2625 }
2626 NDR_CHECK(ndr_push_eventlog6_RpcInfo(ndr, NDR_SCALARS, r->out.error));
2627 NDR_CHECK(ndr_push_WERROR(ndr, NDR_SCALARS, r->out.result));
2628 }
2629 return NDR_ERR_SUCCESS;
2630}
2631
2632static enum ndr_err_code ndr_pull_eventlog6_EvtRpcLocalizeExportLog(struct ndr_pull *ndr, int flags, struct eventlog6_EvtRpcLocalizeExportLog *r)
2633{
2634 uint32_t size_logFilePath_1 = 0;
2635 uint32_t length_logFilePath_1 = 0;
2636 TALLOC_CTX *_mem_save_control_0;
2637 TALLOC_CTX *_mem_save_error_0;
2638 if (flags & NDR_IN) {
2639 ZERO_STRUCT(r->out);
2640
2641 if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
2642 NDR_PULL_ALLOC(ndr, r->in.control);
2643 }
2644 _mem_save_control_0 = NDR_PULL_GET_MEM_CTX(ndr);
2645 NDR_PULL_SET_MEM_CTX(ndr, r->in.control, LIBNDR_FLAG_REF_ALLOC);
2646 NDR_CHECK(ndr_pull_policy_handle(ndr, NDR_SCALARS, r->in.control));
2647 NDR_PULL_SET_MEM_CTX(ndr, _mem_save_control_0, LIBNDR_FLAG_REF_ALLOC);
2648 NDR_CHECK(ndr_pull_array_size(ndr, &r->in.logFilePath));
2649 NDR_CHECK(ndr_pull_array_length(ndr, &r->in.logFilePath));
2650 size_logFilePath_1 = ndr_get_array_size(ndr, &r->in.logFilePath);
2651 if (size_logFilePath_1 < 1 || size_logFilePath_1 > MAX_RPC_FILE_PATH_LENGTH) {
2652 return ndr_pull_error(ndr, NDR_ERR_RANGE, "value out of range");
2653 }
2654 length_logFilePath_1 = ndr_get_array_length(ndr, &r->in.logFilePath);
2655 if (length_logFilePath_1 < 1 || length_logFilePath_1 > MAX_RPC_FILE_PATH_LENGTH) {
2656 return ndr_pull_error(ndr, NDR_ERR_RANGE, "value out of range");
2657 }
2658 if (length_logFilePath_1 > size_logFilePath_1) {
2659 return ndr_pull_error(ndr, NDR_ERR_ARRAY_SIZE, "Bad array size %u should exceed array length %u", size_logFilePath_1, length_logFilePath_1);
2660 }
2661 NDR_CHECK(ndr_check_string_terminator(ndr, length_logFilePath_1, sizeof(uint16_t)));
2662 NDR_CHECK(ndr_pull_charset(ndr, NDR_SCALARS, &r->in.logFilePath, length_logFilePath_1, sizeof(uint16_t), CH_UTF16));
2663 NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->in.locale));
2664 NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->in.flags));
2665 NDR_PULL_ALLOC(ndr, r->out.error);
2666 ZERO_STRUCTP(r->out.error);
2667 }
2668 if (flags & NDR_OUT) {
2669 if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
2670 NDR_PULL_ALLOC(ndr, r->out.error);
2671 }
2672 _mem_save_error_0 = NDR_PULL_GET_MEM_CTX(ndr);
2673 NDR_PULL_SET_MEM_CTX(ndr, r->out.error, LIBNDR_FLAG_REF_ALLOC);
2674 NDR_CHECK(ndr_pull_eventlog6_RpcInfo(ndr, NDR_SCALARS, r->out.error));
2675 NDR_PULL_SET_MEM_CTX(ndr, _mem_save_error_0, LIBNDR_FLAG_REF_ALLOC);
2676 NDR_CHECK(ndr_pull_WERROR(ndr, NDR_SCALARS, &r->out.result));
2677 }
2678 return NDR_ERR_SUCCESS;
2679}
2680
2681_PUBLIC_ void ndr_print_eventlog6_EvtRpcLocalizeExportLog(struct ndr_print *ndr, const char *name, int flags, const struct eventlog6_EvtRpcLocalizeExportLog *r)
2682{
2683 ndr_print_struct(ndr, name, "eventlog6_EvtRpcLocalizeExportLog");
2684 if (r == NULL) { ndr_print_null(ndr); return; }
2685 ndr->depth++;
2686 if (flags & NDR_SET_VALUES) {
2687 ndr->flags |= LIBNDR_PRINT_SET_VALUES;
2688 }
2689 if (flags & NDR_IN) {
2690 ndr_print_struct(ndr, "in", "eventlog6_EvtRpcLocalizeExportLog");
2691 ndr->depth++;
2692 ndr_print_ptr(ndr, "control", r->in.control);
2693 ndr->depth++;
2694 ndr_print_policy_handle(ndr, "control", r->in.control);
2695 ndr->depth--;
2696 ndr_print_ptr(ndr, "logFilePath", r->in.logFilePath);
2697 ndr->depth++;
2698 ndr_print_string(ndr, "logFilePath", r->in.logFilePath);
2699 ndr->depth--;
2700 ndr_print_uint32(ndr, "locale", r->in.locale);
2701 ndr_print_uint32(ndr, "flags", r->in.flags);
2702 ndr->depth--;
2703 }
2704 if (flags & NDR_OUT) {
2705 ndr_print_struct(ndr, "out", "eventlog6_EvtRpcLocalizeExportLog");
2706 ndr->depth++;
2707 ndr_print_ptr(ndr, "error", r->out.error);
2708 ndr->depth++;
2709 ndr_print_eventlog6_RpcInfo(ndr, "error", r->out.error);
2710 ndr->depth--;
2711 ndr_print_WERROR(ndr, "result", r->out.result);
2712 ndr->depth--;
2713 }
2714 ndr->depth--;
2715}
2716
2717static enum ndr_err_code ndr_push_eventlog6_EvtRpcMessageRender(struct ndr_push *ndr, int flags, const struct eventlog6_EvtRpcMessageRender *r)
2718{
2719 if (flags & NDR_IN) {
2720 if (r->in.pubCfgObj == NULL) {
2721 return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
2722 }
2723 NDR_CHECK(ndr_push_policy_handle(ndr, NDR_SCALARS, r->in.pubCfgObj));
2724 NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->in.sizeEventId));
2725 if (r->in.eventId == NULL) {
2726 return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
2727 }
2728 NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, r->in.sizeEventId));
2729 NDR_CHECK(ndr_push_array_uint8(ndr, NDR_SCALARS, r->in.eventId, r->in.sizeEventId));
2730 NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->in.messageId));
2731 if (r->in.values == NULL) {
2732 return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
2733 }
2734 NDR_CHECK(ndr_push_eventlog6_EvtRpcVariantList(ndr, NDR_SCALARS|NDR_BUFFERS, r->in.values));
2735 NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->in.flags));
2736 NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->in.maxSizeString));
2737 }
2738 if (flags & NDR_OUT) {
2739 if (r->out.actualSizeString == NULL) {
2740 return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
2741 }
2742 NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, *r->out.actualSizeString));
2743 if (r->out.neededSizeString == NULL) {
2744 return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
2745 }
2746 NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, *r->out.neededSizeString));
2747 if (r->out.string == NULL) {
2748 return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
2749 }
2750 NDR_CHECK(ndr_push_unique_ptr(ndr, *r->out.string));
2751 if (*r->out.string) {
2752 NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, *r->out.actualSizeString));
2753 NDR_CHECK(ndr_push_array_uint8(ndr, NDR_SCALARS, *r->out.string, *r->out.actualSizeString));
2754 }
2755 if (r->out.error == NULL) {
2756 return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
2757 }
2758 NDR_CHECK(ndr_push_eventlog6_RpcInfo(ndr, NDR_SCALARS, r->out.error));
2759 NDR_CHECK(ndr_push_WERROR(ndr, NDR_SCALARS, r->out.result));
2760 }
2761 return NDR_ERR_SUCCESS;
2762}
2763
2764static enum ndr_err_code ndr_pull_eventlog6_EvtRpcMessageRender(struct ndr_pull *ndr, int flags, struct eventlog6_EvtRpcMessageRender *r)
2765{
2766 uint32_t size_eventId_1 = 0;
2767 uint32_t _ptr_string;
2768 uint32_t size_string_2 = 0;
2769 TALLOC_CTX *_mem_save_pubCfgObj_0;
2770 TALLOC_CTX *_mem_save_values_0;
2771 TALLOC_CTX *_mem_save_actualSizeString_0;
2772 TALLOC_CTX *_mem_save_neededSizeString_0;
2773 TALLOC_CTX *_mem_save_string_0;
2774 TALLOC_CTX *_mem_save_string_1;
2775 TALLOC_CTX *_mem_save_error_0;
2776 if (flags & NDR_IN) {
2777 ZERO_STRUCT(r->out);
2778
2779 if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
2780 NDR_PULL_ALLOC(ndr, r->in.pubCfgObj);
2781 }
2782 _mem_save_pubCfgObj_0 = NDR_PULL_GET_MEM_CTX(ndr);
2783 NDR_PULL_SET_MEM_CTX(ndr, r->in.pubCfgObj, LIBNDR_FLAG_REF_ALLOC);
2784 NDR_CHECK(ndr_pull_policy_handle(ndr, NDR_SCALARS, r->in.pubCfgObj));
2785 NDR_PULL_SET_MEM_CTX(ndr, _mem_save_pubCfgObj_0, LIBNDR_FLAG_REF_ALLOC);
2786 NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->in.sizeEventId));
2787 if (r->in.sizeEventId < 1 || r->in.sizeEventId > MAX_RPC_EVENT_ID_SIZE) {
2788 return ndr_pull_error(ndr, NDR_ERR_RANGE, "value out of range");
2789 }
2790 NDR_CHECK(ndr_pull_array_size(ndr, &r->in.eventId));
2791 size_eventId_1 = ndr_get_array_size(ndr, &r->in.eventId);
2792 if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
2793 NDR_PULL_ALLOC_N(ndr, r->in.eventId, size_eventId_1);
2794 }
2795 NDR_CHECK(ndr_pull_array_uint8(ndr, NDR_SCALARS, r->in.eventId, size_eventId_1));
2796 NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->in.messageId));
2797 if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
2798 NDR_PULL_ALLOC(ndr, r->in.values);
2799 }
2800 _mem_save_values_0 = NDR_PULL_GET_MEM_CTX(ndr);
2801 NDR_PULL_SET_MEM_CTX(ndr, r->in.values, LIBNDR_FLAG_REF_ALLOC);
2802 NDR_CHECK(ndr_pull_eventlog6_EvtRpcVariantList(ndr, NDR_SCALARS|NDR_BUFFERS, r->in.values));
2803 NDR_PULL_SET_MEM_CTX(ndr, _mem_save_values_0, LIBNDR_FLAG_REF_ALLOC);
2804 NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->in.flags));
2805 NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->in.maxSizeString));
2806 NDR_PULL_ALLOC(ndr, r->out.actualSizeString);
2807 ZERO_STRUCTP(r->out.actualSizeString);
2808 NDR_PULL_ALLOC(ndr, r->out.neededSizeString);
2809 ZERO_STRUCTP(r->out.neededSizeString);
2810 NDR_PULL_ALLOC(ndr, r->out.string);
2811 ZERO_STRUCTP(r->out.string);
2812 NDR_PULL_ALLOC(ndr, r->out.error);
2813 ZERO_STRUCTP(r->out.error);
2814 if (r->in.eventId) {
2815 NDR_CHECK(ndr_check_array_size(ndr, (void*)&r->in.eventId, r->in.sizeEventId));
2816 }
2817 }
2818 if (flags & NDR_OUT) {
2819 if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
2820 NDR_PULL_ALLOC(ndr, r->out.actualSizeString);
2821 }
2822 _mem_save_actualSizeString_0 = NDR_PULL_GET_MEM_CTX(ndr);
2823 NDR_PULL_SET_MEM_CTX(ndr, r->out.actualSizeString, LIBNDR_FLAG_REF_ALLOC);
2824 NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, r->out.actualSizeString));
2825 NDR_PULL_SET_MEM_CTX(ndr, _mem_save_actualSizeString_0, LIBNDR_FLAG_REF_ALLOC);
2826 if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
2827 NDR_PULL_ALLOC(ndr, r->out.neededSizeString);
2828 }
2829 _mem_save_neededSizeString_0 = NDR_PULL_GET_MEM_CTX(ndr);
2830 NDR_PULL_SET_MEM_CTX(ndr, r->out.neededSizeString, LIBNDR_FLAG_REF_ALLOC);
2831 NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, r->out.neededSizeString));
2832 NDR_PULL_SET_MEM_CTX(ndr, _mem_save_neededSizeString_0, LIBNDR_FLAG_REF_ALLOC);
2833 if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
2834 NDR_PULL_ALLOC(ndr, r->out.string);
2835 }
2836 _mem_save_string_0 = NDR_PULL_GET_MEM_CTX(ndr);
2837 NDR_PULL_SET_MEM_CTX(ndr, r->out.string, LIBNDR_FLAG_REF_ALLOC);
2838 NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_string));
2839 if (_ptr_string) {
2840 NDR_PULL_ALLOC(ndr, *r->out.string);
2841 } else {
2842 *r->out.string = NULL;
2843 }
2844 if (*r->out.string) {
2845 _mem_save_string_1 = NDR_PULL_GET_MEM_CTX(ndr);
2846 NDR_PULL_SET_MEM_CTX(ndr, *r->out.string, 0);
2847 NDR_CHECK(ndr_pull_array_size(ndr, r->out.string));
2848 size_string_2 = ndr_get_array_size(ndr, r->out.string);
2849 if (size_string_2 > MAX_RPC_RENDERED_STRING_SIZE) {
2850 return ndr_pull_error(ndr, NDR_ERR_RANGE, "value out of range");
2851 }
2852 NDR_PULL_ALLOC_N(ndr, *r->out.string, size_string_2);
2853 NDR_CHECK(ndr_pull_array_uint8(ndr, NDR_SCALARS, *r->out.string, size_string_2));
2854 NDR_PULL_SET_MEM_CTX(ndr, _mem_save_string_1, 0);
2855 }
2856 NDR_PULL_SET_MEM_CTX(ndr, _mem_save_string_0, LIBNDR_FLAG_REF_ALLOC);
2857 if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
2858 NDR_PULL_ALLOC(ndr, r->out.error);
2859 }
2860 _mem_save_error_0 = NDR_PULL_GET_MEM_CTX(ndr);
2861 NDR_PULL_SET_MEM_CTX(ndr, r->out.error, LIBNDR_FLAG_REF_ALLOC);
2862 NDR_CHECK(ndr_pull_eventlog6_RpcInfo(ndr, NDR_SCALARS, r->out.error));
2863 NDR_PULL_SET_MEM_CTX(ndr, _mem_save_error_0, LIBNDR_FLAG_REF_ALLOC);
2864 NDR_CHECK(ndr_pull_WERROR(ndr, NDR_SCALARS, &r->out.result));
2865 if (*r->out.string) {
2866 NDR_CHECK(ndr_check_array_size(ndr, (void*)r->out.string, *r->out.actualSizeString));
2867 }
2868 }
2869 return NDR_ERR_SUCCESS;
2870}
2871
2872_PUBLIC_ void ndr_print_eventlog6_EvtRpcMessageRender(struct ndr_print *ndr, const char *name, int flags, const struct eventlog6_EvtRpcMessageRender *r)
2873{
2874 ndr_print_struct(ndr, name, "eventlog6_EvtRpcMessageRender");
2875 if (r == NULL) { ndr_print_null(ndr); return; }
2876 ndr->depth++;
2877 if (flags & NDR_SET_VALUES) {
2878 ndr->flags |= LIBNDR_PRINT_SET_VALUES;
2879 }
2880 if (flags & NDR_IN) {
2881 ndr_print_struct(ndr, "in", "eventlog6_EvtRpcMessageRender");
2882 ndr->depth++;
2883 ndr_print_ptr(ndr, "pubCfgObj", r->in.pubCfgObj);
2884 ndr->depth++;
2885 ndr_print_policy_handle(ndr, "pubCfgObj", r->in.pubCfgObj);
2886 ndr->depth--;
2887 ndr_print_uint32(ndr, "sizeEventId", r->in.sizeEventId);
2888 ndr_print_ptr(ndr, "eventId", r->in.eventId);
2889 ndr->depth++;
2890 ndr_print_array_uint8(ndr, "eventId", r->in.eventId, r->in.sizeEventId);
2891 ndr->depth--;
2892 ndr_print_uint32(ndr, "messageId", r->in.messageId);
2893 ndr_print_ptr(ndr, "values", r->in.values);
2894 ndr->depth++;
2895 ndr_print_eventlog6_EvtRpcVariantList(ndr, "values", r->in.values);
2896 ndr->depth--;
2897 ndr_print_uint32(ndr, "flags", r->in.flags);
2898 ndr_print_uint32(ndr, "maxSizeString", r->in.maxSizeString);
2899 ndr->depth--;
2900 }
2901 if (flags & NDR_OUT) {
2902 ndr_print_struct(ndr, "out", "eventlog6_EvtRpcMessageRender");
2903 ndr->depth++;
2904 ndr_print_ptr(ndr, "actualSizeString", r->out.actualSizeString);
2905 ndr->depth++;
2906 ndr_print_uint32(ndr, "actualSizeString", *r->out.actualSizeString);
2907 ndr->depth--;
2908 ndr_print_ptr(ndr, "neededSizeString", r->out.neededSizeString);
2909 ndr->depth++;
2910 ndr_print_uint32(ndr, "neededSizeString", *r->out.neededSizeString);
2911 ndr->depth--;
2912 ndr_print_ptr(ndr, "string", r->out.string);
2913 ndr->depth++;
2914 ndr_print_ptr(ndr, "string", *r->out.string);
2915 ndr->depth++;
2916 if (*r->out.string) {
2917 ndr_print_array_uint8(ndr, "string", *r->out.string, *r->out.actualSizeString);
2918 }
2919 ndr->depth--;
2920 ndr->depth--;
2921 ndr_print_ptr(ndr, "error", r->out.error);
2922 ndr->depth++;
2923 ndr_print_eventlog6_RpcInfo(ndr, "error", r->out.error);
2924 ndr->depth--;
2925 ndr_print_WERROR(ndr, "result", r->out.result);
2926 ndr->depth--;
2927 }
2928 ndr->depth--;
2929}
2930
2931static enum ndr_err_code ndr_push_eventlog6_EvtRpcMessageRenderDefault(struct ndr_push *ndr, int flags, const struct eventlog6_EvtRpcMessageRenderDefault *r)
2932{
2933 if (flags & NDR_IN) {
2934 NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->in.sizeEventId));
2935 if (r->in.eventId == NULL) {
2936 return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
2937 }
2938 NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, r->in.sizeEventId));
2939 NDR_CHECK(ndr_push_array_uint8(ndr, NDR_SCALARS, r->in.eventId, r->in.sizeEventId));
2940 NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->in.messageId));
2941 if (r->in.values == NULL) {
2942 return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
2943 }
2944 NDR_CHECK(ndr_push_eventlog6_EvtRpcVariantList(ndr, NDR_SCALARS|NDR_BUFFERS, r->in.values));
2945 NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->in.flags));
2946 NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->in.maxSizeString));
2947 }
2948 if (flags & NDR_OUT) {
2949 if (r->out.actualSizeString == NULL) {
2950 return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
2951 }
2952 NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, *r->out.actualSizeString));
2953 if (r->out.neededSizeString == NULL) {
2954 return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
2955 }
2956 NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, *r->out.neededSizeString));
2957 if (r->out.string == NULL) {
2958 return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
2959 }
2960 NDR_CHECK(ndr_push_unique_ptr(ndr, *r->out.string));
2961 if (*r->out.string) {
2962 NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, *r->out.actualSizeString));
2963 NDR_CHECK(ndr_push_array_uint8(ndr, NDR_SCALARS, *r->out.string, *r->out.actualSizeString));
2964 }
2965 if (r->out.error == NULL) {
2966 return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
2967 }
2968 NDR_CHECK(ndr_push_eventlog6_RpcInfo(ndr, NDR_SCALARS, r->out.error));
2969 NDR_CHECK(ndr_push_WERROR(ndr, NDR_SCALARS, r->out.result));
2970 }
2971 return NDR_ERR_SUCCESS;
2972}
2973
2974static enum ndr_err_code ndr_pull_eventlog6_EvtRpcMessageRenderDefault(struct ndr_pull *ndr, int flags, struct eventlog6_EvtRpcMessageRenderDefault *r)
2975{
2976 uint32_t size_eventId_1 = 0;
2977 uint32_t _ptr_string;
2978 uint32_t size_string_2 = 0;
2979 TALLOC_CTX *_mem_save_values_0;
2980 TALLOC_CTX *_mem_save_actualSizeString_0;
2981 TALLOC_CTX *_mem_save_neededSizeString_0;
2982 TALLOC_CTX *_mem_save_string_0;
2983 TALLOC_CTX *_mem_save_string_1;
2984 TALLOC_CTX *_mem_save_error_0;
2985 if (flags & NDR_IN) {
2986 ZERO_STRUCT(r->out);
2987
2988 NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->in.sizeEventId));
2989 if (r->in.sizeEventId < 1 || r->in.sizeEventId > MAX_RPC_EVENT_ID_SIZE) {
2990 return ndr_pull_error(ndr, NDR_ERR_RANGE, "value out of range");
2991 }
2992 NDR_CHECK(ndr_pull_array_size(ndr, &r->in.eventId));
2993 size_eventId_1 = ndr_get_array_size(ndr, &r->in.eventId);
2994 if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
2995 NDR_PULL_ALLOC_N(ndr, r->in.eventId, size_eventId_1);
2996 }
2997 NDR_CHECK(ndr_pull_array_uint8(ndr, NDR_SCALARS, r->in.eventId, size_eventId_1));
2998 NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->in.messageId));
2999 if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
3000 NDR_PULL_ALLOC(ndr, r->in.values);
3001 }
3002 _mem_save_values_0 = NDR_PULL_GET_MEM_CTX(ndr);
3003 NDR_PULL_SET_MEM_CTX(ndr, r->in.values, LIBNDR_FLAG_REF_ALLOC);
3004 NDR_CHECK(ndr_pull_eventlog6_EvtRpcVariantList(ndr, NDR_SCALARS|NDR_BUFFERS, r->in.values));
3005 NDR_PULL_SET_MEM_CTX(ndr, _mem_save_values_0, LIBNDR_FLAG_REF_ALLOC);
3006 NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->in.flags));
3007 NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->in.maxSizeString));
3008 NDR_PULL_ALLOC(ndr, r->out.actualSizeString);
3009 ZERO_STRUCTP(r->out.actualSizeString);
3010 NDR_PULL_ALLOC(ndr, r->out.neededSizeString);
3011 ZERO_STRUCTP(r->out.neededSizeString);
3012 NDR_PULL_ALLOC(ndr, r->out.string);
3013 ZERO_STRUCTP(r->out.string);
3014 NDR_PULL_ALLOC(ndr, r->out.error);
3015 ZERO_STRUCTP(r->out.error);
3016 if (r->in.eventId) {
3017 NDR_CHECK(ndr_check_array_size(ndr, (void*)&r->in.eventId, r->in.sizeEventId));
3018 }
3019 }
3020 if (flags & NDR_OUT) {
3021 if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
3022 NDR_PULL_ALLOC(ndr, r->out.actualSizeString);
3023 }
3024 _mem_save_actualSizeString_0 = NDR_PULL_GET_MEM_CTX(ndr);
3025 NDR_PULL_SET_MEM_CTX(ndr, r->out.actualSizeString, LIBNDR_FLAG_REF_ALLOC);
3026 NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, r->out.actualSizeString));
3027 NDR_PULL_SET_MEM_CTX(ndr, _mem_save_actualSizeString_0, LIBNDR_FLAG_REF_ALLOC);
3028 if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
3029 NDR_PULL_ALLOC(ndr, r->out.neededSizeString);
3030 }
3031 _mem_save_neededSizeString_0 = NDR_PULL_GET_MEM_CTX(ndr);
3032 NDR_PULL_SET_MEM_CTX(ndr, r->out.neededSizeString, LIBNDR_FLAG_REF_ALLOC);
3033 NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, r->out.neededSizeString));
3034 NDR_PULL_SET_MEM_CTX(ndr, _mem_save_neededSizeString_0, LIBNDR_FLAG_REF_ALLOC);
3035 if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
3036 NDR_PULL_ALLOC(ndr, r->out.string);
3037 }
3038 _mem_save_string_0 = NDR_PULL_GET_MEM_CTX(ndr);
3039 NDR_PULL_SET_MEM_CTX(ndr, r->out.string, LIBNDR_FLAG_REF_ALLOC);
3040 NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_string));
3041 if (_ptr_string) {
3042 NDR_PULL_ALLOC(ndr, *r->out.string);
3043 } else {
3044 *r->out.string = NULL;
3045 }
3046 if (*r->out.string) {
3047 _mem_save_string_1 = NDR_PULL_GET_MEM_CTX(ndr);
3048 NDR_PULL_SET_MEM_CTX(ndr, *r->out.string, 0);
3049 NDR_CHECK(ndr_pull_array_size(ndr, r->out.string));
3050 size_string_2 = ndr_get_array_size(ndr, r->out.string);
3051 if (size_string_2 > MAX_RPC_RENDERED_STRING_SIZE) {
3052 return ndr_pull_error(ndr, NDR_ERR_RANGE, "value out of range");
3053 }
3054 NDR_PULL_ALLOC_N(ndr, *r->out.string, size_string_2);
3055 NDR_CHECK(ndr_pull_array_uint8(ndr, NDR_SCALARS, *r->out.string, size_string_2));
3056 NDR_PULL_SET_MEM_CTX(ndr, _mem_save_string_1, 0);
3057 }
3058 NDR_PULL_SET_MEM_CTX(ndr, _mem_save_string_0, LIBNDR_FLAG_REF_ALLOC);
3059 if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
3060 NDR_PULL_ALLOC(ndr, r->out.error);
3061 }
3062 _mem_save_error_0 = NDR_PULL_GET_MEM_CTX(ndr);
3063 NDR_PULL_SET_MEM_CTX(ndr, r->out.error, LIBNDR_FLAG_REF_ALLOC);
3064 NDR_CHECK(ndr_pull_eventlog6_RpcInfo(ndr, NDR_SCALARS, r->out.error));
3065 NDR_PULL_SET_MEM_CTX(ndr, _mem_save_error_0, LIBNDR_FLAG_REF_ALLOC);
3066 NDR_CHECK(ndr_pull_WERROR(ndr, NDR_SCALARS, &r->out.result));
3067 if (*r->out.string) {
3068 NDR_CHECK(ndr_check_array_size(ndr, (void*)r->out.string, *r->out.actualSizeString));
3069 }
3070 }
3071 return NDR_ERR_SUCCESS;
3072}
3073
3074_PUBLIC_ void ndr_print_eventlog6_EvtRpcMessageRenderDefault(struct ndr_print *ndr, const char *name, int flags, const struct eventlog6_EvtRpcMessageRenderDefault *r)
3075{
3076 ndr_print_struct(ndr, name, "eventlog6_EvtRpcMessageRenderDefault");
3077 if (r == NULL) { ndr_print_null(ndr); return; }
3078 ndr->depth++;
3079 if (flags & NDR_SET_VALUES) {
3080 ndr->flags |= LIBNDR_PRINT_SET_VALUES;
3081 }
3082 if (flags & NDR_IN) {
3083 ndr_print_struct(ndr, "in", "eventlog6_EvtRpcMessageRenderDefault");
3084 ndr->depth++;
3085 ndr_print_uint32(ndr, "sizeEventId", r->in.sizeEventId);
3086 ndr_print_ptr(ndr, "eventId", r->in.eventId);
3087 ndr->depth++;
3088 ndr_print_array_uint8(ndr, "eventId", r->in.eventId, r->in.sizeEventId);
3089 ndr->depth--;
3090 ndr_print_uint32(ndr, "messageId", r->in.messageId);
3091 ndr_print_ptr(ndr, "values", r->in.values);
3092 ndr->depth++;
3093 ndr_print_eventlog6_EvtRpcVariantList(ndr, "values", r->in.values);
3094 ndr->depth--;
3095 ndr_print_uint32(ndr, "flags", r->in.flags);
3096 ndr_print_uint32(ndr, "maxSizeString", r->in.maxSizeString);
3097 ndr->depth--;
3098 }
3099 if (flags & NDR_OUT) {
3100 ndr_print_struct(ndr, "out", "eventlog6_EvtRpcMessageRenderDefault");
3101 ndr->depth++;
3102 ndr_print_ptr(ndr, "actualSizeString", r->out.actualSizeString);
3103 ndr->depth++;
3104 ndr_print_uint32(ndr, "actualSizeString", *r->out.actualSizeString);
3105 ndr->depth--;
3106 ndr_print_ptr(ndr, "neededSizeString", r->out.neededSizeString);
3107 ndr->depth++;
3108 ndr_print_uint32(ndr, "neededSizeString", *r->out.neededSizeString);
3109 ndr->depth--;
3110 ndr_print_ptr(ndr, "string", r->out.string);
3111 ndr->depth++;
3112 ndr_print_ptr(ndr, "string", *r->out.string);
3113 ndr->depth++;
3114 if (*r->out.string) {
3115 ndr_print_array_uint8(ndr, "string", *r->out.string, *r->out.actualSizeString);
3116 }
3117 ndr->depth--;
3118 ndr->depth--;
3119 ndr_print_ptr(ndr, "error", r->out.error);
3120 ndr->depth++;
3121 ndr_print_eventlog6_RpcInfo(ndr, "error", r->out.error);
3122 ndr->depth--;
3123 ndr_print_WERROR(ndr, "result", r->out.result);
3124 ndr->depth--;
3125 }
3126 ndr->depth--;
3127}
3128
3129static enum ndr_err_code ndr_push_eventlog6_EvtRpcQueryNext(struct ndr_push *ndr, int flags, const struct eventlog6_EvtRpcQueryNext *r)
3130{
3131 uint32_t cntr_eventDataIndices_2;
3132 uint32_t cntr_eventDataSizes_2;
3133 if (flags & NDR_IN) {
3134 if (r->in.logQuery == NULL) {
3135 return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
3136 }
3137 NDR_CHECK(ndr_push_policy_handle(ndr, NDR_SCALARS, r->in.logQuery));
3138 NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->in.numRequestedRecords));
3139 NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->in.timeOutEnd));
3140 NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->in.flags));
3141 }
3142 if (flags & NDR_OUT) {
3143 if (r->out.numActualRecords == NULL) {
3144 return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
3145 }
3146 NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, *r->out.numActualRecords));
3147 if (r->out.eventDataIndices == NULL) {
3148 return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
3149 }
3150 NDR_CHECK(ndr_push_unique_ptr(ndr, *r->out.eventDataIndices));
3151 if (*r->out.eventDataIndices) {
3152 NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, *r->out.numActualRecords));
3153 for (cntr_eventDataIndices_2 = 0; cntr_eventDataIndices_2 < *r->out.numActualRecords; cntr_eventDataIndices_2++) {
3154 NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, (*r->out.eventDataIndices)[cntr_eventDataIndices_2]));
3155 }
3156 }
3157 if (r->out.eventDataSizes == NULL) {
3158 return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
3159 }
3160 NDR_CHECK(ndr_push_unique_ptr(ndr, *r->out.eventDataSizes));
3161 if (*r->out.eventDataSizes) {
3162 NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, *r->out.numActualRecords));
3163 for (cntr_eventDataSizes_2 = 0; cntr_eventDataSizes_2 < *r->out.numActualRecords; cntr_eventDataSizes_2++) {
3164 NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, (*r->out.eventDataSizes)[cntr_eventDataSizes_2]));
3165 }
3166 }
3167 if (r->out.resultBufferSize == NULL) {
3168 return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
3169 }
3170 NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, *r->out.resultBufferSize));
3171 if (r->out.resultBuffer == NULL) {
3172 return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
3173 }
3174 NDR_CHECK(ndr_push_unique_ptr(ndr, *r->out.resultBuffer));
3175 if (*r->out.resultBuffer) {
3176 NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, *r->out.resultBufferSize));
3177 NDR_CHECK(ndr_push_array_uint8(ndr, NDR_SCALARS, *r->out.resultBuffer, *r->out.resultBufferSize));
3178 }
3179 NDR_CHECK(ndr_push_WERROR(ndr, NDR_SCALARS, r->out.result));
3180 }
3181 return NDR_ERR_SUCCESS;
3182}
3183
3184static enum ndr_err_code ndr_pull_eventlog6_EvtRpcQueryNext(struct ndr_pull *ndr, int flags, struct eventlog6_EvtRpcQueryNext *r)
3185{
3186 uint32_t _ptr_eventDataIndices;
3187 uint32_t size_eventDataIndices_2 = 0;
3188 uint32_t cntr_eventDataIndices_2;
3189 uint32_t _ptr_eventDataSizes;
3190 uint32_t size_eventDataSizes_2 = 0;
3191 uint32_t cntr_eventDataSizes_2;
3192 uint32_t _ptr_resultBuffer;
3193 uint32_t size_resultBuffer_2 = 0;
3194 TALLOC_CTX *_mem_save_logQuery_0;
3195 TALLOC_CTX *_mem_save_numActualRecords_0;
3196 TALLOC_CTX *_mem_save_eventDataIndices_0;
3197 TALLOC_CTX *_mem_save_eventDataIndices_1;
3198 TALLOC_CTX *_mem_save_eventDataIndices_2;
3199 TALLOC_CTX *_mem_save_eventDataSizes_0;
3200 TALLOC_CTX *_mem_save_eventDataSizes_1;
3201 TALLOC_CTX *_mem_save_eventDataSizes_2;
3202 TALLOC_CTX *_mem_save_resultBufferSize_0;
3203 TALLOC_CTX *_mem_save_resultBuffer_0;
3204 TALLOC_CTX *_mem_save_resultBuffer_1;
3205 if (flags & NDR_IN) {
3206 ZERO_STRUCT(r->out);
3207
3208 if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
3209 NDR_PULL_ALLOC(ndr, r->in.logQuery);
3210 }
3211 _mem_save_logQuery_0 = NDR_PULL_GET_MEM_CTX(ndr);
3212 NDR_PULL_SET_MEM_CTX(ndr, r->in.logQuery, LIBNDR_FLAG_REF_ALLOC);
3213 NDR_CHECK(ndr_pull_policy_handle(ndr, NDR_SCALARS, r->in.logQuery));
3214 NDR_PULL_SET_MEM_CTX(ndr, _mem_save_logQuery_0, LIBNDR_FLAG_REF_ALLOC);
3215 NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->in.numRequestedRecords));
3216 NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->in.timeOutEnd));
3217 NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->in.flags));
3218 NDR_PULL_ALLOC(ndr, r->out.numActualRecords);
3219 ZERO_STRUCTP(r->out.numActualRecords);
3220 NDR_PULL_ALLOC(ndr, r->out.eventDataIndices);
3221 ZERO_STRUCTP(r->out.eventDataIndices);
3222 NDR_PULL_ALLOC(ndr, r->out.eventDataSizes);
3223 ZERO_STRUCTP(r->out.eventDataSizes);
3224 NDR_PULL_ALLOC(ndr, r->out.resultBufferSize);
3225 ZERO_STRUCTP(r->out.resultBufferSize);
3226 NDR_PULL_ALLOC(ndr, r->out.resultBuffer);
3227 ZERO_STRUCTP(r->out.resultBuffer);
3228 }
3229 if (flags & NDR_OUT) {
3230 if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
3231 NDR_PULL_ALLOC(ndr, r->out.numActualRecords);
3232 }
3233 _mem_save_numActualRecords_0 = NDR_PULL_GET_MEM_CTX(ndr);
3234 NDR_PULL_SET_MEM_CTX(ndr, r->out.numActualRecords, LIBNDR_FLAG_REF_ALLOC);
3235 NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, r->out.numActualRecords));
3236 NDR_PULL_SET_MEM_CTX(ndr, _mem_save_numActualRecords_0, LIBNDR_FLAG_REF_ALLOC);
3237 if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
3238 NDR_PULL_ALLOC(ndr, r->out.eventDataIndices);
3239 }
3240 _mem_save_eventDataIndices_0 = NDR_PULL_GET_MEM_CTX(ndr);
3241 NDR_PULL_SET_MEM_CTX(ndr, r->out.eventDataIndices, LIBNDR_FLAG_REF_ALLOC);
3242 NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_eventDataIndices));
3243 if (_ptr_eventDataIndices) {
3244 NDR_PULL_ALLOC(ndr, *r->out.eventDataIndices);
3245 } else {
3246 *r->out.eventDataIndices = NULL;
3247 }
3248 if (*r->out.eventDataIndices) {
3249 _mem_save_eventDataIndices_1 = NDR_PULL_GET_MEM_CTX(ndr);
3250 NDR_PULL_SET_MEM_CTX(ndr, *r->out.eventDataIndices, 0);
3251 NDR_CHECK(ndr_pull_array_size(ndr, r->out.eventDataIndices));
3252 size_eventDataIndices_2 = ndr_get_array_size(ndr, r->out.eventDataIndices);
3253 if (size_eventDataIndices_2 > MAX_RPC_RECORD_COUNT) {
3254 return ndr_pull_error(ndr, NDR_ERR_RANGE, "value out of range");
3255 }
3256 NDR_PULL_ALLOC_N(ndr, *r->out.eventDataIndices, size_eventDataIndices_2);
3257 _mem_save_eventDataIndices_2 = NDR_PULL_GET_MEM_CTX(ndr);
3258 NDR_PULL_SET_MEM_CTX(ndr, *r->out.eventDataIndices, 0);
3259 for (cntr_eventDataIndices_2 = 0; cntr_eventDataIndices_2 < size_eventDataIndices_2; cntr_eventDataIndices_2++) {
3260 NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &(*r->out.eventDataIndices)[cntr_eventDataIndices_2]));
3261 }
3262 NDR_PULL_SET_MEM_CTX(ndr, _mem_save_eventDataIndices_2, 0);
3263 NDR_PULL_SET_MEM_CTX(ndr, _mem_save_eventDataIndices_1, 0);
3264 }
3265 NDR_PULL_SET_MEM_CTX(ndr, _mem_save_eventDataIndices_0, LIBNDR_FLAG_REF_ALLOC);
3266 if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
3267 NDR_PULL_ALLOC(ndr, r->out.eventDataSizes);
3268 }
3269 _mem_save_eventDataSizes_0 = NDR_PULL_GET_MEM_CTX(ndr);
3270 NDR_PULL_SET_MEM_CTX(ndr, r->out.eventDataSizes, LIBNDR_FLAG_REF_ALLOC);
3271 NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_eventDataSizes));
3272 if (_ptr_eventDataSizes) {
3273 NDR_PULL_ALLOC(ndr, *r->out.eventDataSizes);
3274 } else {
3275 *r->out.eventDataSizes = NULL;
3276 }
3277 if (*r->out.eventDataSizes) {
3278 _mem_save_eventDataSizes_1 = NDR_PULL_GET_MEM_CTX(ndr);
3279 NDR_PULL_SET_MEM_CTX(ndr, *r->out.eventDataSizes, 0);
3280 NDR_CHECK(ndr_pull_array_size(ndr, r->out.eventDataSizes));
3281 size_eventDataSizes_2 = ndr_get_array_size(ndr, r->out.eventDataSizes);
3282 if (size_eventDataSizes_2 > MAX_RPC_RECORD_COUNT) {
3283 return ndr_pull_error(ndr, NDR_ERR_RANGE, "value out of range");
3284 }
3285 NDR_PULL_ALLOC_N(ndr, *r->out.eventDataSizes, size_eventDataSizes_2);
3286 _mem_save_eventDataSizes_2 = NDR_PULL_GET_MEM_CTX(ndr);
3287 NDR_PULL_SET_MEM_CTX(ndr, *r->out.eventDataSizes, 0);
3288 for (cntr_eventDataSizes_2 = 0; cntr_eventDataSizes_2 < size_eventDataSizes_2; cntr_eventDataSizes_2++) {
3289 NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &(*r->out.eventDataSizes)[cntr_eventDataSizes_2]));
3290 }
3291 NDR_PULL_SET_MEM_CTX(ndr, _mem_save_eventDataSizes_2, 0);
3292 NDR_PULL_SET_MEM_CTX(ndr, _mem_save_eventDataSizes_1, 0);
3293 }
3294 NDR_PULL_SET_MEM_CTX(ndr, _mem_save_eventDataSizes_0, LIBNDR_FLAG_REF_ALLOC);
3295 if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
3296 NDR_PULL_ALLOC(ndr, r->out.resultBufferSize);
3297 }
3298 _mem_save_resultBufferSize_0 = NDR_PULL_GET_MEM_CTX(ndr);
3299 NDR_PULL_SET_MEM_CTX(ndr, r->out.resultBufferSize, LIBNDR_FLAG_REF_ALLOC);
3300 NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, r->out.resultBufferSize));
3301 NDR_PULL_SET_MEM_CTX(ndr, _mem_save_resultBufferSize_0, LIBNDR_FLAG_REF_ALLOC);
3302 if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
3303 NDR_PULL_ALLOC(ndr, r->out.resultBuffer);
3304 }
3305 _mem_save_resultBuffer_0 = NDR_PULL_GET_MEM_CTX(ndr);
3306 NDR_PULL_SET_MEM_CTX(ndr, r->out.resultBuffer, LIBNDR_FLAG_REF_ALLOC);
3307 NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_resultBuffer));
3308 if (_ptr_resultBuffer) {
3309 NDR_PULL_ALLOC(ndr, *r->out.resultBuffer);
3310 } else {
3311 *r->out.resultBuffer = NULL;
3312 }
3313 if (*r->out.resultBuffer) {
3314 _mem_save_resultBuffer_1 = NDR_PULL_GET_MEM_CTX(ndr);
3315 NDR_PULL_SET_MEM_CTX(ndr, *r->out.resultBuffer, 0);
3316 NDR_CHECK(ndr_pull_array_size(ndr, r->out.resultBuffer));
3317 size_resultBuffer_2 = ndr_get_array_size(ndr, r->out.resultBuffer);
3318 if (size_resultBuffer_2 > MAX_RPC_BATCH_SIZE) {
3319 return ndr_pull_error(ndr, NDR_ERR_RANGE, "value out of range");
3320 }
3321 NDR_PULL_ALLOC_N(ndr, *r->out.resultBuffer, size_resultBuffer_2);
3322 NDR_CHECK(ndr_pull_array_uint8(ndr, NDR_SCALARS, *r->out.resultBuffer, size_resultBuffer_2));
3323 NDR_PULL_SET_MEM_CTX(ndr, _mem_save_resultBuffer_1, 0);
3324 }
3325 NDR_PULL_SET_MEM_CTX(ndr, _mem_save_resultBuffer_0, LIBNDR_FLAG_REF_ALLOC);
3326 NDR_CHECK(ndr_pull_WERROR(ndr, NDR_SCALARS, &r->out.result));
3327 if (*r->out.eventDataIndices) {
3328 NDR_CHECK(ndr_check_array_size(ndr, (void*)r->out.eventDataIndices, *r->out.numActualRecords));
3329 }
3330 if (*r->out.eventDataSizes) {
3331 NDR_CHECK(ndr_check_array_size(ndr, (void*)r->out.eventDataSizes, *r->out.numActualRecords));
3332 }
3333 if (*r->out.resultBuffer) {
3334 NDR_CHECK(ndr_check_array_size(ndr, (void*)r->out.resultBuffer, *r->out.resultBufferSize));
3335 }
3336 }
3337 return NDR_ERR_SUCCESS;
3338}
3339
3340_PUBLIC_ void ndr_print_eventlog6_EvtRpcQueryNext(struct ndr_print *ndr, const char *name, int flags, const struct eventlog6_EvtRpcQueryNext *r)
3341{
3342 uint32_t cntr_eventDataIndices_2;
3343 uint32_t cntr_eventDataSizes_2;
3344 ndr_print_struct(ndr, name, "eventlog6_EvtRpcQueryNext");
3345 if (r == NULL) { ndr_print_null(ndr); return; }
3346 ndr->depth++;
3347 if (flags & NDR_SET_VALUES) {
3348 ndr->flags |= LIBNDR_PRINT_SET_VALUES;
3349 }
3350 if (flags & NDR_IN) {
3351 ndr_print_struct(ndr, "in", "eventlog6_EvtRpcQueryNext");
3352 ndr->depth++;
3353 ndr_print_ptr(ndr, "logQuery", r->in.logQuery);
3354 ndr->depth++;
3355 ndr_print_policy_handle(ndr, "logQuery", r->in.logQuery);
3356 ndr->depth--;
3357 ndr_print_uint32(ndr, "numRequestedRecords", r->in.numRequestedRecords);
3358 ndr_print_uint32(ndr, "timeOutEnd", r->in.timeOutEnd);
3359 ndr_print_uint32(ndr, "flags", r->in.flags);
3360 ndr->depth--;
3361 }
3362 if (flags & NDR_OUT) {
3363 ndr_print_struct(ndr, "out", "eventlog6_EvtRpcQueryNext");
3364 ndr->depth++;
3365 ndr_print_ptr(ndr, "numActualRecords", r->out.numActualRecords);
3366 ndr->depth++;
3367 ndr_print_uint32(ndr, "numActualRecords", *r->out.numActualRecords);
3368 ndr->depth--;
3369 ndr_print_ptr(ndr, "eventDataIndices", r->out.eventDataIndices);
3370 ndr->depth++;
3371 ndr_print_ptr(ndr, "eventDataIndices", *r->out.eventDataIndices);
3372 ndr->depth++;
3373 if (*r->out.eventDataIndices) {
3374 ndr->print(ndr, "%s: ARRAY(%d)", "eventDataIndices", (int)*r->out.numActualRecords);
3375 ndr->depth++;
3376 for (cntr_eventDataIndices_2=0;cntr_eventDataIndices_2<*r->out.numActualRecords;cntr_eventDataIndices_2++) {
3377 ndr_print_uint32(ndr, "eventDataIndices", (*r->out.eventDataIndices)[cntr_eventDataIndices_2]);
3378 }
3379 ndr->depth--;
3380 }
3381 ndr->depth--;
3382 ndr->depth--;
3383 ndr_print_ptr(ndr, "eventDataSizes", r->out.eventDataSizes);
3384 ndr->depth++;
3385 ndr_print_ptr(ndr, "eventDataSizes", *r->out.eventDataSizes);
3386 ndr->depth++;
3387 if (*r->out.eventDataSizes) {
3388 ndr->print(ndr, "%s: ARRAY(%d)", "eventDataSizes", (int)*r->out.numActualRecords);
3389 ndr->depth++;
3390 for (cntr_eventDataSizes_2=0;cntr_eventDataSizes_2<*r->out.numActualRecords;cntr_eventDataSizes_2++) {
3391 ndr_print_uint32(ndr, "eventDataSizes", (*r->out.eventDataSizes)[cntr_eventDataSizes_2]);
3392 }
3393 ndr->depth--;
3394 }
3395 ndr->depth--;
3396 ndr->depth--;
3397 ndr_print_ptr(ndr, "resultBufferSize", r->out.resultBufferSize);
3398 ndr->depth++;
3399 ndr_print_uint32(ndr, "resultBufferSize", *r->out.resultBufferSize);
3400 ndr->depth--;
3401 ndr_print_ptr(ndr, "resultBuffer", r->out.resultBuffer);
3402 ndr->depth++;
3403 ndr_print_ptr(ndr, "resultBuffer", *r->out.resultBuffer);
3404 ndr->depth++;
3405 if (*r->out.resultBuffer) {
3406 ndr_print_array_uint8(ndr, "resultBuffer", *r->out.resultBuffer, *r->out.resultBufferSize);
3407 }
3408 ndr->depth--;
3409 ndr->depth--;
3410 ndr_print_WERROR(ndr, "result", r->out.result);
3411 ndr->depth--;
3412 }
3413 ndr->depth--;
3414}
3415
3416static enum ndr_err_code ndr_push_eventlog6_EvtRpcQuerySeek(struct ndr_push *ndr, int flags, const struct eventlog6_EvtRpcQuerySeek *r)
3417{
3418 if (flags & NDR_IN) {
3419 if (r->in.logQuery == NULL) {
3420 return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
3421 }
3422 NDR_CHECK(ndr_push_policy_handle(ndr, NDR_SCALARS, r->in.logQuery));
3423 NDR_CHECK(ndr_push_hyper(ndr, NDR_SCALARS, r->in.pos));
3424 NDR_CHECK(ndr_push_unique_ptr(ndr, r->in.bookmarkXml));
3425 if (r->in.bookmarkXml) {
3426 NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->in.bookmarkXml, CH_UTF16)));
3427 NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, 0));
3428 NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->in.bookmarkXml, CH_UTF16)));
3429 NDR_CHECK(ndr_push_charset(ndr, NDR_SCALARS, r->in.bookmarkXml, ndr_charset_length(r->in.bookmarkXml, CH_UTF16), sizeof(uint16_t), CH_UTF16));
3430 }
3431 NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->in.timeOut));
3432 NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->in.flags));
3433 }
3434 if (flags & NDR_OUT) {
3435 if (r->out.error == NULL) {
3436 return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
3437 }
3438 NDR_CHECK(ndr_push_eventlog6_RpcInfo(ndr, NDR_SCALARS, r->out.error));
3439 NDR_CHECK(ndr_push_WERROR(ndr, NDR_SCALARS, r->out.result));
3440 }
3441 return NDR_ERR_SUCCESS;
3442}
3443
3444static enum ndr_err_code ndr_pull_eventlog6_EvtRpcQuerySeek(struct ndr_pull *ndr, int flags, struct eventlog6_EvtRpcQuerySeek *r)
3445{
3446 uint32_t _ptr_bookmarkXml;
3447 uint32_t size_bookmarkXml_1 = 0;
3448 uint32_t length_bookmarkXml_1 = 0;
3449 TALLOC_CTX *_mem_save_logQuery_0;
3450 TALLOC_CTX *_mem_save_bookmarkXml_0;
3451 TALLOC_CTX *_mem_save_error_0;
3452 if (flags & NDR_IN) {
3453 ZERO_STRUCT(r->out);
3454
3455 if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
3456 NDR_PULL_ALLOC(ndr, r->in.logQuery);
3457 }
3458 _mem_save_logQuery_0 = NDR_PULL_GET_MEM_CTX(ndr);
3459 NDR_PULL_SET_MEM_CTX(ndr, r->in.logQuery, LIBNDR_FLAG_REF_ALLOC);
3460 NDR_CHECK(ndr_pull_policy_handle(ndr, NDR_SCALARS, r->in.logQuery));
3461 NDR_PULL_SET_MEM_CTX(ndr, _mem_save_logQuery_0, LIBNDR_FLAG_REF_ALLOC);
3462 NDR_CHECK(ndr_pull_hyper(ndr, NDR_SCALARS, &r->in.pos));
3463 NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_bookmarkXml));
3464 if (_ptr_bookmarkXml) {
3465 NDR_PULL_ALLOC(ndr, r->in.bookmarkXml);
3466 } else {
3467 r->in.bookmarkXml = NULL;
3468 }
3469 if (r->in.bookmarkXml) {
3470 _mem_save_bookmarkXml_0 = NDR_PULL_GET_MEM_CTX(ndr);
3471 NDR_PULL_SET_MEM_CTX(ndr, r->in.bookmarkXml, 0);
3472 NDR_CHECK(ndr_pull_array_size(ndr, &r->in.bookmarkXml));
3473 NDR_CHECK(ndr_pull_array_length(ndr, &r->in.bookmarkXml));
3474 size_bookmarkXml_1 = ndr_get_array_size(ndr, &r->in.bookmarkXml);
3475 if (size_bookmarkXml_1 > MAX_RPC_BOOKMARK_LENGTH) {
3476 return ndr_pull_error(ndr, NDR_ERR_RANGE, "value out of range");
3477 }
3478 length_bookmarkXml_1 = ndr_get_array_length(ndr, &r->in.bookmarkXml);
3479 if (length_bookmarkXml_1 > MAX_RPC_BOOKMARK_LENGTH) {
3480 return ndr_pull_error(ndr, NDR_ERR_RANGE, "value out of range");
3481 }
3482 if (length_bookmarkXml_1 > size_bookmarkXml_1) {
3483 return ndr_pull_error(ndr, NDR_ERR_ARRAY_SIZE, "Bad array size %u should exceed array length %u", size_bookmarkXml_1, length_bookmarkXml_1);
3484 }
3485 NDR_CHECK(ndr_check_string_terminator(ndr, length_bookmarkXml_1, sizeof(uint16_t)));
3486 NDR_CHECK(ndr_pull_charset(ndr, NDR_SCALARS, &r->in.bookmarkXml, length_bookmarkXml_1, sizeof(uint16_t), CH_UTF16));
3487 NDR_PULL_SET_MEM_CTX(ndr, _mem_save_bookmarkXml_0, 0);
3488 }
3489 NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->in.timeOut));
3490 NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->in.flags));
3491 NDR_PULL_ALLOC(ndr, r->out.error);
3492 ZERO_STRUCTP(r->out.error);
3493 }
3494 if (flags & NDR_OUT) {
3495 if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
3496 NDR_PULL_ALLOC(ndr, r->out.error);
3497 }
3498 _mem_save_error_0 = NDR_PULL_GET_MEM_CTX(ndr);
3499 NDR_PULL_SET_MEM_CTX(ndr, r->out.error, LIBNDR_FLAG_REF_ALLOC);
3500 NDR_CHECK(ndr_pull_eventlog6_RpcInfo(ndr, NDR_SCALARS, r->out.error));
3501 NDR_PULL_SET_MEM_CTX(ndr, _mem_save_error_0, LIBNDR_FLAG_REF_ALLOC);
3502 NDR_CHECK(ndr_pull_WERROR(ndr, NDR_SCALARS, &r->out.result));
3503 }
3504 return NDR_ERR_SUCCESS;
3505}
3506
3507_PUBLIC_ void ndr_print_eventlog6_EvtRpcQuerySeek(struct ndr_print *ndr, const char *name, int flags, const struct eventlog6_EvtRpcQuerySeek *r)
3508{
3509 ndr_print_struct(ndr, name, "eventlog6_EvtRpcQuerySeek");
3510 if (r == NULL) { ndr_print_null(ndr); return; }
3511 ndr->depth++;
3512 if (flags & NDR_SET_VALUES) {
3513 ndr->flags |= LIBNDR_PRINT_SET_VALUES;
3514 }
3515 if (flags & NDR_IN) {
3516 ndr_print_struct(ndr, "in", "eventlog6_EvtRpcQuerySeek");
3517 ndr->depth++;
3518 ndr_print_ptr(ndr, "logQuery", r->in.logQuery);
3519 ndr->depth++;
3520 ndr_print_policy_handle(ndr, "logQuery", r->in.logQuery);
3521 ndr->depth--;
3522 ndr_print_hyper(ndr, "pos", r->in.pos);
3523 ndr_print_ptr(ndr, "bookmarkXml", r->in.bookmarkXml);
3524 ndr->depth++;
3525 if (r->in.bookmarkXml) {
3526 ndr_print_string(ndr, "bookmarkXml", r->in.bookmarkXml);
3527 }
3528 ndr->depth--;
3529 ndr_print_uint32(ndr, "timeOut", r->in.timeOut);
3530 ndr_print_uint32(ndr, "flags", r->in.flags);
3531 ndr->depth--;
3532 }
3533 if (flags & NDR_OUT) {
3534 ndr_print_struct(ndr, "out", "eventlog6_EvtRpcQuerySeek");
3535 ndr->depth++;
3536 ndr_print_ptr(ndr, "error", r->out.error);
3537 ndr->depth++;
3538 ndr_print_eventlog6_RpcInfo(ndr, "error", r->out.error);
3539 ndr->depth--;
3540 ndr_print_WERROR(ndr, "result", r->out.result);
3541 ndr->depth--;
3542 }
3543 ndr->depth--;
3544}
3545
3546static enum ndr_err_code ndr_push_eventlog6_EvtRpcClose(struct ndr_push *ndr, int flags, const struct eventlog6_EvtRpcClose *r)
3547{
3548 if (flags & NDR_IN) {
3549 if (r->in.handle == NULL) {
3550 return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
3551 }
3552 NDR_CHECK(ndr_push_unique_ptr(ndr, *r->in.handle));
3553 if (*r->in.handle) {
3554 NDR_CHECK(ndr_push_policy_handle(ndr, NDR_SCALARS, *r->in.handle));
3555 }
3556 }
3557 if (flags & NDR_OUT) {
3558 if (r->out.handle == NULL) {
3559 return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
3560 }
3561 NDR_CHECK(ndr_push_unique_ptr(ndr, *r->out.handle));
3562 if (*r->out.handle) {
3563 NDR_CHECK(ndr_push_policy_handle(ndr, NDR_SCALARS, *r->out.handle));
3564 }
3565 NDR_CHECK(ndr_push_WERROR(ndr, NDR_SCALARS, r->out.result));
3566 }
3567 return NDR_ERR_SUCCESS;
3568}
3569
3570static enum ndr_err_code ndr_pull_eventlog6_EvtRpcClose(struct ndr_pull *ndr, int flags, struct eventlog6_EvtRpcClose *r)
3571{
3572 uint32_t _ptr_handle;
3573 TALLOC_CTX *_mem_save_handle_0;
3574 TALLOC_CTX *_mem_save_handle_1;
3575 if (flags & NDR_IN) {
3576 ZERO_STRUCT(r->out);
3577
3578 if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
3579 NDR_PULL_ALLOC(ndr, r->in.handle);
3580 }
3581 _mem_save_handle_0 = NDR_PULL_GET_MEM_CTX(ndr);
3582 NDR_PULL_SET_MEM_CTX(ndr, r->in.handle, LIBNDR_FLAG_REF_ALLOC);
3583 NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_handle));
3584 if (_ptr_handle) {
3585 NDR_PULL_ALLOC(ndr, *r->in.handle);
3586 } else {
3587 *r->in.handle = NULL;
3588 }
3589 if (*r->in.handle) {
3590 _mem_save_handle_1 = NDR_PULL_GET_MEM_CTX(ndr);
3591 NDR_PULL_SET_MEM_CTX(ndr, *r->in.handle, 0);
3592 NDR_CHECK(ndr_pull_policy_handle(ndr, NDR_SCALARS, *r->in.handle));
3593 NDR_PULL_SET_MEM_CTX(ndr, _mem_save_handle_1, 0);
3594 }
3595 NDR_PULL_SET_MEM_CTX(ndr, _mem_save_handle_0, LIBNDR_FLAG_REF_ALLOC);
3596 NDR_PULL_ALLOC(ndr, r->out.handle);
3597 *r->out.handle = *r->in.handle;
3598 }
3599 if (flags & NDR_OUT) {
3600 if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
3601 NDR_PULL_ALLOC(ndr, r->out.handle);
3602 }
3603 _mem_save_handle_0 = NDR_PULL_GET_MEM_CTX(ndr);
3604 NDR_PULL_SET_MEM_CTX(ndr, r->out.handle, LIBNDR_FLAG_REF_ALLOC);
3605 NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_handle));
3606 if (_ptr_handle) {
3607 NDR_PULL_ALLOC(ndr, *r->out.handle);
3608 } else {
3609 *r->out.handle = NULL;
3610 }
3611 if (*r->out.handle) {
3612 _mem_save_handle_1 = NDR_PULL_GET_MEM_CTX(ndr);
3613 NDR_PULL_SET_MEM_CTX(ndr, *r->out.handle, 0);
3614 NDR_CHECK(ndr_pull_policy_handle(ndr, NDR_SCALARS, *r->out.handle));
3615 NDR_PULL_SET_MEM_CTX(ndr, _mem_save_handle_1, 0);
3616 }
3617 NDR_PULL_SET_MEM_CTX(ndr, _mem_save_handle_0, LIBNDR_FLAG_REF_ALLOC);
3618 NDR_CHECK(ndr_pull_WERROR(ndr, NDR_SCALARS, &r->out.result));
3619 }
3620 return NDR_ERR_SUCCESS;
3621}
3622
3623_PUBLIC_ void ndr_print_eventlog6_EvtRpcClose(struct ndr_print *ndr, const char *name, int flags, const struct eventlog6_EvtRpcClose *r)
3624{
3625 ndr_print_struct(ndr, name, "eventlog6_EvtRpcClose");
3626 if (r == NULL) { ndr_print_null(ndr); return; }
3627 ndr->depth++;
3628 if (flags & NDR_SET_VALUES) {
3629 ndr->flags |= LIBNDR_PRINT_SET_VALUES;
3630 }
3631 if (flags & NDR_IN) {
3632 ndr_print_struct(ndr, "in", "eventlog6_EvtRpcClose");
3633 ndr->depth++;
3634 ndr_print_ptr(ndr, "handle", r->in.handle);
3635 ndr->depth++;
3636 ndr_print_ptr(ndr, "handle", *r->in.handle);
3637 ndr->depth++;
3638 if (*r->in.handle) {
3639 ndr_print_policy_handle(ndr, "handle", *r->in.handle);
3640 }
3641 ndr->depth--;
3642 ndr->depth--;
3643 ndr->depth--;
3644 }
3645 if (flags & NDR_OUT) {
3646 ndr_print_struct(ndr, "out", "eventlog6_EvtRpcClose");
3647 ndr->depth++;
3648 ndr_print_ptr(ndr, "handle", r->out.handle);
3649 ndr->depth++;
3650 ndr_print_ptr(ndr, "handle", *r->out.handle);
3651 ndr->depth++;
3652 if (*r->out.handle) {
3653 ndr_print_policy_handle(ndr, "handle", *r->out.handle);
3654 }
3655 ndr->depth--;
3656 ndr->depth--;
3657 ndr_print_WERROR(ndr, "result", r->out.result);
3658 ndr->depth--;
3659 }
3660 ndr->depth--;
3661}
3662
3663static enum ndr_err_code ndr_push_eventlog6_EvtRpcCancel(struct ndr_push *ndr, int flags, const struct eventlog6_EvtRpcCancel *r)
3664{
3665 if (flags & NDR_IN) {
3666 if (r->in.handle == NULL) {
3667 return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
3668 }
3669 NDR_CHECK(ndr_push_policy_handle(ndr, NDR_SCALARS, r->in.handle));
3670 }
3671 if (flags & NDR_OUT) {
3672 NDR_CHECK(ndr_push_WERROR(ndr, NDR_SCALARS, r->out.result));
3673 }
3674 return NDR_ERR_SUCCESS;
3675}
3676
3677static enum ndr_err_code ndr_pull_eventlog6_EvtRpcCancel(struct ndr_pull *ndr, int flags, struct eventlog6_EvtRpcCancel *r)
3678{
3679 TALLOC_CTX *_mem_save_handle_0;
3680 if (flags & NDR_IN) {
3681 if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
3682 NDR_PULL_ALLOC(ndr, r->in.handle);
3683 }
3684 _mem_save_handle_0 = NDR_PULL_GET_MEM_CTX(ndr);
3685 NDR_PULL_SET_MEM_CTX(ndr, r->in.handle, LIBNDR_FLAG_REF_ALLOC);
3686 NDR_CHECK(ndr_pull_policy_handle(ndr, NDR_SCALARS, r->in.handle));
3687 NDR_PULL_SET_MEM_CTX(ndr, _mem_save_handle_0, LIBNDR_FLAG_REF_ALLOC);
3688 }
3689 if (flags & NDR_OUT) {
3690 NDR_CHECK(ndr_pull_WERROR(ndr, NDR_SCALARS, &r->out.result));
3691 }
3692 return NDR_ERR_SUCCESS;
3693}
3694
3695_PUBLIC_ void ndr_print_eventlog6_EvtRpcCancel(struct ndr_print *ndr, const char *name, int flags, const struct eventlog6_EvtRpcCancel *r)
3696{
3697 ndr_print_struct(ndr, name, "eventlog6_EvtRpcCancel");
3698 if (r == NULL) { ndr_print_null(ndr); return; }
3699 ndr->depth++;
3700 if (flags & NDR_SET_VALUES) {
3701 ndr->flags |= LIBNDR_PRINT_SET_VALUES;
3702 }
3703 if (flags & NDR_IN) {
3704 ndr_print_struct(ndr, "in", "eventlog6_EvtRpcCancel");
3705 ndr->depth++;
3706 ndr_print_ptr(ndr, "handle", r->in.handle);
3707 ndr->depth++;
3708 ndr_print_policy_handle(ndr, "handle", r->in.handle);
3709 ndr->depth--;
3710 ndr->depth--;
3711 }
3712 if (flags & NDR_OUT) {
3713 ndr_print_struct(ndr, "out", "eventlog6_EvtRpcCancel");
3714 ndr->depth++;
3715 ndr_print_WERROR(ndr, "result", r->out.result);
3716 ndr->depth--;
3717 }
3718 ndr->depth--;
3719}
3720
3721static enum ndr_err_code ndr_push_eventlog6_EvtRpcAssertConfig(struct ndr_push *ndr, int flags, const struct eventlog6_EvtRpcAssertConfig *r)
3722{
3723 if (flags & NDR_IN) {
3724 if (r->in.path == NULL) {
3725 return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
3726 }
3727 NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->in.path, CH_UTF16)));
3728 NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, 0));
3729 NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->in.path, CH_UTF16)));
3730 NDR_CHECK(ndr_push_charset(ndr, NDR_SCALARS, r->in.path, ndr_charset_length(r->in.path, CH_UTF16), sizeof(uint16_t), CH_UTF16));
3731 NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->in.flags));
3732 }
3733 if (flags & NDR_OUT) {
3734 NDR_CHECK(ndr_push_WERROR(ndr, NDR_SCALARS, r->out.result));
3735 }
3736 return NDR_ERR_SUCCESS;
3737}
3738
3739static enum ndr_err_code ndr_pull_eventlog6_EvtRpcAssertConfig(struct ndr_pull *ndr, int flags, struct eventlog6_EvtRpcAssertConfig *r)
3740{
3741 uint32_t size_path_1 = 0;
3742 uint32_t length_path_1 = 0;
3743 if (flags & NDR_IN) {
3744 NDR_CHECK(ndr_pull_array_size(ndr, &r->in.path));
3745 NDR_CHECK(ndr_pull_array_length(ndr, &r->in.path));
3746 size_path_1 = ndr_get_array_size(ndr, &r->in.path);
3747 if (size_path_1 < 1 || size_path_1 > MAX_RPC_CHANNEL_NAME_LENGTH) {
3748 return ndr_pull_error(ndr, NDR_ERR_RANGE, "value out of range");
3749 }
3750 length_path_1 = ndr_get_array_length(ndr, &r->in.path);
3751 if (length_path_1 < 1 || length_path_1 > MAX_RPC_CHANNEL_NAME_LENGTH) {
3752 return ndr_pull_error(ndr, NDR_ERR_RANGE, "value out of range");
3753 }
3754 if (length_path_1 > size_path_1) {
3755 return ndr_pull_error(ndr, NDR_ERR_ARRAY_SIZE, "Bad array size %u should exceed array length %u", size_path_1, length_path_1);
3756 }
3757 NDR_CHECK(ndr_check_string_terminator(ndr, length_path_1, sizeof(uint16_t)));
3758 NDR_CHECK(ndr_pull_charset(ndr, NDR_SCALARS, &r->in.path, length_path_1, sizeof(uint16_t), CH_UTF16));
3759 NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->in.flags));
3760 }
3761 if (flags & NDR_OUT) {
3762 NDR_CHECK(ndr_pull_WERROR(ndr, NDR_SCALARS, &r->out.result));
3763 }
3764 return NDR_ERR_SUCCESS;
3765}
3766
3767_PUBLIC_ void ndr_print_eventlog6_EvtRpcAssertConfig(struct ndr_print *ndr, const char *name, int flags, const struct eventlog6_EvtRpcAssertConfig *r)
3768{
3769 ndr_print_struct(ndr, name, "eventlog6_EvtRpcAssertConfig");
3770 if (r == NULL) { ndr_print_null(ndr); return; }
3771 ndr->depth++;
3772 if (flags & NDR_SET_VALUES) {
3773 ndr->flags |= LIBNDR_PRINT_SET_VALUES;
3774 }
3775 if (flags & NDR_IN) {
3776 ndr_print_struct(ndr, "in", "eventlog6_EvtRpcAssertConfig");
3777 ndr->depth++;
3778 ndr_print_ptr(ndr, "path", r->in.path);
3779 ndr->depth++;
3780 ndr_print_string(ndr, "path", r->in.path);
3781 ndr->depth--;
3782 ndr_print_uint32(ndr, "flags", r->in.flags);
3783 ndr->depth--;
3784 }
3785 if (flags & NDR_OUT) {
3786 ndr_print_struct(ndr, "out", "eventlog6_EvtRpcAssertConfig");
3787 ndr->depth++;
3788 ndr_print_WERROR(ndr, "result", r->out.result);
3789 ndr->depth--;
3790 }
3791 ndr->depth--;
3792}
3793
3794static enum ndr_err_code ndr_push_eventlog6_EvtRpcRetractConfig(struct ndr_push *ndr, int flags, const struct eventlog6_EvtRpcRetractConfig *r)
3795{
3796 if (flags & NDR_IN) {
3797 if (r->in.path == NULL) {
3798 return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
3799 }
3800 NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->in.path, CH_UTF16)));
3801 NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, 0));
3802 NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->in.path, CH_UTF16)));
3803 NDR_CHECK(ndr_push_charset(ndr, NDR_SCALARS, r->in.path, ndr_charset_length(r->in.path, CH_UTF16), sizeof(uint16_t), CH_UTF16));
3804 NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->in.flags));
3805 }
3806 if (flags & NDR_OUT) {
3807 NDR_CHECK(ndr_push_WERROR(ndr, NDR_SCALARS, r->out.result));
3808 }
3809 return NDR_ERR_SUCCESS;
3810}
3811
3812static enum ndr_err_code ndr_pull_eventlog6_EvtRpcRetractConfig(struct ndr_pull *ndr, int flags, struct eventlog6_EvtRpcRetractConfig *r)
3813{
3814 uint32_t size_path_1 = 0;
3815 uint32_t length_path_1 = 0;
3816 if (flags & NDR_IN) {
3817 NDR_CHECK(ndr_pull_array_size(ndr, &r->in.path));
3818 NDR_CHECK(ndr_pull_array_length(ndr, &r->in.path));
3819 size_path_1 = ndr_get_array_size(ndr, &r->in.path);
3820 if (size_path_1 < 1 || size_path_1 > MAX_RPC_CHANNEL_NAME_LENGTH) {
3821 return ndr_pull_error(ndr, NDR_ERR_RANGE, "value out of range");
3822 }
3823 length_path_1 = ndr_get_array_length(ndr, &r->in.path);
3824 if (length_path_1 < 1 || length_path_1 > MAX_RPC_CHANNEL_NAME_LENGTH) {
3825 return ndr_pull_error(ndr, NDR_ERR_RANGE, "value out of range");
3826 }
3827 if (length_path_1 > size_path_1) {
3828 return ndr_pull_error(ndr, NDR_ERR_ARRAY_SIZE, "Bad array size %u should exceed array length %u", size_path_1, length_path_1);
3829 }
3830 NDR_CHECK(ndr_check_string_terminator(ndr, length_path_1, sizeof(uint16_t)));
3831 NDR_CHECK(ndr_pull_charset(ndr, NDR_SCALARS, &r->in.path, length_path_1, sizeof(uint16_t), CH_UTF16));
3832 NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->in.flags));
3833 }
3834 if (flags & NDR_OUT) {
3835 NDR_CHECK(ndr_pull_WERROR(ndr, NDR_SCALARS, &r->out.result));
3836 }
3837 return NDR_ERR_SUCCESS;
3838}
3839
3840_PUBLIC_ void ndr_print_eventlog6_EvtRpcRetractConfig(struct ndr_print *ndr, const char *name, int flags, const struct eventlog6_EvtRpcRetractConfig *r)
3841{
3842 ndr_print_struct(ndr, name, "eventlog6_EvtRpcRetractConfig");
3843 if (r == NULL) { ndr_print_null(ndr); return; }
3844 ndr->depth++;
3845 if (flags & NDR_SET_VALUES) {
3846 ndr->flags |= LIBNDR_PRINT_SET_VALUES;
3847 }
3848 if (flags & NDR_IN) {
3849 ndr_print_struct(ndr, "in", "eventlog6_EvtRpcRetractConfig");
3850 ndr->depth++;
3851 ndr_print_ptr(ndr, "path", r->in.path);
3852 ndr->depth++;
3853 ndr_print_string(ndr, "path", r->in.path);
3854 ndr->depth--;
3855 ndr_print_uint32(ndr, "flags", r->in.flags);
3856 ndr->depth--;
3857 }
3858 if (flags & NDR_OUT) {
3859 ndr_print_struct(ndr, "out", "eventlog6_EvtRpcRetractConfig");
3860 ndr->depth++;
3861 ndr_print_WERROR(ndr, "result", r->out.result);
3862 ndr->depth--;
3863 }
3864 ndr->depth--;
3865}
3866
3867static enum ndr_err_code ndr_push_eventlog6_EvtRpcOpenLogHandle(struct ndr_push *ndr, int flags, const struct eventlog6_EvtRpcOpenLogHandle *r)
3868{
3869 if (flags & NDR_IN) {
3870 if (r->in.channel == NULL) {
3871 return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
3872 }
3873 NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->in.channel, CH_UTF16)));
3874 NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, 0));
3875 NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->in.channel, CH_UTF16)));
3876 NDR_CHECK(ndr_push_charset(ndr, NDR_SCALARS, r->in.channel, ndr_charset_length(r->in.channel, CH_UTF16), sizeof(uint16_t), CH_UTF16));
3877 NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->in.flags));
3878 }
3879 if (flags & NDR_OUT) {
3880 if (r->out.handle == NULL) {
3881 return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
3882 }
3883 NDR_CHECK(ndr_push_policy_handle(ndr, NDR_SCALARS, r->out.handle));
3884 if (r->out.error == NULL) {
3885 return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
3886 }
3887 NDR_CHECK(ndr_push_eventlog6_RpcInfo(ndr, NDR_SCALARS, r->out.error));
3888 NDR_CHECK(ndr_push_WERROR(ndr, NDR_SCALARS, r->out.result));
3889 }
3890 return NDR_ERR_SUCCESS;
3891}
3892
3893static enum ndr_err_code ndr_pull_eventlog6_EvtRpcOpenLogHandle(struct ndr_pull *ndr, int flags, struct eventlog6_EvtRpcOpenLogHandle *r)
3894{
3895 uint32_t size_channel_1 = 0;
3896 uint32_t length_channel_1 = 0;
3897 TALLOC_CTX *_mem_save_handle_0;
3898 TALLOC_CTX *_mem_save_error_0;
3899 if (flags & NDR_IN) {
3900 ZERO_STRUCT(r->out);
3901
3902 NDR_CHECK(ndr_pull_array_size(ndr, &r->in.channel));
3903 NDR_CHECK(ndr_pull_array_length(ndr, &r->in.channel));
3904 size_channel_1 = ndr_get_array_size(ndr, &r->in.channel);
3905 if (size_channel_1 < 1 || size_channel_1 > MAX_RPC_CHANNEL_NAME_LENGTH) {
3906 return ndr_pull_error(ndr, NDR_ERR_RANGE, "value out of range");
3907 }
3908 length_channel_1 = ndr_get_array_length(ndr, &r->in.channel);
3909 if (length_channel_1 < 1 || length_channel_1 > MAX_RPC_CHANNEL_NAME_LENGTH) {
3910 return ndr_pull_error(ndr, NDR_ERR_RANGE, "value out of range");
3911 }
3912 if (length_channel_1 > size_channel_1) {
3913 return ndr_pull_error(ndr, NDR_ERR_ARRAY_SIZE, "Bad array size %u should exceed array length %u", size_channel_1, length_channel_1);
3914 }
3915 NDR_CHECK(ndr_check_string_terminator(ndr, length_channel_1, sizeof(uint16_t)));
3916 NDR_CHECK(ndr_pull_charset(ndr, NDR_SCALARS, &r->in.channel, length_channel_1, sizeof(uint16_t), CH_UTF16));
3917 NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->in.flags));
3918 NDR_PULL_ALLOC(ndr, r->out.handle);
3919 ZERO_STRUCTP(r->out.handle);
3920 NDR_PULL_ALLOC(ndr, r->out.error);
3921 ZERO_STRUCTP(r->out.error);
3922 }
3923 if (flags & NDR_OUT) {
3924 if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
3925 NDR_PULL_ALLOC(ndr, r->out.handle);
3926 }
3927 _mem_save_handle_0 = NDR_PULL_GET_MEM_CTX(ndr);
3928 NDR_PULL_SET_MEM_CTX(ndr, r->out.handle, LIBNDR_FLAG_REF_ALLOC);
3929 NDR_CHECK(ndr_pull_policy_handle(ndr, NDR_SCALARS, r->out.handle));
3930 NDR_PULL_SET_MEM_CTX(ndr, _mem_save_handle_0, LIBNDR_FLAG_REF_ALLOC);
3931 if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
3932 NDR_PULL_ALLOC(ndr, r->out.error);
3933 }
3934 _mem_save_error_0 = NDR_PULL_GET_MEM_CTX(ndr);
3935 NDR_PULL_SET_MEM_CTX(ndr, r->out.error, LIBNDR_FLAG_REF_ALLOC);
3936 NDR_CHECK(ndr_pull_eventlog6_RpcInfo(ndr, NDR_SCALARS, r->out.error));
3937 NDR_PULL_SET_MEM_CTX(ndr, _mem_save_error_0, LIBNDR_FLAG_REF_ALLOC);
3938 NDR_CHECK(ndr_pull_WERROR(ndr, NDR_SCALARS, &r->out.result));
3939 }
3940 return NDR_ERR_SUCCESS;
3941}
3942
3943_PUBLIC_ void ndr_print_eventlog6_EvtRpcOpenLogHandle(struct ndr_print *ndr, const char *name, int flags, const struct eventlog6_EvtRpcOpenLogHandle *r)
3944{
3945 ndr_print_struct(ndr, name, "eventlog6_EvtRpcOpenLogHandle");
3946 if (r == NULL) { ndr_print_null(ndr); return; }
3947 ndr->depth++;
3948 if (flags & NDR_SET_VALUES) {
3949 ndr->flags |= LIBNDR_PRINT_SET_VALUES;
3950 }
3951 if (flags & NDR_IN) {
3952 ndr_print_struct(ndr, "in", "eventlog6_EvtRpcOpenLogHandle");
3953 ndr->depth++;
3954 ndr_print_ptr(ndr, "channel", r->in.channel);
3955 ndr->depth++;
3956 ndr_print_string(ndr, "channel", r->in.channel);
3957 ndr->depth--;
3958 ndr_print_uint32(ndr, "flags", r->in.flags);
3959 ndr->depth--;
3960 }
3961 if (flags & NDR_OUT) {
3962 ndr_print_struct(ndr, "out", "eventlog6_EvtRpcOpenLogHandle");
3963 ndr->depth++;
3964 ndr_print_ptr(ndr, "handle", r->out.handle);
3965 ndr->depth++;
3966 ndr_print_policy_handle(ndr, "handle", r->out.handle);
3967 ndr->depth--;
3968 ndr_print_ptr(ndr, "error", r->out.error);
3969 ndr->depth++;
3970 ndr_print_eventlog6_RpcInfo(ndr, "error", r->out.error);
3971 ndr->depth--;
3972 ndr_print_WERROR(ndr, "result", r->out.result);
3973 ndr->depth--;
3974 }
3975 ndr->depth--;
3976}
3977
3978static enum ndr_err_code ndr_push_eventlog6_EvtRpcGetLogFileInfo(struct ndr_push *ndr, int flags, const struct eventlog6_EvtRpcGetLogFileInfo *r)
3979{
3980 if (flags & NDR_IN) {
3981 if (r->in.logHandle == NULL) {
3982 return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
3983 }
3984 NDR_CHECK(ndr_push_policy_handle(ndr, NDR_SCALARS, r->in.logHandle));
3985 NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->in.propertyId));
3986 NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->in.propertyValueBufferSize));
3987 }
3988 if (flags & NDR_OUT) {
3989 if (r->out.propertyValueBuffer == NULL) {
3990 return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
3991 }
3992 NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, r->in.propertyValueBufferSize));
3993 NDR_CHECK(ndr_push_array_uint8(ndr, NDR_SCALARS, r->out.propertyValueBuffer, r->in.propertyValueBufferSize));
3994 if (r->out.propertyValueBufferLength == NULL) {
3995 return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
3996 }
3997 NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, *r->out.propertyValueBufferLength));
3998 NDR_CHECK(ndr_push_WERROR(ndr, NDR_SCALARS, r->out.result));
3999 }
4000 return NDR_ERR_SUCCESS;
4001}
4002
4003static enum ndr_err_code ndr_pull_eventlog6_EvtRpcGetLogFileInfo(struct ndr_pull *ndr, int flags, struct eventlog6_EvtRpcGetLogFileInfo *r)
4004{
4005 uint32_t size_propertyValueBuffer_1 = 0;
4006 TALLOC_CTX *_mem_save_logHandle_0;
4007 TALLOC_CTX *_mem_save_propertyValueBufferLength_0;
4008 if (flags & NDR_IN) {
4009 ZERO_STRUCT(r->out);
4010
4011 if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
4012 NDR_PULL_ALLOC(ndr, r->in.logHandle);
4013 }
4014 _mem_save_logHandle_0 = NDR_PULL_GET_MEM_CTX(ndr);
4015 NDR_PULL_SET_MEM_CTX(ndr, r->in.logHandle, LIBNDR_FLAG_REF_ALLOC);
4016 NDR_CHECK(ndr_pull_policy_handle(ndr, NDR_SCALARS, r->in.logHandle));
4017 NDR_PULL_SET_MEM_CTX(ndr, _mem_save_logHandle_0, LIBNDR_FLAG_REF_ALLOC);
4018 NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->in.propertyId));
4019 NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->in.propertyValueBufferSize));
4020 if (r->in.propertyValueBufferSize > MAX_RPC_PROPERTY_BUFFER_SIZE) {
4021 return ndr_pull_error(ndr, NDR_ERR_RANGE, "value out of range");
4022 }
4023 NDR_PULL_ALLOC_N(ndr, r->out.propertyValueBuffer, r->in.propertyValueBufferSize);
4024 memset(r->out.propertyValueBuffer, 0, (r->in.propertyValueBufferSize) * sizeof(*r->out.propertyValueBuffer));
4025 NDR_PULL_ALLOC(ndr, r->out.propertyValueBufferLength);
4026 ZERO_STRUCTP(r->out.propertyValueBufferLength);
4027 }
4028 if (flags & NDR_OUT) {
4029 NDR_CHECK(ndr_pull_array_size(ndr, &r->out.propertyValueBuffer));
4030 size_propertyValueBuffer_1 = ndr_get_array_size(ndr, &r->out.propertyValueBuffer);
4031 if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
4032 NDR_PULL_ALLOC_N(ndr, r->out.propertyValueBuffer, size_propertyValueBuffer_1);
4033 }
4034 NDR_CHECK(ndr_pull_array_uint8(ndr, NDR_SCALARS, r->out.propertyValueBuffer, size_propertyValueBuffer_1));
4035 if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
4036 NDR_PULL_ALLOC(ndr, r->out.propertyValueBufferLength);
4037 }
4038 _mem_save_propertyValueBufferLength_0 = NDR_PULL_GET_MEM_CTX(ndr);
4039 NDR_PULL_SET_MEM_CTX(ndr, r->out.propertyValueBufferLength, LIBNDR_FLAG_REF_ALLOC);
4040 NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, r->out.propertyValueBufferLength));
4041 NDR_PULL_SET_MEM_CTX(ndr, _mem_save_propertyValueBufferLength_0, LIBNDR_FLAG_REF_ALLOC);
4042 NDR_CHECK(ndr_pull_WERROR(ndr, NDR_SCALARS, &r->out.result));
4043 if (r->out.propertyValueBuffer) {
4044 NDR_CHECK(ndr_check_array_size(ndr, (void*)&r->out.propertyValueBuffer, r->in.propertyValueBufferSize));
4045 }
4046 }
4047 return NDR_ERR_SUCCESS;
4048}
4049
4050_PUBLIC_ void ndr_print_eventlog6_EvtRpcGetLogFileInfo(struct ndr_print *ndr, const char *name, int flags, const struct eventlog6_EvtRpcGetLogFileInfo *r)
4051{
4052 ndr_print_struct(ndr, name, "eventlog6_EvtRpcGetLogFileInfo");
4053 if (r == NULL) { ndr_print_null(ndr); return; }
4054 ndr->depth++;
4055 if (flags & NDR_SET_VALUES) {
4056 ndr->flags |= LIBNDR_PRINT_SET_VALUES;
4057 }
4058 if (flags & NDR_IN) {
4059 ndr_print_struct(ndr, "in", "eventlog6_EvtRpcGetLogFileInfo");
4060 ndr->depth++;
4061 ndr_print_ptr(ndr, "logHandle", r->in.logHandle);
4062 ndr->depth++;
4063 ndr_print_policy_handle(ndr, "logHandle", r->in.logHandle);
4064 ndr->depth--;
4065 ndr_print_uint32(ndr, "propertyId", r->in.propertyId);
4066 ndr_print_uint32(ndr, "propertyValueBufferSize", r->in.propertyValueBufferSize);
4067 ndr->depth--;
4068 }
4069 if (flags & NDR_OUT) {
4070 ndr_print_struct(ndr, "out", "eventlog6_EvtRpcGetLogFileInfo");
4071 ndr->depth++;
4072 ndr_print_ptr(ndr, "propertyValueBuffer", r->out.propertyValueBuffer);
4073 ndr->depth++;
4074 ndr_print_array_uint8(ndr, "propertyValueBuffer", r->out.propertyValueBuffer, r->in.propertyValueBufferSize);
4075 ndr->depth--;
4076 ndr_print_ptr(ndr, "propertyValueBufferLength", r->out.propertyValueBufferLength);
4077 ndr->depth++;
4078 ndr_print_uint32(ndr, "propertyValueBufferLength", *r->out.propertyValueBufferLength);
4079 ndr->depth--;
4080 ndr_print_WERROR(ndr, "result", r->out.result);
4081 ndr->depth--;
4082 }
4083 ndr->depth--;
4084}
4085
4086static enum ndr_err_code ndr_push_eventlog6_EvtRpcGetChannelList(struct ndr_push *ndr, int flags, const struct eventlog6_EvtRpcGetChannelList *r)
4087{
4088 uint32_t cntr_channelPaths_2;
4089 if (flags & NDR_IN) {
4090 NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->in.flags));
4091 }
4092 if (flags & NDR_OUT) {
4093 if (r->out.numChannelPaths == NULL) {
4094 return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
4095 }
4096 NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, *r->out.numChannelPaths));
4097 if (r->out.channelPaths == NULL) {
4098 return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
4099 }
4100 NDR_CHECK(ndr_push_unique_ptr(ndr, *r->out.channelPaths));
4101 if (*r->out.channelPaths) {
4102 NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, *r->out.numChannelPaths));
4103 for (cntr_channelPaths_2 = 0; cntr_channelPaths_2 < *r->out.numChannelPaths; cntr_channelPaths_2++) {
4104 NDR_CHECK(ndr_push_unique_ptr(ndr, (*r->out.channelPaths)[cntr_channelPaths_2]));
4105 }
4106 for (cntr_channelPaths_2 = 0; cntr_channelPaths_2 < *r->out.numChannelPaths; cntr_channelPaths_2++) {
4107 if ((*r->out.channelPaths)[cntr_channelPaths_2]) {
4108 NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length((*r->out.channelPaths)[cntr_channelPaths_2], CH_UTF16)));
4109 NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, 0));
4110 NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length((*r->out.channelPaths)[cntr_channelPaths_2], CH_UTF16)));
4111 NDR_CHECK(ndr_push_charset(ndr, NDR_SCALARS, (*r->out.channelPaths)[cntr_channelPaths_2], ndr_charset_length((*r->out.channelPaths)[cntr_channelPaths_2], CH_UTF16), sizeof(uint16_t), CH_UTF16));
4112 }
4113 }
4114 }
4115 NDR_CHECK(ndr_push_WERROR(ndr, NDR_SCALARS, r->out.result));
4116 }
4117 return NDR_ERR_SUCCESS;
4118}
4119
4120static enum ndr_err_code ndr_pull_eventlog6_EvtRpcGetChannelList(struct ndr_pull *ndr, int flags, struct eventlog6_EvtRpcGetChannelList *r)
4121{
4122 uint32_t _ptr_channelPaths;
4123 uint32_t size_channelPaths_2 = 0;
4124 uint32_t cntr_channelPaths_2;
4125 uint32_t size_channelPaths_4 = 0;
4126 uint32_t length_channelPaths_4 = 0;
4127 TALLOC_CTX *_mem_save_numChannelPaths_0;
4128 TALLOC_CTX *_mem_save_channelPaths_0;
4129 TALLOC_CTX *_mem_save_channelPaths_1;
4130 TALLOC_CTX *_mem_save_channelPaths_2;
4131 TALLOC_CTX *_mem_save_channelPaths_3;
4132 if (flags & NDR_IN) {
4133 ZERO_STRUCT(r->out);
4134
4135 NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->in.flags));
4136 NDR_PULL_ALLOC(ndr, r->out.numChannelPaths);
4137 ZERO_STRUCTP(r->out.numChannelPaths);
4138 NDR_PULL_ALLOC(ndr, r->out.channelPaths);
4139 ZERO_STRUCTP(r->out.channelPaths);
4140 }
4141 if (flags & NDR_OUT) {
4142 if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
4143 NDR_PULL_ALLOC(ndr, r->out.numChannelPaths);
4144 }
4145 _mem_save_numChannelPaths_0 = NDR_PULL_GET_MEM_CTX(ndr);
4146 NDR_PULL_SET_MEM_CTX(ndr, r->out.numChannelPaths, LIBNDR_FLAG_REF_ALLOC);
4147 NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, r->out.numChannelPaths));
4148 NDR_PULL_SET_MEM_CTX(ndr, _mem_save_numChannelPaths_0, LIBNDR_FLAG_REF_ALLOC);
4149 if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
4150 NDR_PULL_ALLOC(ndr, r->out.channelPaths);
4151 }
4152 _mem_save_channelPaths_0 = NDR_PULL_GET_MEM_CTX(ndr);
4153 NDR_PULL_SET_MEM_CTX(ndr, r->out.channelPaths, LIBNDR_FLAG_REF_ALLOC);
4154 NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_channelPaths));
4155 if (_ptr_channelPaths) {
4156 NDR_PULL_ALLOC(ndr, *r->out.channelPaths);
4157 } else {
4158 *r->out.channelPaths = NULL;
4159 }
4160 if (*r->out.channelPaths) {
4161 _mem_save_channelPaths_1 = NDR_PULL_GET_MEM_CTX(ndr);
4162 NDR_PULL_SET_MEM_CTX(ndr, *r->out.channelPaths, 0);
4163 NDR_CHECK(ndr_pull_array_size(ndr, r->out.channelPaths));
4164 size_channelPaths_2 = ndr_get_array_size(ndr, r->out.channelPaths);
4165 if (size_channelPaths_2 > MAX_RPC_CHANNEL_COUNT) {
4166 return ndr_pull_error(ndr, NDR_ERR_RANGE, "value out of range");
4167 }
4168 NDR_PULL_ALLOC_N(ndr, *r->out.channelPaths, size_channelPaths_2);
4169 _mem_save_channelPaths_2 = NDR_PULL_GET_MEM_CTX(ndr);
4170 NDR_PULL_SET_MEM_CTX(ndr, *r->out.channelPaths, 0);
4171 for (cntr_channelPaths_2 = 0; cntr_channelPaths_2 < size_channelPaths_2; cntr_channelPaths_2++) {
4172 NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_channelPaths));
4173 if (_ptr_channelPaths) {
4174 NDR_PULL_ALLOC(ndr, (*r->out.channelPaths)[cntr_channelPaths_2]);
4175 } else {
4176 (*r->out.channelPaths)[cntr_channelPaths_2] = NULL;
4177 }
4178 }
4179 for (cntr_channelPaths_2 = 0; cntr_channelPaths_2 < size_channelPaths_2; cntr_channelPaths_2++) {
4180 if ((*r->out.channelPaths)[cntr_channelPaths_2]) {
4181 _mem_save_channelPaths_3 = NDR_PULL_GET_MEM_CTX(ndr);
4182 NDR_PULL_SET_MEM_CTX(ndr, (*r->out.channelPaths)[cntr_channelPaths_2], 0);
4183 NDR_CHECK(ndr_pull_array_size(ndr, &(*r->out.channelPaths)[cntr_channelPaths_2]));
4184 NDR_CHECK(ndr_pull_array_length(ndr, &(*r->out.channelPaths)[cntr_channelPaths_2]));
4185 size_channelPaths_4 = ndr_get_array_size(ndr, &(*r->out.channelPaths)[cntr_channelPaths_2]);
4186 if (size_channelPaths_4 > MAX_RPC_CHANNEL_COUNT) {
4187 return ndr_pull_error(ndr, NDR_ERR_RANGE, "value out of range");
4188 }
4189 length_channelPaths_4 = ndr_get_array_length(ndr, &(*r->out.channelPaths)[cntr_channelPaths_2]);
4190 if (length_channelPaths_4 > MAX_RPC_CHANNEL_COUNT) {
4191 return ndr_pull_error(ndr, NDR_ERR_RANGE, "value out of range");
4192 }
4193 if (length_channelPaths_4 > size_channelPaths_4) {
4194 return ndr_pull_error(ndr, NDR_ERR_ARRAY_SIZE, "Bad array size %u should exceed array length %u", size_channelPaths_4, length_channelPaths_4);
4195 }
4196 NDR_CHECK(ndr_check_string_terminator(ndr, length_channelPaths_4, sizeof(uint16_t)));
4197 NDR_CHECK(ndr_pull_charset(ndr, NDR_SCALARS, &(*r->out.channelPaths)[cntr_channelPaths_2], length_channelPaths_4, sizeof(uint16_t), CH_UTF16));
4198 NDR_PULL_SET_MEM_CTX(ndr, _mem_save_channelPaths_3, 0);
4199 }
4200 }
4201 NDR_PULL_SET_MEM_CTX(ndr, _mem_save_channelPaths_2, 0);
4202 NDR_PULL_SET_MEM_CTX(ndr, _mem_save_channelPaths_1, 0);
4203 }
4204 NDR_PULL_SET_MEM_CTX(ndr, _mem_save_channelPaths_0, LIBNDR_FLAG_REF_ALLOC);
4205 NDR_CHECK(ndr_pull_WERROR(ndr, NDR_SCALARS, &r->out.result));
4206 if (*r->out.channelPaths) {
4207 NDR_CHECK(ndr_check_array_size(ndr, (void*)r->out.channelPaths, *r->out.numChannelPaths));
4208 }
4209 }
4210 return NDR_ERR_SUCCESS;
4211}
4212
4213_PUBLIC_ void ndr_print_eventlog6_EvtRpcGetChannelList(struct ndr_print *ndr, const char *name, int flags, const struct eventlog6_EvtRpcGetChannelList *r)
4214{
4215 uint32_t cntr_channelPaths_2;
4216 ndr_print_struct(ndr, name, "eventlog6_EvtRpcGetChannelList");
4217 if (r == NULL) { ndr_print_null(ndr); return; }
4218 ndr->depth++;
4219 if (flags & NDR_SET_VALUES) {
4220 ndr->flags |= LIBNDR_PRINT_SET_VALUES;
4221 }
4222 if (flags & NDR_IN) {
4223 ndr_print_struct(ndr, "in", "eventlog6_EvtRpcGetChannelList");
4224 ndr->depth++;
4225 ndr_print_uint32(ndr, "flags", r->in.flags);
4226 ndr->depth--;
4227 }
4228 if (flags & NDR_OUT) {
4229 ndr_print_struct(ndr, "out", "eventlog6_EvtRpcGetChannelList");
4230 ndr->depth++;
4231 ndr_print_ptr(ndr, "numChannelPaths", r->out.numChannelPaths);
4232 ndr->depth++;
4233 ndr_print_uint32(ndr, "numChannelPaths", *r->out.numChannelPaths);
4234 ndr->depth--;
4235 ndr_print_ptr(ndr, "channelPaths", r->out.channelPaths);
4236 ndr->depth++;
4237 ndr_print_ptr(ndr, "channelPaths", *r->out.channelPaths);
4238 ndr->depth++;
4239 if (*r->out.channelPaths) {
4240 ndr->print(ndr, "%s: ARRAY(%d)", "channelPaths", (int)*r->out.numChannelPaths);
4241 ndr->depth++;
4242 for (cntr_channelPaths_2=0;cntr_channelPaths_2<*r->out.numChannelPaths;cntr_channelPaths_2++) {
4243 ndr_print_ptr(ndr, "channelPaths", (*r->out.channelPaths)[cntr_channelPaths_2]);
4244 ndr->depth++;
4245 if ((*r->out.channelPaths)[cntr_channelPaths_2]) {
4246 ndr_print_string(ndr, "channelPaths", (*r->out.channelPaths)[cntr_channelPaths_2]);
4247 }
4248 ndr->depth--;
4249 }
4250 ndr->depth--;
4251 }
4252 ndr->depth--;
4253 ndr->depth--;
4254 ndr_print_WERROR(ndr, "result", r->out.result);
4255 ndr->depth--;
4256 }
4257 ndr->depth--;
4258}
4259
4260static enum ndr_err_code ndr_push_eventlog6_EvtRpcGetChannelConfig(struct ndr_push *ndr, int flags, const struct eventlog6_EvtRpcGetChannelConfig *r)
4261{
4262 if (flags & NDR_IN) {
4263 if (r->in.channelPath == NULL) {
4264 return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
4265 }
4266 NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->in.channelPath, CH_UTF16)));
4267 NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, 0));
4268 NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->in.channelPath, CH_UTF16)));
4269 NDR_CHECK(ndr_push_charset(ndr, NDR_SCALARS, r->in.channelPath, ndr_charset_length(r->in.channelPath, CH_UTF16), sizeof(uint16_t), CH_UTF16));
4270 NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->in.flags));
4271 }
4272 if (flags & NDR_OUT) {
4273 if (r->out.props == NULL) {
4274 return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
4275 }
4276 NDR_CHECK(ndr_push_eventlog6_EvtRpcVariantList(ndr, NDR_SCALARS|NDR_BUFFERS, r->out.props));
4277 NDR_CHECK(ndr_push_WERROR(ndr, NDR_SCALARS, r->out.result));
4278 }
4279 return NDR_ERR_SUCCESS;
4280}
4281
4282static enum ndr_err_code ndr_pull_eventlog6_EvtRpcGetChannelConfig(struct ndr_pull *ndr, int flags, struct eventlog6_EvtRpcGetChannelConfig *r)
4283{
4284 uint32_t size_channelPath_1 = 0;
4285 uint32_t length_channelPath_1 = 0;
4286 TALLOC_CTX *_mem_save_props_0;
4287 if (flags & NDR_IN) {
4288 ZERO_STRUCT(r->out);
4289
4290 NDR_CHECK(ndr_pull_array_size(ndr, &r->in.channelPath));
4291 NDR_CHECK(ndr_pull_array_length(ndr, &r->in.channelPath));
4292 size_channelPath_1 = ndr_get_array_size(ndr, &r->in.channelPath);
4293 if (size_channelPath_1 < 1 || size_channelPath_1 > MAX_RPC_CHANNEL_NAME_LENGTH) {
4294 return ndr_pull_error(ndr, NDR_ERR_RANGE, "value out of range");
4295 }
4296 length_channelPath_1 = ndr_get_array_length(ndr, &r->in.channelPath);
4297 if (length_channelPath_1 < 1 || length_channelPath_1 > MAX_RPC_CHANNEL_NAME_LENGTH) {
4298 return ndr_pull_error(ndr, NDR_ERR_RANGE, "value out of range");
4299 }
4300 if (length_channelPath_1 > size_channelPath_1) {
4301 return ndr_pull_error(ndr, NDR_ERR_ARRAY_SIZE, "Bad array size %u should exceed array length %u", size_channelPath_1, length_channelPath_1);
4302 }
4303 NDR_CHECK(ndr_check_string_terminator(ndr, length_channelPath_1, sizeof(uint16_t)));
4304 NDR_CHECK(ndr_pull_charset(ndr, NDR_SCALARS, &r->in.channelPath, length_channelPath_1, sizeof(uint16_t), CH_UTF16));
4305 NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->in.flags));
4306 NDR_PULL_ALLOC(ndr, r->out.props);
4307 ZERO_STRUCTP(r->out.props);
4308 }
4309 if (flags & NDR_OUT) {
4310 if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
4311 NDR_PULL_ALLOC(ndr, r->out.props);
4312 }
4313 _mem_save_props_0 = NDR_PULL_GET_MEM_CTX(ndr);
4314 NDR_PULL_SET_MEM_CTX(ndr, r->out.props, LIBNDR_FLAG_REF_ALLOC);
4315 NDR_CHECK(ndr_pull_eventlog6_EvtRpcVariantList(ndr, NDR_SCALARS|NDR_BUFFERS, r->out.props));
4316 NDR_PULL_SET_MEM_CTX(ndr, _mem_save_props_0, LIBNDR_FLAG_REF_ALLOC);
4317 NDR_CHECK(ndr_pull_WERROR(ndr, NDR_SCALARS, &r->out.result));
4318 }
4319 return NDR_ERR_SUCCESS;
4320}
4321
4322_PUBLIC_ void ndr_print_eventlog6_EvtRpcGetChannelConfig(struct ndr_print *ndr, const char *name, int flags, const struct eventlog6_EvtRpcGetChannelConfig *r)
4323{
4324 ndr_print_struct(ndr, name, "eventlog6_EvtRpcGetChannelConfig");
4325 if (r == NULL) { ndr_print_null(ndr); return; }
4326 ndr->depth++;
4327 if (flags & NDR_SET_VALUES) {
4328 ndr->flags |= LIBNDR_PRINT_SET_VALUES;
4329 }
4330 if (flags & NDR_IN) {
4331 ndr_print_struct(ndr, "in", "eventlog6_EvtRpcGetChannelConfig");
4332 ndr->depth++;
4333 ndr_print_ptr(ndr, "channelPath", r->in.channelPath);
4334 ndr->depth++;
4335 ndr_print_string(ndr, "channelPath", r->in.channelPath);
4336 ndr->depth--;
4337 ndr_print_uint32(ndr, "flags", r->in.flags);
4338 ndr->depth--;
4339 }
4340 if (flags & NDR_OUT) {
4341 ndr_print_struct(ndr, "out", "eventlog6_EvtRpcGetChannelConfig");
4342 ndr->depth++;
4343 ndr_print_ptr(ndr, "props", r->out.props);
4344 ndr->depth++;
4345 ndr_print_eventlog6_EvtRpcVariantList(ndr, "props", r->out.props);
4346 ndr->depth--;
4347 ndr_print_WERROR(ndr, "result", r->out.result);
4348 ndr->depth--;
4349 }
4350 ndr->depth--;
4351}
4352
4353static enum ndr_err_code ndr_push_eventlog6_EvtRpcPutChannelConfig(struct ndr_push *ndr, int flags, const struct eventlog6_EvtRpcPutChannelConfig *r)
4354{
4355 if (flags & NDR_IN) {
4356 if (r->in.channelPath == NULL) {
4357 return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
4358 }
4359 NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->in.channelPath, CH_UTF16)));
4360 NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, 0));
4361 NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->in.channelPath, CH_UTF16)));
4362 NDR_CHECK(ndr_push_charset(ndr, NDR_SCALARS, r->in.channelPath, ndr_charset_length(r->in.channelPath, CH_UTF16), sizeof(uint16_t), CH_UTF16));
4363 NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->in.flags));
4364 if (r->in.props == NULL) {
4365 return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
4366 }
4367 NDR_CHECK(ndr_push_eventlog6_EvtRpcVariantList(ndr, NDR_SCALARS|NDR_BUFFERS, r->in.props));
4368 }
4369 if (flags & NDR_OUT) {
4370 if (r->out.error == NULL) {
4371 return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
4372 }
4373 NDR_CHECK(ndr_push_eventlog6_RpcInfo(ndr, NDR_SCALARS, r->out.error));
4374 NDR_CHECK(ndr_push_WERROR(ndr, NDR_SCALARS, r->out.result));
4375 }
4376 return NDR_ERR_SUCCESS;
4377}
4378
4379static enum ndr_err_code ndr_pull_eventlog6_EvtRpcPutChannelConfig(struct ndr_pull *ndr, int flags, struct eventlog6_EvtRpcPutChannelConfig *r)
4380{
4381 uint32_t size_channelPath_1 = 0;
4382 uint32_t length_channelPath_1 = 0;
4383 TALLOC_CTX *_mem_save_props_0;
4384 TALLOC_CTX *_mem_save_error_0;
4385 if (flags & NDR_IN) {
4386 ZERO_STRUCT(r->out);
4387
4388 NDR_CHECK(ndr_pull_array_size(ndr, &r->in.channelPath));
4389 NDR_CHECK(ndr_pull_array_length(ndr, &r->in.channelPath));
4390 size_channelPath_1 = ndr_get_array_size(ndr, &r->in.channelPath);
4391 if (size_channelPath_1 < 1 || size_channelPath_1 > MAX_RPC_CHANNEL_NAME_LENGTH) {
4392 return ndr_pull_error(ndr, NDR_ERR_RANGE, "value out of range");
4393 }
4394 length_channelPath_1 = ndr_get_array_length(ndr, &r->in.channelPath);
4395 if (length_channelPath_1 < 1 || length_channelPath_1 > MAX_RPC_CHANNEL_NAME_LENGTH) {
4396 return ndr_pull_error(ndr, NDR_ERR_RANGE, "value out of range");
4397 }
4398 if (length_channelPath_1 > size_channelPath_1) {
4399 return ndr_pull_error(ndr, NDR_ERR_ARRAY_SIZE, "Bad array size %u should exceed array length %u", size_channelPath_1, length_channelPath_1);
4400 }
4401 NDR_CHECK(ndr_check_string_terminator(ndr, length_channelPath_1, sizeof(uint16_t)));
4402 NDR_CHECK(ndr_pull_charset(ndr, NDR_SCALARS, &r->in.channelPath, length_channelPath_1, sizeof(uint16_t), CH_UTF16));
4403 NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->in.flags));
4404 if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
4405 NDR_PULL_ALLOC(ndr, r->in.props);
4406 }
4407 _mem_save_props_0 = NDR_PULL_GET_MEM_CTX(ndr);
4408 NDR_PULL_SET_MEM_CTX(ndr, r->in.props, LIBNDR_FLAG_REF_ALLOC);
4409 NDR_CHECK(ndr_pull_eventlog6_EvtRpcVariantList(ndr, NDR_SCALARS|NDR_BUFFERS, r->in.props));
4410 NDR_PULL_SET_MEM_CTX(ndr, _mem_save_props_0, LIBNDR_FLAG_REF_ALLOC);
4411 NDR_PULL_ALLOC(ndr, r->out.error);
4412 ZERO_STRUCTP(r->out.error);
4413 }
4414 if (flags & NDR_OUT) {
4415 if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
4416 NDR_PULL_ALLOC(ndr, r->out.error);
4417 }
4418 _mem_save_error_0 = NDR_PULL_GET_MEM_CTX(ndr);
4419 NDR_PULL_SET_MEM_CTX(ndr, r->out.error, LIBNDR_FLAG_REF_ALLOC);
4420 NDR_CHECK(ndr_pull_eventlog6_RpcInfo(ndr, NDR_SCALARS, r->out.error));
4421 NDR_PULL_SET_MEM_CTX(ndr, _mem_save_error_0, LIBNDR_FLAG_REF_ALLOC);
4422 NDR_CHECK(ndr_pull_WERROR(ndr, NDR_SCALARS, &r->out.result));
4423 }
4424 return NDR_ERR_SUCCESS;
4425}
4426
4427_PUBLIC_ void ndr_print_eventlog6_EvtRpcPutChannelConfig(struct ndr_print *ndr, const char *name, int flags, const struct eventlog6_EvtRpcPutChannelConfig *r)
4428{
4429 ndr_print_struct(ndr, name, "eventlog6_EvtRpcPutChannelConfig");
4430 if (r == NULL) { ndr_print_null(ndr); return; }
4431 ndr->depth++;
4432 if (flags & NDR_SET_VALUES) {
4433 ndr->flags |= LIBNDR_PRINT_SET_VALUES;
4434 }
4435 if (flags & NDR_IN) {
4436 ndr_print_struct(ndr, "in", "eventlog6_EvtRpcPutChannelConfig");
4437 ndr->depth++;
4438 ndr_print_ptr(ndr, "channelPath", r->in.channelPath);
4439 ndr->depth++;
4440 ndr_print_string(ndr, "channelPath", r->in.channelPath);
4441 ndr->depth--;
4442 ndr_print_uint32(ndr, "flags", r->in.flags);
4443 ndr_print_ptr(ndr, "props", r->in.props);
4444 ndr->depth++;
4445 ndr_print_eventlog6_EvtRpcVariantList(ndr, "props", r->in.props);
4446 ndr->depth--;
4447 ndr->depth--;
4448 }
4449 if (flags & NDR_OUT) {
4450 ndr_print_struct(ndr, "out", "eventlog6_EvtRpcPutChannelConfig");
4451 ndr->depth++;
4452 ndr_print_ptr(ndr, "error", r->out.error);
4453 ndr->depth++;
4454 ndr_print_eventlog6_RpcInfo(ndr, "error", r->out.error);
4455 ndr->depth--;
4456 ndr_print_WERROR(ndr, "result", r->out.result);
4457 ndr->depth--;
4458 }
4459 ndr->depth--;
4460}
4461
4462static enum ndr_err_code ndr_push_eventlog6_EvtRpcGetPublisherList(struct ndr_push *ndr, int flags, const struct eventlog6_EvtRpcGetPublisherList *r)
4463{
4464 uint32_t cntr_publisherIds_2;
4465 if (flags & NDR_IN) {
4466 NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->in.flags));
4467 }
4468 if (flags & NDR_OUT) {
4469 if (r->out.numPublisherIds == NULL) {
4470 return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
4471 }
4472 NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, *r->out.numPublisherIds));
4473 if (r->out.publisherIds == NULL) {
4474 return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
4475 }
4476 NDR_CHECK(ndr_push_unique_ptr(ndr, *r->out.publisherIds));
4477 if (*r->out.publisherIds) {
4478 NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, *r->out.numPublisherIds));
4479 for (cntr_publisherIds_2 = 0; cntr_publisherIds_2 < *r->out.numPublisherIds; cntr_publisherIds_2++) {
4480 NDR_CHECK(ndr_push_unique_ptr(ndr, (*r->out.publisherIds)[cntr_publisherIds_2]));
4481 }
4482 for (cntr_publisherIds_2 = 0; cntr_publisherIds_2 < *r->out.numPublisherIds; cntr_publisherIds_2++) {
4483 if ((*r->out.publisherIds)[cntr_publisherIds_2]) {
4484 NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length((*r->out.publisherIds)[cntr_publisherIds_2], CH_UTF16)));
4485 NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, 0));
4486 NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length((*r->out.publisherIds)[cntr_publisherIds_2], CH_UTF16)));
4487 NDR_CHECK(ndr_push_charset(ndr, NDR_SCALARS, (*r->out.publisherIds)[cntr_publisherIds_2], ndr_charset_length((*r->out.publisherIds)[cntr_publisherIds_2], CH_UTF16), sizeof(uint16_t), CH_UTF16));
4488 }
4489 }
4490 }
4491 NDR_CHECK(ndr_push_WERROR(ndr, NDR_SCALARS, r->out.result));
4492 }
4493 return NDR_ERR_SUCCESS;
4494}
4495
4496static enum ndr_err_code ndr_pull_eventlog6_EvtRpcGetPublisherList(struct ndr_pull *ndr, int flags, struct eventlog6_EvtRpcGetPublisherList *r)
4497{
4498 uint32_t _ptr_publisherIds;
4499 uint32_t size_publisherIds_2 = 0;
4500 uint32_t cntr_publisherIds_2;
4501 uint32_t size_publisherIds_4 = 0;
4502 uint32_t length_publisherIds_4 = 0;
4503 TALLOC_CTX *_mem_save_numPublisherIds_0;
4504 TALLOC_CTX *_mem_save_publisherIds_0;
4505 TALLOC_CTX *_mem_save_publisherIds_1;
4506 TALLOC_CTX *_mem_save_publisherIds_2;
4507 TALLOC_CTX *_mem_save_publisherIds_3;
4508 if (flags & NDR_IN) {
4509 ZERO_STRUCT(r->out);
4510
4511 NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->in.flags));
4512 NDR_PULL_ALLOC(ndr, r->out.numPublisherIds);
4513 ZERO_STRUCTP(r->out.numPublisherIds);
4514 NDR_PULL_ALLOC(ndr, r->out.publisherIds);
4515 ZERO_STRUCTP(r->out.publisherIds);
4516 }
4517 if (flags & NDR_OUT) {
4518 if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
4519 NDR_PULL_ALLOC(ndr, r->out.numPublisherIds);
4520 }
4521 _mem_save_numPublisherIds_0 = NDR_PULL_GET_MEM_CTX(ndr);
4522 NDR_PULL_SET_MEM_CTX(ndr, r->out.numPublisherIds, LIBNDR_FLAG_REF_ALLOC);
4523 NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, r->out.numPublisherIds));
4524 NDR_PULL_SET_MEM_CTX(ndr, _mem_save_numPublisherIds_0, LIBNDR_FLAG_REF_ALLOC);
4525 if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
4526 NDR_PULL_ALLOC(ndr, r->out.publisherIds);
4527 }
4528 _mem_save_publisherIds_0 = NDR_PULL_GET_MEM_CTX(ndr);
4529 NDR_PULL_SET_MEM_CTX(ndr, r->out.publisherIds, LIBNDR_FLAG_REF_ALLOC);
4530 NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_publisherIds));
4531 if (_ptr_publisherIds) {
4532 NDR_PULL_ALLOC(ndr, *r->out.publisherIds);
4533 } else {
4534 *r->out.publisherIds = NULL;
4535 }
4536 if (*r->out.publisherIds) {
4537 _mem_save_publisherIds_1 = NDR_PULL_GET_MEM_CTX(ndr);
4538 NDR_PULL_SET_MEM_CTX(ndr, *r->out.publisherIds, 0);
4539 NDR_CHECK(ndr_pull_array_size(ndr, r->out.publisherIds));
4540 size_publisherIds_2 = ndr_get_array_size(ndr, r->out.publisherIds);
4541 if (size_publisherIds_2 > MAX_RPC_PUBLISHER_COUNT) {
4542 return ndr_pull_error(ndr, NDR_ERR_RANGE, "value out of range");
4543 }
4544 NDR_PULL_ALLOC_N(ndr, *r->out.publisherIds, size_publisherIds_2);
4545 _mem_save_publisherIds_2 = NDR_PULL_GET_MEM_CTX(ndr);
4546 NDR_PULL_SET_MEM_CTX(ndr, *r->out.publisherIds, 0);
4547 for (cntr_publisherIds_2 = 0; cntr_publisherIds_2 < size_publisherIds_2; cntr_publisherIds_2++) {
4548 NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_publisherIds));
4549 if (_ptr_publisherIds) {
4550 NDR_PULL_ALLOC(ndr, (*r->out.publisherIds)[cntr_publisherIds_2]);
4551 } else {
4552 (*r->out.publisherIds)[cntr_publisherIds_2] = NULL;
4553 }
4554 }
4555 for (cntr_publisherIds_2 = 0; cntr_publisherIds_2 < size_publisherIds_2; cntr_publisherIds_2++) {
4556 if ((*r->out.publisherIds)[cntr_publisherIds_2]) {
4557 _mem_save_publisherIds_3 = NDR_PULL_GET_MEM_CTX(ndr);
4558 NDR_PULL_SET_MEM_CTX(ndr, (*r->out.publisherIds)[cntr_publisherIds_2], 0);
4559 NDR_CHECK(ndr_pull_array_size(ndr, &(*r->out.publisherIds)[cntr_publisherIds_2]));
4560 NDR_CHECK(ndr_pull_array_length(ndr, &(*r->out.publisherIds)[cntr_publisherIds_2]));
4561 size_publisherIds_4 = ndr_get_array_size(ndr, &(*r->out.publisherIds)[cntr_publisherIds_2]);
4562 if (size_publisherIds_4 > MAX_RPC_PUBLISHER_COUNT) {
4563 return ndr_pull_error(ndr, NDR_ERR_RANGE, "value out of range");
4564 }
4565 length_publisherIds_4 = ndr_get_array_length(ndr, &(*r->out.publisherIds)[cntr_publisherIds_2]);
4566 if (length_publisherIds_4 > MAX_RPC_PUBLISHER_COUNT) {
4567 return ndr_pull_error(ndr, NDR_ERR_RANGE, "value out of range");
4568 }
4569 if (length_publisherIds_4 > size_publisherIds_4) {
4570 return ndr_pull_error(ndr, NDR_ERR_ARRAY_SIZE, "Bad array size %u should exceed array length %u", size_publisherIds_4, length_publisherIds_4);
4571 }
4572 NDR_CHECK(ndr_check_string_terminator(ndr, length_publisherIds_4, sizeof(uint16_t)));
4573 NDR_CHECK(ndr_pull_charset(ndr, NDR_SCALARS, &(*r->out.publisherIds)[cntr_publisherIds_2], length_publisherIds_4, sizeof(uint16_t), CH_UTF16));
4574 NDR_PULL_SET_MEM_CTX(ndr, _mem_save_publisherIds_3, 0);
4575 }
4576 }
4577 NDR_PULL_SET_MEM_CTX(ndr, _mem_save_publisherIds_2, 0);
4578 NDR_PULL_SET_MEM_CTX(ndr, _mem_save_publisherIds_1, 0);
4579 }
4580 NDR_PULL_SET_MEM_CTX(ndr, _mem_save_publisherIds_0, LIBNDR_FLAG_REF_ALLOC);
4581 NDR_CHECK(ndr_pull_WERROR(ndr, NDR_SCALARS, &r->out.result));
4582 if (*r->out.publisherIds) {
4583 NDR_CHECK(ndr_check_array_size(ndr, (void*)r->out.publisherIds, *r->out.numPublisherIds));
4584 }
4585 }
4586 return NDR_ERR_SUCCESS;
4587}
4588
4589_PUBLIC_ void ndr_print_eventlog6_EvtRpcGetPublisherList(struct ndr_print *ndr, const char *name, int flags, const struct eventlog6_EvtRpcGetPublisherList *r)
4590{
4591 uint32_t cntr_publisherIds_2;
4592 ndr_print_struct(ndr, name, "eventlog6_EvtRpcGetPublisherList");
4593 if (r == NULL) { ndr_print_null(ndr); return; }
4594 ndr->depth++;
4595 if (flags & NDR_SET_VALUES) {
4596 ndr->flags |= LIBNDR_PRINT_SET_VALUES;
4597 }
4598 if (flags & NDR_IN) {
4599 ndr_print_struct(ndr, "in", "eventlog6_EvtRpcGetPublisherList");
4600 ndr->depth++;
4601 ndr_print_uint32(ndr, "flags", r->in.flags);
4602 ndr->depth--;
4603 }
4604 if (flags & NDR_OUT) {
4605 ndr_print_struct(ndr, "out", "eventlog6_EvtRpcGetPublisherList");
4606 ndr->depth++;
4607 ndr_print_ptr(ndr, "numPublisherIds", r->out.numPublisherIds);
4608 ndr->depth++;
4609 ndr_print_uint32(ndr, "numPublisherIds", *r->out.numPublisherIds);
4610 ndr->depth--;
4611 ndr_print_ptr(ndr, "publisherIds", r->out.publisherIds);
4612 ndr->depth++;
4613 ndr_print_ptr(ndr, "publisherIds", *r->out.publisherIds);
4614 ndr->depth++;
4615 if (*r->out.publisherIds) {
4616 ndr->print(ndr, "%s: ARRAY(%d)", "publisherIds", (int)*r->out.numPublisherIds);
4617 ndr->depth++;
4618 for (cntr_publisherIds_2=0;cntr_publisherIds_2<*r->out.numPublisherIds;cntr_publisherIds_2++) {
4619 ndr_print_ptr(ndr, "publisherIds", (*r->out.publisherIds)[cntr_publisherIds_2]);
4620 ndr->depth++;
4621 if ((*r->out.publisherIds)[cntr_publisherIds_2]) {
4622 ndr_print_string(ndr, "publisherIds", (*r->out.publisherIds)[cntr_publisherIds_2]);
4623 }
4624 ndr->depth--;
4625 }
4626 ndr->depth--;
4627 }
4628 ndr->depth--;
4629 ndr->depth--;
4630 ndr_print_WERROR(ndr, "result", r->out.result);
4631 ndr->depth--;
4632 }
4633 ndr->depth--;
4634}
4635
4636static enum ndr_err_code ndr_push_eventlog6_EvtRpcGetPublisherListForChannel(struct ndr_push *ndr, int flags, const struct eventlog6_EvtRpcGetPublisherListForChannel *r)
4637{
4638 uint32_t cntr_publisherIds_2;
4639 if (flags & NDR_IN) {
4640 if (r->in.channelName == NULL) {
4641 return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
4642 }
4643 NDR_CHECK(ndr_push_uint16(ndr, NDR_SCALARS, *r->in.channelName));
4644 NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->in.flags));
4645 }
4646 if (flags & NDR_OUT) {
4647 if (r->out.numPublisherIds == NULL) {
4648 return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
4649 }
4650 NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, *r->out.numPublisherIds));
4651 if (r->out.publisherIds == NULL) {
4652 return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
4653 }
4654 NDR_CHECK(ndr_push_unique_ptr(ndr, *r->out.publisherIds));
4655 if (*r->out.publisherIds) {
4656 NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, *r->out.numPublisherIds));
4657 for (cntr_publisherIds_2 = 0; cntr_publisherIds_2 < *r->out.numPublisherIds; cntr_publisherIds_2++) {
4658 NDR_CHECK(ndr_push_unique_ptr(ndr, (*r->out.publisherIds)[cntr_publisherIds_2]));
4659 }
4660 for (cntr_publisherIds_2 = 0; cntr_publisherIds_2 < *r->out.numPublisherIds; cntr_publisherIds_2++) {
4661 if ((*r->out.publisherIds)[cntr_publisherIds_2]) {
4662 NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length((*r->out.publisherIds)[cntr_publisherIds_2], CH_UTF16)));
4663 NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, 0));
4664 NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length((*r->out.publisherIds)[cntr_publisherIds_2], CH_UTF16)));
4665 NDR_CHECK(ndr_push_charset(ndr, NDR_SCALARS, (*r->out.publisherIds)[cntr_publisherIds_2], ndr_charset_length((*r->out.publisherIds)[cntr_publisherIds_2], CH_UTF16), sizeof(uint16_t), CH_UTF16));
4666 }
4667 }
4668 }
4669 NDR_CHECK(ndr_push_WERROR(ndr, NDR_SCALARS, r->out.result));
4670 }
4671 return NDR_ERR_SUCCESS;
4672}
4673
4674static enum ndr_err_code ndr_pull_eventlog6_EvtRpcGetPublisherListForChannel(struct ndr_pull *ndr, int flags, struct eventlog6_EvtRpcGetPublisherListForChannel *r)
4675{
4676 uint32_t _ptr_publisherIds;
4677 uint32_t size_publisherIds_2 = 0;
4678 uint32_t cntr_publisherIds_2;
4679 uint32_t size_publisherIds_4 = 0;
4680 uint32_t length_publisherIds_4 = 0;
4681 TALLOC_CTX *_mem_save_channelName_0;
4682 TALLOC_CTX *_mem_save_numPublisherIds_0;
4683 TALLOC_CTX *_mem_save_publisherIds_0;
4684 TALLOC_CTX *_mem_save_publisherIds_1;
4685 TALLOC_CTX *_mem_save_publisherIds_2;
4686 TALLOC_CTX *_mem_save_publisherIds_3;
4687 if (flags & NDR_IN) {
4688 ZERO_STRUCT(r->out);
4689
4690 if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
4691 NDR_PULL_ALLOC(ndr, r->in.channelName);
4692 }
4693 _mem_save_channelName_0 = NDR_PULL_GET_MEM_CTX(ndr);
4694 NDR_PULL_SET_MEM_CTX(ndr, r->in.channelName, LIBNDR_FLAG_REF_ALLOC);
4695 NDR_CHECK(ndr_pull_uint16(ndr, NDR_SCALARS, r->in.channelName));
4696 NDR_PULL_SET_MEM_CTX(ndr, _mem_save_channelName_0, LIBNDR_FLAG_REF_ALLOC);
4697 NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->in.flags));
4698 NDR_PULL_ALLOC(ndr, r->out.numPublisherIds);
4699 ZERO_STRUCTP(r->out.numPublisherIds);
4700 NDR_PULL_ALLOC(ndr, r->out.publisherIds);
4701 ZERO_STRUCTP(r->out.publisherIds);
4702 }
4703 if (flags & NDR_OUT) {
4704 if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
4705 NDR_PULL_ALLOC(ndr, r->out.numPublisherIds);
4706 }
4707 _mem_save_numPublisherIds_0 = NDR_PULL_GET_MEM_CTX(ndr);
4708 NDR_PULL_SET_MEM_CTX(ndr, r->out.numPublisherIds, LIBNDR_FLAG_REF_ALLOC);
4709 NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, r->out.numPublisherIds));
4710 NDR_PULL_SET_MEM_CTX(ndr, _mem_save_numPublisherIds_0, LIBNDR_FLAG_REF_ALLOC);
4711 if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
4712 NDR_PULL_ALLOC(ndr, r->out.publisherIds);
4713 }
4714 _mem_save_publisherIds_0 = NDR_PULL_GET_MEM_CTX(ndr);
4715 NDR_PULL_SET_MEM_CTX(ndr, r->out.publisherIds, LIBNDR_FLAG_REF_ALLOC);
4716 NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_publisherIds));
4717 if (_ptr_publisherIds) {
4718 NDR_PULL_ALLOC(ndr, *r->out.publisherIds);
4719 } else {
4720 *r->out.publisherIds = NULL;
4721 }
4722 if (*r->out.publisherIds) {
4723 _mem_save_publisherIds_1 = NDR_PULL_GET_MEM_CTX(ndr);
4724 NDR_PULL_SET_MEM_CTX(ndr, *r->out.publisherIds, 0);
4725 NDR_CHECK(ndr_pull_array_size(ndr, r->out.publisherIds));
4726 size_publisherIds_2 = ndr_get_array_size(ndr, r->out.publisherIds);
4727 if (size_publisherIds_2 > MAX_RPC_PUBLISHER_COUNT) {
4728 return ndr_pull_error(ndr, NDR_ERR_RANGE, "value out of range");
4729 }
4730 NDR_PULL_ALLOC_N(ndr, *r->out.publisherIds, size_publisherIds_2);
4731 _mem_save_publisherIds_2 = NDR_PULL_GET_MEM_CTX(ndr);
4732 NDR_PULL_SET_MEM_CTX(ndr, *r->out.publisherIds, 0);
4733 for (cntr_publisherIds_2 = 0; cntr_publisherIds_2 < size_publisherIds_2; cntr_publisherIds_2++) {
4734 NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_publisherIds));
4735 if (_ptr_publisherIds) {
4736 NDR_PULL_ALLOC(ndr, (*r->out.publisherIds)[cntr_publisherIds_2]);
4737 } else {
4738 (*r->out.publisherIds)[cntr_publisherIds_2] = NULL;
4739 }
4740 }
4741 for (cntr_publisherIds_2 = 0; cntr_publisherIds_2 < size_publisherIds_2; cntr_publisherIds_2++) {
4742 if ((*r->out.publisherIds)[cntr_publisherIds_2]) {
4743 _mem_save_publisherIds_3 = NDR_PULL_GET_MEM_CTX(ndr);
4744 NDR_PULL_SET_MEM_CTX(ndr, (*r->out.publisherIds)[cntr_publisherIds_2], 0);
4745 NDR_CHECK(ndr_pull_array_size(ndr, &(*r->out.publisherIds)[cntr_publisherIds_2]));
4746 NDR_CHECK(ndr_pull_array_length(ndr, &(*r->out.publisherIds)[cntr_publisherIds_2]));
4747 size_publisherIds_4 = ndr_get_array_size(ndr, &(*r->out.publisherIds)[cntr_publisherIds_2]);
4748 if (size_publisherIds_4 > MAX_RPC_PUBLISHER_COUNT) {
4749 return ndr_pull_error(ndr, NDR_ERR_RANGE, "value out of range");
4750 }
4751 length_publisherIds_4 = ndr_get_array_length(ndr, &(*r->out.publisherIds)[cntr_publisherIds_2]);
4752 if (length_publisherIds_4 > MAX_RPC_PUBLISHER_COUNT) {
4753 return ndr_pull_error(ndr, NDR_ERR_RANGE, "value out of range");
4754 }
4755 if (length_publisherIds_4 > size_publisherIds_4) {
4756 return ndr_pull_error(ndr, NDR_ERR_ARRAY_SIZE, "Bad array size %u should exceed array length %u", size_publisherIds_4, length_publisherIds_4);
4757 }
4758 NDR_CHECK(ndr_check_string_terminator(ndr, length_publisherIds_4, sizeof(uint16_t)));
4759 NDR_CHECK(ndr_pull_charset(ndr, NDR_SCALARS, &(*r->out.publisherIds)[cntr_publisherIds_2], length_publisherIds_4, sizeof(uint16_t), CH_UTF16));
4760 NDR_PULL_SET_MEM_CTX(ndr, _mem_save_publisherIds_3, 0);
4761 }
4762 }
4763 NDR_PULL_SET_MEM_CTX(ndr, _mem_save_publisherIds_2, 0);
4764 NDR_PULL_SET_MEM_CTX(ndr, _mem_save_publisherIds_1, 0);
4765 }
4766 NDR_PULL_SET_MEM_CTX(ndr, _mem_save_publisherIds_0, LIBNDR_FLAG_REF_ALLOC);
4767 NDR_CHECK(ndr_pull_WERROR(ndr, NDR_SCALARS, &r->out.result));
4768 if (*r->out.publisherIds) {
4769 NDR_CHECK(ndr_check_array_size(ndr, (void*)r->out.publisherIds, *r->out.numPublisherIds));
4770 }
4771 }
4772 return NDR_ERR_SUCCESS;
4773}
4774
4775_PUBLIC_ void ndr_print_eventlog6_EvtRpcGetPublisherListForChannel(struct ndr_print *ndr, const char *name, int flags, const struct eventlog6_EvtRpcGetPublisherListForChannel *r)
4776{
4777 uint32_t cntr_publisherIds_2;
4778 ndr_print_struct(ndr, name, "eventlog6_EvtRpcGetPublisherListForChannel");
4779 if (r == NULL) { ndr_print_null(ndr); return; }
4780 ndr->depth++;
4781 if (flags & NDR_SET_VALUES) {
4782 ndr->flags |= LIBNDR_PRINT_SET_VALUES;
4783 }
4784 if (flags & NDR_IN) {
4785 ndr_print_struct(ndr, "in", "eventlog6_EvtRpcGetPublisherListForChannel");
4786 ndr->depth++;
4787 ndr_print_ptr(ndr, "channelName", r->in.channelName);
4788 ndr->depth++;
4789 ndr_print_uint16(ndr, "channelName", *r->in.channelName);
4790 ndr->depth--;
4791 ndr_print_uint32(ndr, "flags", r->in.flags);
4792 ndr->depth--;
4793 }
4794 if (flags & NDR_OUT) {
4795 ndr_print_struct(ndr, "out", "eventlog6_EvtRpcGetPublisherListForChannel");
4796 ndr->depth++;
4797 ndr_print_ptr(ndr, "numPublisherIds", r->out.numPublisherIds);
4798 ndr->depth++;
4799 ndr_print_uint32(ndr, "numPublisherIds", *r->out.numPublisherIds);
4800 ndr->depth--;
4801 ndr_print_ptr(ndr, "publisherIds", r->out.publisherIds);
4802 ndr->depth++;
4803 ndr_print_ptr(ndr, "publisherIds", *r->out.publisherIds);
4804 ndr->depth++;
4805 if (*r->out.publisherIds) {
4806 ndr->print(ndr, "%s: ARRAY(%d)", "publisherIds", (int)*r->out.numPublisherIds);
4807 ndr->depth++;
4808 for (cntr_publisherIds_2=0;cntr_publisherIds_2<*r->out.numPublisherIds;cntr_publisherIds_2++) {
4809 ndr_print_ptr(ndr, "publisherIds", (*r->out.publisherIds)[cntr_publisherIds_2]);
4810 ndr->depth++;
4811 if ((*r->out.publisherIds)[cntr_publisherIds_2]) {
4812 ndr_print_string(ndr, "publisherIds", (*r->out.publisherIds)[cntr_publisherIds_2]);
4813 }
4814 ndr->depth--;
4815 }
4816 ndr->depth--;
4817 }
4818 ndr->depth--;
4819 ndr->depth--;
4820 ndr_print_WERROR(ndr, "result", r->out.result);
4821 ndr->depth--;
4822 }
4823 ndr->depth--;
4824}
4825
4826static enum ndr_err_code ndr_push_eventlog6_EvtRpcGetPublisherMetadata(struct ndr_push *ndr, int flags, const struct eventlog6_EvtRpcGetPublisherMetadata *r)
4827{
4828 if (flags & NDR_IN) {
4829 NDR_CHECK(ndr_push_unique_ptr(ndr, r->in.publisherId));
4830 if (r->in.publisherId) {
4831 NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->in.publisherId, CH_UTF16)));
4832 NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, 0));
4833 NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->in.publisherId, CH_UTF16)));
4834 NDR_CHECK(ndr_push_charset(ndr, NDR_SCALARS, r->in.publisherId, ndr_charset_length(r->in.publisherId, CH_UTF16), sizeof(uint16_t), CH_UTF16));
4835 }
4836 NDR_CHECK(ndr_push_unique_ptr(ndr, r->in.logFilePath));
4837 if (r->in.logFilePath) {
4838 NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->in.logFilePath, CH_UTF16)));
4839 NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, 0));
4840 NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->in.logFilePath, CH_UTF16)));
4841 NDR_CHECK(ndr_push_charset(ndr, NDR_SCALARS, r->in.logFilePath, ndr_charset_length(r->in.logFilePath, CH_UTF16), sizeof(uint16_t), CH_UTF16));
4842 }
4843 NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->in.locale));
4844 NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->in.flags));
4845 }
4846 if (flags & NDR_OUT) {
4847 if (r->out.pubMetadataProps == NULL) {
4848 return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
4849 }
4850 NDR_CHECK(ndr_push_eventlog6_EvtRpcVariantList(ndr, NDR_SCALARS|NDR_BUFFERS, r->out.pubMetadataProps));
4851 if (r->out.pubMetadata == NULL) {
4852 return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
4853 }
4854 NDR_CHECK(ndr_push_policy_handle(ndr, NDR_SCALARS, r->out.pubMetadata));
4855 NDR_CHECK(ndr_push_WERROR(ndr, NDR_SCALARS, r->out.result));
4856 }
4857 return NDR_ERR_SUCCESS;
4858}
4859
4860static enum ndr_err_code ndr_pull_eventlog6_EvtRpcGetPublisherMetadata(struct ndr_pull *ndr, int flags, struct eventlog6_EvtRpcGetPublisherMetadata *r)
4861{
4862 uint32_t _ptr_publisherId;
4863 uint32_t size_publisherId_1 = 0;
4864 uint32_t length_publisherId_1 = 0;
4865 uint32_t _ptr_logFilePath;
4866 uint32_t size_logFilePath_1 = 0;
4867 uint32_t length_logFilePath_1 = 0;
4868 TALLOC_CTX *_mem_save_publisherId_0;
4869 TALLOC_CTX *_mem_save_logFilePath_0;
4870 TALLOC_CTX *_mem_save_pubMetadataProps_0;
4871 TALLOC_CTX *_mem_save_pubMetadata_0;
4872 if (flags & NDR_IN) {
4873 ZERO_STRUCT(r->out);
4874
4875 NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_publisherId));
4876 if (_ptr_publisherId) {
4877 NDR_PULL_ALLOC(ndr, r->in.publisherId);
4878 } else {
4879 r->in.publisherId = NULL;
4880 }
4881 if (r->in.publisherId) {
4882 _mem_save_publisherId_0 = NDR_PULL_GET_MEM_CTX(ndr);
4883 NDR_PULL_SET_MEM_CTX(ndr, r->in.publisherId, 0);
4884 NDR_CHECK(ndr_pull_array_size(ndr, &r->in.publisherId));
4885 NDR_CHECK(ndr_pull_array_length(ndr, &r->in.publisherId));
4886 size_publisherId_1 = ndr_get_array_size(ndr, &r->in.publisherId);
4887 if (size_publisherId_1 > MAX_RPC_PUBLISHER_ID_LENGTH) {
4888 return ndr_pull_error(ndr, NDR_ERR_RANGE, "value out of range");
4889 }
4890 length_publisherId_1 = ndr_get_array_length(ndr, &r->in.publisherId);
4891 if (length_publisherId_1 > MAX_RPC_PUBLISHER_ID_LENGTH) {
4892 return ndr_pull_error(ndr, NDR_ERR_RANGE, "value out of range");
4893 }
4894 if (length_publisherId_1 > size_publisherId_1) {
4895 return ndr_pull_error(ndr, NDR_ERR_ARRAY_SIZE, "Bad array size %u should exceed array length %u", size_publisherId_1, length_publisherId_1);
4896 }
4897 NDR_CHECK(ndr_check_string_terminator(ndr, length_publisherId_1, sizeof(uint16_t)));
4898 NDR_CHECK(ndr_pull_charset(ndr, NDR_SCALARS, &r->in.publisherId, length_publisherId_1, sizeof(uint16_t), CH_UTF16));
4899 NDR_PULL_SET_MEM_CTX(ndr, _mem_save_publisherId_0, 0);
4900 }
4901 NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_logFilePath));
4902 if (_ptr_logFilePath) {
4903 NDR_PULL_ALLOC(ndr, r->in.logFilePath);
4904 } else {
4905 r->in.logFilePath = NULL;
4906 }
4907 if (r->in.logFilePath) {
4908 _mem_save_logFilePath_0 = NDR_PULL_GET_MEM_CTX(ndr);
4909 NDR_PULL_SET_MEM_CTX(ndr, r->in.logFilePath, 0);
4910 NDR_CHECK(ndr_pull_array_size(ndr, &r->in.logFilePath));
4911 NDR_CHECK(ndr_pull_array_length(ndr, &r->in.logFilePath));
4912 size_logFilePath_1 = ndr_get_array_size(ndr, &r->in.logFilePath);
4913 if (size_logFilePath_1 > MAX_RPC_FILE_PATH_LENGTH) {
4914 return ndr_pull_error(ndr, NDR_ERR_RANGE, "value out of range");
4915 }
4916 length_logFilePath_1 = ndr_get_array_length(ndr, &r->in.logFilePath);
4917 if (length_logFilePath_1 > MAX_RPC_FILE_PATH_LENGTH) {
4918 return ndr_pull_error(ndr, NDR_ERR_RANGE, "value out of range");
4919 }
4920 if (length_logFilePath_1 > size_logFilePath_1) {
4921 return ndr_pull_error(ndr, NDR_ERR_ARRAY_SIZE, "Bad array size %u should exceed array length %u", size_logFilePath_1, length_logFilePath_1);
4922 }
4923 NDR_CHECK(ndr_check_string_terminator(ndr, length_logFilePath_1, sizeof(uint16_t)));
4924 NDR_CHECK(ndr_pull_charset(ndr, NDR_SCALARS, &r->in.logFilePath, length_logFilePath_1, sizeof(uint16_t), CH_UTF16));
4925 NDR_PULL_SET_MEM_CTX(ndr, _mem_save_logFilePath_0, 0);
4926 }
4927 NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->in.locale));
4928 NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->in.flags));
4929 NDR_PULL_ALLOC(ndr, r->out.pubMetadataProps);
4930 ZERO_STRUCTP(r->out.pubMetadataProps);
4931 NDR_PULL_ALLOC(ndr, r->out.pubMetadata);
4932 ZERO_STRUCTP(r->out.pubMetadata);
4933 }
4934 if (flags & NDR_OUT) {
4935 if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
4936 NDR_PULL_ALLOC(ndr, r->out.pubMetadataProps);
4937 }
4938 _mem_save_pubMetadataProps_0 = NDR_PULL_GET_MEM_CTX(ndr);
4939 NDR_PULL_SET_MEM_CTX(ndr, r->out.pubMetadataProps, LIBNDR_FLAG_REF_ALLOC);
4940 NDR_CHECK(ndr_pull_eventlog6_EvtRpcVariantList(ndr, NDR_SCALARS|NDR_BUFFERS, r->out.pubMetadataProps));
4941 NDR_PULL_SET_MEM_CTX(ndr, _mem_save_pubMetadataProps_0, LIBNDR_FLAG_REF_ALLOC);
4942 if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
4943 NDR_PULL_ALLOC(ndr, r->out.pubMetadata);
4944 }
4945 _mem_save_pubMetadata_0 = NDR_PULL_GET_MEM_CTX(ndr);
4946 NDR_PULL_SET_MEM_CTX(ndr, r->out.pubMetadata, LIBNDR_FLAG_REF_ALLOC);
4947 NDR_CHECK(ndr_pull_policy_handle(ndr, NDR_SCALARS, r->out.pubMetadata));
4948 NDR_PULL_SET_MEM_CTX(ndr, _mem_save_pubMetadata_0, LIBNDR_FLAG_REF_ALLOC);
4949 NDR_CHECK(ndr_pull_WERROR(ndr, NDR_SCALARS, &r->out.result));
4950 }
4951 return NDR_ERR_SUCCESS;
4952}
4953
4954_PUBLIC_ void ndr_print_eventlog6_EvtRpcGetPublisherMetadata(struct ndr_print *ndr, const char *name, int flags, const struct eventlog6_EvtRpcGetPublisherMetadata *r)
4955{
4956 ndr_print_struct(ndr, name, "eventlog6_EvtRpcGetPublisherMetadata");
4957 if (r == NULL) { ndr_print_null(ndr); return; }
4958 ndr->depth++;
4959 if (flags & NDR_SET_VALUES) {
4960 ndr->flags |= LIBNDR_PRINT_SET_VALUES;
4961 }
4962 if (flags & NDR_IN) {
4963 ndr_print_struct(ndr, "in", "eventlog6_EvtRpcGetPublisherMetadata");
4964 ndr->depth++;
4965 ndr_print_ptr(ndr, "publisherId", r->in.publisherId);
4966 ndr->depth++;
4967 if (r->in.publisherId) {
4968 ndr_print_string(ndr, "publisherId", r->in.publisherId);
4969 }
4970 ndr->depth--;
4971 ndr_print_ptr(ndr, "logFilePath", r->in.logFilePath);
4972 ndr->depth++;
4973 if (r->in.logFilePath) {
4974 ndr_print_string(ndr, "logFilePath", r->in.logFilePath);
4975 }
4976 ndr->depth--;
4977 ndr_print_uint32(ndr, "locale", r->in.locale);
4978 ndr_print_uint32(ndr, "flags", r->in.flags);
4979 ndr->depth--;
4980 }
4981 if (flags & NDR_OUT) {
4982 ndr_print_struct(ndr, "out", "eventlog6_EvtRpcGetPublisherMetadata");
4983 ndr->depth++;
4984 ndr_print_ptr(ndr, "pubMetadataProps", r->out.pubMetadataProps);
4985 ndr->depth++;
4986 ndr_print_eventlog6_EvtRpcVariantList(ndr, "pubMetadataProps", r->out.pubMetadataProps);
4987 ndr->depth--;
4988 ndr_print_ptr(ndr, "pubMetadata", r->out.pubMetadata);
4989 ndr->depth++;
4990 ndr_print_policy_handle(ndr, "pubMetadata", r->out.pubMetadata);
4991 ndr->depth--;
4992 ndr_print_WERROR(ndr, "result", r->out.result);
4993 ndr->depth--;
4994 }
4995 ndr->depth--;
4996}
4997
4998static enum ndr_err_code ndr_push_eventlog6_EvtRpcGetPublisherResourceMetadata(struct ndr_push *ndr, int flags, const struct eventlog6_EvtRpcGetPublisherResourceMetadata *r)
4999{
5000 if (flags & NDR_IN) {
5001 if (r->in.handle == NULL) {
5002 return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
5003 }
5004 NDR_CHECK(ndr_push_policy_handle(ndr, NDR_SCALARS, r->in.handle));
5005 NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->in.propertyId));
5006 NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->in.flags));
5007 }
5008 if (flags & NDR_OUT) {
5009 if (r->out.pubMetadataProps == NULL) {
5010 return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
5011 }
5012 NDR_CHECK(ndr_push_eventlog6_EvtRpcVariantList(ndr, NDR_SCALARS|NDR_BUFFERS, r->out.pubMetadataProps));
5013 NDR_CHECK(ndr_push_WERROR(ndr, NDR_SCALARS, r->out.result));
5014 }
5015 return NDR_ERR_SUCCESS;
5016}
5017
5018static enum ndr_err_code ndr_pull_eventlog6_EvtRpcGetPublisherResourceMetadata(struct ndr_pull *ndr, int flags, struct eventlog6_EvtRpcGetPublisherResourceMetadata *r)
5019{
5020 TALLOC_CTX *_mem_save_handle_0;
5021 TALLOC_CTX *_mem_save_pubMetadataProps_0;
5022 if (flags & NDR_IN) {
5023 ZERO_STRUCT(r->out);
5024
5025 if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
5026 NDR_PULL_ALLOC(ndr, r->in.handle);
5027 }
5028 _mem_save_handle_0 = NDR_PULL_GET_MEM_CTX(ndr);
5029 NDR_PULL_SET_MEM_CTX(ndr, r->in.handle, LIBNDR_FLAG_REF_ALLOC);
5030 NDR_CHECK(ndr_pull_policy_handle(ndr, NDR_SCALARS, r->in.handle));
5031 NDR_PULL_SET_MEM_CTX(ndr, _mem_save_handle_0, LIBNDR_FLAG_REF_ALLOC);
5032 NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->in.propertyId));
5033 NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->in.flags));
5034 NDR_PULL_ALLOC(ndr, r->out.pubMetadataProps);
5035 ZERO_STRUCTP(r->out.pubMetadataProps);
5036 }
5037 if (flags & NDR_OUT) {
5038 if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
5039 NDR_PULL_ALLOC(ndr, r->out.pubMetadataProps);
5040 }
5041 _mem_save_pubMetadataProps_0 = NDR_PULL_GET_MEM_CTX(ndr);
5042 NDR_PULL_SET_MEM_CTX(ndr, r->out.pubMetadataProps, LIBNDR_FLAG_REF_ALLOC);
5043 NDR_CHECK(ndr_pull_eventlog6_EvtRpcVariantList(ndr, NDR_SCALARS|NDR_BUFFERS, r->out.pubMetadataProps));
5044 NDR_PULL_SET_MEM_CTX(ndr, _mem_save_pubMetadataProps_0, LIBNDR_FLAG_REF_ALLOC);
5045 NDR_CHECK(ndr_pull_WERROR(ndr, NDR_SCALARS, &r->out.result));
5046 }
5047 return NDR_ERR_SUCCESS;
5048}
5049
5050_PUBLIC_ void ndr_print_eventlog6_EvtRpcGetPublisherResourceMetadata(struct ndr_print *ndr, const char *name, int flags, const struct eventlog6_EvtRpcGetPublisherResourceMetadata *r)
5051{
5052 ndr_print_struct(ndr, name, "eventlog6_EvtRpcGetPublisherResourceMetadata");
5053 if (r == NULL) { ndr_print_null(ndr); return; }
5054 ndr->depth++;
5055 if (flags & NDR_SET_VALUES) {
5056 ndr->flags |= LIBNDR_PRINT_SET_VALUES;
5057 }
5058 if (flags & NDR_IN) {
5059 ndr_print_struct(ndr, "in", "eventlog6_EvtRpcGetPublisherResourceMetadata");
5060 ndr->depth++;
5061 ndr_print_ptr(ndr, "handle", r->in.handle);
5062 ndr->depth++;
5063 ndr_print_policy_handle(ndr, "handle", r->in.handle);
5064 ndr->depth--;
5065 ndr_print_uint32(ndr, "propertyId", r->in.propertyId);
5066 ndr_print_uint32(ndr, "flags", r->in.flags);
5067 ndr->depth--;
5068 }
5069 if (flags & NDR_OUT) {
5070 ndr_print_struct(ndr, "out", "eventlog6_EvtRpcGetPublisherResourceMetadata");
5071 ndr->depth++;
5072 ndr_print_ptr(ndr, "pubMetadataProps", r->out.pubMetadataProps);
5073 ndr->depth++;
5074 ndr_print_eventlog6_EvtRpcVariantList(ndr, "pubMetadataProps", r->out.pubMetadataProps);
5075 ndr->depth--;
5076 ndr_print_WERROR(ndr, "result", r->out.result);
5077 ndr->depth--;
5078 }
5079 ndr->depth--;
5080}
5081
5082static enum ndr_err_code ndr_push_eventlog6_EvtRpcGetEventMetadataEnum(struct ndr_push *ndr, int flags, const struct eventlog6_EvtRpcGetEventMetadataEnum *r)
5083{
5084 if (flags & NDR_IN) {
5085 if (r->in.pubMetadata == NULL) {
5086 return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
5087 }
5088 NDR_CHECK(ndr_push_policy_handle(ndr, NDR_SCALARS, r->in.pubMetadata));
5089 NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->in.flags));
5090 NDR_CHECK(ndr_push_unique_ptr(ndr, r->in.reservedForFilter));
5091 if (r->in.reservedForFilter) {
5092 NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->in.reservedForFilter, CH_UTF16)));
5093 NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, 0));
5094 NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->in.reservedForFilter, CH_UTF16)));
5095 NDR_CHECK(ndr_push_charset(ndr, NDR_SCALARS, r->in.reservedForFilter, ndr_charset_length(r->in.reservedForFilter, CH_UTF16), sizeof(uint16_t), CH_UTF16));
5096 }
5097 }
5098 if (flags & NDR_OUT) {
5099 if (r->out.eventMetaDataEnum == NULL) {
5100 return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
5101 }
5102 NDR_CHECK(ndr_push_policy_handle(ndr, NDR_SCALARS, r->out.eventMetaDataEnum));
5103 NDR_CHECK(ndr_push_WERROR(ndr, NDR_SCALARS, r->out.result));
5104 }
5105 return NDR_ERR_SUCCESS;
5106}
5107
5108static enum ndr_err_code ndr_pull_eventlog6_EvtRpcGetEventMetadataEnum(struct ndr_pull *ndr, int flags, struct eventlog6_EvtRpcGetEventMetadataEnum *r)
5109{
5110 uint32_t _ptr_reservedForFilter;
5111 uint32_t size_reservedForFilter_1 = 0;
5112 uint32_t length_reservedForFilter_1 = 0;
5113 TALLOC_CTX *_mem_save_pubMetadata_0;
5114 TALLOC_CTX *_mem_save_reservedForFilter_0;
5115 TALLOC_CTX *_mem_save_eventMetaDataEnum_0;
5116 if (flags & NDR_IN) {
5117 ZERO_STRUCT(r->out);
5118
5119 if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
5120 NDR_PULL_ALLOC(ndr, r->in.pubMetadata);
5121 }
5122 _mem_save_pubMetadata_0 = NDR_PULL_GET_MEM_CTX(ndr);
5123 NDR_PULL_SET_MEM_CTX(ndr, r->in.pubMetadata, LIBNDR_FLAG_REF_ALLOC);
5124 NDR_CHECK(ndr_pull_policy_handle(ndr, NDR_SCALARS, r->in.pubMetadata));
5125 NDR_PULL_SET_MEM_CTX(ndr, _mem_save_pubMetadata_0, LIBNDR_FLAG_REF_ALLOC);
5126 NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->in.flags));
5127 NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_reservedForFilter));
5128 if (_ptr_reservedForFilter) {
5129 NDR_PULL_ALLOC(ndr, r->in.reservedForFilter);
5130 } else {
5131 r->in.reservedForFilter = NULL;
5132 }
5133 if (r->in.reservedForFilter) {
5134 _mem_save_reservedForFilter_0 = NDR_PULL_GET_MEM_CTX(ndr);
5135 NDR_PULL_SET_MEM_CTX(ndr, r->in.reservedForFilter, 0);
5136 NDR_CHECK(ndr_pull_array_size(ndr, &r->in.reservedForFilter));
5137 NDR_CHECK(ndr_pull_array_length(ndr, &r->in.reservedForFilter));
5138 size_reservedForFilter_1 = ndr_get_array_size(ndr, &r->in.reservedForFilter);
5139 if (size_reservedForFilter_1 > MAX_RPC_FILTER_LENGTH) {
5140 return ndr_pull_error(ndr, NDR_ERR_RANGE, "value out of range");
5141 }
5142 length_reservedForFilter_1 = ndr_get_array_length(ndr, &r->in.reservedForFilter);
5143 if (length_reservedForFilter_1 > MAX_RPC_FILTER_LENGTH) {
5144 return ndr_pull_error(ndr, NDR_ERR_RANGE, "value out of range");
5145 }
5146 if (length_reservedForFilter_1 > size_reservedForFilter_1) {
5147 return ndr_pull_error(ndr, NDR_ERR_ARRAY_SIZE, "Bad array size %u should exceed array length %u", size_reservedForFilter_1, length_reservedForFilter_1);
5148 }
5149 NDR_CHECK(ndr_check_string_terminator(ndr, length_reservedForFilter_1, sizeof(uint16_t)));
5150 NDR_CHECK(ndr_pull_charset(ndr, NDR_SCALARS, &r->in.reservedForFilter, length_reservedForFilter_1, sizeof(uint16_t), CH_UTF16));
5151 NDR_PULL_SET_MEM_CTX(ndr, _mem_save_reservedForFilter_0, 0);
5152 }
5153 NDR_PULL_ALLOC(ndr, r->out.eventMetaDataEnum);
5154 ZERO_STRUCTP(r->out.eventMetaDataEnum);
5155 }
5156 if (flags & NDR_OUT) {
5157 if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
5158 NDR_PULL_ALLOC(ndr, r->out.eventMetaDataEnum);
5159 }
5160 _mem_save_eventMetaDataEnum_0 = NDR_PULL_GET_MEM_CTX(ndr);
5161 NDR_PULL_SET_MEM_CTX(ndr, r->out.eventMetaDataEnum, LIBNDR_FLAG_REF_ALLOC);
5162 NDR_CHECK(ndr_pull_policy_handle(ndr, NDR_SCALARS, r->out.eventMetaDataEnum));
5163 NDR_PULL_SET_MEM_CTX(ndr, _mem_save_eventMetaDataEnum_0, LIBNDR_FLAG_REF_ALLOC);
5164 NDR_CHECK(ndr_pull_WERROR(ndr, NDR_SCALARS, &r->out.result));
5165 }
5166 return NDR_ERR_SUCCESS;
5167}
5168
5169_PUBLIC_ void ndr_print_eventlog6_EvtRpcGetEventMetadataEnum(struct ndr_print *ndr, const char *name, int flags, const struct eventlog6_EvtRpcGetEventMetadataEnum *r)
5170{
5171 ndr_print_struct(ndr, name, "eventlog6_EvtRpcGetEventMetadataEnum");
5172 if (r == NULL) { ndr_print_null(ndr); return; }
5173 ndr->depth++;
5174 if (flags & NDR_SET_VALUES) {
5175 ndr->flags |= LIBNDR_PRINT_SET_VALUES;
5176 }
5177 if (flags & NDR_IN) {
5178 ndr_print_struct(ndr, "in", "eventlog6_EvtRpcGetEventMetadataEnum");
5179 ndr->depth++;
5180 ndr_print_ptr(ndr, "pubMetadata", r->in.pubMetadata);
5181 ndr->depth++;
5182 ndr_print_policy_handle(ndr, "pubMetadata", r->in.pubMetadata);
5183 ndr->depth--;
5184 ndr_print_uint32(ndr, "flags", r->in.flags);
5185 ndr_print_ptr(ndr, "reservedForFilter", r->in.reservedForFilter);
5186 ndr->depth++;
5187 if (r->in.reservedForFilter) {
5188 ndr_print_string(ndr, "reservedForFilter", r->in.reservedForFilter);
5189 }
5190 ndr->depth--;
5191 ndr->depth--;
5192 }
5193 if (flags & NDR_OUT) {
5194 ndr_print_struct(ndr, "out", "eventlog6_EvtRpcGetEventMetadataEnum");
5195 ndr->depth++;
5196 ndr_print_ptr(ndr, "eventMetaDataEnum", r->out.eventMetaDataEnum);
5197 ndr->depth++;
5198 ndr_print_policy_handle(ndr, "eventMetaDataEnum", r->out.eventMetaDataEnum);
5199 ndr->depth--;
5200 ndr_print_WERROR(ndr, "result", r->out.result);
5201 ndr->depth--;
5202 }
5203 ndr->depth--;
5204}
5205
5206static enum ndr_err_code ndr_push_eventlog6_EvtRpcGetNextEventMetadata(struct ndr_push *ndr, int flags, const struct eventlog6_EvtRpcGetNextEventMetadata *r)
5207{
5208 uint32_t cntr_eventMetadataInstances_2;
5209 if (flags & NDR_IN) {
5210 if (r->in.eventMetaDataEnum == NULL) {
5211 return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
5212 }
5213 NDR_CHECK(ndr_push_policy_handle(ndr, NDR_SCALARS, r->in.eventMetaDataEnum));
5214 NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->in.flags));
5215 NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->in.numRequested));
5216 }
5217 if (flags & NDR_OUT) {
5218 if (r->out.numReturned == NULL) {
5219 return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
5220 }
5221 NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, *r->out.numReturned));
5222 if (r->out.eventMetadataInstances == NULL) {
5223 return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
5224 }
5225 NDR_CHECK(ndr_push_unique_ptr(ndr, *r->out.eventMetadataInstances));
5226 if (*r->out.eventMetadataInstances) {
5227 NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, *r->out.numReturned));
5228 for (cntr_eventMetadataInstances_2 = 0; cntr_eventMetadataInstances_2 < *r->out.numReturned; cntr_eventMetadataInstances_2++) {
5229 NDR_CHECK(ndr_push_eventlog6_EvtRpcVariantList(ndr, NDR_SCALARS, &(*r->out.eventMetadataInstances)[cntr_eventMetadataInstances_2]));
5230 }
5231 for (cntr_eventMetadataInstances_2 = 0; cntr_eventMetadataInstances_2 < *r->out.numReturned; cntr_eventMetadataInstances_2++) {
5232 NDR_CHECK(ndr_push_eventlog6_EvtRpcVariantList(ndr, NDR_BUFFERS, &(*r->out.eventMetadataInstances)[cntr_eventMetadataInstances_2]));
5233 }
5234 }
5235 NDR_CHECK(ndr_push_WERROR(ndr, NDR_SCALARS, r->out.result));
5236 }
5237 return NDR_ERR_SUCCESS;
5238}
5239
5240static enum ndr_err_code ndr_pull_eventlog6_EvtRpcGetNextEventMetadata(struct ndr_pull *ndr, int flags, struct eventlog6_EvtRpcGetNextEventMetadata *r)
5241{
5242 uint32_t _ptr_eventMetadataInstances;
5243 uint32_t size_eventMetadataInstances_2 = 0;
5244 uint32_t cntr_eventMetadataInstances_2;
5245 TALLOC_CTX *_mem_save_eventMetaDataEnum_0;
5246 TALLOC_CTX *_mem_save_numReturned_0;
5247 TALLOC_CTX *_mem_save_eventMetadataInstances_0;
5248 TALLOC_CTX *_mem_save_eventMetadataInstances_1;
5249 TALLOC_CTX *_mem_save_eventMetadataInstances_2;
5250 if (flags & NDR_IN) {
5251 ZERO_STRUCT(r->out);
5252
5253 if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
5254 NDR_PULL_ALLOC(ndr, r->in.eventMetaDataEnum);
5255 }
5256 _mem_save_eventMetaDataEnum_0 = NDR_PULL_GET_MEM_CTX(ndr);
5257 NDR_PULL_SET_MEM_CTX(ndr, r->in.eventMetaDataEnum, LIBNDR_FLAG_REF_ALLOC);
5258 NDR_CHECK(ndr_pull_policy_handle(ndr, NDR_SCALARS, r->in.eventMetaDataEnum));
5259 NDR_PULL_SET_MEM_CTX(ndr, _mem_save_eventMetaDataEnum_0, LIBNDR_FLAG_REF_ALLOC);
5260 NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->in.flags));
5261 NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->in.numRequested));
5262 NDR_PULL_ALLOC(ndr, r->out.numReturned);
5263 ZERO_STRUCTP(r->out.numReturned);
5264 NDR_PULL_ALLOC(ndr, r->out.eventMetadataInstances);
5265 ZERO_STRUCTP(r->out.eventMetadataInstances);
5266 }
5267 if (flags & NDR_OUT) {
5268 if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
5269 NDR_PULL_ALLOC(ndr, r->out.numReturned);
5270 }
5271 _mem_save_numReturned_0 = NDR_PULL_GET_MEM_CTX(ndr);
5272 NDR_PULL_SET_MEM_CTX(ndr, r->out.numReturned, LIBNDR_FLAG_REF_ALLOC);
5273 NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, r->out.numReturned));
5274 NDR_PULL_SET_MEM_CTX(ndr, _mem_save_numReturned_0, LIBNDR_FLAG_REF_ALLOC);
5275 if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
5276 NDR_PULL_ALLOC(ndr, r->out.eventMetadataInstances);
5277 }
5278 _mem_save_eventMetadataInstances_0 = NDR_PULL_GET_MEM_CTX(ndr);
5279 NDR_PULL_SET_MEM_CTX(ndr, r->out.eventMetadataInstances, LIBNDR_FLAG_REF_ALLOC);
5280 NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_eventMetadataInstances));
5281 if (_ptr_eventMetadataInstances) {
5282 NDR_PULL_ALLOC(ndr, *r->out.eventMetadataInstances);
5283 } else {
5284 *r->out.eventMetadataInstances = NULL;
5285 }
5286 if (*r->out.eventMetadataInstances) {
5287 _mem_save_eventMetadataInstances_1 = NDR_PULL_GET_MEM_CTX(ndr);
5288 NDR_PULL_SET_MEM_CTX(ndr, *r->out.eventMetadataInstances, 0);
5289 NDR_CHECK(ndr_pull_array_size(ndr, r->out.eventMetadataInstances));
5290 size_eventMetadataInstances_2 = ndr_get_array_size(ndr, r->out.eventMetadataInstances);
5291 if (size_eventMetadataInstances_2 > MAX_RPC_EVENT_METADATA_COUNT) {
5292 return ndr_pull_error(ndr, NDR_ERR_RANGE, "value out of range");
5293 }
5294 NDR_PULL_ALLOC_N(ndr, *r->out.eventMetadataInstances, size_eventMetadataInstances_2);
5295 _mem_save_eventMetadataInstances_2 = NDR_PULL_GET_MEM_CTX(ndr);
5296 NDR_PULL_SET_MEM_CTX(ndr, *r->out.eventMetadataInstances, 0);
5297 for (cntr_eventMetadataInstances_2 = 0; cntr_eventMetadataInstances_2 < size_eventMetadataInstances_2; cntr_eventMetadataInstances_2++) {
5298 NDR_CHECK(ndr_pull_eventlog6_EvtRpcVariantList(ndr, NDR_SCALARS, &(*r->out.eventMetadataInstances)[cntr_eventMetadataInstances_2]));
5299 }
5300 for (cntr_eventMetadataInstances_2 = 0; cntr_eventMetadataInstances_2 < size_eventMetadataInstances_2; cntr_eventMetadataInstances_2++) {
5301 NDR_CHECK(ndr_pull_eventlog6_EvtRpcVariantList(ndr, NDR_BUFFERS, &(*r->out.eventMetadataInstances)[cntr_eventMetadataInstances_2]));
5302 }
5303 NDR_PULL_SET_MEM_CTX(ndr, _mem_save_eventMetadataInstances_2, 0);
5304 NDR_PULL_SET_MEM_CTX(ndr, _mem_save_eventMetadataInstances_1, 0);
5305 }
5306 NDR_PULL_SET_MEM_CTX(ndr, _mem_save_eventMetadataInstances_0, LIBNDR_FLAG_REF_ALLOC);
5307 NDR_CHECK(ndr_pull_WERROR(ndr, NDR_SCALARS, &r->out.result));
5308 if (*r->out.eventMetadataInstances) {
5309 NDR_CHECK(ndr_check_array_size(ndr, (void*)r->out.eventMetadataInstances, *r->out.numReturned));
5310 }
5311 }
5312 return NDR_ERR_SUCCESS;
5313}
5314
5315_PUBLIC_ void ndr_print_eventlog6_EvtRpcGetNextEventMetadata(struct ndr_print *ndr, const char *name, int flags, const struct eventlog6_EvtRpcGetNextEventMetadata *r)
5316{
5317 uint32_t cntr_eventMetadataInstances_2;
5318 ndr_print_struct(ndr, name, "eventlog6_EvtRpcGetNextEventMetadata");
5319 if (r == NULL) { ndr_print_null(ndr); return; }
5320 ndr->depth++;
5321 if (flags & NDR_SET_VALUES) {
5322 ndr->flags |= LIBNDR_PRINT_SET_VALUES;
5323 }
5324 if (flags & NDR_IN) {
5325 ndr_print_struct(ndr, "in", "eventlog6_EvtRpcGetNextEventMetadata");
5326 ndr->depth++;
5327 ndr_print_ptr(ndr, "eventMetaDataEnum", r->in.eventMetaDataEnum);
5328 ndr->depth++;
5329 ndr_print_policy_handle(ndr, "eventMetaDataEnum", r->in.eventMetaDataEnum);
5330 ndr->depth--;
5331 ndr_print_uint32(ndr, "flags", r->in.flags);
5332 ndr_print_uint32(ndr, "numRequested", r->in.numRequested);
5333 ndr->depth--;
5334 }
5335 if (flags & NDR_OUT) {
5336 ndr_print_struct(ndr, "out", "eventlog6_EvtRpcGetNextEventMetadata");
5337 ndr->depth++;
5338 ndr_print_ptr(ndr, "numReturned", r->out.numReturned);
5339 ndr->depth++;
5340 ndr_print_uint32(ndr, "numReturned", *r->out.numReturned);
5341 ndr->depth--;
5342 ndr_print_ptr(ndr, "eventMetadataInstances", r->out.eventMetadataInstances);
5343 ndr->depth++;
5344 ndr_print_ptr(ndr, "eventMetadataInstances", *r->out.eventMetadataInstances);
5345 ndr->depth++;
5346 if (*r->out.eventMetadataInstances) {
5347 ndr->print(ndr, "%s: ARRAY(%d)", "eventMetadataInstances", (int)*r->out.numReturned);
5348 ndr->depth++;
5349 for (cntr_eventMetadataInstances_2=0;cntr_eventMetadataInstances_2<*r->out.numReturned;cntr_eventMetadataInstances_2++) {
5350 ndr_print_eventlog6_EvtRpcVariantList(ndr, "eventMetadataInstances", &(*r->out.eventMetadataInstances)[cntr_eventMetadataInstances_2]);
5351 }
5352 ndr->depth--;
5353 }
5354 ndr->depth--;
5355 ndr->depth--;
5356 ndr_print_WERROR(ndr, "result", r->out.result);
5357 ndr->depth--;
5358 }
5359 ndr->depth--;
5360}
5361
5362static enum ndr_err_code ndr_push_eventlog6_EvtRpcGetClassicLogDisplayName(struct ndr_push *ndr, int flags, const struct eventlog6_EvtRpcGetClassicLogDisplayName *r)
5363{
5364 if (flags & NDR_IN) {
5365 if (r->in.logName == NULL) {
5366 return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
5367 }
5368 NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->in.logName, CH_UTF16)));
5369 NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, 0));
5370 NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->in.logName, CH_UTF16)));
5371 NDR_CHECK(ndr_push_charset(ndr, NDR_SCALARS, r->in.logName, ndr_charset_length(r->in.logName, CH_UTF16), sizeof(uint16_t), CH_UTF16));
5372 NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->in.locale));
5373 NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->in.flags));
5374 }
5375 if (flags & NDR_OUT) {
5376 if (r->out.displayName == NULL) {
5377 return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
5378 }
5379 NDR_CHECK(ndr_push_unique_ptr(ndr, *r->out.displayName));
5380 if (*r->out.displayName) {
5381 NDR_CHECK(ndr_push_uint16(ndr, NDR_SCALARS, **r->out.displayName));
5382 }
5383 NDR_CHECK(ndr_push_WERROR(ndr, NDR_SCALARS, r->out.result));
5384 }
5385 return NDR_ERR_SUCCESS;
5386}
5387
5388static enum ndr_err_code ndr_pull_eventlog6_EvtRpcGetClassicLogDisplayName(struct ndr_pull *ndr, int flags, struct eventlog6_EvtRpcGetClassicLogDisplayName *r)
5389{
5390 uint32_t size_logName_1 = 0;
5391 uint32_t length_logName_1 = 0;
5392 uint32_t _ptr_displayName;
5393 TALLOC_CTX *_mem_save_displayName_0;
5394 TALLOC_CTX *_mem_save_displayName_1;
5395 if (flags & NDR_IN) {
5396 ZERO_STRUCT(r->out);
5397
5398 NDR_CHECK(ndr_pull_array_size(ndr, &r->in.logName));
5399 NDR_CHECK(ndr_pull_array_length(ndr, &r->in.logName));
5400 size_logName_1 = ndr_get_array_size(ndr, &r->in.logName);
5401 if (size_logName_1 < 1 || size_logName_1 > MAX_RPC_CHANNEL_NAME_LENGTH) {
5402 return ndr_pull_error(ndr, NDR_ERR_RANGE, "value out of range");
5403 }
5404 length_logName_1 = ndr_get_array_length(ndr, &r->in.logName);
5405 if (length_logName_1 < 1 || length_logName_1 > MAX_RPC_CHANNEL_NAME_LENGTH) {
5406 return ndr_pull_error(ndr, NDR_ERR_RANGE, "value out of range");
5407 }
5408 if (length_logName_1 > size_logName_1) {
5409 return ndr_pull_error(ndr, NDR_ERR_ARRAY_SIZE, "Bad array size %u should exceed array length %u", size_logName_1, length_logName_1);
5410 }
5411 NDR_CHECK(ndr_check_string_terminator(ndr, length_logName_1, sizeof(uint16_t)));
5412 NDR_CHECK(ndr_pull_charset(ndr, NDR_SCALARS, &r->in.logName, length_logName_1, sizeof(uint16_t), CH_UTF16));
5413 NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->in.locale));
5414 NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->in.flags));
5415 NDR_PULL_ALLOC(ndr, r->out.displayName);
5416 ZERO_STRUCTP(r->out.displayName);
5417 }
5418 if (flags & NDR_OUT) {
5419 if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
5420 NDR_PULL_ALLOC(ndr, r->out.displayName);
5421 }
5422 _mem_save_displayName_0 = NDR_PULL_GET_MEM_CTX(ndr);
5423 NDR_PULL_SET_MEM_CTX(ndr, r->out.displayName, LIBNDR_FLAG_REF_ALLOC);
5424 NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_displayName));
5425 if (_ptr_displayName) {
5426 NDR_PULL_ALLOC(ndr, *r->out.displayName);
5427 } else {
5428 *r->out.displayName = NULL;
5429 }
5430 if (*r->out.displayName) {
5431 _mem_save_displayName_1 = NDR_PULL_GET_MEM_CTX(ndr);
5432 NDR_PULL_SET_MEM_CTX(ndr, *r->out.displayName, 0);
5433 NDR_CHECK(ndr_pull_uint16(ndr, NDR_SCALARS, *r->out.displayName));
5434 NDR_PULL_SET_MEM_CTX(ndr, _mem_save_displayName_1, 0);
5435 }
5436 NDR_PULL_SET_MEM_CTX(ndr, _mem_save_displayName_0, LIBNDR_FLAG_REF_ALLOC);
5437 NDR_CHECK(ndr_pull_WERROR(ndr, NDR_SCALARS, &r->out.result));
5438 }
5439 return NDR_ERR_SUCCESS;
5440}
5441
5442_PUBLIC_ void ndr_print_eventlog6_EvtRpcGetClassicLogDisplayName(struct ndr_print *ndr, const char *name, int flags, const struct eventlog6_EvtRpcGetClassicLogDisplayName *r)
5443{
5444 ndr_print_struct(ndr, name, "eventlog6_EvtRpcGetClassicLogDisplayName");
5445 if (r == NULL) { ndr_print_null(ndr); return; }
5446 ndr->depth++;
5447 if (flags & NDR_SET_VALUES) {
5448 ndr->flags |= LIBNDR_PRINT_SET_VALUES;
5449 }
5450 if (flags & NDR_IN) {
5451 ndr_print_struct(ndr, "in", "eventlog6_EvtRpcGetClassicLogDisplayName");
5452 ndr->depth++;
5453 ndr_print_ptr(ndr, "logName", r->in.logName);
5454 ndr->depth++;
5455 ndr_print_string(ndr, "logName", r->in.logName);
5456 ndr->depth--;
5457 ndr_print_uint32(ndr, "locale", r->in.locale);
5458 ndr_print_uint32(ndr, "flags", r->in.flags);
5459 ndr->depth--;
5460 }
5461 if (flags & NDR_OUT) {
5462 ndr_print_struct(ndr, "out", "eventlog6_EvtRpcGetClassicLogDisplayName");
5463 ndr->depth++;
5464 ndr_print_ptr(ndr, "displayName", r->out.displayName);
5465 ndr->depth++;
5466 ndr_print_ptr(ndr, "displayName", *r->out.displayName);
5467 ndr->depth++;
5468 if (*r->out.displayName) {
5469 ndr_print_uint16(ndr, "displayName", **r->out.displayName);
5470 }
5471 ndr->depth--;
5472 ndr->depth--;
5473 ndr_print_WERROR(ndr, "result", r->out.result);
5474 ndr->depth--;
5475 }
5476 ndr->depth--;
5477}
5478
5479static const struct ndr_interface_call eventlog6_calls[] = {
5480 {
5481 "eventlog6_EvtRpcRegisterRemoteSubscription",
5482 sizeof(struct eventlog6_EvtRpcRegisterRemoteSubscription),
5483 (ndr_push_flags_fn_t) ndr_push_eventlog6_EvtRpcRegisterRemoteSubscription,
5484 (ndr_pull_flags_fn_t) ndr_pull_eventlog6_EvtRpcRegisterRemoteSubscription,
5485 (ndr_print_function_t) ndr_print_eventlog6_EvtRpcRegisterRemoteSubscription,
5486 { 0, NULL },
5487 { 0, NULL },
5488 },
5489 {
5490 "eventlog6_EvtRpcRemoteSubscriptionNextAsync",
5491 sizeof(struct eventlog6_EvtRpcRemoteSubscriptionNextAsync),
5492 (ndr_push_flags_fn_t) ndr_push_eventlog6_EvtRpcRemoteSubscriptionNextAsync,
5493 (ndr_pull_flags_fn_t) ndr_pull_eventlog6_EvtRpcRemoteSubscriptionNextAsync,
5494 (ndr_print_function_t) ndr_print_eventlog6_EvtRpcRemoteSubscriptionNextAsync,
5495 { 0, NULL },
5496 { 0, NULL },
5497 },
5498 {
5499 "eventlog6_EvtRpcRemoteSubscriptionNext",
5500 sizeof(struct eventlog6_EvtRpcRemoteSubscriptionNext),
5501 (ndr_push_flags_fn_t) ndr_push_eventlog6_EvtRpcRemoteSubscriptionNext,
5502 (ndr_pull_flags_fn_t) ndr_pull_eventlog6_EvtRpcRemoteSubscriptionNext,
5503 (ndr_print_function_t) ndr_print_eventlog6_EvtRpcRemoteSubscriptionNext,
5504 { 0, NULL },
5505 { 0, NULL },
5506 },
5507 {
5508 "eventlog6_EvtRpcRemoteSubscriptionWaitAsync",
5509 sizeof(struct eventlog6_EvtRpcRemoteSubscriptionWaitAsync),
5510 (ndr_push_flags_fn_t) ndr_push_eventlog6_EvtRpcRemoteSubscriptionWaitAsync,
5511 (ndr_pull_flags_fn_t) ndr_pull_eventlog6_EvtRpcRemoteSubscriptionWaitAsync,
5512 (ndr_print_function_t) ndr_print_eventlog6_EvtRpcRemoteSubscriptionWaitAsync,
5513 { 0, NULL },
5514 { 0, NULL },
5515 },
5516 {
5517 "eventlog6_EvtRpcRegisterControllableOperation",
5518 sizeof(struct eventlog6_EvtRpcRegisterControllableOperation),
5519 (ndr_push_flags_fn_t) ndr_push_eventlog6_EvtRpcRegisterControllableOperation,
5520 (ndr_pull_flags_fn_t) ndr_pull_eventlog6_EvtRpcRegisterControllableOperation,
5521 (ndr_print_function_t) ndr_print_eventlog6_EvtRpcRegisterControllableOperation,
5522 { 0, NULL },
5523 { 0, NULL },
5524 },
5525 {
5526 "eventlog6_EvtRpcRegisterLogQuery",
5527 sizeof(struct eventlog6_EvtRpcRegisterLogQuery),
5528 (ndr_push_flags_fn_t) ndr_push_eventlog6_EvtRpcRegisterLogQuery,
5529 (ndr_pull_flags_fn_t) ndr_pull_eventlog6_EvtRpcRegisterLogQuery,
5530 (ndr_print_function_t) ndr_print_eventlog6_EvtRpcRegisterLogQuery,
5531 { 0, NULL },
5532 { 0, NULL },
5533 },
5534 {
5535 "eventlog6_EvtRpcClearLog",
5536 sizeof(struct eventlog6_EvtRpcClearLog),
5537 (ndr_push_flags_fn_t) ndr_push_eventlog6_EvtRpcClearLog,
5538 (ndr_pull_flags_fn_t) ndr_pull_eventlog6_EvtRpcClearLog,
5539 (ndr_print_function_t) ndr_print_eventlog6_EvtRpcClearLog,
5540 { 0, NULL },
5541 { 0, NULL },
5542 },
5543 {
5544 "eventlog6_EvtRpcExportLog",
5545 sizeof(struct eventlog6_EvtRpcExportLog),
5546 (ndr_push_flags_fn_t) ndr_push_eventlog6_EvtRpcExportLog,
5547 (ndr_pull_flags_fn_t) ndr_pull_eventlog6_EvtRpcExportLog,
5548 (ndr_print_function_t) ndr_print_eventlog6_EvtRpcExportLog,
5549 { 0, NULL },
5550 { 0, NULL },
5551 },
5552 {
5553 "eventlog6_EvtRpcLocalizeExportLog",
5554 sizeof(struct eventlog6_EvtRpcLocalizeExportLog),
5555 (ndr_push_flags_fn_t) ndr_push_eventlog6_EvtRpcLocalizeExportLog,
5556 (ndr_pull_flags_fn_t) ndr_pull_eventlog6_EvtRpcLocalizeExportLog,
5557 (ndr_print_function_t) ndr_print_eventlog6_EvtRpcLocalizeExportLog,
5558 { 0, NULL },
5559 { 0, NULL },
5560 },
5561 {
5562 "eventlog6_EvtRpcMessageRender",
5563 sizeof(struct eventlog6_EvtRpcMessageRender),
5564 (ndr_push_flags_fn_t) ndr_push_eventlog6_EvtRpcMessageRender,
5565 (ndr_pull_flags_fn_t) ndr_pull_eventlog6_EvtRpcMessageRender,
5566 (ndr_print_function_t) ndr_print_eventlog6_EvtRpcMessageRender,
5567 { 0, NULL },
5568 { 0, NULL },
5569 },
5570 {
5571 "eventlog6_EvtRpcMessageRenderDefault",
5572 sizeof(struct eventlog6_EvtRpcMessageRenderDefault),
5573 (ndr_push_flags_fn_t) ndr_push_eventlog6_EvtRpcMessageRenderDefault,
5574 (ndr_pull_flags_fn_t) ndr_pull_eventlog6_EvtRpcMessageRenderDefault,
5575 (ndr_print_function_t) ndr_print_eventlog6_EvtRpcMessageRenderDefault,
5576 { 0, NULL },
5577 { 0, NULL },
5578 },
5579 {
5580 "eventlog6_EvtRpcQueryNext",
5581 sizeof(struct eventlog6_EvtRpcQueryNext),
5582 (ndr_push_flags_fn_t) ndr_push_eventlog6_EvtRpcQueryNext,
5583 (ndr_pull_flags_fn_t) ndr_pull_eventlog6_EvtRpcQueryNext,
5584 (ndr_print_function_t) ndr_print_eventlog6_EvtRpcQueryNext,
5585 { 0, NULL },
5586 { 0, NULL },
5587 },
5588 {
5589 "eventlog6_EvtRpcQuerySeek",
5590 sizeof(struct eventlog6_EvtRpcQuerySeek),
5591 (ndr_push_flags_fn_t) ndr_push_eventlog6_EvtRpcQuerySeek,
5592 (ndr_pull_flags_fn_t) ndr_pull_eventlog6_EvtRpcQuerySeek,
5593 (ndr_print_function_t) ndr_print_eventlog6_EvtRpcQuerySeek,
5594 { 0, NULL },
5595 { 0, NULL },
5596 },
5597 {
5598 "eventlog6_EvtRpcClose",
5599 sizeof(struct eventlog6_EvtRpcClose),
5600 (ndr_push_flags_fn_t) ndr_push_eventlog6_EvtRpcClose,
5601 (ndr_pull_flags_fn_t) ndr_pull_eventlog6_EvtRpcClose,
5602 (ndr_print_function_t) ndr_print_eventlog6_EvtRpcClose,
5603 { 0, NULL },
5604 { 0, NULL },
5605 },
5606 {
5607 "eventlog6_EvtRpcCancel",
5608 sizeof(struct eventlog6_EvtRpcCancel),
5609 (ndr_push_flags_fn_t) ndr_push_eventlog6_EvtRpcCancel,
5610 (ndr_pull_flags_fn_t) ndr_pull_eventlog6_EvtRpcCancel,
5611 (ndr_print_function_t) ndr_print_eventlog6_EvtRpcCancel,
5612 { 0, NULL },
5613 { 0, NULL },
5614 },
5615 {
5616 "eventlog6_EvtRpcAssertConfig",
5617 sizeof(struct eventlog6_EvtRpcAssertConfig),
5618 (ndr_push_flags_fn_t) ndr_push_eventlog6_EvtRpcAssertConfig,
5619 (ndr_pull_flags_fn_t) ndr_pull_eventlog6_EvtRpcAssertConfig,
5620 (ndr_print_function_t) ndr_print_eventlog6_EvtRpcAssertConfig,
5621 { 0, NULL },
5622 { 0, NULL },
5623 },
5624 {
5625 "eventlog6_EvtRpcRetractConfig",
5626 sizeof(struct eventlog6_EvtRpcRetractConfig),
5627 (ndr_push_flags_fn_t) ndr_push_eventlog6_EvtRpcRetractConfig,
5628 (ndr_pull_flags_fn_t) ndr_pull_eventlog6_EvtRpcRetractConfig,
5629 (ndr_print_function_t) ndr_print_eventlog6_EvtRpcRetractConfig,
5630 { 0, NULL },
5631 { 0, NULL },
5632 },
5633 {
5634 "eventlog6_EvtRpcOpenLogHandle",
5635 sizeof(struct eventlog6_EvtRpcOpenLogHandle),
5636 (ndr_push_flags_fn_t) ndr_push_eventlog6_EvtRpcOpenLogHandle,
5637 (ndr_pull_flags_fn_t) ndr_pull_eventlog6_EvtRpcOpenLogHandle,
5638 (ndr_print_function_t) ndr_print_eventlog6_EvtRpcOpenLogHandle,
5639 { 0, NULL },
5640 { 0, NULL },
5641 },
5642 {
5643 "eventlog6_EvtRpcGetLogFileInfo",
5644 sizeof(struct eventlog6_EvtRpcGetLogFileInfo),
5645 (ndr_push_flags_fn_t) ndr_push_eventlog6_EvtRpcGetLogFileInfo,
5646 (ndr_pull_flags_fn_t) ndr_pull_eventlog6_EvtRpcGetLogFileInfo,
5647 (ndr_print_function_t) ndr_print_eventlog6_EvtRpcGetLogFileInfo,
5648 { 0, NULL },
5649 { 0, NULL },
5650 },
5651 {
5652 "eventlog6_EvtRpcGetChannelList",
5653 sizeof(struct eventlog6_EvtRpcGetChannelList),
5654 (ndr_push_flags_fn_t) ndr_push_eventlog6_EvtRpcGetChannelList,
5655 (ndr_pull_flags_fn_t) ndr_pull_eventlog6_EvtRpcGetChannelList,
5656 (ndr_print_function_t) ndr_print_eventlog6_EvtRpcGetChannelList,
5657 { 0, NULL },
5658 { 0, NULL },
5659 },
5660 {
5661 "eventlog6_EvtRpcGetChannelConfig",
5662 sizeof(struct eventlog6_EvtRpcGetChannelConfig),
5663 (ndr_push_flags_fn_t) ndr_push_eventlog6_EvtRpcGetChannelConfig,
5664 (ndr_pull_flags_fn_t) ndr_pull_eventlog6_EvtRpcGetChannelConfig,
5665 (ndr_print_function_t) ndr_print_eventlog6_EvtRpcGetChannelConfig,
5666 { 0, NULL },
5667 { 0, NULL },
5668 },
5669 {
5670 "eventlog6_EvtRpcPutChannelConfig",
5671 sizeof(struct eventlog6_EvtRpcPutChannelConfig),
5672 (ndr_push_flags_fn_t) ndr_push_eventlog6_EvtRpcPutChannelConfig,
5673 (ndr_pull_flags_fn_t) ndr_pull_eventlog6_EvtRpcPutChannelConfig,
5674 (ndr_print_function_t) ndr_print_eventlog6_EvtRpcPutChannelConfig,
5675 { 0, NULL },
5676 { 0, NULL },
5677 },
5678 {
5679 "eventlog6_EvtRpcGetPublisherList",
5680 sizeof(struct eventlog6_EvtRpcGetPublisherList),
5681 (ndr_push_flags_fn_t) ndr_push_eventlog6_EvtRpcGetPublisherList,
5682 (ndr_pull_flags_fn_t) ndr_pull_eventlog6_EvtRpcGetPublisherList,
5683 (ndr_print_function_t) ndr_print_eventlog6_EvtRpcGetPublisherList,
5684 { 0, NULL },
5685 { 0, NULL },
5686 },
5687 {
5688 "eventlog6_EvtRpcGetPublisherListForChannel",
5689 sizeof(struct eventlog6_EvtRpcGetPublisherListForChannel),
5690 (ndr_push_flags_fn_t) ndr_push_eventlog6_EvtRpcGetPublisherListForChannel,
5691 (ndr_pull_flags_fn_t) ndr_pull_eventlog6_EvtRpcGetPublisherListForChannel,
5692 (ndr_print_function_t) ndr_print_eventlog6_EvtRpcGetPublisherListForChannel,
5693 { 0, NULL },
5694 { 0, NULL },
5695 },
5696 {
5697 "eventlog6_EvtRpcGetPublisherMetadata",
5698 sizeof(struct eventlog6_EvtRpcGetPublisherMetadata),
5699 (ndr_push_flags_fn_t) ndr_push_eventlog6_EvtRpcGetPublisherMetadata,
5700 (ndr_pull_flags_fn_t) ndr_pull_eventlog6_EvtRpcGetPublisherMetadata,
5701 (ndr_print_function_t) ndr_print_eventlog6_EvtRpcGetPublisherMetadata,
5702 { 0, NULL },
5703 { 0, NULL },
5704 },
5705 {
5706 "eventlog6_EvtRpcGetPublisherResourceMetadata",
5707 sizeof(struct eventlog6_EvtRpcGetPublisherResourceMetadata),
5708 (ndr_push_flags_fn_t) ndr_push_eventlog6_EvtRpcGetPublisherResourceMetadata,
5709 (ndr_pull_flags_fn_t) ndr_pull_eventlog6_EvtRpcGetPublisherResourceMetadata,
5710 (ndr_print_function_t) ndr_print_eventlog6_EvtRpcGetPublisherResourceMetadata,
5711 { 0, NULL },
5712 { 0, NULL },
5713 },
5714 {
5715 "eventlog6_EvtRpcGetEventMetadataEnum",
5716 sizeof(struct eventlog6_EvtRpcGetEventMetadataEnum),
5717 (ndr_push_flags_fn_t) ndr_push_eventlog6_EvtRpcGetEventMetadataEnum,
5718 (ndr_pull_flags_fn_t) ndr_pull_eventlog6_EvtRpcGetEventMetadataEnum,
5719 (ndr_print_function_t) ndr_print_eventlog6_EvtRpcGetEventMetadataEnum,
5720 { 0, NULL },
5721 { 0, NULL },
5722 },
5723 {
5724 "eventlog6_EvtRpcGetNextEventMetadata",
5725 sizeof(struct eventlog6_EvtRpcGetNextEventMetadata),
5726 (ndr_push_flags_fn_t) ndr_push_eventlog6_EvtRpcGetNextEventMetadata,
5727 (ndr_pull_flags_fn_t) ndr_pull_eventlog6_EvtRpcGetNextEventMetadata,
5728 (ndr_print_function_t) ndr_print_eventlog6_EvtRpcGetNextEventMetadata,
5729 { 0, NULL },
5730 { 0, NULL },
5731 },
5732 {
5733 "eventlog6_EvtRpcGetClassicLogDisplayName",
5734 sizeof(struct eventlog6_EvtRpcGetClassicLogDisplayName),
5735 (ndr_push_flags_fn_t) ndr_push_eventlog6_EvtRpcGetClassicLogDisplayName,
5736 (ndr_pull_flags_fn_t) ndr_pull_eventlog6_EvtRpcGetClassicLogDisplayName,
5737 (ndr_print_function_t) ndr_print_eventlog6_EvtRpcGetClassicLogDisplayName,
5738 { 0, NULL },
5739 { 0, NULL },
5740 },
5741 { NULL, 0, NULL, NULL, NULL }
5742};
5743
5744static const char * const eventlog6_endpoint_strings[] = {
5745 "ncacn_ip_tcp:",
5746};
5747
5748static const struct ndr_interface_string_array eventlog6_endpoints = {
5749 .count = 1,
5750 .names = eventlog6_endpoint_strings
5751};
5752
5753static const char * const eventlog6_authservice_strings[] = {
5754 "host",
5755};
5756
5757static const struct ndr_interface_string_array eventlog6_authservices = {
5758 .count = 1,
5759 .names = eventlog6_authservice_strings
5760};
5761
5762
5763const struct ndr_interface_table ndr_table_eventlog6 = {
5764 .name = "eventlog6",
5765 .syntax_id = {
5766 {0xf6beaff7,0x1e19,0x4fbb,{0x9f,0x8f},{0xb8,0x9e,0x20,0x18,0x33,0x7c}},
5767 NDR_EVENTLOG6_VERSION
5768 },
5769 .helpstring = NDR_EVENTLOG6_HELPSTRING,
5770 .num_calls = 29,
5771 .calls = eventlog6_calls,
5772 .endpoints = &eventlog6_endpoints,
5773 .authservices = &eventlog6_authservices
5774};
5775
Note: See TracBrowser for help on using the repository browser.