2
* Unix SMB/CIFS implementation.
3
* server auto-generated by pidl. DO NOT MODIFY!
7
#include "../librpc/gen_ndr/srv_spoolss.h"
9
static bool api_spoolss_EnumPrinters(pipes_struct *p)
11
const struct ndr_interface_call *call;
12
struct ndr_pull *pull;
13
struct ndr_push *push;
14
enum ndr_err_code ndr_err;
16
struct spoolss_EnumPrinters *r;
18
call = &ndr_table_spoolss.calls[NDR_SPOOLSS_ENUMPRINTERS];
20
r = talloc(talloc_tos(), struct spoolss_EnumPrinters);
25
if (!prs_data_blob(&p->in_data.data, &blob, r)) {
30
pull = ndr_pull_init_blob(&blob, r, NULL);
36
pull->flags |= LIBNDR_FLAG_REF_ALLOC;
37
ndr_err = call->ndr_pull(pull, NDR_IN, r);
38
if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
43
if (DEBUGLEVEL >= 10) {
44
NDR_PRINT_IN_DEBUG(spoolss_EnumPrinters, r);
48
r->out.count = talloc_zero(r, uint32_t);
49
if (r->out.count == NULL) {
54
r->out.info = talloc_zero(r, union spoolss_PrinterInfo *);
55
if (r->out.info == NULL) {
60
r->out.needed = talloc_zero(r, uint32_t);
61
if (r->out.needed == NULL) {
66
r->out.result = _spoolss_EnumPrinters(p, r);
68
if (p->rng_fault_state) {
70
/* Return true here, srv_pipe_hnd.c will take care */
74
if (DEBUGLEVEL >= 10) {
75
NDR_PRINT_OUT_DEBUG(spoolss_EnumPrinters, r);
78
push = ndr_push_init_ctx(r, NULL);
84
ndr_err = call->ndr_push(push, NDR_OUT, r);
85
if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
90
blob = ndr_push_blob(push);
91
if (!prs_copy_data_in(&p->out_data.rdata, (const char *)blob.data, (uint32_t)blob.length)) {
101
static bool api_spoolss_OpenPrinter(pipes_struct *p)
103
const struct ndr_interface_call *call;
104
struct ndr_pull *pull;
105
struct ndr_push *push;
106
enum ndr_err_code ndr_err;
108
struct spoolss_OpenPrinter *r;
110
call = &ndr_table_spoolss.calls[NDR_SPOOLSS_OPENPRINTER];
112
r = talloc(talloc_tos(), struct spoolss_OpenPrinter);
117
if (!prs_data_blob(&p->in_data.data, &blob, r)) {
122
pull = ndr_pull_init_blob(&blob, r, NULL);
128
pull->flags |= LIBNDR_FLAG_REF_ALLOC;
129
ndr_err = call->ndr_pull(pull, NDR_IN, r);
130
if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
135
if (DEBUGLEVEL >= 10) {
136
NDR_PRINT_IN_DEBUG(spoolss_OpenPrinter, r);
140
r->out.handle = talloc_zero(r, struct policy_handle);
141
if (r->out.handle == NULL) {
146
r->out.result = _spoolss_OpenPrinter(p, r);
148
if (p->rng_fault_state) {
150
/* Return true here, srv_pipe_hnd.c will take care */
154
if (DEBUGLEVEL >= 10) {
155
NDR_PRINT_OUT_DEBUG(spoolss_OpenPrinter, r);
158
push = ndr_push_init_ctx(r, NULL);
164
ndr_err = call->ndr_push(push, NDR_OUT, r);
165
if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
170
blob = ndr_push_blob(push);
171
if (!prs_copy_data_in(&p->out_data.rdata, (const char *)blob.data, (uint32_t)blob.length)) {
181
static bool api_spoolss_SetJob(pipes_struct *p)
183
const struct ndr_interface_call *call;
184
struct ndr_pull *pull;
185
struct ndr_push *push;
186
enum ndr_err_code ndr_err;
188
struct spoolss_SetJob *r;
190
call = &ndr_table_spoolss.calls[NDR_SPOOLSS_SETJOB];
192
r = talloc(talloc_tos(), struct spoolss_SetJob);
197
if (!prs_data_blob(&p->in_data.data, &blob, r)) {
202
pull = ndr_pull_init_blob(&blob, r, NULL);
208
pull->flags |= LIBNDR_FLAG_REF_ALLOC;
209
ndr_err = call->ndr_pull(pull, NDR_IN, r);
210
if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
215
if (DEBUGLEVEL >= 10) {
216
NDR_PRINT_IN_DEBUG(spoolss_SetJob, r);
219
r->out.result = _spoolss_SetJob(p, r);
221
if (p->rng_fault_state) {
223
/* Return true here, srv_pipe_hnd.c will take care */
227
if (DEBUGLEVEL >= 10) {
228
NDR_PRINT_OUT_DEBUG(spoolss_SetJob, r);
231
push = ndr_push_init_ctx(r, NULL);
237
ndr_err = call->ndr_push(push, NDR_OUT, r);
238
if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
243
blob = ndr_push_blob(push);
244
if (!prs_copy_data_in(&p->out_data.rdata, (const char *)blob.data, (uint32_t)blob.length)) {
254
static bool api_spoolss_GetJob(pipes_struct *p)
256
const struct ndr_interface_call *call;
257
struct ndr_pull *pull;
258
struct ndr_push *push;
259
enum ndr_err_code ndr_err;
261
struct spoolss_GetJob *r;
263
call = &ndr_table_spoolss.calls[NDR_SPOOLSS_GETJOB];
265
r = talloc(talloc_tos(), struct spoolss_GetJob);
270
if (!prs_data_blob(&p->in_data.data, &blob, r)) {
275
pull = ndr_pull_init_blob(&blob, r, NULL);
281
pull->flags |= LIBNDR_FLAG_REF_ALLOC;
282
ndr_err = call->ndr_pull(pull, NDR_IN, r);
283
if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
288
if (DEBUGLEVEL >= 10) {
289
NDR_PRINT_IN_DEBUG(spoolss_GetJob, r);
293
r->out.info = talloc_zero(r, union spoolss_JobInfo);
294
if (r->out.info == NULL) {
299
r->out.needed = talloc_zero(r, uint32_t);
300
if (r->out.needed == NULL) {
305
r->out.result = _spoolss_GetJob(p, r);
307
if (p->rng_fault_state) {
309
/* Return true here, srv_pipe_hnd.c will take care */
313
if (DEBUGLEVEL >= 10) {
314
NDR_PRINT_OUT_DEBUG(spoolss_GetJob, r);
317
push = ndr_push_init_ctx(r, NULL);
323
ndr_err = call->ndr_push(push, NDR_OUT, r);
324
if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
329
blob = ndr_push_blob(push);
330
if (!prs_copy_data_in(&p->out_data.rdata, (const char *)blob.data, (uint32_t)blob.length)) {
340
static bool api_spoolss_EnumJobs(pipes_struct *p)
342
const struct ndr_interface_call *call;
343
struct ndr_pull *pull;
344
struct ndr_push *push;
345
enum ndr_err_code ndr_err;
347
struct spoolss_EnumJobs *r;
349
call = &ndr_table_spoolss.calls[NDR_SPOOLSS_ENUMJOBS];
351
r = talloc(talloc_tos(), struct spoolss_EnumJobs);
356
if (!prs_data_blob(&p->in_data.data, &blob, r)) {
361
pull = ndr_pull_init_blob(&blob, r, NULL);
367
pull->flags |= LIBNDR_FLAG_REF_ALLOC;
368
ndr_err = call->ndr_pull(pull, NDR_IN, r);
369
if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
374
if (DEBUGLEVEL >= 10) {
375
NDR_PRINT_IN_DEBUG(spoolss_EnumJobs, r);
379
r->out.count = talloc_zero(r, uint32_t);
380
if (r->out.count == NULL) {
385
r->out.info = talloc_zero(r, union spoolss_JobInfo *);
386
if (r->out.info == NULL) {
391
r->out.needed = talloc_zero(r, uint32_t);
392
if (r->out.needed == NULL) {
397
r->out.result = _spoolss_EnumJobs(p, r);
399
if (p->rng_fault_state) {
401
/* Return true here, srv_pipe_hnd.c will take care */
405
if (DEBUGLEVEL >= 10) {
406
NDR_PRINT_OUT_DEBUG(spoolss_EnumJobs, r);
409
push = ndr_push_init_ctx(r, NULL);
415
ndr_err = call->ndr_push(push, NDR_OUT, r);
416
if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
421
blob = ndr_push_blob(push);
422
if (!prs_copy_data_in(&p->out_data.rdata, (const char *)blob.data, (uint32_t)blob.length)) {
432
static bool api_spoolss_AddPrinter(pipes_struct *p)
434
const struct ndr_interface_call *call;
435
struct ndr_pull *pull;
436
struct ndr_push *push;
437
enum ndr_err_code ndr_err;
439
struct spoolss_AddPrinter *r;
441
call = &ndr_table_spoolss.calls[NDR_SPOOLSS_ADDPRINTER];
443
r = talloc(talloc_tos(), struct spoolss_AddPrinter);
448
if (!prs_data_blob(&p->in_data.data, &blob, r)) {
453
pull = ndr_pull_init_blob(&blob, r, NULL);
459
pull->flags |= LIBNDR_FLAG_REF_ALLOC;
460
ndr_err = call->ndr_pull(pull, NDR_IN, r);
461
if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
466
if (DEBUGLEVEL >= 10) {
467
NDR_PRINT_IN_DEBUG(spoolss_AddPrinter, r);
470
r->out.result = _spoolss_AddPrinter(p, r);
472
if (p->rng_fault_state) {
474
/* Return true here, srv_pipe_hnd.c will take care */
478
if (DEBUGLEVEL >= 10) {
479
NDR_PRINT_OUT_DEBUG(spoolss_AddPrinter, r);
482
push = ndr_push_init_ctx(r, NULL);
488
ndr_err = call->ndr_push(push, NDR_OUT, r);
489
if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
494
blob = ndr_push_blob(push);
495
if (!prs_copy_data_in(&p->out_data.rdata, (const char *)blob.data, (uint32_t)blob.length)) {
505
static bool api_spoolss_DeletePrinter(pipes_struct *p)
507
const struct ndr_interface_call *call;
508
struct ndr_pull *pull;
509
struct ndr_push *push;
510
enum ndr_err_code ndr_err;
512
struct spoolss_DeletePrinter *r;
514
call = &ndr_table_spoolss.calls[NDR_SPOOLSS_DELETEPRINTER];
516
r = talloc(talloc_tos(), struct spoolss_DeletePrinter);
521
if (!prs_data_blob(&p->in_data.data, &blob, r)) {
526
pull = ndr_pull_init_blob(&blob, r, NULL);
532
pull->flags |= LIBNDR_FLAG_REF_ALLOC;
533
ndr_err = call->ndr_pull(pull, NDR_IN, r);
534
if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
539
if (DEBUGLEVEL >= 10) {
540
NDR_PRINT_IN_DEBUG(spoolss_DeletePrinter, r);
543
r->out.result = _spoolss_DeletePrinter(p, r);
545
if (p->rng_fault_state) {
547
/* Return true here, srv_pipe_hnd.c will take care */
551
if (DEBUGLEVEL >= 10) {
552
NDR_PRINT_OUT_DEBUG(spoolss_DeletePrinter, r);
555
push = ndr_push_init_ctx(r, NULL);
561
ndr_err = call->ndr_push(push, NDR_OUT, r);
562
if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
567
blob = ndr_push_blob(push);
568
if (!prs_copy_data_in(&p->out_data.rdata, (const char *)blob.data, (uint32_t)blob.length)) {
578
static bool api_spoolss_SetPrinter(pipes_struct *p)
580
const struct ndr_interface_call *call;
581
struct ndr_pull *pull;
582
struct ndr_push *push;
583
enum ndr_err_code ndr_err;
585
struct spoolss_SetPrinter *r;
587
call = &ndr_table_spoolss.calls[NDR_SPOOLSS_SETPRINTER];
589
r = talloc(talloc_tos(), struct spoolss_SetPrinter);
594
if (!prs_data_blob(&p->in_data.data, &blob, r)) {
599
pull = ndr_pull_init_blob(&blob, r, NULL);
605
pull->flags |= LIBNDR_FLAG_REF_ALLOC;
606
ndr_err = call->ndr_pull(pull, NDR_IN, r);
607
if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
612
if (DEBUGLEVEL >= 10) {
613
NDR_PRINT_IN_DEBUG(spoolss_SetPrinter, r);
616
r->out.result = _spoolss_SetPrinter(p, r);
618
if (p->rng_fault_state) {
620
/* Return true here, srv_pipe_hnd.c will take care */
624
if (DEBUGLEVEL >= 10) {
625
NDR_PRINT_OUT_DEBUG(spoolss_SetPrinter, r);
628
push = ndr_push_init_ctx(r, NULL);
634
ndr_err = call->ndr_push(push, NDR_OUT, r);
635
if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
640
blob = ndr_push_blob(push);
641
if (!prs_copy_data_in(&p->out_data.rdata, (const char *)blob.data, (uint32_t)blob.length)) {
651
static bool api_spoolss_GetPrinter(pipes_struct *p)
653
const struct ndr_interface_call *call;
654
struct ndr_pull *pull;
655
struct ndr_push *push;
656
enum ndr_err_code ndr_err;
658
struct spoolss_GetPrinter *r;
660
call = &ndr_table_spoolss.calls[NDR_SPOOLSS_GETPRINTER];
662
r = talloc(talloc_tos(), struct spoolss_GetPrinter);
667
if (!prs_data_blob(&p->in_data.data, &blob, r)) {
672
pull = ndr_pull_init_blob(&blob, r, NULL);
678
pull->flags |= LIBNDR_FLAG_REF_ALLOC;
679
ndr_err = call->ndr_pull(pull, NDR_IN, r);
680
if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
685
if (DEBUGLEVEL >= 10) {
686
NDR_PRINT_IN_DEBUG(spoolss_GetPrinter, r);
690
r->out.info = talloc_zero(r, union spoolss_PrinterInfo);
691
if (r->out.info == NULL) {
696
r->out.needed = talloc_zero(r, uint32_t);
697
if (r->out.needed == NULL) {
702
r->out.result = _spoolss_GetPrinter(p, r);
704
if (p->rng_fault_state) {
706
/* Return true here, srv_pipe_hnd.c will take care */
710
if (DEBUGLEVEL >= 10) {
711
NDR_PRINT_OUT_DEBUG(spoolss_GetPrinter, r);
714
push = ndr_push_init_ctx(r, NULL);
720
ndr_err = call->ndr_push(push, NDR_OUT, r);
721
if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
726
blob = ndr_push_blob(push);
727
if (!prs_copy_data_in(&p->out_data.rdata, (const char *)blob.data, (uint32_t)blob.length)) {
737
static bool api_spoolss_AddPrinterDriver(pipes_struct *p)
739
const struct ndr_interface_call *call;
740
struct ndr_pull *pull;
741
struct ndr_push *push;
742
enum ndr_err_code ndr_err;
744
struct spoolss_AddPrinterDriver *r;
746
call = &ndr_table_spoolss.calls[NDR_SPOOLSS_ADDPRINTERDRIVER];
748
r = talloc(talloc_tos(), struct spoolss_AddPrinterDriver);
753
if (!prs_data_blob(&p->in_data.data, &blob, r)) {
758
pull = ndr_pull_init_blob(&blob, r, NULL);
764
pull->flags |= LIBNDR_FLAG_REF_ALLOC;
765
ndr_err = call->ndr_pull(pull, NDR_IN, r);
766
if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
771
if (DEBUGLEVEL >= 10) {
772
NDR_PRINT_IN_DEBUG(spoolss_AddPrinterDriver, r);
775
r->out.result = _spoolss_AddPrinterDriver(p, r);
777
if (p->rng_fault_state) {
779
/* Return true here, srv_pipe_hnd.c will take care */
783
if (DEBUGLEVEL >= 10) {
784
NDR_PRINT_OUT_DEBUG(spoolss_AddPrinterDriver, r);
787
push = ndr_push_init_ctx(r, NULL);
793
ndr_err = call->ndr_push(push, NDR_OUT, r);
794
if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
799
blob = ndr_push_blob(push);
800
if (!prs_copy_data_in(&p->out_data.rdata, (const char *)blob.data, (uint32_t)blob.length)) {
810
static bool api_spoolss_EnumPrinterDrivers(pipes_struct *p)
812
const struct ndr_interface_call *call;
813
struct ndr_pull *pull;
814
struct ndr_push *push;
815
enum ndr_err_code ndr_err;
817
struct spoolss_EnumPrinterDrivers *r;
819
call = &ndr_table_spoolss.calls[NDR_SPOOLSS_ENUMPRINTERDRIVERS];
821
r = talloc(talloc_tos(), struct spoolss_EnumPrinterDrivers);
826
if (!prs_data_blob(&p->in_data.data, &blob, r)) {
831
pull = ndr_pull_init_blob(&blob, r, NULL);
837
pull->flags |= LIBNDR_FLAG_REF_ALLOC;
838
ndr_err = call->ndr_pull(pull, NDR_IN, r);
839
if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
844
if (DEBUGLEVEL >= 10) {
845
NDR_PRINT_IN_DEBUG(spoolss_EnumPrinterDrivers, r);
849
r->out.count = talloc_zero(r, uint32_t);
850
if (r->out.count == NULL) {
855
r->out.info = talloc_zero(r, union spoolss_DriverInfo *);
856
if (r->out.info == NULL) {
861
r->out.needed = talloc_zero(r, uint32_t);
862
if (r->out.needed == NULL) {
867
r->out.result = _spoolss_EnumPrinterDrivers(p, r);
869
if (p->rng_fault_state) {
871
/* Return true here, srv_pipe_hnd.c will take care */
875
if (DEBUGLEVEL >= 10) {
876
NDR_PRINT_OUT_DEBUG(spoolss_EnumPrinterDrivers, r);
879
push = ndr_push_init_ctx(r, NULL);
885
ndr_err = call->ndr_push(push, NDR_OUT, r);
886
if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
891
blob = ndr_push_blob(push);
892
if (!prs_copy_data_in(&p->out_data.rdata, (const char *)blob.data, (uint32_t)blob.length)) {
902
static bool api_spoolss_GetPrinterDriver(pipes_struct *p)
904
const struct ndr_interface_call *call;
905
struct ndr_pull *pull;
906
struct ndr_push *push;
907
enum ndr_err_code ndr_err;
909
struct spoolss_GetPrinterDriver *r;
911
call = &ndr_table_spoolss.calls[NDR_SPOOLSS_GETPRINTERDRIVER];
913
r = talloc(talloc_tos(), struct spoolss_GetPrinterDriver);
918
if (!prs_data_blob(&p->in_data.data, &blob, r)) {
923
pull = ndr_pull_init_blob(&blob, r, NULL);
929
pull->flags |= LIBNDR_FLAG_REF_ALLOC;
930
ndr_err = call->ndr_pull(pull, NDR_IN, r);
931
if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
936
if (DEBUGLEVEL >= 10) {
937
NDR_PRINT_IN_DEBUG(spoolss_GetPrinterDriver, r);
940
r->out.result = _spoolss_GetPrinterDriver(p, r);
942
if (p->rng_fault_state) {
944
/* Return true here, srv_pipe_hnd.c will take care */
948
if (DEBUGLEVEL >= 10) {
949
NDR_PRINT_OUT_DEBUG(spoolss_GetPrinterDriver, r);
952
push = ndr_push_init_ctx(r, NULL);
958
ndr_err = call->ndr_push(push, NDR_OUT, r);
959
if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
964
blob = ndr_push_blob(push);
965
if (!prs_copy_data_in(&p->out_data.rdata, (const char *)blob.data, (uint32_t)blob.length)) {
975
static bool api_spoolss_GetPrinterDriverDirectory(pipes_struct *p)
977
const struct ndr_interface_call *call;
978
struct ndr_pull *pull;
979
struct ndr_push *push;
980
enum ndr_err_code ndr_err;
982
struct spoolss_GetPrinterDriverDirectory *r;
984
call = &ndr_table_spoolss.calls[NDR_SPOOLSS_GETPRINTERDRIVERDIRECTORY];
986
r = talloc(talloc_tos(), struct spoolss_GetPrinterDriverDirectory);
991
if (!prs_data_blob(&p->in_data.data, &blob, r)) {
996
pull = ndr_pull_init_blob(&blob, r, NULL);
1002
pull->flags |= LIBNDR_FLAG_REF_ALLOC;
1003
ndr_err = call->ndr_pull(pull, NDR_IN, r);
1004
if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
1009
if (DEBUGLEVEL >= 10) {
1010
NDR_PRINT_IN_DEBUG(spoolss_GetPrinterDriverDirectory, r);
1013
ZERO_STRUCT(r->out);
1014
r->out.info = talloc_zero(r, union spoolss_DriverDirectoryInfo);
1015
if (r->out.info == NULL) {
1020
r->out.needed = talloc_zero(r, uint32_t);
1021
if (r->out.needed == NULL) {
1026
r->out.result = _spoolss_GetPrinterDriverDirectory(p, r);
1028
if (p->rng_fault_state) {
1030
/* Return true here, srv_pipe_hnd.c will take care */
1034
if (DEBUGLEVEL >= 10) {
1035
NDR_PRINT_OUT_DEBUG(spoolss_GetPrinterDriverDirectory, r);
1038
push = ndr_push_init_ctx(r, NULL);
1044
ndr_err = call->ndr_push(push, NDR_OUT, r);
1045
if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
1050
blob = ndr_push_blob(push);
1051
if (!prs_copy_data_in(&p->out_data.rdata, (const char *)blob.data, (uint32_t)blob.length)) {
1061
static bool api_spoolss_DeletePrinterDriver(pipes_struct *p)
1063
const struct ndr_interface_call *call;
1064
struct ndr_pull *pull;
1065
struct ndr_push *push;
1066
enum ndr_err_code ndr_err;
1068
struct spoolss_DeletePrinterDriver *r;
1070
call = &ndr_table_spoolss.calls[NDR_SPOOLSS_DELETEPRINTERDRIVER];
1072
r = talloc(talloc_tos(), struct spoolss_DeletePrinterDriver);
1077
if (!prs_data_blob(&p->in_data.data, &blob, r)) {
1082
pull = ndr_pull_init_blob(&blob, r, NULL);
1088
pull->flags |= LIBNDR_FLAG_REF_ALLOC;
1089
ndr_err = call->ndr_pull(pull, NDR_IN, r);
1090
if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
1095
if (DEBUGLEVEL >= 10) {
1096
NDR_PRINT_IN_DEBUG(spoolss_DeletePrinterDriver, r);
1099
r->out.result = _spoolss_DeletePrinterDriver(p, r);
1101
if (p->rng_fault_state) {
1103
/* Return true here, srv_pipe_hnd.c will take care */
1107
if (DEBUGLEVEL >= 10) {
1108
NDR_PRINT_OUT_DEBUG(spoolss_DeletePrinterDriver, r);
1111
push = ndr_push_init_ctx(r, NULL);
1117
ndr_err = call->ndr_push(push, NDR_OUT, r);
1118
if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
1123
blob = ndr_push_blob(push);
1124
if (!prs_copy_data_in(&p->out_data.rdata, (const char *)blob.data, (uint32_t)blob.length)) {
1134
static bool api_spoolss_AddPrintProcessor(pipes_struct *p)
1136
const struct ndr_interface_call *call;
1137
struct ndr_pull *pull;
1138
struct ndr_push *push;
1139
enum ndr_err_code ndr_err;
1141
struct spoolss_AddPrintProcessor *r;
1143
call = &ndr_table_spoolss.calls[NDR_SPOOLSS_ADDPRINTPROCESSOR];
1145
r = talloc(talloc_tos(), struct spoolss_AddPrintProcessor);
1150
if (!prs_data_blob(&p->in_data.data, &blob, r)) {
1155
pull = ndr_pull_init_blob(&blob, r, NULL);
1161
pull->flags |= LIBNDR_FLAG_REF_ALLOC;
1162
ndr_err = call->ndr_pull(pull, NDR_IN, r);
1163
if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
1168
if (DEBUGLEVEL >= 10) {
1169
NDR_PRINT_IN_DEBUG(spoolss_AddPrintProcessor, r);
1172
r->out.result = _spoolss_AddPrintProcessor(p, r);
1174
if (p->rng_fault_state) {
1176
/* Return true here, srv_pipe_hnd.c will take care */
1180
if (DEBUGLEVEL >= 10) {
1181
NDR_PRINT_OUT_DEBUG(spoolss_AddPrintProcessor, r);
1184
push = ndr_push_init_ctx(r, NULL);
1190
ndr_err = call->ndr_push(push, NDR_OUT, r);
1191
if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
1196
blob = ndr_push_blob(push);
1197
if (!prs_copy_data_in(&p->out_data.rdata, (const char *)blob.data, (uint32_t)blob.length)) {
1207
static bool api_spoolss_EnumPrintProcessors(pipes_struct *p)
1209
const struct ndr_interface_call *call;
1210
struct ndr_pull *pull;
1211
struct ndr_push *push;
1212
enum ndr_err_code ndr_err;
1214
struct spoolss_EnumPrintProcessors *r;
1216
call = &ndr_table_spoolss.calls[NDR_SPOOLSS_ENUMPRINTPROCESSORS];
1218
r = talloc(talloc_tos(), struct spoolss_EnumPrintProcessors);
1223
if (!prs_data_blob(&p->in_data.data, &blob, r)) {
1228
pull = ndr_pull_init_blob(&blob, r, NULL);
1234
pull->flags |= LIBNDR_FLAG_REF_ALLOC;
1235
ndr_err = call->ndr_pull(pull, NDR_IN, r);
1236
if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
1241
if (DEBUGLEVEL >= 10) {
1242
NDR_PRINT_IN_DEBUG(spoolss_EnumPrintProcessors, r);
1245
ZERO_STRUCT(r->out);
1246
r->out.count = talloc_zero(r, uint32_t);
1247
if (r->out.count == NULL) {
1252
r->out.info = talloc_zero(r, union spoolss_PrintProcessorInfo *);
1253
if (r->out.info == NULL) {
1258
r->out.needed = talloc_zero(r, uint32_t);
1259
if (r->out.needed == NULL) {
1264
r->out.result = _spoolss_EnumPrintProcessors(p, r);
1266
if (p->rng_fault_state) {
1268
/* Return true here, srv_pipe_hnd.c will take care */
1272
if (DEBUGLEVEL >= 10) {
1273
NDR_PRINT_OUT_DEBUG(spoolss_EnumPrintProcessors, r);
1276
push = ndr_push_init_ctx(r, NULL);
1282
ndr_err = call->ndr_push(push, NDR_OUT, r);
1283
if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
1288
blob = ndr_push_blob(push);
1289
if (!prs_copy_data_in(&p->out_data.rdata, (const char *)blob.data, (uint32_t)blob.length)) {
1299
static bool api_spoolss_GetPrintProcessorDirectory(pipes_struct *p)
1301
const struct ndr_interface_call *call;
1302
struct ndr_pull *pull;
1303
struct ndr_push *push;
1304
enum ndr_err_code ndr_err;
1306
struct spoolss_GetPrintProcessorDirectory *r;
1308
call = &ndr_table_spoolss.calls[NDR_SPOOLSS_GETPRINTPROCESSORDIRECTORY];
1310
r = talloc(talloc_tos(), struct spoolss_GetPrintProcessorDirectory);
1315
if (!prs_data_blob(&p->in_data.data, &blob, r)) {
1320
pull = ndr_pull_init_blob(&blob, r, NULL);
1326
pull->flags |= LIBNDR_FLAG_REF_ALLOC;
1327
ndr_err = call->ndr_pull(pull, NDR_IN, r);
1328
if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
1333
if (DEBUGLEVEL >= 10) {
1334
NDR_PRINT_IN_DEBUG(spoolss_GetPrintProcessorDirectory, r);
1337
ZERO_STRUCT(r->out);
1338
r->out.info = talloc_zero(r, union spoolss_PrintProcessorDirectoryInfo);
1339
if (r->out.info == NULL) {
1344
r->out.needed = talloc_zero(r, uint32_t);
1345
if (r->out.needed == NULL) {
1350
r->out.result = _spoolss_GetPrintProcessorDirectory(p, r);
1352
if (p->rng_fault_state) {
1354
/* Return true here, srv_pipe_hnd.c will take care */
1358
if (DEBUGLEVEL >= 10) {
1359
NDR_PRINT_OUT_DEBUG(spoolss_GetPrintProcessorDirectory, r);
1362
push = ndr_push_init_ctx(r, NULL);
1368
ndr_err = call->ndr_push(push, NDR_OUT, r);
1369
if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
1374
blob = ndr_push_blob(push);
1375
if (!prs_copy_data_in(&p->out_data.rdata, (const char *)blob.data, (uint32_t)blob.length)) {
1385
static bool api_spoolss_StartDocPrinter(pipes_struct *p)
1387
const struct ndr_interface_call *call;
1388
struct ndr_pull *pull;
1389
struct ndr_push *push;
1390
enum ndr_err_code ndr_err;
1392
struct spoolss_StartDocPrinter *r;
1394
call = &ndr_table_spoolss.calls[NDR_SPOOLSS_STARTDOCPRINTER];
1396
r = talloc(talloc_tos(), struct spoolss_StartDocPrinter);
1401
if (!prs_data_blob(&p->in_data.data, &blob, r)) {
1406
pull = ndr_pull_init_blob(&blob, r, NULL);
1412
pull->flags |= LIBNDR_FLAG_REF_ALLOC;
1413
ndr_err = call->ndr_pull(pull, NDR_IN, r);
1414
if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
1419
if (DEBUGLEVEL >= 10) {
1420
NDR_PRINT_IN_DEBUG(spoolss_StartDocPrinter, r);
1423
ZERO_STRUCT(r->out);
1424
r->out.job_id = talloc_zero(r, uint32_t);
1425
if (r->out.job_id == NULL) {
1430
r->out.result = _spoolss_StartDocPrinter(p, r);
1432
if (p->rng_fault_state) {
1434
/* Return true here, srv_pipe_hnd.c will take care */
1438
if (DEBUGLEVEL >= 10) {
1439
NDR_PRINT_OUT_DEBUG(spoolss_StartDocPrinter, r);
1442
push = ndr_push_init_ctx(r, NULL);
1448
ndr_err = call->ndr_push(push, NDR_OUT, r);
1449
if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
1454
blob = ndr_push_blob(push);
1455
if (!prs_copy_data_in(&p->out_data.rdata, (const char *)blob.data, (uint32_t)blob.length)) {
1465
static bool api_spoolss_StartPagePrinter(pipes_struct *p)
1467
const struct ndr_interface_call *call;
1468
struct ndr_pull *pull;
1469
struct ndr_push *push;
1470
enum ndr_err_code ndr_err;
1472
struct spoolss_StartPagePrinter *r;
1474
call = &ndr_table_spoolss.calls[NDR_SPOOLSS_STARTPAGEPRINTER];
1476
r = talloc(talloc_tos(), struct spoolss_StartPagePrinter);
1481
if (!prs_data_blob(&p->in_data.data, &blob, r)) {
1486
pull = ndr_pull_init_blob(&blob, r, NULL);
1492
pull->flags |= LIBNDR_FLAG_REF_ALLOC;
1493
ndr_err = call->ndr_pull(pull, NDR_IN, r);
1494
if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
1499
if (DEBUGLEVEL >= 10) {
1500
NDR_PRINT_IN_DEBUG(spoolss_StartPagePrinter, r);
1503
r->out.result = _spoolss_StartPagePrinter(p, r);
1505
if (p->rng_fault_state) {
1507
/* Return true here, srv_pipe_hnd.c will take care */
1511
if (DEBUGLEVEL >= 10) {
1512
NDR_PRINT_OUT_DEBUG(spoolss_StartPagePrinter, r);
1515
push = ndr_push_init_ctx(r, NULL);
1521
ndr_err = call->ndr_push(push, NDR_OUT, r);
1522
if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
1527
blob = ndr_push_blob(push);
1528
if (!prs_copy_data_in(&p->out_data.rdata, (const char *)blob.data, (uint32_t)blob.length)) {
1538
static bool api_spoolss_WritePrinter(pipes_struct *p)
1540
const struct ndr_interface_call *call;
1541
struct ndr_pull *pull;
1542
struct ndr_push *push;
1543
enum ndr_err_code ndr_err;
1545
struct spoolss_WritePrinter *r;
1547
call = &ndr_table_spoolss.calls[NDR_SPOOLSS_WRITEPRINTER];
1549
r = talloc(talloc_tos(), struct spoolss_WritePrinter);
1554
if (!prs_data_blob(&p->in_data.data, &blob, r)) {
1559
pull = ndr_pull_init_blob(&blob, r, NULL);
1565
pull->flags |= LIBNDR_FLAG_REF_ALLOC;
1566
ndr_err = call->ndr_pull(pull, NDR_IN, r);
1567
if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
1572
if (DEBUGLEVEL >= 10) {
1573
NDR_PRINT_IN_DEBUG(spoolss_WritePrinter, r);
1576
ZERO_STRUCT(r->out);
1577
r->out.num_written = talloc_zero(r, uint32_t);
1578
if (r->out.num_written == NULL) {
1583
r->out.result = _spoolss_WritePrinter(p, r);
1585
if (p->rng_fault_state) {
1587
/* Return true here, srv_pipe_hnd.c will take care */
1591
if (DEBUGLEVEL >= 10) {
1592
NDR_PRINT_OUT_DEBUG(spoolss_WritePrinter, r);
1595
push = ndr_push_init_ctx(r, NULL);
1601
ndr_err = call->ndr_push(push, NDR_OUT, r);
1602
if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
1607
blob = ndr_push_blob(push);
1608
if (!prs_copy_data_in(&p->out_data.rdata, (const char *)blob.data, (uint32_t)blob.length)) {
1618
static bool api_spoolss_EndPagePrinter(pipes_struct *p)
1620
const struct ndr_interface_call *call;
1621
struct ndr_pull *pull;
1622
struct ndr_push *push;
1623
enum ndr_err_code ndr_err;
1625
struct spoolss_EndPagePrinter *r;
1627
call = &ndr_table_spoolss.calls[NDR_SPOOLSS_ENDPAGEPRINTER];
1629
r = talloc(talloc_tos(), struct spoolss_EndPagePrinter);
1634
if (!prs_data_blob(&p->in_data.data, &blob, r)) {
1639
pull = ndr_pull_init_blob(&blob, r, NULL);
1645
pull->flags |= LIBNDR_FLAG_REF_ALLOC;
1646
ndr_err = call->ndr_pull(pull, NDR_IN, r);
1647
if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
1652
if (DEBUGLEVEL >= 10) {
1653
NDR_PRINT_IN_DEBUG(spoolss_EndPagePrinter, r);
1656
r->out.result = _spoolss_EndPagePrinter(p, r);
1658
if (p->rng_fault_state) {
1660
/* Return true here, srv_pipe_hnd.c will take care */
1664
if (DEBUGLEVEL >= 10) {
1665
NDR_PRINT_OUT_DEBUG(spoolss_EndPagePrinter, r);
1668
push = ndr_push_init_ctx(r, NULL);
1674
ndr_err = call->ndr_push(push, NDR_OUT, r);
1675
if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
1680
blob = ndr_push_blob(push);
1681
if (!prs_copy_data_in(&p->out_data.rdata, (const char *)blob.data, (uint32_t)blob.length)) {
1691
static bool api_spoolss_AbortPrinter(pipes_struct *p)
1693
const struct ndr_interface_call *call;
1694
struct ndr_pull *pull;
1695
struct ndr_push *push;
1696
enum ndr_err_code ndr_err;
1698
struct spoolss_AbortPrinter *r;
1700
call = &ndr_table_spoolss.calls[NDR_SPOOLSS_ABORTPRINTER];
1702
r = talloc(talloc_tos(), struct spoolss_AbortPrinter);
1707
if (!prs_data_blob(&p->in_data.data, &blob, r)) {
1712
pull = ndr_pull_init_blob(&blob, r, NULL);
1718
pull->flags |= LIBNDR_FLAG_REF_ALLOC;
1719
ndr_err = call->ndr_pull(pull, NDR_IN, r);
1720
if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
1725
if (DEBUGLEVEL >= 10) {
1726
NDR_PRINT_IN_DEBUG(spoolss_AbortPrinter, r);
1729
r->out.result = _spoolss_AbortPrinter(p, r);
1731
if (p->rng_fault_state) {
1733
/* Return true here, srv_pipe_hnd.c will take care */
1737
if (DEBUGLEVEL >= 10) {
1738
NDR_PRINT_OUT_DEBUG(spoolss_AbortPrinter, r);
1741
push = ndr_push_init_ctx(r, NULL);
1747
ndr_err = call->ndr_push(push, NDR_OUT, r);
1748
if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
1753
blob = ndr_push_blob(push);
1754
if (!prs_copy_data_in(&p->out_data.rdata, (const char *)blob.data, (uint32_t)blob.length)) {
1764
static bool api_spoolss_ReadPrinter(pipes_struct *p)
1766
const struct ndr_interface_call *call;
1767
struct ndr_pull *pull;
1768
struct ndr_push *push;
1769
enum ndr_err_code ndr_err;
1771
struct spoolss_ReadPrinter *r;
1773
call = &ndr_table_spoolss.calls[NDR_SPOOLSS_READPRINTER];
1775
r = talloc(talloc_tos(), struct spoolss_ReadPrinter);
1780
if (!prs_data_blob(&p->in_data.data, &blob, r)) {
1785
pull = ndr_pull_init_blob(&blob, r, NULL);
1791
pull->flags |= LIBNDR_FLAG_REF_ALLOC;
1792
ndr_err = call->ndr_pull(pull, NDR_IN, r);
1793
if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
1798
if (DEBUGLEVEL >= 10) {
1799
NDR_PRINT_IN_DEBUG(spoolss_ReadPrinter, r);
1802
ZERO_STRUCT(r->out);
1803
r->out.data = talloc_zero_array(r, uint8_t, r->in.data_size);
1804
if (r->out.data == NULL) {
1809
r->out._data_size = talloc_zero(r, uint32_t);
1810
if (r->out._data_size == NULL) {
1815
r->out.result = _spoolss_ReadPrinter(p, r);
1817
if (p->rng_fault_state) {
1819
/* Return true here, srv_pipe_hnd.c will take care */
1823
if (DEBUGLEVEL >= 10) {
1824
NDR_PRINT_OUT_DEBUG(spoolss_ReadPrinter, r);
1827
push = ndr_push_init_ctx(r, NULL);
1833
ndr_err = call->ndr_push(push, NDR_OUT, r);
1834
if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
1839
blob = ndr_push_blob(push);
1840
if (!prs_copy_data_in(&p->out_data.rdata, (const char *)blob.data, (uint32_t)blob.length)) {
1850
static bool api_spoolss_EndDocPrinter(pipes_struct *p)
1852
const struct ndr_interface_call *call;
1853
struct ndr_pull *pull;
1854
struct ndr_push *push;
1855
enum ndr_err_code ndr_err;
1857
struct spoolss_EndDocPrinter *r;
1859
call = &ndr_table_spoolss.calls[NDR_SPOOLSS_ENDDOCPRINTER];
1861
r = talloc(talloc_tos(), struct spoolss_EndDocPrinter);
1866
if (!prs_data_blob(&p->in_data.data, &blob, r)) {
1871
pull = ndr_pull_init_blob(&blob, r, NULL);
1877
pull->flags |= LIBNDR_FLAG_REF_ALLOC;
1878
ndr_err = call->ndr_pull(pull, NDR_IN, r);
1879
if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
1884
if (DEBUGLEVEL >= 10) {
1885
NDR_PRINT_IN_DEBUG(spoolss_EndDocPrinter, r);
1888
r->out.result = _spoolss_EndDocPrinter(p, r);
1890
if (p->rng_fault_state) {
1892
/* Return true here, srv_pipe_hnd.c will take care */
1896
if (DEBUGLEVEL >= 10) {
1897
NDR_PRINT_OUT_DEBUG(spoolss_EndDocPrinter, r);
1900
push = ndr_push_init_ctx(r, NULL);
1906
ndr_err = call->ndr_push(push, NDR_OUT, r);
1907
if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
1912
blob = ndr_push_blob(push);
1913
if (!prs_copy_data_in(&p->out_data.rdata, (const char *)blob.data, (uint32_t)blob.length)) {
1923
static bool api_spoolss_AddJob(pipes_struct *p)
1925
const struct ndr_interface_call *call;
1926
struct ndr_pull *pull;
1927
struct ndr_push *push;
1928
enum ndr_err_code ndr_err;
1930
struct spoolss_AddJob *r;
1932
call = &ndr_table_spoolss.calls[NDR_SPOOLSS_ADDJOB];
1934
r = talloc(talloc_tos(), struct spoolss_AddJob);
1939
if (!prs_data_blob(&p->in_data.data, &blob, r)) {
1944
pull = ndr_pull_init_blob(&blob, r, NULL);
1950
pull->flags |= LIBNDR_FLAG_REF_ALLOC;
1951
ndr_err = call->ndr_pull(pull, NDR_IN, r);
1952
if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
1957
if (DEBUGLEVEL >= 10) {
1958
NDR_PRINT_IN_DEBUG(spoolss_AddJob, r);
1961
ZERO_STRUCT(r->out);
1962
r->out.buffer = r->in.buffer;
1963
r->out.needed = talloc_zero(r, uint32_t);
1964
if (r->out.needed == NULL) {
1969
r->out.result = _spoolss_AddJob(p, r);
1971
if (p->rng_fault_state) {
1973
/* Return true here, srv_pipe_hnd.c will take care */
1977
if (DEBUGLEVEL >= 10) {
1978
NDR_PRINT_OUT_DEBUG(spoolss_AddJob, r);
1981
push = ndr_push_init_ctx(r, NULL);
1987
ndr_err = call->ndr_push(push, NDR_OUT, r);
1988
if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
1993
blob = ndr_push_blob(push);
1994
if (!prs_copy_data_in(&p->out_data.rdata, (const char *)blob.data, (uint32_t)blob.length)) {
2004
static bool api_spoolss_ScheduleJob(pipes_struct *p)
2006
const struct ndr_interface_call *call;
2007
struct ndr_pull *pull;
2008
struct ndr_push *push;
2009
enum ndr_err_code ndr_err;
2011
struct spoolss_ScheduleJob *r;
2013
call = &ndr_table_spoolss.calls[NDR_SPOOLSS_SCHEDULEJOB];
2015
r = talloc(talloc_tos(), struct spoolss_ScheduleJob);
2020
if (!prs_data_blob(&p->in_data.data, &blob, r)) {
2025
pull = ndr_pull_init_blob(&blob, r, NULL);
2031
pull->flags |= LIBNDR_FLAG_REF_ALLOC;
2032
ndr_err = call->ndr_pull(pull, NDR_IN, r);
2033
if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
2038
if (DEBUGLEVEL >= 10) {
2039
NDR_PRINT_IN_DEBUG(spoolss_ScheduleJob, r);
2042
r->out.result = _spoolss_ScheduleJob(p, r);
2044
if (p->rng_fault_state) {
2046
/* Return true here, srv_pipe_hnd.c will take care */
2050
if (DEBUGLEVEL >= 10) {
2051
NDR_PRINT_OUT_DEBUG(spoolss_ScheduleJob, r);
2054
push = ndr_push_init_ctx(r, NULL);
2060
ndr_err = call->ndr_push(push, NDR_OUT, r);
2061
if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
2066
blob = ndr_push_blob(push);
2067
if (!prs_copy_data_in(&p->out_data.rdata, (const char *)blob.data, (uint32_t)blob.length)) {
2077
static bool api_spoolss_GetPrinterData(pipes_struct *p)
2079
const struct ndr_interface_call *call;
2080
struct ndr_pull *pull;
2081
struct ndr_push *push;
2082
enum ndr_err_code ndr_err;
2084
struct spoolss_GetPrinterData *r;
2086
call = &ndr_table_spoolss.calls[NDR_SPOOLSS_GETPRINTERDATA];
2088
r = talloc(talloc_tos(), struct spoolss_GetPrinterData);
2093
if (!prs_data_blob(&p->in_data.data, &blob, r)) {
2098
pull = ndr_pull_init_blob(&blob, r, NULL);
2104
pull->flags |= LIBNDR_FLAG_REF_ALLOC;
2105
ndr_err = call->ndr_pull(pull, NDR_IN, r);
2106
if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
2111
if (DEBUGLEVEL >= 10) {
2112
NDR_PRINT_IN_DEBUG(spoolss_GetPrinterData, r);
2115
ZERO_STRUCT(r->out);
2116
r->out.type = talloc_zero(r, enum winreg_Type);
2117
if (r->out.type == NULL) {
2122
r->out.data = talloc_zero_array(r, uint8_t, r->in.offered);
2123
if (r->out.data == NULL) {
2128
r->out.needed = talloc_zero(r, uint32_t);
2129
if (r->out.needed == NULL) {
2134
r->out.result = _spoolss_GetPrinterData(p, r);
2136
if (p->rng_fault_state) {
2138
/* Return true here, srv_pipe_hnd.c will take care */
2142
if (DEBUGLEVEL >= 10) {
2143
NDR_PRINT_OUT_DEBUG(spoolss_GetPrinterData, r);
2146
push = ndr_push_init_ctx(r, NULL);
2152
ndr_err = call->ndr_push(push, NDR_OUT, r);
2153
if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
2158
blob = ndr_push_blob(push);
2159
if (!prs_copy_data_in(&p->out_data.rdata, (const char *)blob.data, (uint32_t)blob.length)) {
2169
static bool api_spoolss_SetPrinterData(pipes_struct *p)
2171
const struct ndr_interface_call *call;
2172
struct ndr_pull *pull;
2173
struct ndr_push *push;
2174
enum ndr_err_code ndr_err;
2176
struct spoolss_SetPrinterData *r;
2178
call = &ndr_table_spoolss.calls[NDR_SPOOLSS_SETPRINTERDATA];
2180
r = talloc(talloc_tos(), struct spoolss_SetPrinterData);
2185
if (!prs_data_blob(&p->in_data.data, &blob, r)) {
2190
pull = ndr_pull_init_blob(&blob, r, NULL);
2196
pull->flags |= LIBNDR_FLAG_REF_ALLOC;
2197
ndr_err = call->ndr_pull(pull, NDR_IN, r);
2198
if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
2203
if (DEBUGLEVEL >= 10) {
2204
NDR_PRINT_IN_DEBUG(spoolss_SetPrinterData, r);
2207
r->out.result = _spoolss_SetPrinterData(p, r);
2209
if (p->rng_fault_state) {
2211
/* Return true here, srv_pipe_hnd.c will take care */
2215
if (DEBUGLEVEL >= 10) {
2216
NDR_PRINT_OUT_DEBUG(spoolss_SetPrinterData, r);
2219
push = ndr_push_init_ctx(r, NULL);
2225
ndr_err = call->ndr_push(push, NDR_OUT, r);
2226
if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
2231
blob = ndr_push_blob(push);
2232
if (!prs_copy_data_in(&p->out_data.rdata, (const char *)blob.data, (uint32_t)blob.length)) {
2242
static bool api_spoolss_WaitForPrinterChange(pipes_struct *p)
2244
const struct ndr_interface_call *call;
2245
struct ndr_pull *pull;
2246
struct ndr_push *push;
2247
enum ndr_err_code ndr_err;
2249
struct spoolss_WaitForPrinterChange *r;
2251
call = &ndr_table_spoolss.calls[NDR_SPOOLSS_WAITFORPRINTERCHANGE];
2253
r = talloc(talloc_tos(), struct spoolss_WaitForPrinterChange);
2258
if (!prs_data_blob(&p->in_data.data, &blob, r)) {
2263
pull = ndr_pull_init_blob(&blob, r, NULL);
2269
pull->flags |= LIBNDR_FLAG_REF_ALLOC;
2270
ndr_err = call->ndr_pull(pull, NDR_IN, r);
2271
if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
2276
if (DEBUGLEVEL >= 10) {
2277
NDR_PRINT_IN_DEBUG(spoolss_WaitForPrinterChange, r);
2280
r->out.result = _spoolss_WaitForPrinterChange(p, r);
2282
if (p->rng_fault_state) {
2284
/* Return true here, srv_pipe_hnd.c will take care */
2288
if (DEBUGLEVEL >= 10) {
2289
NDR_PRINT_OUT_DEBUG(spoolss_WaitForPrinterChange, r);
2292
push = ndr_push_init_ctx(r, NULL);
2298
ndr_err = call->ndr_push(push, NDR_OUT, r);
2299
if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
2304
blob = ndr_push_blob(push);
2305
if (!prs_copy_data_in(&p->out_data.rdata, (const char *)blob.data, (uint32_t)blob.length)) {
2315
static bool api_spoolss_ClosePrinter(pipes_struct *p)
2317
const struct ndr_interface_call *call;
2318
struct ndr_pull *pull;
2319
struct ndr_push *push;
2320
enum ndr_err_code ndr_err;
2322
struct spoolss_ClosePrinter *r;
2324
call = &ndr_table_spoolss.calls[NDR_SPOOLSS_CLOSEPRINTER];
2326
r = talloc(talloc_tos(), struct spoolss_ClosePrinter);
2331
if (!prs_data_blob(&p->in_data.data, &blob, r)) {
2336
pull = ndr_pull_init_blob(&blob, r, NULL);
2342
pull->flags |= LIBNDR_FLAG_REF_ALLOC;
2343
ndr_err = call->ndr_pull(pull, NDR_IN, r);
2344
if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
2349
if (DEBUGLEVEL >= 10) {
2350
NDR_PRINT_IN_DEBUG(spoolss_ClosePrinter, r);
2353
ZERO_STRUCT(r->out);
2354
r->out.handle = r->in.handle;
2355
r->out.result = _spoolss_ClosePrinter(p, r);
2357
if (p->rng_fault_state) {
2359
/* Return true here, srv_pipe_hnd.c will take care */
2363
if (DEBUGLEVEL >= 10) {
2364
NDR_PRINT_OUT_DEBUG(spoolss_ClosePrinter, r);
2367
push = ndr_push_init_ctx(r, NULL);
2373
ndr_err = call->ndr_push(push, NDR_OUT, r);
2374
if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
2379
blob = ndr_push_blob(push);
2380
if (!prs_copy_data_in(&p->out_data.rdata, (const char *)blob.data, (uint32_t)blob.length)) {
2390
static bool api_spoolss_AddForm(pipes_struct *p)
2392
const struct ndr_interface_call *call;
2393
struct ndr_pull *pull;
2394
struct ndr_push *push;
2395
enum ndr_err_code ndr_err;
2397
struct spoolss_AddForm *r;
2399
call = &ndr_table_spoolss.calls[NDR_SPOOLSS_ADDFORM];
2401
r = talloc(talloc_tos(), struct spoolss_AddForm);
2406
if (!prs_data_blob(&p->in_data.data, &blob, r)) {
2411
pull = ndr_pull_init_blob(&blob, r, NULL);
2417
pull->flags |= LIBNDR_FLAG_REF_ALLOC;
2418
ndr_err = call->ndr_pull(pull, NDR_IN, r);
2419
if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
2424
if (DEBUGLEVEL >= 10) {
2425
NDR_PRINT_IN_DEBUG(spoolss_AddForm, r);
2428
r->out.result = _spoolss_AddForm(p, r);
2430
if (p->rng_fault_state) {
2432
/* Return true here, srv_pipe_hnd.c will take care */
2436
if (DEBUGLEVEL >= 10) {
2437
NDR_PRINT_OUT_DEBUG(spoolss_AddForm, r);
2440
push = ndr_push_init_ctx(r, NULL);
2446
ndr_err = call->ndr_push(push, NDR_OUT, r);
2447
if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
2452
blob = ndr_push_blob(push);
2453
if (!prs_copy_data_in(&p->out_data.rdata, (const char *)blob.data, (uint32_t)blob.length)) {
2463
static bool api_spoolss_DeleteForm(pipes_struct *p)
2465
const struct ndr_interface_call *call;
2466
struct ndr_pull *pull;
2467
struct ndr_push *push;
2468
enum ndr_err_code ndr_err;
2470
struct spoolss_DeleteForm *r;
2472
call = &ndr_table_spoolss.calls[NDR_SPOOLSS_DELETEFORM];
2474
r = talloc(talloc_tos(), struct spoolss_DeleteForm);
2479
if (!prs_data_blob(&p->in_data.data, &blob, r)) {
2484
pull = ndr_pull_init_blob(&blob, r, NULL);
2490
pull->flags |= LIBNDR_FLAG_REF_ALLOC;
2491
ndr_err = call->ndr_pull(pull, NDR_IN, r);
2492
if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
2497
if (DEBUGLEVEL >= 10) {
2498
NDR_PRINT_IN_DEBUG(spoolss_DeleteForm, r);
2501
r->out.result = _spoolss_DeleteForm(p, r);
2503
if (p->rng_fault_state) {
2505
/* Return true here, srv_pipe_hnd.c will take care */
2509
if (DEBUGLEVEL >= 10) {
2510
NDR_PRINT_OUT_DEBUG(spoolss_DeleteForm, r);
2513
push = ndr_push_init_ctx(r, NULL);
2519
ndr_err = call->ndr_push(push, NDR_OUT, r);
2520
if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
2525
blob = ndr_push_blob(push);
2526
if (!prs_copy_data_in(&p->out_data.rdata, (const char *)blob.data, (uint32_t)blob.length)) {
2536
static bool api_spoolss_GetForm(pipes_struct *p)
2538
const struct ndr_interface_call *call;
2539
struct ndr_pull *pull;
2540
struct ndr_push *push;
2541
enum ndr_err_code ndr_err;
2543
struct spoolss_GetForm *r;
2545
call = &ndr_table_spoolss.calls[NDR_SPOOLSS_GETFORM];
2547
r = talloc(talloc_tos(), struct spoolss_GetForm);
2552
if (!prs_data_blob(&p->in_data.data, &blob, r)) {
2557
pull = ndr_pull_init_blob(&blob, r, NULL);
2563
pull->flags |= LIBNDR_FLAG_REF_ALLOC;
2564
ndr_err = call->ndr_pull(pull, NDR_IN, r);
2565
if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
2570
if (DEBUGLEVEL >= 10) {
2571
NDR_PRINT_IN_DEBUG(spoolss_GetForm, r);
2574
ZERO_STRUCT(r->out);
2575
r->out.info = talloc_zero(r, union spoolss_FormInfo);
2576
if (r->out.info == NULL) {
2581
r->out.needed = talloc_zero(r, uint32_t);
2582
if (r->out.needed == NULL) {
2587
r->out.result = _spoolss_GetForm(p, r);
2589
if (p->rng_fault_state) {
2591
/* Return true here, srv_pipe_hnd.c will take care */
2595
if (DEBUGLEVEL >= 10) {
2596
NDR_PRINT_OUT_DEBUG(spoolss_GetForm, r);
2599
push = ndr_push_init_ctx(r, NULL);
2605
ndr_err = call->ndr_push(push, NDR_OUT, r);
2606
if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
2611
blob = ndr_push_blob(push);
2612
if (!prs_copy_data_in(&p->out_data.rdata, (const char *)blob.data, (uint32_t)blob.length)) {
2622
static bool api_spoolss_SetForm(pipes_struct *p)
2624
const struct ndr_interface_call *call;
2625
struct ndr_pull *pull;
2626
struct ndr_push *push;
2627
enum ndr_err_code ndr_err;
2629
struct spoolss_SetForm *r;
2631
call = &ndr_table_spoolss.calls[NDR_SPOOLSS_SETFORM];
2633
r = talloc(talloc_tos(), struct spoolss_SetForm);
2638
if (!prs_data_blob(&p->in_data.data, &blob, r)) {
2643
pull = ndr_pull_init_blob(&blob, r, NULL);
2649
pull->flags |= LIBNDR_FLAG_REF_ALLOC;
2650
ndr_err = call->ndr_pull(pull, NDR_IN, r);
2651
if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
2656
if (DEBUGLEVEL >= 10) {
2657
NDR_PRINT_IN_DEBUG(spoolss_SetForm, r);
2660
r->out.result = _spoolss_SetForm(p, r);
2662
if (p->rng_fault_state) {
2664
/* Return true here, srv_pipe_hnd.c will take care */
2668
if (DEBUGLEVEL >= 10) {
2669
NDR_PRINT_OUT_DEBUG(spoolss_SetForm, r);
2672
push = ndr_push_init_ctx(r, NULL);
2678
ndr_err = call->ndr_push(push, NDR_OUT, r);
2679
if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
2684
blob = ndr_push_blob(push);
2685
if (!prs_copy_data_in(&p->out_data.rdata, (const char *)blob.data, (uint32_t)blob.length)) {
2695
static bool api_spoolss_EnumForms(pipes_struct *p)
2697
const struct ndr_interface_call *call;
2698
struct ndr_pull *pull;
2699
struct ndr_push *push;
2700
enum ndr_err_code ndr_err;
2702
struct spoolss_EnumForms *r;
2704
call = &ndr_table_spoolss.calls[NDR_SPOOLSS_ENUMFORMS];
2706
r = talloc(talloc_tos(), struct spoolss_EnumForms);
2711
if (!prs_data_blob(&p->in_data.data, &blob, r)) {
2716
pull = ndr_pull_init_blob(&blob, r, NULL);
2722
pull->flags |= LIBNDR_FLAG_REF_ALLOC;
2723
ndr_err = call->ndr_pull(pull, NDR_IN, r);
2724
if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
2729
if (DEBUGLEVEL >= 10) {
2730
NDR_PRINT_IN_DEBUG(spoolss_EnumForms, r);
2733
ZERO_STRUCT(r->out);
2734
r->out.count = talloc_zero(r, uint32_t);
2735
if (r->out.count == NULL) {
2740
r->out.info = talloc_zero(r, union spoolss_FormInfo *);
2741
if (r->out.info == NULL) {
2746
r->out.needed = talloc_zero(r, uint32_t);
2747
if (r->out.needed == NULL) {
2752
r->out.result = _spoolss_EnumForms(p, r);
2754
if (p->rng_fault_state) {
2756
/* Return true here, srv_pipe_hnd.c will take care */
2760
if (DEBUGLEVEL >= 10) {
2761
NDR_PRINT_OUT_DEBUG(spoolss_EnumForms, r);
2764
push = ndr_push_init_ctx(r, NULL);
2770
ndr_err = call->ndr_push(push, NDR_OUT, r);
2771
if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
2776
blob = ndr_push_blob(push);
2777
if (!prs_copy_data_in(&p->out_data.rdata, (const char *)blob.data, (uint32_t)blob.length)) {
2787
static bool api_spoolss_EnumPorts(pipes_struct *p)
2789
const struct ndr_interface_call *call;
2790
struct ndr_pull *pull;
2791
struct ndr_push *push;
2792
enum ndr_err_code ndr_err;
2794
struct spoolss_EnumPorts *r;
2796
call = &ndr_table_spoolss.calls[NDR_SPOOLSS_ENUMPORTS];
2798
r = talloc(talloc_tos(), struct spoolss_EnumPorts);
2803
if (!prs_data_blob(&p->in_data.data, &blob, r)) {
2808
pull = ndr_pull_init_blob(&blob, r, NULL);
2814
pull->flags |= LIBNDR_FLAG_REF_ALLOC;
2815
ndr_err = call->ndr_pull(pull, NDR_IN, r);
2816
if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
2821
if (DEBUGLEVEL >= 10) {
2822
NDR_PRINT_IN_DEBUG(spoolss_EnumPorts, r);
2825
ZERO_STRUCT(r->out);
2826
r->out.count = talloc_zero(r, uint32_t);
2827
if (r->out.count == NULL) {
2832
r->out.info = talloc_zero(r, union spoolss_PortInfo *);
2833
if (r->out.info == NULL) {
2838
r->out.needed = talloc_zero(r, uint32_t);
2839
if (r->out.needed == NULL) {
2844
r->out.result = _spoolss_EnumPorts(p, r);
2846
if (p->rng_fault_state) {
2848
/* Return true here, srv_pipe_hnd.c will take care */
2852
if (DEBUGLEVEL >= 10) {
2853
NDR_PRINT_OUT_DEBUG(spoolss_EnumPorts, r);
2856
push = ndr_push_init_ctx(r, NULL);
2862
ndr_err = call->ndr_push(push, NDR_OUT, r);
2863
if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
2868
blob = ndr_push_blob(push);
2869
if (!prs_copy_data_in(&p->out_data.rdata, (const char *)blob.data, (uint32_t)blob.length)) {
2879
static bool api_spoolss_EnumMonitors(pipes_struct *p)
2881
const struct ndr_interface_call *call;
2882
struct ndr_pull *pull;
2883
struct ndr_push *push;
2884
enum ndr_err_code ndr_err;
2886
struct spoolss_EnumMonitors *r;
2888
call = &ndr_table_spoolss.calls[NDR_SPOOLSS_ENUMMONITORS];
2890
r = talloc(talloc_tos(), struct spoolss_EnumMonitors);
2895
if (!prs_data_blob(&p->in_data.data, &blob, r)) {
2900
pull = ndr_pull_init_blob(&blob, r, NULL);
2906
pull->flags |= LIBNDR_FLAG_REF_ALLOC;
2907
ndr_err = call->ndr_pull(pull, NDR_IN, r);
2908
if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
2913
if (DEBUGLEVEL >= 10) {
2914
NDR_PRINT_IN_DEBUG(spoolss_EnumMonitors, r);
2917
ZERO_STRUCT(r->out);
2918
r->out.count = talloc_zero(r, uint32_t);
2919
if (r->out.count == NULL) {
2924
r->out.info = talloc_zero(r, union spoolss_MonitorInfo *);
2925
if (r->out.info == NULL) {
2930
r->out.needed = talloc_zero(r, uint32_t);
2931
if (r->out.needed == NULL) {
2936
r->out.result = _spoolss_EnumMonitors(p, r);
2938
if (p->rng_fault_state) {
2940
/* Return true here, srv_pipe_hnd.c will take care */
2944
if (DEBUGLEVEL >= 10) {
2945
NDR_PRINT_OUT_DEBUG(spoolss_EnumMonitors, r);
2948
push = ndr_push_init_ctx(r, NULL);
2954
ndr_err = call->ndr_push(push, NDR_OUT, r);
2955
if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
2960
blob = ndr_push_blob(push);
2961
if (!prs_copy_data_in(&p->out_data.rdata, (const char *)blob.data, (uint32_t)blob.length)) {
2971
static bool api_spoolss_AddPort(pipes_struct *p)
2973
const struct ndr_interface_call *call;
2974
struct ndr_pull *pull;
2975
struct ndr_push *push;
2976
enum ndr_err_code ndr_err;
2978
struct spoolss_AddPort *r;
2980
call = &ndr_table_spoolss.calls[NDR_SPOOLSS_ADDPORT];
2982
r = talloc(talloc_tos(), struct spoolss_AddPort);
2987
if (!prs_data_blob(&p->in_data.data, &blob, r)) {
2992
pull = ndr_pull_init_blob(&blob, r, NULL);
2998
pull->flags |= LIBNDR_FLAG_REF_ALLOC;
2999
ndr_err = call->ndr_pull(pull, NDR_IN, r);
3000
if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
3005
if (DEBUGLEVEL >= 10) {
3006
NDR_PRINT_IN_DEBUG(spoolss_AddPort, r);
3009
r->out.result = _spoolss_AddPort(p, r);
3011
if (p->rng_fault_state) {
3013
/* Return true here, srv_pipe_hnd.c will take care */
3017
if (DEBUGLEVEL >= 10) {
3018
NDR_PRINT_OUT_DEBUG(spoolss_AddPort, r);
3021
push = ndr_push_init_ctx(r, NULL);
3027
ndr_err = call->ndr_push(push, NDR_OUT, r);
3028
if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
3033
blob = ndr_push_blob(push);
3034
if (!prs_copy_data_in(&p->out_data.rdata, (const char *)blob.data, (uint32_t)blob.length)) {
3044
static bool api_spoolss_ConfigurePort(pipes_struct *p)
3046
const struct ndr_interface_call *call;
3047
struct ndr_pull *pull;
3048
struct ndr_push *push;
3049
enum ndr_err_code ndr_err;
3051
struct spoolss_ConfigurePort *r;
3053
call = &ndr_table_spoolss.calls[NDR_SPOOLSS_CONFIGUREPORT];
3055
r = talloc(talloc_tos(), struct spoolss_ConfigurePort);
3060
if (!prs_data_blob(&p->in_data.data, &blob, r)) {
3065
pull = ndr_pull_init_blob(&blob, r, NULL);
3071
pull->flags |= LIBNDR_FLAG_REF_ALLOC;
3072
ndr_err = call->ndr_pull(pull, NDR_IN, r);
3073
if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
3078
if (DEBUGLEVEL >= 10) {
3079
NDR_PRINT_IN_DEBUG(spoolss_ConfigurePort, r);
3082
r->out.result = _spoolss_ConfigurePort(p, r);
3084
if (p->rng_fault_state) {
3086
/* Return true here, srv_pipe_hnd.c will take care */
3090
if (DEBUGLEVEL >= 10) {
3091
NDR_PRINT_OUT_DEBUG(spoolss_ConfigurePort, r);
3094
push = ndr_push_init_ctx(r, NULL);
3100
ndr_err = call->ndr_push(push, NDR_OUT, r);
3101
if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
3106
blob = ndr_push_blob(push);
3107
if (!prs_copy_data_in(&p->out_data.rdata, (const char *)blob.data, (uint32_t)blob.length)) {
3117
static bool api_spoolss_DeletePort(pipes_struct *p)
3119
const struct ndr_interface_call *call;
3120
struct ndr_pull *pull;
3121
struct ndr_push *push;
3122
enum ndr_err_code ndr_err;
3124
struct spoolss_DeletePort *r;
3126
call = &ndr_table_spoolss.calls[NDR_SPOOLSS_DELETEPORT];
3128
r = talloc(talloc_tos(), struct spoolss_DeletePort);
3133
if (!prs_data_blob(&p->in_data.data, &blob, r)) {
3138
pull = ndr_pull_init_blob(&blob, r, NULL);
3144
pull->flags |= LIBNDR_FLAG_REF_ALLOC;
3145
ndr_err = call->ndr_pull(pull, NDR_IN, r);
3146
if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
3151
if (DEBUGLEVEL >= 10) {
3152
NDR_PRINT_IN_DEBUG(spoolss_DeletePort, r);
3155
r->out.result = _spoolss_DeletePort(p, r);
3157
if (p->rng_fault_state) {
3159
/* Return true here, srv_pipe_hnd.c will take care */
3163
if (DEBUGLEVEL >= 10) {
3164
NDR_PRINT_OUT_DEBUG(spoolss_DeletePort, r);
3167
push = ndr_push_init_ctx(r, NULL);
3173
ndr_err = call->ndr_push(push, NDR_OUT, r);
3174
if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
3179
blob = ndr_push_blob(push);
3180
if (!prs_copy_data_in(&p->out_data.rdata, (const char *)blob.data, (uint32_t)blob.length)) {
3190
static bool api_spoolss_CreatePrinterIC(pipes_struct *p)
3192
const struct ndr_interface_call *call;
3193
struct ndr_pull *pull;
3194
struct ndr_push *push;
3195
enum ndr_err_code ndr_err;
3197
struct spoolss_CreatePrinterIC *r;
3199
call = &ndr_table_spoolss.calls[NDR_SPOOLSS_CREATEPRINTERIC];
3201
r = talloc(talloc_tos(), struct spoolss_CreatePrinterIC);
3206
if (!prs_data_blob(&p->in_data.data, &blob, r)) {
3211
pull = ndr_pull_init_blob(&blob, r, NULL);
3217
pull->flags |= LIBNDR_FLAG_REF_ALLOC;
3218
ndr_err = call->ndr_pull(pull, NDR_IN, r);
3219
if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
3224
if (DEBUGLEVEL >= 10) {
3225
NDR_PRINT_IN_DEBUG(spoolss_CreatePrinterIC, r);
3228
r->out.result = _spoolss_CreatePrinterIC(p, r);
3230
if (p->rng_fault_state) {
3232
/* Return true here, srv_pipe_hnd.c will take care */
3236
if (DEBUGLEVEL >= 10) {
3237
NDR_PRINT_OUT_DEBUG(spoolss_CreatePrinterIC, r);
3240
push = ndr_push_init_ctx(r, NULL);
3246
ndr_err = call->ndr_push(push, NDR_OUT, r);
3247
if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
3252
blob = ndr_push_blob(push);
3253
if (!prs_copy_data_in(&p->out_data.rdata, (const char *)blob.data, (uint32_t)blob.length)) {
3263
static bool api_spoolss_PlayGDIScriptOnPrinterIC(pipes_struct *p)
3265
const struct ndr_interface_call *call;
3266
struct ndr_pull *pull;
3267
struct ndr_push *push;
3268
enum ndr_err_code ndr_err;
3270
struct spoolss_PlayGDIScriptOnPrinterIC *r;
3272
call = &ndr_table_spoolss.calls[NDR_SPOOLSS_PLAYGDISCRIPTONPRINTERIC];
3274
r = talloc(talloc_tos(), struct spoolss_PlayGDIScriptOnPrinterIC);
3279
if (!prs_data_blob(&p->in_data.data, &blob, r)) {
3284
pull = ndr_pull_init_blob(&blob, r, NULL);
3290
pull->flags |= LIBNDR_FLAG_REF_ALLOC;
3291
ndr_err = call->ndr_pull(pull, NDR_IN, r);
3292
if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
3297
if (DEBUGLEVEL >= 10) {
3298
NDR_PRINT_IN_DEBUG(spoolss_PlayGDIScriptOnPrinterIC, r);
3301
r->out.result = _spoolss_PlayGDIScriptOnPrinterIC(p, r);
3303
if (p->rng_fault_state) {
3305
/* Return true here, srv_pipe_hnd.c will take care */
3309
if (DEBUGLEVEL >= 10) {
3310
NDR_PRINT_OUT_DEBUG(spoolss_PlayGDIScriptOnPrinterIC, r);
3313
push = ndr_push_init_ctx(r, NULL);
3319
ndr_err = call->ndr_push(push, NDR_OUT, r);
3320
if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
3325
blob = ndr_push_blob(push);
3326
if (!prs_copy_data_in(&p->out_data.rdata, (const char *)blob.data, (uint32_t)blob.length)) {
3336
static bool api_spoolss_DeletePrinterIC(pipes_struct *p)
3338
const struct ndr_interface_call *call;
3339
struct ndr_pull *pull;
3340
struct ndr_push *push;
3341
enum ndr_err_code ndr_err;
3343
struct spoolss_DeletePrinterIC *r;
3345
call = &ndr_table_spoolss.calls[NDR_SPOOLSS_DELETEPRINTERIC];
3347
r = talloc(talloc_tos(), struct spoolss_DeletePrinterIC);
3352
if (!prs_data_blob(&p->in_data.data, &blob, r)) {
3357
pull = ndr_pull_init_blob(&blob, r, NULL);
3363
pull->flags |= LIBNDR_FLAG_REF_ALLOC;
3364
ndr_err = call->ndr_pull(pull, NDR_IN, r);
3365
if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
3370
if (DEBUGLEVEL >= 10) {
3371
NDR_PRINT_IN_DEBUG(spoolss_DeletePrinterIC, r);
3374
r->out.result = _spoolss_DeletePrinterIC(p, r);
3376
if (p->rng_fault_state) {
3378
/* Return true here, srv_pipe_hnd.c will take care */
3382
if (DEBUGLEVEL >= 10) {
3383
NDR_PRINT_OUT_DEBUG(spoolss_DeletePrinterIC, r);
3386
push = ndr_push_init_ctx(r, NULL);
3392
ndr_err = call->ndr_push(push, NDR_OUT, r);
3393
if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
3398
blob = ndr_push_blob(push);
3399
if (!prs_copy_data_in(&p->out_data.rdata, (const char *)blob.data, (uint32_t)blob.length)) {
3409
static bool api_spoolss_AddPrinterConnection(pipes_struct *p)
3411
const struct ndr_interface_call *call;
3412
struct ndr_pull *pull;
3413
struct ndr_push *push;
3414
enum ndr_err_code ndr_err;
3416
struct spoolss_AddPrinterConnection *r;
3418
call = &ndr_table_spoolss.calls[NDR_SPOOLSS_ADDPRINTERCONNECTION];
3420
r = talloc(talloc_tos(), struct spoolss_AddPrinterConnection);
3425
if (!prs_data_blob(&p->in_data.data, &blob, r)) {
3430
pull = ndr_pull_init_blob(&blob, r, NULL);
3436
pull->flags |= LIBNDR_FLAG_REF_ALLOC;
3437
ndr_err = call->ndr_pull(pull, NDR_IN, r);
3438
if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
3443
if (DEBUGLEVEL >= 10) {
3444
NDR_PRINT_IN_DEBUG(spoolss_AddPrinterConnection, r);
3447
r->out.result = _spoolss_AddPrinterConnection(p, r);
3449
if (p->rng_fault_state) {
3451
/* Return true here, srv_pipe_hnd.c will take care */
3455
if (DEBUGLEVEL >= 10) {
3456
NDR_PRINT_OUT_DEBUG(spoolss_AddPrinterConnection, r);
3459
push = ndr_push_init_ctx(r, NULL);
3465
ndr_err = call->ndr_push(push, NDR_OUT, r);
3466
if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
3471
blob = ndr_push_blob(push);
3472
if (!prs_copy_data_in(&p->out_data.rdata, (const char *)blob.data, (uint32_t)blob.length)) {
3482
static bool api_spoolss_DeletePrinterConnection(pipes_struct *p)
3484
const struct ndr_interface_call *call;
3485
struct ndr_pull *pull;
3486
struct ndr_push *push;
3487
enum ndr_err_code ndr_err;
3489
struct spoolss_DeletePrinterConnection *r;
3491
call = &ndr_table_spoolss.calls[NDR_SPOOLSS_DELETEPRINTERCONNECTION];
3493
r = talloc(talloc_tos(), struct spoolss_DeletePrinterConnection);
3498
if (!prs_data_blob(&p->in_data.data, &blob, r)) {
3503
pull = ndr_pull_init_blob(&blob, r, NULL);
3509
pull->flags |= LIBNDR_FLAG_REF_ALLOC;
3510
ndr_err = call->ndr_pull(pull, NDR_IN, r);
3511
if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
3516
if (DEBUGLEVEL >= 10) {
3517
NDR_PRINT_IN_DEBUG(spoolss_DeletePrinterConnection, r);
3520
r->out.result = _spoolss_DeletePrinterConnection(p, r);
3522
if (p->rng_fault_state) {
3524
/* Return true here, srv_pipe_hnd.c will take care */
3528
if (DEBUGLEVEL >= 10) {
3529
NDR_PRINT_OUT_DEBUG(spoolss_DeletePrinterConnection, r);
3532
push = ndr_push_init_ctx(r, NULL);
3538
ndr_err = call->ndr_push(push, NDR_OUT, r);
3539
if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
3544
blob = ndr_push_blob(push);
3545
if (!prs_copy_data_in(&p->out_data.rdata, (const char *)blob.data, (uint32_t)blob.length)) {
3555
static bool api_spoolss_PrinterMessageBox(pipes_struct *p)
3557
const struct ndr_interface_call *call;
3558
struct ndr_pull *pull;
3559
struct ndr_push *push;
3560
enum ndr_err_code ndr_err;
3562
struct spoolss_PrinterMessageBox *r;
3564
call = &ndr_table_spoolss.calls[NDR_SPOOLSS_PRINTERMESSAGEBOX];
3566
r = talloc(talloc_tos(), struct spoolss_PrinterMessageBox);
3571
if (!prs_data_blob(&p->in_data.data, &blob, r)) {
3576
pull = ndr_pull_init_blob(&blob, r, NULL);
3582
pull->flags |= LIBNDR_FLAG_REF_ALLOC;
3583
ndr_err = call->ndr_pull(pull, NDR_IN, r);
3584
if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
3589
if (DEBUGLEVEL >= 10) {
3590
NDR_PRINT_IN_DEBUG(spoolss_PrinterMessageBox, r);
3593
r->out.result = _spoolss_PrinterMessageBox(p, r);
3595
if (p->rng_fault_state) {
3597
/* Return true here, srv_pipe_hnd.c will take care */
3601
if (DEBUGLEVEL >= 10) {
3602
NDR_PRINT_OUT_DEBUG(spoolss_PrinterMessageBox, r);
3605
push = ndr_push_init_ctx(r, NULL);
3611
ndr_err = call->ndr_push(push, NDR_OUT, r);
3612
if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
3617
blob = ndr_push_blob(push);
3618
if (!prs_copy_data_in(&p->out_data.rdata, (const char *)blob.data, (uint32_t)blob.length)) {
3628
static bool api_spoolss_AddMonitor(pipes_struct *p)
3630
const struct ndr_interface_call *call;
3631
struct ndr_pull *pull;
3632
struct ndr_push *push;
3633
enum ndr_err_code ndr_err;
3635
struct spoolss_AddMonitor *r;
3637
call = &ndr_table_spoolss.calls[NDR_SPOOLSS_ADDMONITOR];
3639
r = talloc(talloc_tos(), struct spoolss_AddMonitor);
3644
if (!prs_data_blob(&p->in_data.data, &blob, r)) {
3649
pull = ndr_pull_init_blob(&blob, r, NULL);
3655
pull->flags |= LIBNDR_FLAG_REF_ALLOC;
3656
ndr_err = call->ndr_pull(pull, NDR_IN, r);
3657
if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
3662
if (DEBUGLEVEL >= 10) {
3663
NDR_PRINT_IN_DEBUG(spoolss_AddMonitor, r);
3666
r->out.result = _spoolss_AddMonitor(p, r);
3668
if (p->rng_fault_state) {
3670
/* Return true here, srv_pipe_hnd.c will take care */
3674
if (DEBUGLEVEL >= 10) {
3675
NDR_PRINT_OUT_DEBUG(spoolss_AddMonitor, r);
3678
push = ndr_push_init_ctx(r, NULL);
3684
ndr_err = call->ndr_push(push, NDR_OUT, r);
3685
if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
3690
blob = ndr_push_blob(push);
3691
if (!prs_copy_data_in(&p->out_data.rdata, (const char *)blob.data, (uint32_t)blob.length)) {
3701
static bool api_spoolss_DeleteMonitor(pipes_struct *p)
3703
const struct ndr_interface_call *call;
3704
struct ndr_pull *pull;
3705
struct ndr_push *push;
3706
enum ndr_err_code ndr_err;
3708
struct spoolss_DeleteMonitor *r;
3710
call = &ndr_table_spoolss.calls[NDR_SPOOLSS_DELETEMONITOR];
3712
r = talloc(talloc_tos(), struct spoolss_DeleteMonitor);
3717
if (!prs_data_blob(&p->in_data.data, &blob, r)) {
3722
pull = ndr_pull_init_blob(&blob, r, NULL);
3728
pull->flags |= LIBNDR_FLAG_REF_ALLOC;
3729
ndr_err = call->ndr_pull(pull, NDR_IN, r);
3730
if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
3735
if (DEBUGLEVEL >= 10) {
3736
NDR_PRINT_IN_DEBUG(spoolss_DeleteMonitor, r);
3739
r->out.result = _spoolss_DeleteMonitor(p, r);
3741
if (p->rng_fault_state) {
3743
/* Return true here, srv_pipe_hnd.c will take care */
3747
if (DEBUGLEVEL >= 10) {
3748
NDR_PRINT_OUT_DEBUG(spoolss_DeleteMonitor, r);
3751
push = ndr_push_init_ctx(r, NULL);
3757
ndr_err = call->ndr_push(push, NDR_OUT, r);
3758
if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
3763
blob = ndr_push_blob(push);
3764
if (!prs_copy_data_in(&p->out_data.rdata, (const char *)blob.data, (uint32_t)blob.length)) {
3774
static bool api_spoolss_DeletePrintProcessor(pipes_struct *p)
3776
const struct ndr_interface_call *call;
3777
struct ndr_pull *pull;
3778
struct ndr_push *push;
3779
enum ndr_err_code ndr_err;
3781
struct spoolss_DeletePrintProcessor *r;
3783
call = &ndr_table_spoolss.calls[NDR_SPOOLSS_DELETEPRINTPROCESSOR];
3785
r = talloc(talloc_tos(), struct spoolss_DeletePrintProcessor);
3790
if (!prs_data_blob(&p->in_data.data, &blob, r)) {
3795
pull = ndr_pull_init_blob(&blob, r, NULL);
3801
pull->flags |= LIBNDR_FLAG_REF_ALLOC;
3802
ndr_err = call->ndr_pull(pull, NDR_IN, r);
3803
if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
3808
if (DEBUGLEVEL >= 10) {
3809
NDR_PRINT_IN_DEBUG(spoolss_DeletePrintProcessor, r);
3812
r->out.result = _spoolss_DeletePrintProcessor(p, r);
3814
if (p->rng_fault_state) {
3816
/* Return true here, srv_pipe_hnd.c will take care */
3820
if (DEBUGLEVEL >= 10) {
3821
NDR_PRINT_OUT_DEBUG(spoolss_DeletePrintProcessor, r);
3824
push = ndr_push_init_ctx(r, NULL);
3830
ndr_err = call->ndr_push(push, NDR_OUT, r);
3831
if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
3836
blob = ndr_push_blob(push);
3837
if (!prs_copy_data_in(&p->out_data.rdata, (const char *)blob.data, (uint32_t)blob.length)) {
3847
static bool api_spoolss_AddPrintProvidor(pipes_struct *p)
3849
const struct ndr_interface_call *call;
3850
struct ndr_pull *pull;
3851
struct ndr_push *push;
3852
enum ndr_err_code ndr_err;
3854
struct spoolss_AddPrintProvidor *r;
3856
call = &ndr_table_spoolss.calls[NDR_SPOOLSS_ADDPRINTPROVIDOR];
3858
r = talloc(talloc_tos(), struct spoolss_AddPrintProvidor);
3863
if (!prs_data_blob(&p->in_data.data, &blob, r)) {
3868
pull = ndr_pull_init_blob(&blob, r, NULL);
3874
pull->flags |= LIBNDR_FLAG_REF_ALLOC;
3875
ndr_err = call->ndr_pull(pull, NDR_IN, r);
3876
if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
3881
if (DEBUGLEVEL >= 10) {
3882
NDR_PRINT_IN_DEBUG(spoolss_AddPrintProvidor, r);
3885
r->out.result = _spoolss_AddPrintProvidor(p, r);
3887
if (p->rng_fault_state) {
3889
/* Return true here, srv_pipe_hnd.c will take care */
3893
if (DEBUGLEVEL >= 10) {
3894
NDR_PRINT_OUT_DEBUG(spoolss_AddPrintProvidor, r);
3897
push = ndr_push_init_ctx(r, NULL);
3903
ndr_err = call->ndr_push(push, NDR_OUT, r);
3904
if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
3909
blob = ndr_push_blob(push);
3910
if (!prs_copy_data_in(&p->out_data.rdata, (const char *)blob.data, (uint32_t)blob.length)) {
3920
static bool api_spoolss_DeletePrintProvidor(pipes_struct *p)
3922
const struct ndr_interface_call *call;
3923
struct ndr_pull *pull;
3924
struct ndr_push *push;
3925
enum ndr_err_code ndr_err;
3927
struct spoolss_DeletePrintProvidor *r;
3929
call = &ndr_table_spoolss.calls[NDR_SPOOLSS_DELETEPRINTPROVIDOR];
3931
r = talloc(talloc_tos(), struct spoolss_DeletePrintProvidor);
3936
if (!prs_data_blob(&p->in_data.data, &blob, r)) {
3941
pull = ndr_pull_init_blob(&blob, r, NULL);
3947
pull->flags |= LIBNDR_FLAG_REF_ALLOC;
3948
ndr_err = call->ndr_pull(pull, NDR_IN, r);
3949
if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
3954
if (DEBUGLEVEL >= 10) {
3955
NDR_PRINT_IN_DEBUG(spoolss_DeletePrintProvidor, r);
3958
r->out.result = _spoolss_DeletePrintProvidor(p, r);
3960
if (p->rng_fault_state) {
3962
/* Return true here, srv_pipe_hnd.c will take care */
3966
if (DEBUGLEVEL >= 10) {
3967
NDR_PRINT_OUT_DEBUG(spoolss_DeletePrintProvidor, r);
3970
push = ndr_push_init_ctx(r, NULL);
3976
ndr_err = call->ndr_push(push, NDR_OUT, r);
3977
if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
3982
blob = ndr_push_blob(push);
3983
if (!prs_copy_data_in(&p->out_data.rdata, (const char *)blob.data, (uint32_t)blob.length)) {
3993
static bool api_spoolss_EnumPrintProcDataTypes(pipes_struct *p)
3995
const struct ndr_interface_call *call;
3996
struct ndr_pull *pull;
3997
struct ndr_push *push;
3998
enum ndr_err_code ndr_err;
4000
struct spoolss_EnumPrintProcDataTypes *r;
4002
call = &ndr_table_spoolss.calls[NDR_SPOOLSS_ENUMPRINTPROCDATATYPES];
4004
r = talloc(talloc_tos(), struct spoolss_EnumPrintProcDataTypes);
4009
if (!prs_data_blob(&p->in_data.data, &blob, r)) {
4014
pull = ndr_pull_init_blob(&blob, r, NULL);
4020
pull->flags |= LIBNDR_FLAG_REF_ALLOC;
4021
ndr_err = call->ndr_pull(pull, NDR_IN, r);
4022
if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
4027
if (DEBUGLEVEL >= 10) {
4028
NDR_PRINT_IN_DEBUG(spoolss_EnumPrintProcDataTypes, r);
4031
ZERO_STRUCT(r->out);
4032
r->out.count = talloc_zero(r, uint32_t);
4033
if (r->out.count == NULL) {
4038
r->out.info = talloc_zero(r, union spoolss_PrintProcDataTypesInfo *);
4039
if (r->out.info == NULL) {
4044
r->out.needed = talloc_zero(r, uint32_t);
4045
if (r->out.needed == NULL) {
4050
r->out.result = _spoolss_EnumPrintProcDataTypes(p, r);
4052
if (p->rng_fault_state) {
4054
/* Return true here, srv_pipe_hnd.c will take care */
4058
if (DEBUGLEVEL >= 10) {
4059
NDR_PRINT_OUT_DEBUG(spoolss_EnumPrintProcDataTypes, r);
4062
push = ndr_push_init_ctx(r, NULL);
4068
ndr_err = call->ndr_push(push, NDR_OUT, r);
4069
if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
4074
blob = ndr_push_blob(push);
4075
if (!prs_copy_data_in(&p->out_data.rdata, (const char *)blob.data, (uint32_t)blob.length)) {
4085
static bool api_spoolss_ResetPrinter(pipes_struct *p)
4087
const struct ndr_interface_call *call;
4088
struct ndr_pull *pull;
4089
struct ndr_push *push;
4090
enum ndr_err_code ndr_err;
4092
struct spoolss_ResetPrinter *r;
4094
call = &ndr_table_spoolss.calls[NDR_SPOOLSS_RESETPRINTER];
4096
r = talloc(talloc_tos(), struct spoolss_ResetPrinter);
4101
if (!prs_data_blob(&p->in_data.data, &blob, r)) {
4106
pull = ndr_pull_init_blob(&blob, r, NULL);
4112
pull->flags |= LIBNDR_FLAG_REF_ALLOC;
4113
ndr_err = call->ndr_pull(pull, NDR_IN, r);
4114
if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
4119
if (DEBUGLEVEL >= 10) {
4120
NDR_PRINT_IN_DEBUG(spoolss_ResetPrinter, r);
4123
r->out.result = _spoolss_ResetPrinter(p, r);
4125
if (p->rng_fault_state) {
4127
/* Return true here, srv_pipe_hnd.c will take care */
4131
if (DEBUGLEVEL >= 10) {
4132
NDR_PRINT_OUT_DEBUG(spoolss_ResetPrinter, r);
4135
push = ndr_push_init_ctx(r, NULL);
4141
ndr_err = call->ndr_push(push, NDR_OUT, r);
4142
if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
4147
blob = ndr_push_blob(push);
4148
if (!prs_copy_data_in(&p->out_data.rdata, (const char *)blob.data, (uint32_t)blob.length)) {
4158
static bool api_spoolss_GetPrinterDriver2(pipes_struct *p)
4160
const struct ndr_interface_call *call;
4161
struct ndr_pull *pull;
4162
struct ndr_push *push;
4163
enum ndr_err_code ndr_err;
4165
struct spoolss_GetPrinterDriver2 *r;
4167
call = &ndr_table_spoolss.calls[NDR_SPOOLSS_GETPRINTERDRIVER2];
4169
r = talloc(talloc_tos(), struct spoolss_GetPrinterDriver2);
4174
if (!prs_data_blob(&p->in_data.data, &blob, r)) {
4179
pull = ndr_pull_init_blob(&blob, r, NULL);
4185
pull->flags |= LIBNDR_FLAG_REF_ALLOC;
4186
ndr_err = call->ndr_pull(pull, NDR_IN, r);
4187
if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
4192
if (DEBUGLEVEL >= 10) {
4193
NDR_PRINT_IN_DEBUG(spoolss_GetPrinterDriver2, r);
4196
ZERO_STRUCT(r->out);
4197
r->out.info = talloc_zero(r, union spoolss_DriverInfo);
4198
if (r->out.info == NULL) {
4203
r->out.needed = talloc_zero(r, uint32_t);
4204
if (r->out.needed == NULL) {
4209
r->out.server_major_version = talloc_zero(r, uint32_t);
4210
if (r->out.server_major_version == NULL) {
4215
r->out.server_minor_version = talloc_zero(r, uint32_t);
4216
if (r->out.server_minor_version == NULL) {
4221
r->out.result = _spoolss_GetPrinterDriver2(p, r);
4223
if (p->rng_fault_state) {
4225
/* Return true here, srv_pipe_hnd.c will take care */
4229
if (DEBUGLEVEL >= 10) {
4230
NDR_PRINT_OUT_DEBUG(spoolss_GetPrinterDriver2, r);
4233
push = ndr_push_init_ctx(r, NULL);
4239
ndr_err = call->ndr_push(push, NDR_OUT, r);
4240
if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
4245
blob = ndr_push_blob(push);
4246
if (!prs_copy_data_in(&p->out_data.rdata, (const char *)blob.data, (uint32_t)blob.length)) {
4256
static bool api_spoolss_FindFirstPrinterChangeNotification(pipes_struct *p)
4258
const struct ndr_interface_call *call;
4259
struct ndr_pull *pull;
4260
struct ndr_push *push;
4261
enum ndr_err_code ndr_err;
4263
struct spoolss_FindFirstPrinterChangeNotification *r;
4265
call = &ndr_table_spoolss.calls[NDR_SPOOLSS_FINDFIRSTPRINTERCHANGENOTIFICATION];
4267
r = talloc(talloc_tos(), struct spoolss_FindFirstPrinterChangeNotification);
4272
if (!prs_data_blob(&p->in_data.data, &blob, r)) {
4277
pull = ndr_pull_init_blob(&blob, r, NULL);
4283
pull->flags |= LIBNDR_FLAG_REF_ALLOC;
4284
ndr_err = call->ndr_pull(pull, NDR_IN, r);
4285
if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
4290
if (DEBUGLEVEL >= 10) {
4291
NDR_PRINT_IN_DEBUG(spoolss_FindFirstPrinterChangeNotification, r);
4294
r->out.result = _spoolss_FindFirstPrinterChangeNotification(p, r);
4296
if (p->rng_fault_state) {
4298
/* Return true here, srv_pipe_hnd.c will take care */
4302
if (DEBUGLEVEL >= 10) {
4303
NDR_PRINT_OUT_DEBUG(spoolss_FindFirstPrinterChangeNotification, r);
4306
push = ndr_push_init_ctx(r, NULL);
4312
ndr_err = call->ndr_push(push, NDR_OUT, r);
4313
if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
4318
blob = ndr_push_blob(push);
4319
if (!prs_copy_data_in(&p->out_data.rdata, (const char *)blob.data, (uint32_t)blob.length)) {
4329
static bool api_spoolss_FindNextPrinterChangeNotification(pipes_struct *p)
4331
const struct ndr_interface_call *call;
4332
struct ndr_pull *pull;
4333
struct ndr_push *push;
4334
enum ndr_err_code ndr_err;
4336
struct spoolss_FindNextPrinterChangeNotification *r;
4338
call = &ndr_table_spoolss.calls[NDR_SPOOLSS_FINDNEXTPRINTERCHANGENOTIFICATION];
4340
r = talloc(talloc_tos(), struct spoolss_FindNextPrinterChangeNotification);
4345
if (!prs_data_blob(&p->in_data.data, &blob, r)) {
4350
pull = ndr_pull_init_blob(&blob, r, NULL);
4356
pull->flags |= LIBNDR_FLAG_REF_ALLOC;
4357
ndr_err = call->ndr_pull(pull, NDR_IN, r);
4358
if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
4363
if (DEBUGLEVEL >= 10) {
4364
NDR_PRINT_IN_DEBUG(spoolss_FindNextPrinterChangeNotification, r);
4367
r->out.result = _spoolss_FindNextPrinterChangeNotification(p, r);
4369
if (p->rng_fault_state) {
4371
/* Return true here, srv_pipe_hnd.c will take care */
4375
if (DEBUGLEVEL >= 10) {
4376
NDR_PRINT_OUT_DEBUG(spoolss_FindNextPrinterChangeNotification, r);
4379
push = ndr_push_init_ctx(r, NULL);
4385
ndr_err = call->ndr_push(push, NDR_OUT, r);
4386
if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
4391
blob = ndr_push_blob(push);
4392
if (!prs_copy_data_in(&p->out_data.rdata, (const char *)blob.data, (uint32_t)blob.length)) {
4402
static bool api_spoolss_FindClosePrinterNotify(pipes_struct *p)
4404
const struct ndr_interface_call *call;
4405
struct ndr_pull *pull;
4406
struct ndr_push *push;
4407
enum ndr_err_code ndr_err;
4409
struct spoolss_FindClosePrinterNotify *r;
4411
call = &ndr_table_spoolss.calls[NDR_SPOOLSS_FINDCLOSEPRINTERNOTIFY];
4413
r = talloc(talloc_tos(), struct spoolss_FindClosePrinterNotify);
4418
if (!prs_data_blob(&p->in_data.data, &blob, r)) {
4423
pull = ndr_pull_init_blob(&blob, r, NULL);
4429
pull->flags |= LIBNDR_FLAG_REF_ALLOC;
4430
ndr_err = call->ndr_pull(pull, NDR_IN, r);
4431
if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
4436
if (DEBUGLEVEL >= 10) {
4437
NDR_PRINT_IN_DEBUG(spoolss_FindClosePrinterNotify, r);
4440
r->out.result = _spoolss_FindClosePrinterNotify(p, r);
4442
if (p->rng_fault_state) {
4444
/* Return true here, srv_pipe_hnd.c will take care */
4448
if (DEBUGLEVEL >= 10) {
4449
NDR_PRINT_OUT_DEBUG(spoolss_FindClosePrinterNotify, r);
4452
push = ndr_push_init_ctx(r, NULL);
4458
ndr_err = call->ndr_push(push, NDR_OUT, r);
4459
if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
4464
blob = ndr_push_blob(push);
4465
if (!prs_copy_data_in(&p->out_data.rdata, (const char *)blob.data, (uint32_t)blob.length)) {
4475
static bool api_spoolss_RouterFindFirstPrinterChangeNotificationOld(pipes_struct *p)
4477
const struct ndr_interface_call *call;
4478
struct ndr_pull *pull;
4479
struct ndr_push *push;
4480
enum ndr_err_code ndr_err;
4482
struct spoolss_RouterFindFirstPrinterChangeNotificationOld *r;
4484
call = &ndr_table_spoolss.calls[NDR_SPOOLSS_ROUTERFINDFIRSTPRINTERCHANGENOTIFICATIONOLD];
4486
r = talloc(talloc_tos(), struct spoolss_RouterFindFirstPrinterChangeNotificationOld);
4491
if (!prs_data_blob(&p->in_data.data, &blob, r)) {
4496
pull = ndr_pull_init_blob(&blob, r, NULL);
4502
pull->flags |= LIBNDR_FLAG_REF_ALLOC;
4503
ndr_err = call->ndr_pull(pull, NDR_IN, r);
4504
if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
4509
if (DEBUGLEVEL >= 10) {
4510
NDR_PRINT_IN_DEBUG(spoolss_RouterFindFirstPrinterChangeNotificationOld, r);
4513
r->out.result = _spoolss_RouterFindFirstPrinterChangeNotificationOld(p, r);
4515
if (p->rng_fault_state) {
4517
/* Return true here, srv_pipe_hnd.c will take care */
4521
if (DEBUGLEVEL >= 10) {
4522
NDR_PRINT_OUT_DEBUG(spoolss_RouterFindFirstPrinterChangeNotificationOld, r);
4525
push = ndr_push_init_ctx(r, NULL);
4531
ndr_err = call->ndr_push(push, NDR_OUT, r);
4532
if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
4537
blob = ndr_push_blob(push);
4538
if (!prs_copy_data_in(&p->out_data.rdata, (const char *)blob.data, (uint32_t)blob.length)) {
4548
static bool api_spoolss_ReplyOpenPrinter(pipes_struct *p)
4550
const struct ndr_interface_call *call;
4551
struct ndr_pull *pull;
4552
struct ndr_push *push;
4553
enum ndr_err_code ndr_err;
4555
struct spoolss_ReplyOpenPrinter *r;
4557
call = &ndr_table_spoolss.calls[NDR_SPOOLSS_REPLYOPENPRINTER];
4559
r = talloc(talloc_tos(), struct spoolss_ReplyOpenPrinter);
4564
if (!prs_data_blob(&p->in_data.data, &blob, r)) {
4569
pull = ndr_pull_init_blob(&blob, r, NULL);
4575
pull->flags |= LIBNDR_FLAG_REF_ALLOC;
4576
ndr_err = call->ndr_pull(pull, NDR_IN, r);
4577
if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
4582
if (DEBUGLEVEL >= 10) {
4583
NDR_PRINT_IN_DEBUG(spoolss_ReplyOpenPrinter, r);
4586
ZERO_STRUCT(r->out);
4587
r->out.handle = talloc_zero(r, struct policy_handle);
4588
if (r->out.handle == NULL) {
4593
r->out.result = _spoolss_ReplyOpenPrinter(p, r);
4595
if (p->rng_fault_state) {
4597
/* Return true here, srv_pipe_hnd.c will take care */
4601
if (DEBUGLEVEL >= 10) {
4602
NDR_PRINT_OUT_DEBUG(spoolss_ReplyOpenPrinter, r);
4605
push = ndr_push_init_ctx(r, NULL);
4611
ndr_err = call->ndr_push(push, NDR_OUT, r);
4612
if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
4617
blob = ndr_push_blob(push);
4618
if (!prs_copy_data_in(&p->out_data.rdata, (const char *)blob.data, (uint32_t)blob.length)) {
4628
static bool api_spoolss_RouterReplyPrinter(pipes_struct *p)
4630
const struct ndr_interface_call *call;
4631
struct ndr_pull *pull;
4632
struct ndr_push *push;
4633
enum ndr_err_code ndr_err;
4635
struct spoolss_RouterReplyPrinter *r;
4637
call = &ndr_table_spoolss.calls[NDR_SPOOLSS_ROUTERREPLYPRINTER];
4639
r = talloc(talloc_tos(), struct spoolss_RouterReplyPrinter);
4644
if (!prs_data_blob(&p->in_data.data, &blob, r)) {
4649
pull = ndr_pull_init_blob(&blob, r, NULL);
4655
pull->flags |= LIBNDR_FLAG_REF_ALLOC;
4656
ndr_err = call->ndr_pull(pull, NDR_IN, r);
4657
if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
4662
if (DEBUGLEVEL >= 10) {
4663
NDR_PRINT_IN_DEBUG(spoolss_RouterReplyPrinter, r);
4666
r->out.result = _spoolss_RouterReplyPrinter(p, r);
4668
if (p->rng_fault_state) {
4670
/* Return true here, srv_pipe_hnd.c will take care */
4674
if (DEBUGLEVEL >= 10) {
4675
NDR_PRINT_OUT_DEBUG(spoolss_RouterReplyPrinter, r);
4678
push = ndr_push_init_ctx(r, NULL);
4684
ndr_err = call->ndr_push(push, NDR_OUT, r);
4685
if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
4690
blob = ndr_push_blob(push);
4691
if (!prs_copy_data_in(&p->out_data.rdata, (const char *)blob.data, (uint32_t)blob.length)) {
4701
static bool api_spoolss_ReplyClosePrinter(pipes_struct *p)
4703
const struct ndr_interface_call *call;
4704
struct ndr_pull *pull;
4705
struct ndr_push *push;
4706
enum ndr_err_code ndr_err;
4708
struct spoolss_ReplyClosePrinter *r;
4710
call = &ndr_table_spoolss.calls[NDR_SPOOLSS_REPLYCLOSEPRINTER];
4712
r = talloc(talloc_tos(), struct spoolss_ReplyClosePrinter);
4717
if (!prs_data_blob(&p->in_data.data, &blob, r)) {
4722
pull = ndr_pull_init_blob(&blob, r, NULL);
4728
pull->flags |= LIBNDR_FLAG_REF_ALLOC;
4729
ndr_err = call->ndr_pull(pull, NDR_IN, r);
4730
if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
4735
if (DEBUGLEVEL >= 10) {
4736
NDR_PRINT_IN_DEBUG(spoolss_ReplyClosePrinter, r);
4739
ZERO_STRUCT(r->out);
4740
r->out.handle = r->in.handle;
4741
r->out.result = _spoolss_ReplyClosePrinter(p, r);
4743
if (p->rng_fault_state) {
4745
/* Return true here, srv_pipe_hnd.c will take care */
4749
if (DEBUGLEVEL >= 10) {
4750
NDR_PRINT_OUT_DEBUG(spoolss_ReplyClosePrinter, r);
4753
push = ndr_push_init_ctx(r, NULL);
4759
ndr_err = call->ndr_push(push, NDR_OUT, r);
4760
if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
4765
blob = ndr_push_blob(push);
4766
if (!prs_copy_data_in(&p->out_data.rdata, (const char *)blob.data, (uint32_t)blob.length)) {
4776
static bool api_spoolss_AddPortEx(pipes_struct *p)
4778
const struct ndr_interface_call *call;
4779
struct ndr_pull *pull;
4780
struct ndr_push *push;
4781
enum ndr_err_code ndr_err;
4783
struct spoolss_AddPortEx *r;
4785
call = &ndr_table_spoolss.calls[NDR_SPOOLSS_ADDPORTEX];
4787
r = talloc(talloc_tos(), struct spoolss_AddPortEx);
4792
if (!prs_data_blob(&p->in_data.data, &blob, r)) {
4797
pull = ndr_pull_init_blob(&blob, r, NULL);
4803
pull->flags |= LIBNDR_FLAG_REF_ALLOC;
4804
ndr_err = call->ndr_pull(pull, NDR_IN, r);
4805
if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
4810
if (DEBUGLEVEL >= 10) {
4811
NDR_PRINT_IN_DEBUG(spoolss_AddPortEx, r);
4814
r->out.result = _spoolss_AddPortEx(p, r);
4816
if (p->rng_fault_state) {
4818
/* Return true here, srv_pipe_hnd.c will take care */
4822
if (DEBUGLEVEL >= 10) {
4823
NDR_PRINT_OUT_DEBUG(spoolss_AddPortEx, r);
4826
push = ndr_push_init_ctx(r, NULL);
4832
ndr_err = call->ndr_push(push, NDR_OUT, r);
4833
if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
4838
blob = ndr_push_blob(push);
4839
if (!prs_copy_data_in(&p->out_data.rdata, (const char *)blob.data, (uint32_t)blob.length)) {
4849
static bool api_spoolss_RouterFindFirstPrinterChangeNotification(pipes_struct *p)
4851
const struct ndr_interface_call *call;
4852
struct ndr_pull *pull;
4853
struct ndr_push *push;
4854
enum ndr_err_code ndr_err;
4856
struct spoolss_RouterFindFirstPrinterChangeNotification *r;
4858
call = &ndr_table_spoolss.calls[NDR_SPOOLSS_ROUTERFINDFIRSTPRINTERCHANGENOTIFICATION];
4860
r = talloc(talloc_tos(), struct spoolss_RouterFindFirstPrinterChangeNotification);
4865
if (!prs_data_blob(&p->in_data.data, &blob, r)) {
4870
pull = ndr_pull_init_blob(&blob, r, NULL);
4876
pull->flags |= LIBNDR_FLAG_REF_ALLOC;
4877
ndr_err = call->ndr_pull(pull, NDR_IN, r);
4878
if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
4883
if (DEBUGLEVEL >= 10) {
4884
NDR_PRINT_IN_DEBUG(spoolss_RouterFindFirstPrinterChangeNotification, r);
4887
r->out.result = _spoolss_RouterFindFirstPrinterChangeNotification(p, r);
4889
if (p->rng_fault_state) {
4891
/* Return true here, srv_pipe_hnd.c will take care */
4895
if (DEBUGLEVEL >= 10) {
4896
NDR_PRINT_OUT_DEBUG(spoolss_RouterFindFirstPrinterChangeNotification, r);
4899
push = ndr_push_init_ctx(r, NULL);
4905
ndr_err = call->ndr_push(push, NDR_OUT, r);
4906
if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
4911
blob = ndr_push_blob(push);
4912
if (!prs_copy_data_in(&p->out_data.rdata, (const char *)blob.data, (uint32_t)blob.length)) {
4922
static bool api_spoolss_SpoolerInit(pipes_struct *p)
4924
const struct ndr_interface_call *call;
4925
struct ndr_pull *pull;
4926
struct ndr_push *push;
4927
enum ndr_err_code ndr_err;
4929
struct spoolss_SpoolerInit *r;
4931
call = &ndr_table_spoolss.calls[NDR_SPOOLSS_SPOOLERINIT];
4933
r = talloc(talloc_tos(), struct spoolss_SpoolerInit);
4938
if (!prs_data_blob(&p->in_data.data, &blob, r)) {
4943
pull = ndr_pull_init_blob(&blob, r, NULL);
4949
pull->flags |= LIBNDR_FLAG_REF_ALLOC;
4950
ndr_err = call->ndr_pull(pull, NDR_IN, r);
4951
if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
4956
if (DEBUGLEVEL >= 10) {
4957
NDR_PRINT_IN_DEBUG(spoolss_SpoolerInit, r);
4960
r->out.result = _spoolss_SpoolerInit(p, r);
4962
if (p->rng_fault_state) {
4964
/* Return true here, srv_pipe_hnd.c will take care */
4968
if (DEBUGLEVEL >= 10) {
4969
NDR_PRINT_OUT_DEBUG(spoolss_SpoolerInit, r);
4972
push = ndr_push_init_ctx(r, NULL);
4978
ndr_err = call->ndr_push(push, NDR_OUT, r);
4979
if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
4984
blob = ndr_push_blob(push);
4985
if (!prs_copy_data_in(&p->out_data.rdata, (const char *)blob.data, (uint32_t)blob.length)) {
4995
static bool api_spoolss_ResetPrinterEx(pipes_struct *p)
4997
const struct ndr_interface_call *call;
4998
struct ndr_pull *pull;
4999
struct ndr_push *push;
5000
enum ndr_err_code ndr_err;
5002
struct spoolss_ResetPrinterEx *r;
5004
call = &ndr_table_spoolss.calls[NDR_SPOOLSS_RESETPRINTEREX];
5006
r = talloc(talloc_tos(), struct spoolss_ResetPrinterEx);
5011
if (!prs_data_blob(&p->in_data.data, &blob, r)) {
5016
pull = ndr_pull_init_blob(&blob, r, NULL);
5022
pull->flags |= LIBNDR_FLAG_REF_ALLOC;
5023
ndr_err = call->ndr_pull(pull, NDR_IN, r);
5024
if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
5029
if (DEBUGLEVEL >= 10) {
5030
NDR_PRINT_IN_DEBUG(spoolss_ResetPrinterEx, r);
5033
r->out.result = _spoolss_ResetPrinterEx(p, r);
5035
if (p->rng_fault_state) {
5037
/* Return true here, srv_pipe_hnd.c will take care */
5041
if (DEBUGLEVEL >= 10) {
5042
NDR_PRINT_OUT_DEBUG(spoolss_ResetPrinterEx, r);
5045
push = ndr_push_init_ctx(r, NULL);
5051
ndr_err = call->ndr_push(push, NDR_OUT, r);
5052
if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
5057
blob = ndr_push_blob(push);
5058
if (!prs_copy_data_in(&p->out_data.rdata, (const char *)blob.data, (uint32_t)blob.length)) {
5068
static bool api_spoolss_RemoteFindFirstPrinterChangeNotifyEx(pipes_struct *p)
5070
const struct ndr_interface_call *call;
5071
struct ndr_pull *pull;
5072
struct ndr_push *push;
5073
enum ndr_err_code ndr_err;
5075
struct spoolss_RemoteFindFirstPrinterChangeNotifyEx *r;
5077
call = &ndr_table_spoolss.calls[NDR_SPOOLSS_REMOTEFINDFIRSTPRINTERCHANGENOTIFYEX];
5079
r = talloc(talloc_tos(), struct spoolss_RemoteFindFirstPrinterChangeNotifyEx);
5084
if (!prs_data_blob(&p->in_data.data, &blob, r)) {
5089
pull = ndr_pull_init_blob(&blob, r, NULL);
5095
pull->flags |= LIBNDR_FLAG_REF_ALLOC;
5096
ndr_err = call->ndr_pull(pull, NDR_IN, r);
5097
if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
5102
if (DEBUGLEVEL >= 10) {
5103
NDR_PRINT_IN_DEBUG(spoolss_RemoteFindFirstPrinterChangeNotifyEx, r);
5106
r->out.result = _spoolss_RemoteFindFirstPrinterChangeNotifyEx(p, r);
5108
if (p->rng_fault_state) {
5110
/* Return true here, srv_pipe_hnd.c will take care */
5114
if (DEBUGLEVEL >= 10) {
5115
NDR_PRINT_OUT_DEBUG(spoolss_RemoteFindFirstPrinterChangeNotifyEx, r);
5118
push = ndr_push_init_ctx(r, NULL);
5124
ndr_err = call->ndr_push(push, NDR_OUT, r);
5125
if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
5130
blob = ndr_push_blob(push);
5131
if (!prs_copy_data_in(&p->out_data.rdata, (const char *)blob.data, (uint32_t)blob.length)) {
5141
static bool api_spoolss_RouterReplyPrinterEx(pipes_struct *p)
5143
const struct ndr_interface_call *call;
5144
struct ndr_pull *pull;
5145
struct ndr_push *push;
5146
enum ndr_err_code ndr_err;
5148
struct spoolss_RouterReplyPrinterEx *r;
5150
call = &ndr_table_spoolss.calls[NDR_SPOOLSS_ROUTERREPLYPRINTEREX];
5152
r = talloc(talloc_tos(), struct spoolss_RouterReplyPrinterEx);
5157
if (!prs_data_blob(&p->in_data.data, &blob, r)) {
5162
pull = ndr_pull_init_blob(&blob, r, NULL);
5168
pull->flags |= LIBNDR_FLAG_REF_ALLOC;
5169
ndr_err = call->ndr_pull(pull, NDR_IN, r);
5170
if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
5175
if (DEBUGLEVEL >= 10) {
5176
NDR_PRINT_IN_DEBUG(spoolss_RouterReplyPrinterEx, r);
5179
ZERO_STRUCT(r->out);
5180
r->out.reply_result = talloc_zero(r, uint32_t);
5181
if (r->out.reply_result == NULL) {
5186
r->out.result = _spoolss_RouterReplyPrinterEx(p, r);
5188
if (p->rng_fault_state) {
5190
/* Return true here, srv_pipe_hnd.c will take care */
5194
if (DEBUGLEVEL >= 10) {
5195
NDR_PRINT_OUT_DEBUG(spoolss_RouterReplyPrinterEx, r);
5198
push = ndr_push_init_ctx(r, NULL);
5204
ndr_err = call->ndr_push(push, NDR_OUT, r);
5205
if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
5210
blob = ndr_push_blob(push);
5211
if (!prs_copy_data_in(&p->out_data.rdata, (const char *)blob.data, (uint32_t)blob.length)) {
5221
static bool api_spoolss_RouterRefreshPrinterChangeNotify(pipes_struct *p)
5223
const struct ndr_interface_call *call;
5224
struct ndr_pull *pull;
5225
struct ndr_push *push;
5226
enum ndr_err_code ndr_err;
5228
struct spoolss_RouterRefreshPrinterChangeNotify *r;
5230
call = &ndr_table_spoolss.calls[NDR_SPOOLSS_ROUTERREFRESHPRINTERCHANGENOTIFY];
5232
r = talloc(talloc_tos(), struct spoolss_RouterRefreshPrinterChangeNotify);
5237
if (!prs_data_blob(&p->in_data.data, &blob, r)) {
5242
pull = ndr_pull_init_blob(&blob, r, NULL);
5248
pull->flags |= LIBNDR_FLAG_REF_ALLOC;
5249
ndr_err = call->ndr_pull(pull, NDR_IN, r);
5250
if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
5255
if (DEBUGLEVEL >= 10) {
5256
NDR_PRINT_IN_DEBUG(spoolss_RouterRefreshPrinterChangeNotify, r);
5259
ZERO_STRUCT(r->out);
5260
r->out.info = talloc_zero(r, struct spoolss_NotifyInfo *);
5261
if (r->out.info == NULL) {
5266
r->out.result = _spoolss_RouterRefreshPrinterChangeNotify(p, r);
5268
if (p->rng_fault_state) {
5270
/* Return true here, srv_pipe_hnd.c will take care */
5274
if (DEBUGLEVEL >= 10) {
5275
NDR_PRINT_OUT_DEBUG(spoolss_RouterRefreshPrinterChangeNotify, r);
5278
push = ndr_push_init_ctx(r, NULL);
5284
ndr_err = call->ndr_push(push, NDR_OUT, r);
5285
if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
5290
blob = ndr_push_blob(push);
5291
if (!prs_copy_data_in(&p->out_data.rdata, (const char *)blob.data, (uint32_t)blob.length)) {
5301
static bool api_spoolss_44(pipes_struct *p)
5303
const struct ndr_interface_call *call;
5304
struct ndr_pull *pull;
5305
struct ndr_push *push;
5306
enum ndr_err_code ndr_err;
5308
struct spoolss_44 *r;
5310
call = &ndr_table_spoolss.calls[NDR_SPOOLSS_44];
5312
r = talloc(talloc_tos(), struct spoolss_44);
5317
if (!prs_data_blob(&p->in_data.data, &blob, r)) {
5322
pull = ndr_pull_init_blob(&blob, r, NULL);
5328
pull->flags |= LIBNDR_FLAG_REF_ALLOC;
5329
ndr_err = call->ndr_pull(pull, NDR_IN, r);
5330
if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
5335
if (DEBUGLEVEL >= 10) {
5336
NDR_PRINT_IN_DEBUG(spoolss_44, r);
5339
r->out.result = _spoolss_44(p, r);
5341
if (p->rng_fault_state) {
5343
/* Return true here, srv_pipe_hnd.c will take care */
5347
if (DEBUGLEVEL >= 10) {
5348
NDR_PRINT_OUT_DEBUG(spoolss_44, r);
5351
push = ndr_push_init_ctx(r, NULL);
5357
ndr_err = call->ndr_push(push, NDR_OUT, r);
5358
if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
5363
blob = ndr_push_blob(push);
5364
if (!prs_copy_data_in(&p->out_data.rdata, (const char *)blob.data, (uint32_t)blob.length)) {
5374
static bool api_spoolss_OpenPrinterEx(pipes_struct *p)
5376
const struct ndr_interface_call *call;
5377
struct ndr_pull *pull;
5378
struct ndr_push *push;
5379
enum ndr_err_code ndr_err;
5381
struct spoolss_OpenPrinterEx *r;
5383
call = &ndr_table_spoolss.calls[NDR_SPOOLSS_OPENPRINTEREX];
5385
r = talloc(talloc_tos(), struct spoolss_OpenPrinterEx);
5390
if (!prs_data_blob(&p->in_data.data, &blob, r)) {
5395
pull = ndr_pull_init_blob(&blob, r, NULL);
5401
pull->flags |= LIBNDR_FLAG_REF_ALLOC;
5402
ndr_err = call->ndr_pull(pull, NDR_IN, r);
5403
if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
5408
if (DEBUGLEVEL >= 10) {
5409
NDR_PRINT_IN_DEBUG(spoolss_OpenPrinterEx, r);
5412
ZERO_STRUCT(r->out);
5413
r->out.handle = talloc_zero(r, struct policy_handle);
5414
if (r->out.handle == NULL) {
5419
r->out.result = _spoolss_OpenPrinterEx(p, r);
5421
if (p->rng_fault_state) {
5423
/* Return true here, srv_pipe_hnd.c will take care */
5427
if (DEBUGLEVEL >= 10) {
5428
NDR_PRINT_OUT_DEBUG(spoolss_OpenPrinterEx, r);
5431
push = ndr_push_init_ctx(r, NULL);
5437
ndr_err = call->ndr_push(push, NDR_OUT, r);
5438
if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
5443
blob = ndr_push_blob(push);
5444
if (!prs_copy_data_in(&p->out_data.rdata, (const char *)blob.data, (uint32_t)blob.length)) {
5454
static bool api_spoolss_AddPrinterEx(pipes_struct *p)
5456
const struct ndr_interface_call *call;
5457
struct ndr_pull *pull;
5458
struct ndr_push *push;
5459
enum ndr_err_code ndr_err;
5461
struct spoolss_AddPrinterEx *r;
5463
call = &ndr_table_spoolss.calls[NDR_SPOOLSS_ADDPRINTEREX];
5465
r = talloc(talloc_tos(), struct spoolss_AddPrinterEx);
5470
if (!prs_data_blob(&p->in_data.data, &blob, r)) {
5475
pull = ndr_pull_init_blob(&blob, r, NULL);
5481
pull->flags |= LIBNDR_FLAG_REF_ALLOC;
5482
ndr_err = call->ndr_pull(pull, NDR_IN, r);
5483
if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
5488
if (DEBUGLEVEL >= 10) {
5489
NDR_PRINT_IN_DEBUG(spoolss_AddPrinterEx, r);
5492
ZERO_STRUCT(r->out);
5493
r->out.handle = talloc_zero(r, struct policy_handle);
5494
if (r->out.handle == NULL) {
5499
r->out.result = _spoolss_AddPrinterEx(p, r);
5501
if (p->rng_fault_state) {
5503
/* Return true here, srv_pipe_hnd.c will take care */
5507
if (DEBUGLEVEL >= 10) {
5508
NDR_PRINT_OUT_DEBUG(spoolss_AddPrinterEx, r);
5511
push = ndr_push_init_ctx(r, NULL);
5517
ndr_err = call->ndr_push(push, NDR_OUT, r);
5518
if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
5523
blob = ndr_push_blob(push);
5524
if (!prs_copy_data_in(&p->out_data.rdata, (const char *)blob.data, (uint32_t)blob.length)) {
5534
static bool api_spoolss_47(pipes_struct *p)
5536
const struct ndr_interface_call *call;
5537
struct ndr_pull *pull;
5538
struct ndr_push *push;
5539
enum ndr_err_code ndr_err;
5541
struct spoolss_47 *r;
5543
call = &ndr_table_spoolss.calls[NDR_SPOOLSS_47];
5545
r = talloc(talloc_tos(), struct spoolss_47);
5550
if (!prs_data_blob(&p->in_data.data, &blob, r)) {
5555
pull = ndr_pull_init_blob(&blob, r, NULL);
5561
pull->flags |= LIBNDR_FLAG_REF_ALLOC;
5562
ndr_err = call->ndr_pull(pull, NDR_IN, r);
5563
if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
5568
if (DEBUGLEVEL >= 10) {
5569
NDR_PRINT_IN_DEBUG(spoolss_47, r);
5572
r->out.result = _spoolss_47(p, r);
5574
if (p->rng_fault_state) {
5576
/* Return true here, srv_pipe_hnd.c will take care */
5580
if (DEBUGLEVEL >= 10) {
5581
NDR_PRINT_OUT_DEBUG(spoolss_47, r);
5584
push = ndr_push_init_ctx(r, NULL);
5590
ndr_err = call->ndr_push(push, NDR_OUT, r);
5591
if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
5596
blob = ndr_push_blob(push);
5597
if (!prs_copy_data_in(&p->out_data.rdata, (const char *)blob.data, (uint32_t)blob.length)) {
5607
static bool api_spoolss_EnumPrinterData(pipes_struct *p)
5609
const struct ndr_interface_call *call;
5610
struct ndr_pull *pull;
5611
struct ndr_push *push;
5612
enum ndr_err_code ndr_err;
5614
struct spoolss_EnumPrinterData *r;
5616
call = &ndr_table_spoolss.calls[NDR_SPOOLSS_ENUMPRINTERDATA];
5618
r = talloc(talloc_tos(), struct spoolss_EnumPrinterData);
5623
if (!prs_data_blob(&p->in_data.data, &blob, r)) {
5628
pull = ndr_pull_init_blob(&blob, r, NULL);
5634
pull->flags |= LIBNDR_FLAG_REF_ALLOC;
5635
ndr_err = call->ndr_pull(pull, NDR_IN, r);
5636
if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
5641
if (DEBUGLEVEL >= 10) {
5642
NDR_PRINT_IN_DEBUG(spoolss_EnumPrinterData, r);
5645
ZERO_STRUCT(r->out);
5646
r->out.value_name = talloc_zero_array(r, const char, r->in.value_offered / 2);
5647
if (r->out.value_name == NULL) {
5652
r->out.value_needed = talloc_zero(r, uint32_t);
5653
if (r->out.value_needed == NULL) {
5658
r->out.type = talloc_zero(r, enum winreg_Type);
5659
if (r->out.type == NULL) {
5664
r->out.data = talloc_zero_array(r, uint8_t, r->in.data_offered);
5665
if (r->out.data == NULL) {
5670
r->out.data_needed = talloc_zero(r, uint32_t);
5671
if (r->out.data_needed == NULL) {
5676
r->out.result = _spoolss_EnumPrinterData(p, r);
5678
if (p->rng_fault_state) {
5680
/* Return true here, srv_pipe_hnd.c will take care */
5684
if (DEBUGLEVEL >= 10) {
5685
NDR_PRINT_OUT_DEBUG(spoolss_EnumPrinterData, r);
5688
push = ndr_push_init_ctx(r, NULL);
5694
ndr_err = call->ndr_push(push, NDR_OUT, r);
5695
if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
5700
blob = ndr_push_blob(push);
5701
if (!prs_copy_data_in(&p->out_data.rdata, (const char *)blob.data, (uint32_t)blob.length)) {
5711
static bool api_spoolss_DeletePrinterData(pipes_struct *p)
5713
const struct ndr_interface_call *call;
5714
struct ndr_pull *pull;
5715
struct ndr_push *push;
5716
enum ndr_err_code ndr_err;
5718
struct spoolss_DeletePrinterData *r;
5720
call = &ndr_table_spoolss.calls[NDR_SPOOLSS_DELETEPRINTERDATA];
5722
r = talloc(talloc_tos(), struct spoolss_DeletePrinterData);
5727
if (!prs_data_blob(&p->in_data.data, &blob, r)) {
5732
pull = ndr_pull_init_blob(&blob, r, NULL);
5738
pull->flags |= LIBNDR_FLAG_REF_ALLOC;
5739
ndr_err = call->ndr_pull(pull, NDR_IN, r);
5740
if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
5745
if (DEBUGLEVEL >= 10) {
5746
NDR_PRINT_IN_DEBUG(spoolss_DeletePrinterData, r);
5749
r->out.result = _spoolss_DeletePrinterData(p, r);
5751
if (p->rng_fault_state) {
5753
/* Return true here, srv_pipe_hnd.c will take care */
5757
if (DEBUGLEVEL >= 10) {
5758
NDR_PRINT_OUT_DEBUG(spoolss_DeletePrinterData, r);
5761
push = ndr_push_init_ctx(r, NULL);
5767
ndr_err = call->ndr_push(push, NDR_OUT, r);
5768
if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
5773
blob = ndr_push_blob(push);
5774
if (!prs_copy_data_in(&p->out_data.rdata, (const char *)blob.data, (uint32_t)blob.length)) {
5784
static bool api_spoolss_4a(pipes_struct *p)
5786
const struct ndr_interface_call *call;
5787
struct ndr_pull *pull;
5788
struct ndr_push *push;
5789
enum ndr_err_code ndr_err;
5791
struct spoolss_4a *r;
5793
call = &ndr_table_spoolss.calls[NDR_SPOOLSS_4A];
5795
r = talloc(talloc_tos(), struct spoolss_4a);
5800
if (!prs_data_blob(&p->in_data.data, &blob, r)) {
5805
pull = ndr_pull_init_blob(&blob, r, NULL);
5811
pull->flags |= LIBNDR_FLAG_REF_ALLOC;
5812
ndr_err = call->ndr_pull(pull, NDR_IN, r);
5813
if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
5818
if (DEBUGLEVEL >= 10) {
5819
NDR_PRINT_IN_DEBUG(spoolss_4a, r);
5822
r->out.result = _spoolss_4a(p, r);
5824
if (p->rng_fault_state) {
5826
/* Return true here, srv_pipe_hnd.c will take care */
5830
if (DEBUGLEVEL >= 10) {
5831
NDR_PRINT_OUT_DEBUG(spoolss_4a, r);
5834
push = ndr_push_init_ctx(r, NULL);
5840
ndr_err = call->ndr_push(push, NDR_OUT, r);
5841
if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
5846
blob = ndr_push_blob(push);
5847
if (!prs_copy_data_in(&p->out_data.rdata, (const char *)blob.data, (uint32_t)blob.length)) {
5857
static bool api_spoolss_4b(pipes_struct *p)
5859
const struct ndr_interface_call *call;
5860
struct ndr_pull *pull;
5861
struct ndr_push *push;
5862
enum ndr_err_code ndr_err;
5864
struct spoolss_4b *r;
5866
call = &ndr_table_spoolss.calls[NDR_SPOOLSS_4B];
5868
r = talloc(talloc_tos(), struct spoolss_4b);
5873
if (!prs_data_blob(&p->in_data.data, &blob, r)) {
5878
pull = ndr_pull_init_blob(&blob, r, NULL);
5884
pull->flags |= LIBNDR_FLAG_REF_ALLOC;
5885
ndr_err = call->ndr_pull(pull, NDR_IN, r);
5886
if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
5891
if (DEBUGLEVEL >= 10) {
5892
NDR_PRINT_IN_DEBUG(spoolss_4b, r);
5895
r->out.result = _spoolss_4b(p, r);
5897
if (p->rng_fault_state) {
5899
/* Return true here, srv_pipe_hnd.c will take care */
5903
if (DEBUGLEVEL >= 10) {
5904
NDR_PRINT_OUT_DEBUG(spoolss_4b, r);
5907
push = ndr_push_init_ctx(r, NULL);
5913
ndr_err = call->ndr_push(push, NDR_OUT, r);
5914
if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
5919
blob = ndr_push_blob(push);
5920
if (!prs_copy_data_in(&p->out_data.rdata, (const char *)blob.data, (uint32_t)blob.length)) {
5930
static bool api_spoolss_4c(pipes_struct *p)
5932
const struct ndr_interface_call *call;
5933
struct ndr_pull *pull;
5934
struct ndr_push *push;
5935
enum ndr_err_code ndr_err;
5937
struct spoolss_4c *r;
5939
call = &ndr_table_spoolss.calls[NDR_SPOOLSS_4C];
5941
r = talloc(talloc_tos(), struct spoolss_4c);
5946
if (!prs_data_blob(&p->in_data.data, &blob, r)) {
5951
pull = ndr_pull_init_blob(&blob, r, NULL);
5957
pull->flags |= LIBNDR_FLAG_REF_ALLOC;
5958
ndr_err = call->ndr_pull(pull, NDR_IN, r);
5959
if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
5964
if (DEBUGLEVEL >= 10) {
5965
NDR_PRINT_IN_DEBUG(spoolss_4c, r);
5968
r->out.result = _spoolss_4c(p, r);
5970
if (p->rng_fault_state) {
5972
/* Return true here, srv_pipe_hnd.c will take care */
5976
if (DEBUGLEVEL >= 10) {
5977
NDR_PRINT_OUT_DEBUG(spoolss_4c, r);
5980
push = ndr_push_init_ctx(r, NULL);
5986
ndr_err = call->ndr_push(push, NDR_OUT, r);
5987
if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
5992
blob = ndr_push_blob(push);
5993
if (!prs_copy_data_in(&p->out_data.rdata, (const char *)blob.data, (uint32_t)blob.length)) {
6003
static bool api_spoolss_SetPrinterDataEx(pipes_struct *p)
6005
const struct ndr_interface_call *call;
6006
struct ndr_pull *pull;
6007
struct ndr_push *push;
6008
enum ndr_err_code ndr_err;
6010
struct spoolss_SetPrinterDataEx *r;
6012
call = &ndr_table_spoolss.calls[NDR_SPOOLSS_SETPRINTERDATAEX];
6014
r = talloc(talloc_tos(), struct spoolss_SetPrinterDataEx);
6019
if (!prs_data_blob(&p->in_data.data, &blob, r)) {
6024
pull = ndr_pull_init_blob(&blob, r, NULL);
6030
pull->flags |= LIBNDR_FLAG_REF_ALLOC;
6031
ndr_err = call->ndr_pull(pull, NDR_IN, r);
6032
if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
6037
if (DEBUGLEVEL >= 10) {
6038
NDR_PRINT_IN_DEBUG(spoolss_SetPrinterDataEx, r);
6041
r->out.result = _spoolss_SetPrinterDataEx(p, r);
6043
if (p->rng_fault_state) {
6045
/* Return true here, srv_pipe_hnd.c will take care */
6049
if (DEBUGLEVEL >= 10) {
6050
NDR_PRINT_OUT_DEBUG(spoolss_SetPrinterDataEx, r);
6053
push = ndr_push_init_ctx(r, NULL);
6059
ndr_err = call->ndr_push(push, NDR_OUT, r);
6060
if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
6065
blob = ndr_push_blob(push);
6066
if (!prs_copy_data_in(&p->out_data.rdata, (const char *)blob.data, (uint32_t)blob.length)) {
6076
static bool api_spoolss_GetPrinterDataEx(pipes_struct *p)
6078
const struct ndr_interface_call *call;
6079
struct ndr_pull *pull;
6080
struct ndr_push *push;
6081
enum ndr_err_code ndr_err;
6083
struct spoolss_GetPrinterDataEx *r;
6085
call = &ndr_table_spoolss.calls[NDR_SPOOLSS_GETPRINTERDATAEX];
6087
r = talloc(talloc_tos(), struct spoolss_GetPrinterDataEx);
6092
if (!prs_data_blob(&p->in_data.data, &blob, r)) {
6097
pull = ndr_pull_init_blob(&blob, r, NULL);
6103
pull->flags |= LIBNDR_FLAG_REF_ALLOC;
6104
ndr_err = call->ndr_pull(pull, NDR_IN, r);
6105
if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
6110
if (DEBUGLEVEL >= 10) {
6111
NDR_PRINT_IN_DEBUG(spoolss_GetPrinterDataEx, r);
6114
ZERO_STRUCT(r->out);
6115
r->out.type = talloc_zero(r, enum winreg_Type);
6116
if (r->out.type == NULL) {
6121
r->out.data = talloc_zero_array(r, uint8_t, r->in.offered);
6122
if (r->out.data == NULL) {
6127
r->out.needed = talloc_zero(r, uint32_t);
6128
if (r->out.needed == NULL) {
6133
r->out.result = _spoolss_GetPrinterDataEx(p, r);
6135
if (p->rng_fault_state) {
6137
/* Return true here, srv_pipe_hnd.c will take care */
6141
if (DEBUGLEVEL >= 10) {
6142
NDR_PRINT_OUT_DEBUG(spoolss_GetPrinterDataEx, r);
6145
push = ndr_push_init_ctx(r, NULL);
6151
ndr_err = call->ndr_push(push, NDR_OUT, r);
6152
if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
6157
blob = ndr_push_blob(push);
6158
if (!prs_copy_data_in(&p->out_data.rdata, (const char *)blob.data, (uint32_t)blob.length)) {
6168
static bool api_spoolss_EnumPrinterDataEx(pipes_struct *p)
6170
const struct ndr_interface_call *call;
6171
struct ndr_pull *pull;
6172
struct ndr_push *push;
6173
enum ndr_err_code ndr_err;
6175
struct spoolss_EnumPrinterDataEx *r;
6177
call = &ndr_table_spoolss.calls[NDR_SPOOLSS_ENUMPRINTERDATAEX];
6179
r = talloc(talloc_tos(), struct spoolss_EnumPrinterDataEx);
6184
if (!prs_data_blob(&p->in_data.data, &blob, r)) {
6189
pull = ndr_pull_init_blob(&blob, r, NULL);
6195
pull->flags |= LIBNDR_FLAG_REF_ALLOC;
6196
ndr_err = call->ndr_pull(pull, NDR_IN, r);
6197
if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
6202
if (DEBUGLEVEL >= 10) {
6203
NDR_PRINT_IN_DEBUG(spoolss_EnumPrinterDataEx, r);
6206
ZERO_STRUCT(r->out);
6207
r->out.count = talloc_zero(r, uint32_t);
6208
if (r->out.count == NULL) {
6213
r->out.info = talloc_zero(r, struct spoolss_PrinterEnumValues *);
6214
if (r->out.info == NULL) {
6219
r->out.needed = talloc_zero(r, uint32_t);
6220
if (r->out.needed == NULL) {
6225
r->out.result = _spoolss_EnumPrinterDataEx(p, r);
6227
if (p->rng_fault_state) {
6229
/* Return true here, srv_pipe_hnd.c will take care */
6233
if (DEBUGLEVEL >= 10) {
6234
NDR_PRINT_OUT_DEBUG(spoolss_EnumPrinterDataEx, r);
6237
push = ndr_push_init_ctx(r, NULL);
6243
ndr_err = call->ndr_push(push, NDR_OUT, r);
6244
if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
6249
blob = ndr_push_blob(push);
6250
if (!prs_copy_data_in(&p->out_data.rdata, (const char *)blob.data, (uint32_t)blob.length)) {
6260
static bool api_spoolss_EnumPrinterKey(pipes_struct *p)
6262
const struct ndr_interface_call *call;
6263
struct ndr_pull *pull;
6264
struct ndr_push *push;
6265
enum ndr_err_code ndr_err;
6267
struct spoolss_EnumPrinterKey *r;
6269
call = &ndr_table_spoolss.calls[NDR_SPOOLSS_ENUMPRINTERKEY];
6271
r = talloc(talloc_tos(), struct spoolss_EnumPrinterKey);
6276
if (!prs_data_blob(&p->in_data.data, &blob, r)) {
6281
pull = ndr_pull_init_blob(&blob, r, NULL);
6287
pull->flags |= LIBNDR_FLAG_REF_ALLOC;
6288
ndr_err = call->ndr_pull(pull, NDR_IN, r);
6289
if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
6294
if (DEBUGLEVEL >= 10) {
6295
NDR_PRINT_IN_DEBUG(spoolss_EnumPrinterKey, r);
6298
ZERO_STRUCT(r->out);
6299
r->out._ndr_size = talloc_zero(r, uint32_t);
6300
if (r->out._ndr_size == NULL) {
6305
r->out.key_buffer = talloc_zero(r, union spoolss_KeyNames);
6306
if (r->out.key_buffer == NULL) {
6311
r->out.needed = talloc_zero(r, uint32_t);
6312
if (r->out.needed == NULL) {
6317
r->out.result = _spoolss_EnumPrinterKey(p, r);
6319
if (p->rng_fault_state) {
6321
/* Return true here, srv_pipe_hnd.c will take care */
6325
if (DEBUGLEVEL >= 10) {
6326
NDR_PRINT_OUT_DEBUG(spoolss_EnumPrinterKey, r);
6329
push = ndr_push_init_ctx(r, NULL);
6335
ndr_err = call->ndr_push(push, NDR_OUT, r);
6336
if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
6341
blob = ndr_push_blob(push);
6342
if (!prs_copy_data_in(&p->out_data.rdata, (const char *)blob.data, (uint32_t)blob.length)) {
6352
static bool api_spoolss_DeletePrinterDataEx(pipes_struct *p)
6354
const struct ndr_interface_call *call;
6355
struct ndr_pull *pull;
6356
struct ndr_push *push;
6357
enum ndr_err_code ndr_err;
6359
struct spoolss_DeletePrinterDataEx *r;
6361
call = &ndr_table_spoolss.calls[NDR_SPOOLSS_DELETEPRINTERDATAEX];
6363
r = talloc(talloc_tos(), struct spoolss_DeletePrinterDataEx);
6368
if (!prs_data_blob(&p->in_data.data, &blob, r)) {
6373
pull = ndr_pull_init_blob(&blob, r, NULL);
6379
pull->flags |= LIBNDR_FLAG_REF_ALLOC;
6380
ndr_err = call->ndr_pull(pull, NDR_IN, r);
6381
if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
6386
if (DEBUGLEVEL >= 10) {
6387
NDR_PRINT_IN_DEBUG(spoolss_DeletePrinterDataEx, r);
6390
r->out.result = _spoolss_DeletePrinterDataEx(p, r);
6392
if (p->rng_fault_state) {
6394
/* Return true here, srv_pipe_hnd.c will take care */
6398
if (DEBUGLEVEL >= 10) {
6399
NDR_PRINT_OUT_DEBUG(spoolss_DeletePrinterDataEx, r);
6402
push = ndr_push_init_ctx(r, NULL);
6408
ndr_err = call->ndr_push(push, NDR_OUT, r);
6409
if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
6414
blob = ndr_push_blob(push);
6415
if (!prs_copy_data_in(&p->out_data.rdata, (const char *)blob.data, (uint32_t)blob.length)) {
6425
static bool api_spoolss_DeletePrinterKey(pipes_struct *p)
6427
const struct ndr_interface_call *call;
6428
struct ndr_pull *pull;
6429
struct ndr_push *push;
6430
enum ndr_err_code ndr_err;
6432
struct spoolss_DeletePrinterKey *r;
6434
call = &ndr_table_spoolss.calls[NDR_SPOOLSS_DELETEPRINTERKEY];
6436
r = talloc(talloc_tos(), struct spoolss_DeletePrinterKey);
6441
if (!prs_data_blob(&p->in_data.data, &blob, r)) {
6446
pull = ndr_pull_init_blob(&blob, r, NULL);
6452
pull->flags |= LIBNDR_FLAG_REF_ALLOC;
6453
ndr_err = call->ndr_pull(pull, NDR_IN, r);
6454
if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
6459
if (DEBUGLEVEL >= 10) {
6460
NDR_PRINT_IN_DEBUG(spoolss_DeletePrinterKey, r);
6463
r->out.result = _spoolss_DeletePrinterKey(p, r);
6465
if (p->rng_fault_state) {
6467
/* Return true here, srv_pipe_hnd.c will take care */
6471
if (DEBUGLEVEL >= 10) {
6472
NDR_PRINT_OUT_DEBUG(spoolss_DeletePrinterKey, r);
6475
push = ndr_push_init_ctx(r, NULL);
6481
ndr_err = call->ndr_push(push, NDR_OUT, r);
6482
if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
6487
blob = ndr_push_blob(push);
6488
if (!prs_copy_data_in(&p->out_data.rdata, (const char *)blob.data, (uint32_t)blob.length)) {
6498
static bool api_spoolss_53(pipes_struct *p)
6500
const struct ndr_interface_call *call;
6501
struct ndr_pull *pull;
6502
struct ndr_push *push;
6503
enum ndr_err_code ndr_err;
6505
struct spoolss_53 *r;
6507
call = &ndr_table_spoolss.calls[NDR_SPOOLSS_53];
6509
r = talloc(talloc_tos(), struct spoolss_53);
6514
if (!prs_data_blob(&p->in_data.data, &blob, r)) {
6519
pull = ndr_pull_init_blob(&blob, r, NULL);
6525
pull->flags |= LIBNDR_FLAG_REF_ALLOC;
6526
ndr_err = call->ndr_pull(pull, NDR_IN, r);
6527
if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
6532
if (DEBUGLEVEL >= 10) {
6533
NDR_PRINT_IN_DEBUG(spoolss_53, r);
6536
r->out.result = _spoolss_53(p, r);
6538
if (p->rng_fault_state) {
6540
/* Return true here, srv_pipe_hnd.c will take care */
6544
if (DEBUGLEVEL >= 10) {
6545
NDR_PRINT_OUT_DEBUG(spoolss_53, r);
6548
push = ndr_push_init_ctx(r, NULL);
6554
ndr_err = call->ndr_push(push, NDR_OUT, r);
6555
if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
6560
blob = ndr_push_blob(push);
6561
if (!prs_copy_data_in(&p->out_data.rdata, (const char *)blob.data, (uint32_t)blob.length)) {
6571
static bool api_spoolss_DeletePrinterDriverEx(pipes_struct *p)
6573
const struct ndr_interface_call *call;
6574
struct ndr_pull *pull;
6575
struct ndr_push *push;
6576
enum ndr_err_code ndr_err;
6578
struct spoolss_DeletePrinterDriverEx *r;
6580
call = &ndr_table_spoolss.calls[NDR_SPOOLSS_DELETEPRINTERDRIVEREX];
6582
r = talloc(talloc_tos(), struct spoolss_DeletePrinterDriverEx);
6587
if (!prs_data_blob(&p->in_data.data, &blob, r)) {
6592
pull = ndr_pull_init_blob(&blob, r, NULL);
6598
pull->flags |= LIBNDR_FLAG_REF_ALLOC;
6599
ndr_err = call->ndr_pull(pull, NDR_IN, r);
6600
if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
6605
if (DEBUGLEVEL >= 10) {
6606
NDR_PRINT_IN_DEBUG(spoolss_DeletePrinterDriverEx, r);
6609
r->out.result = _spoolss_DeletePrinterDriverEx(p, r);
6611
if (p->rng_fault_state) {
6613
/* Return true here, srv_pipe_hnd.c will take care */
6617
if (DEBUGLEVEL >= 10) {
6618
NDR_PRINT_OUT_DEBUG(spoolss_DeletePrinterDriverEx, r);
6621
push = ndr_push_init_ctx(r, NULL);
6627
ndr_err = call->ndr_push(push, NDR_OUT, r);
6628
if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
6633
blob = ndr_push_blob(push);
6634
if (!prs_copy_data_in(&p->out_data.rdata, (const char *)blob.data, (uint32_t)blob.length)) {
6644
static bool api_spoolss_55(pipes_struct *p)
6646
const struct ndr_interface_call *call;
6647
struct ndr_pull *pull;
6648
struct ndr_push *push;
6649
enum ndr_err_code ndr_err;
6651
struct spoolss_55 *r;
6653
call = &ndr_table_spoolss.calls[NDR_SPOOLSS_55];
6655
r = talloc(talloc_tos(), struct spoolss_55);
6660
if (!prs_data_blob(&p->in_data.data, &blob, r)) {
6665
pull = ndr_pull_init_blob(&blob, r, NULL);
6671
pull->flags |= LIBNDR_FLAG_REF_ALLOC;
6672
ndr_err = call->ndr_pull(pull, NDR_IN, r);
6673
if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
6678
if (DEBUGLEVEL >= 10) {
6679
NDR_PRINT_IN_DEBUG(spoolss_55, r);
6682
r->out.result = _spoolss_55(p, r);
6684
if (p->rng_fault_state) {
6686
/* Return true here, srv_pipe_hnd.c will take care */
6690
if (DEBUGLEVEL >= 10) {
6691
NDR_PRINT_OUT_DEBUG(spoolss_55, r);
6694
push = ndr_push_init_ctx(r, NULL);
6700
ndr_err = call->ndr_push(push, NDR_OUT, r);
6701
if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
6706
blob = ndr_push_blob(push);
6707
if (!prs_copy_data_in(&p->out_data.rdata, (const char *)blob.data, (uint32_t)blob.length)) {
6717
static bool api_spoolss_56(pipes_struct *p)
6719
const struct ndr_interface_call *call;
6720
struct ndr_pull *pull;
6721
struct ndr_push *push;
6722
enum ndr_err_code ndr_err;
6724
struct spoolss_56 *r;
6726
call = &ndr_table_spoolss.calls[NDR_SPOOLSS_56];
6728
r = talloc(talloc_tos(), struct spoolss_56);
6733
if (!prs_data_blob(&p->in_data.data, &blob, r)) {
6738
pull = ndr_pull_init_blob(&blob, r, NULL);
6744
pull->flags |= LIBNDR_FLAG_REF_ALLOC;
6745
ndr_err = call->ndr_pull(pull, NDR_IN, r);
6746
if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
6751
if (DEBUGLEVEL >= 10) {
6752
NDR_PRINT_IN_DEBUG(spoolss_56, r);
6755
r->out.result = _spoolss_56(p, r);
6757
if (p->rng_fault_state) {
6759
/* Return true here, srv_pipe_hnd.c will take care */
6763
if (DEBUGLEVEL >= 10) {
6764
NDR_PRINT_OUT_DEBUG(spoolss_56, r);
6767
push = ndr_push_init_ctx(r, NULL);
6773
ndr_err = call->ndr_push(push, NDR_OUT, r);
6774
if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
6779
blob = ndr_push_blob(push);
6780
if (!prs_copy_data_in(&p->out_data.rdata, (const char *)blob.data, (uint32_t)blob.length)) {
6790
static bool api_spoolss_57(pipes_struct *p)
6792
const struct ndr_interface_call *call;
6793
struct ndr_pull *pull;
6794
struct ndr_push *push;
6795
enum ndr_err_code ndr_err;
6797
struct spoolss_57 *r;
6799
call = &ndr_table_spoolss.calls[NDR_SPOOLSS_57];
6801
r = talloc(talloc_tos(), struct spoolss_57);
6806
if (!prs_data_blob(&p->in_data.data, &blob, r)) {
6811
pull = ndr_pull_init_blob(&blob, r, NULL);
6817
pull->flags |= LIBNDR_FLAG_REF_ALLOC;
6818
ndr_err = call->ndr_pull(pull, NDR_IN, r);
6819
if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
6824
if (DEBUGLEVEL >= 10) {
6825
NDR_PRINT_IN_DEBUG(spoolss_57, r);
6828
r->out.result = _spoolss_57(p, r);
6830
if (p->rng_fault_state) {
6832
/* Return true here, srv_pipe_hnd.c will take care */
6836
if (DEBUGLEVEL >= 10) {
6837
NDR_PRINT_OUT_DEBUG(spoolss_57, r);
6840
push = ndr_push_init_ctx(r, NULL);
6846
ndr_err = call->ndr_push(push, NDR_OUT, r);
6847
if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
6852
blob = ndr_push_blob(push);
6853
if (!prs_copy_data_in(&p->out_data.rdata, (const char *)blob.data, (uint32_t)blob.length)) {
6863
static bool api_spoolss_XcvData(pipes_struct *p)
6865
const struct ndr_interface_call *call;
6866
struct ndr_pull *pull;
6867
struct ndr_push *push;
6868
enum ndr_err_code ndr_err;
6870
struct spoolss_XcvData *r;
6872
call = &ndr_table_spoolss.calls[NDR_SPOOLSS_XCVDATA];
6874
r = talloc(talloc_tos(), struct spoolss_XcvData);
6879
if (!prs_data_blob(&p->in_data.data, &blob, r)) {
6884
pull = ndr_pull_init_blob(&blob, r, NULL);
6890
pull->flags |= LIBNDR_FLAG_REF_ALLOC;
6891
ndr_err = call->ndr_pull(pull, NDR_IN, r);
6892
if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
6897
if (DEBUGLEVEL >= 10) {
6898
NDR_PRINT_IN_DEBUG(spoolss_XcvData, r);
6901
ZERO_STRUCT(r->out);
6902
r->out.status_code = r->in.status_code;
6903
r->out.out_data = talloc_zero_array(r, uint8_t, r->in.out_data_size);
6904
if (r->out.out_data == NULL) {
6909
r->out.needed = talloc_zero(r, uint32_t);
6910
if (r->out.needed == NULL) {
6915
r->out.result = _spoolss_XcvData(p, r);
6917
if (p->rng_fault_state) {
6919
/* Return true here, srv_pipe_hnd.c will take care */
6923
if (DEBUGLEVEL >= 10) {
6924
NDR_PRINT_OUT_DEBUG(spoolss_XcvData, r);
6927
push = ndr_push_init_ctx(r, NULL);
6933
ndr_err = call->ndr_push(push, NDR_OUT, r);
6934
if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
6939
blob = ndr_push_blob(push);
6940
if (!prs_copy_data_in(&p->out_data.rdata, (const char *)blob.data, (uint32_t)blob.length)) {
6950
static bool api_spoolss_AddPrinterDriverEx(pipes_struct *p)
6952
const struct ndr_interface_call *call;
6953
struct ndr_pull *pull;
6954
struct ndr_push *push;
6955
enum ndr_err_code ndr_err;
6957
struct spoolss_AddPrinterDriverEx *r;
6959
call = &ndr_table_spoolss.calls[NDR_SPOOLSS_ADDPRINTERDRIVEREX];
6961
r = talloc(talloc_tos(), struct spoolss_AddPrinterDriverEx);
6966
if (!prs_data_blob(&p->in_data.data, &blob, r)) {
6971
pull = ndr_pull_init_blob(&blob, r, NULL);
6977
pull->flags |= LIBNDR_FLAG_REF_ALLOC;
6978
ndr_err = call->ndr_pull(pull, NDR_IN, r);
6979
if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
6984
if (DEBUGLEVEL >= 10) {
6985
NDR_PRINT_IN_DEBUG(spoolss_AddPrinterDriverEx, r);
6988
r->out.result = _spoolss_AddPrinterDriverEx(p, r);
6990
if (p->rng_fault_state) {
6992
/* Return true here, srv_pipe_hnd.c will take care */
6996
if (DEBUGLEVEL >= 10) {
6997
NDR_PRINT_OUT_DEBUG(spoolss_AddPrinterDriverEx, r);
7000
push = ndr_push_init_ctx(r, NULL);
7006
ndr_err = call->ndr_push(push, NDR_OUT, r);
7007
if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
7012
blob = ndr_push_blob(push);
7013
if (!prs_copy_data_in(&p->out_data.rdata, (const char *)blob.data, (uint32_t)blob.length)) {
7023
static bool api_spoolss_5a(pipes_struct *p)
7025
const struct ndr_interface_call *call;
7026
struct ndr_pull *pull;
7027
struct ndr_push *push;
7028
enum ndr_err_code ndr_err;
7030
struct spoolss_5a *r;
7032
call = &ndr_table_spoolss.calls[NDR_SPOOLSS_5A];
7034
r = talloc(talloc_tos(), struct spoolss_5a);
7039
if (!prs_data_blob(&p->in_data.data, &blob, r)) {
7044
pull = ndr_pull_init_blob(&blob, r, NULL);
7050
pull->flags |= LIBNDR_FLAG_REF_ALLOC;
7051
ndr_err = call->ndr_pull(pull, NDR_IN, r);
7052
if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
7057
if (DEBUGLEVEL >= 10) {
7058
NDR_PRINT_IN_DEBUG(spoolss_5a, r);
7061
r->out.result = _spoolss_5a(p, r);
7063
if (p->rng_fault_state) {
7065
/* Return true here, srv_pipe_hnd.c will take care */
7069
if (DEBUGLEVEL >= 10) {
7070
NDR_PRINT_OUT_DEBUG(spoolss_5a, r);
7073
push = ndr_push_init_ctx(r, NULL);
7079
ndr_err = call->ndr_push(push, NDR_OUT, r);
7080
if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
7085
blob = ndr_push_blob(push);
7086
if (!prs_copy_data_in(&p->out_data.rdata, (const char *)blob.data, (uint32_t)blob.length)) {
7096
static bool api_spoolss_5b(pipes_struct *p)
7098
const struct ndr_interface_call *call;
7099
struct ndr_pull *pull;
7100
struct ndr_push *push;
7101
enum ndr_err_code ndr_err;
7103
struct spoolss_5b *r;
7105
call = &ndr_table_spoolss.calls[NDR_SPOOLSS_5B];
7107
r = talloc(talloc_tos(), struct spoolss_5b);
7112
if (!prs_data_blob(&p->in_data.data, &blob, r)) {
7117
pull = ndr_pull_init_blob(&blob, r, NULL);
7123
pull->flags |= LIBNDR_FLAG_REF_ALLOC;
7124
ndr_err = call->ndr_pull(pull, NDR_IN, r);
7125
if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
7130
if (DEBUGLEVEL >= 10) {
7131
NDR_PRINT_IN_DEBUG(spoolss_5b, r);
7134
r->out.result = _spoolss_5b(p, r);
7136
if (p->rng_fault_state) {
7138
/* Return true here, srv_pipe_hnd.c will take care */
7142
if (DEBUGLEVEL >= 10) {
7143
NDR_PRINT_OUT_DEBUG(spoolss_5b, r);
7146
push = ndr_push_init_ctx(r, NULL);
7152
ndr_err = call->ndr_push(push, NDR_OUT, r);
7153
if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
7158
blob = ndr_push_blob(push);
7159
if (!prs_copy_data_in(&p->out_data.rdata, (const char *)blob.data, (uint32_t)blob.length)) {
7169
static bool api_spoolss_5c(pipes_struct *p)
7171
const struct ndr_interface_call *call;
7172
struct ndr_pull *pull;
7173
struct ndr_push *push;
7174
enum ndr_err_code ndr_err;
7176
struct spoolss_5c *r;
7178
call = &ndr_table_spoolss.calls[NDR_SPOOLSS_5C];
7180
r = talloc(talloc_tos(), struct spoolss_5c);
7185
if (!prs_data_blob(&p->in_data.data, &blob, r)) {
7190
pull = ndr_pull_init_blob(&blob, r, NULL);
7196
pull->flags |= LIBNDR_FLAG_REF_ALLOC;
7197
ndr_err = call->ndr_pull(pull, NDR_IN, r);
7198
if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
7203
if (DEBUGLEVEL >= 10) {
7204
NDR_PRINT_IN_DEBUG(spoolss_5c, r);
7207
r->out.result = _spoolss_5c(p, r);
7209
if (p->rng_fault_state) {
7211
/* Return true here, srv_pipe_hnd.c will take care */
7215
if (DEBUGLEVEL >= 10) {
7216
NDR_PRINT_OUT_DEBUG(spoolss_5c, r);
7219
push = ndr_push_init_ctx(r, NULL);
7225
ndr_err = call->ndr_push(push, NDR_OUT, r);
7226
if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
7231
blob = ndr_push_blob(push);
7232
if (!prs_copy_data_in(&p->out_data.rdata, (const char *)blob.data, (uint32_t)blob.length)) {
7242
static bool api_spoolss_5d(pipes_struct *p)
7244
const struct ndr_interface_call *call;
7245
struct ndr_pull *pull;
7246
struct ndr_push *push;
7247
enum ndr_err_code ndr_err;
7249
struct spoolss_5d *r;
7251
call = &ndr_table_spoolss.calls[NDR_SPOOLSS_5D];
7253
r = talloc(talloc_tos(), struct spoolss_5d);
7258
if (!prs_data_blob(&p->in_data.data, &blob, r)) {
7263
pull = ndr_pull_init_blob(&blob, r, NULL);
7269
pull->flags |= LIBNDR_FLAG_REF_ALLOC;
7270
ndr_err = call->ndr_pull(pull, NDR_IN, r);
7271
if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
7276
if (DEBUGLEVEL >= 10) {
7277
NDR_PRINT_IN_DEBUG(spoolss_5d, r);
7280
r->out.result = _spoolss_5d(p, r);
7282
if (p->rng_fault_state) {
7284
/* Return true here, srv_pipe_hnd.c will take care */
7288
if (DEBUGLEVEL >= 10) {
7289
NDR_PRINT_OUT_DEBUG(spoolss_5d, r);
7292
push = ndr_push_init_ctx(r, NULL);
7298
ndr_err = call->ndr_push(push, NDR_OUT, r);
7299
if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
7304
blob = ndr_push_blob(push);
7305
if (!prs_copy_data_in(&p->out_data.rdata, (const char *)blob.data, (uint32_t)blob.length)) {
7315
static bool api_spoolss_5e(pipes_struct *p)
7317
const struct ndr_interface_call *call;
7318
struct ndr_pull *pull;
7319
struct ndr_push *push;
7320
enum ndr_err_code ndr_err;
7322
struct spoolss_5e *r;
7324
call = &ndr_table_spoolss.calls[NDR_SPOOLSS_5E];
7326
r = talloc(talloc_tos(), struct spoolss_5e);
7331
if (!prs_data_blob(&p->in_data.data, &blob, r)) {
7336
pull = ndr_pull_init_blob(&blob, r, NULL);
7342
pull->flags |= LIBNDR_FLAG_REF_ALLOC;
7343
ndr_err = call->ndr_pull(pull, NDR_IN, r);
7344
if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
7349
if (DEBUGLEVEL >= 10) {
7350
NDR_PRINT_IN_DEBUG(spoolss_5e, r);
7353
r->out.result = _spoolss_5e(p, r);
7355
if (p->rng_fault_state) {
7357
/* Return true here, srv_pipe_hnd.c will take care */
7361
if (DEBUGLEVEL >= 10) {
7362
NDR_PRINT_OUT_DEBUG(spoolss_5e, r);
7365
push = ndr_push_init_ctx(r, NULL);
7371
ndr_err = call->ndr_push(push, NDR_OUT, r);
7372
if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
7377
blob = ndr_push_blob(push);
7378
if (!prs_copy_data_in(&p->out_data.rdata, (const char *)blob.data, (uint32_t)blob.length)) {
7388
static bool api_spoolss_5f(pipes_struct *p)
7390
const struct ndr_interface_call *call;
7391
struct ndr_pull *pull;
7392
struct ndr_push *push;
7393
enum ndr_err_code ndr_err;
7395
struct spoolss_5f *r;
7397
call = &ndr_table_spoolss.calls[NDR_SPOOLSS_5F];
7399
r = talloc(talloc_tos(), struct spoolss_5f);
7404
if (!prs_data_blob(&p->in_data.data, &blob, r)) {
7409
pull = ndr_pull_init_blob(&blob, r, NULL);
7415
pull->flags |= LIBNDR_FLAG_REF_ALLOC;
7416
ndr_err = call->ndr_pull(pull, NDR_IN, r);
7417
if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
7422
if (DEBUGLEVEL >= 10) {
7423
NDR_PRINT_IN_DEBUG(spoolss_5f, r);
7426
r->out.result = _spoolss_5f(p, r);
7428
if (p->rng_fault_state) {
7430
/* Return true here, srv_pipe_hnd.c will take care */
7434
if (DEBUGLEVEL >= 10) {
7435
NDR_PRINT_OUT_DEBUG(spoolss_5f, r);
7438
push = ndr_push_init_ctx(r, NULL);
7444
ndr_err = call->ndr_push(push, NDR_OUT, r);
7445
if (!NDR_ERR_CODE_IS_SUCCESS(ndr_err)) {
7450
blob = ndr_push_blob(push);
7451
if (!prs_copy_data_in(&p->out_data.rdata, (const char *)blob.data, (uint32_t)blob.length)) {
7463
static struct api_struct api_spoolss_cmds[] =
7465
{"SPOOLSS_ENUMPRINTERS", NDR_SPOOLSS_ENUMPRINTERS, api_spoolss_EnumPrinters},
7466
{"SPOOLSS_OPENPRINTER", NDR_SPOOLSS_OPENPRINTER, api_spoolss_OpenPrinter},
7467
{"SPOOLSS_SETJOB", NDR_SPOOLSS_SETJOB, api_spoolss_SetJob},
7468
{"SPOOLSS_GETJOB", NDR_SPOOLSS_GETJOB, api_spoolss_GetJob},
7469
{"SPOOLSS_ENUMJOBS", NDR_SPOOLSS_ENUMJOBS, api_spoolss_EnumJobs},
7470
{"SPOOLSS_ADDPRINTER", NDR_SPOOLSS_ADDPRINTER, api_spoolss_AddPrinter},
7471
{"SPOOLSS_DELETEPRINTER", NDR_SPOOLSS_DELETEPRINTER, api_spoolss_DeletePrinter},
7472
{"SPOOLSS_SETPRINTER", NDR_SPOOLSS_SETPRINTER, api_spoolss_SetPrinter},
7473
{"SPOOLSS_GETPRINTER", NDR_SPOOLSS_GETPRINTER, api_spoolss_GetPrinter},
7474
{"SPOOLSS_ADDPRINTERDRIVER", NDR_SPOOLSS_ADDPRINTERDRIVER, api_spoolss_AddPrinterDriver},
7475
{"SPOOLSS_ENUMPRINTERDRIVERS", NDR_SPOOLSS_ENUMPRINTERDRIVERS, api_spoolss_EnumPrinterDrivers},
7476
{"SPOOLSS_GETPRINTERDRIVER", NDR_SPOOLSS_GETPRINTERDRIVER, api_spoolss_GetPrinterDriver},
7477
{"SPOOLSS_GETPRINTERDRIVERDIRECTORY", NDR_SPOOLSS_GETPRINTERDRIVERDIRECTORY, api_spoolss_GetPrinterDriverDirectory},
7478
{"SPOOLSS_DELETEPRINTERDRIVER", NDR_SPOOLSS_DELETEPRINTERDRIVER, api_spoolss_DeletePrinterDriver},
7479
{"SPOOLSS_ADDPRINTPROCESSOR", NDR_SPOOLSS_ADDPRINTPROCESSOR, api_spoolss_AddPrintProcessor},
7480
{"SPOOLSS_ENUMPRINTPROCESSORS", NDR_SPOOLSS_ENUMPRINTPROCESSORS, api_spoolss_EnumPrintProcessors},
7481
{"SPOOLSS_GETPRINTPROCESSORDIRECTORY", NDR_SPOOLSS_GETPRINTPROCESSORDIRECTORY, api_spoolss_GetPrintProcessorDirectory},
7482
{"SPOOLSS_STARTDOCPRINTER", NDR_SPOOLSS_STARTDOCPRINTER, api_spoolss_StartDocPrinter},
7483
{"SPOOLSS_STARTPAGEPRINTER", NDR_SPOOLSS_STARTPAGEPRINTER, api_spoolss_StartPagePrinter},
7484
{"SPOOLSS_WRITEPRINTER", NDR_SPOOLSS_WRITEPRINTER, api_spoolss_WritePrinter},
7485
{"SPOOLSS_ENDPAGEPRINTER", NDR_SPOOLSS_ENDPAGEPRINTER, api_spoolss_EndPagePrinter},
7486
{"SPOOLSS_ABORTPRINTER", NDR_SPOOLSS_ABORTPRINTER, api_spoolss_AbortPrinter},
7487
{"SPOOLSS_READPRINTER", NDR_SPOOLSS_READPRINTER, api_spoolss_ReadPrinter},
7488
{"SPOOLSS_ENDDOCPRINTER", NDR_SPOOLSS_ENDDOCPRINTER, api_spoolss_EndDocPrinter},
7489
{"SPOOLSS_ADDJOB", NDR_SPOOLSS_ADDJOB, api_spoolss_AddJob},
7490
{"SPOOLSS_SCHEDULEJOB", NDR_SPOOLSS_SCHEDULEJOB, api_spoolss_ScheduleJob},
7491
{"SPOOLSS_GETPRINTERDATA", NDR_SPOOLSS_GETPRINTERDATA, api_spoolss_GetPrinterData},
7492
{"SPOOLSS_SETPRINTERDATA", NDR_SPOOLSS_SETPRINTERDATA, api_spoolss_SetPrinterData},
7493
{"SPOOLSS_WAITFORPRINTERCHANGE", NDR_SPOOLSS_WAITFORPRINTERCHANGE, api_spoolss_WaitForPrinterChange},
7494
{"SPOOLSS_CLOSEPRINTER", NDR_SPOOLSS_CLOSEPRINTER, api_spoolss_ClosePrinter},
7495
{"SPOOLSS_ADDFORM", NDR_SPOOLSS_ADDFORM, api_spoolss_AddForm},
7496
{"SPOOLSS_DELETEFORM", NDR_SPOOLSS_DELETEFORM, api_spoolss_DeleteForm},
7497
{"SPOOLSS_GETFORM", NDR_SPOOLSS_GETFORM, api_spoolss_GetForm},
7498
{"SPOOLSS_SETFORM", NDR_SPOOLSS_SETFORM, api_spoolss_SetForm},
7499
{"SPOOLSS_ENUMFORMS", NDR_SPOOLSS_ENUMFORMS, api_spoolss_EnumForms},
7500
{"SPOOLSS_ENUMPORTS", NDR_SPOOLSS_ENUMPORTS, api_spoolss_EnumPorts},
7501
{"SPOOLSS_ENUMMONITORS", NDR_SPOOLSS_ENUMMONITORS, api_spoolss_EnumMonitors},
7502
{"SPOOLSS_ADDPORT", NDR_SPOOLSS_ADDPORT, api_spoolss_AddPort},
7503
{"SPOOLSS_CONFIGUREPORT", NDR_SPOOLSS_CONFIGUREPORT, api_spoolss_ConfigurePort},
7504
{"SPOOLSS_DELETEPORT", NDR_SPOOLSS_DELETEPORT, api_spoolss_DeletePort},
7505
{"SPOOLSS_CREATEPRINTERIC", NDR_SPOOLSS_CREATEPRINTERIC, api_spoolss_CreatePrinterIC},
7506
{"SPOOLSS_PLAYGDISCRIPTONPRINTERIC", NDR_SPOOLSS_PLAYGDISCRIPTONPRINTERIC, api_spoolss_PlayGDIScriptOnPrinterIC},
7507
{"SPOOLSS_DELETEPRINTERIC", NDR_SPOOLSS_DELETEPRINTERIC, api_spoolss_DeletePrinterIC},
7508
{"SPOOLSS_ADDPRINTERCONNECTION", NDR_SPOOLSS_ADDPRINTERCONNECTION, api_spoolss_AddPrinterConnection},
7509
{"SPOOLSS_DELETEPRINTERCONNECTION", NDR_SPOOLSS_DELETEPRINTERCONNECTION, api_spoolss_DeletePrinterConnection},
7510
{"SPOOLSS_PRINTERMESSAGEBOX", NDR_SPOOLSS_PRINTERMESSAGEBOX, api_spoolss_PrinterMessageBox},
7511
{"SPOOLSS_ADDMONITOR", NDR_SPOOLSS_ADDMONITOR, api_spoolss_AddMonitor},
7512
{"SPOOLSS_DELETEMONITOR", NDR_SPOOLSS_DELETEMONITOR, api_spoolss_DeleteMonitor},
7513
{"SPOOLSS_DELETEPRINTPROCESSOR", NDR_SPOOLSS_DELETEPRINTPROCESSOR, api_spoolss_DeletePrintProcessor},
7514
{"SPOOLSS_ADDPRINTPROVIDOR", NDR_SPOOLSS_ADDPRINTPROVIDOR, api_spoolss_AddPrintProvidor},
7515
{"SPOOLSS_DELETEPRINTPROVIDOR", NDR_SPOOLSS_DELETEPRINTPROVIDOR, api_spoolss_DeletePrintProvidor},
7516
{"SPOOLSS_ENUMPRINTPROCDATATYPES", NDR_SPOOLSS_ENUMPRINTPROCDATATYPES, api_spoolss_EnumPrintProcDataTypes},
7517
{"SPOOLSS_RESETPRINTER", NDR_SPOOLSS_RESETPRINTER, api_spoolss_ResetPrinter},
7518
{"SPOOLSS_GETPRINTERDRIVER2", NDR_SPOOLSS_GETPRINTERDRIVER2, api_spoolss_GetPrinterDriver2},
7519
{"SPOOLSS_FINDFIRSTPRINTERCHANGENOTIFICATION", NDR_SPOOLSS_FINDFIRSTPRINTERCHANGENOTIFICATION, api_spoolss_FindFirstPrinterChangeNotification},
7520
{"SPOOLSS_FINDNEXTPRINTERCHANGENOTIFICATION", NDR_SPOOLSS_FINDNEXTPRINTERCHANGENOTIFICATION, api_spoolss_FindNextPrinterChangeNotification},
7521
{"SPOOLSS_FINDCLOSEPRINTERNOTIFY", NDR_SPOOLSS_FINDCLOSEPRINTERNOTIFY, api_spoolss_FindClosePrinterNotify},
7522
{"SPOOLSS_ROUTERFINDFIRSTPRINTERCHANGENOTIFICATIONOLD", NDR_SPOOLSS_ROUTERFINDFIRSTPRINTERCHANGENOTIFICATIONOLD, api_spoolss_RouterFindFirstPrinterChangeNotificationOld},
7523
{"SPOOLSS_REPLYOPENPRINTER", NDR_SPOOLSS_REPLYOPENPRINTER, api_spoolss_ReplyOpenPrinter},
7524
{"SPOOLSS_ROUTERREPLYPRINTER", NDR_SPOOLSS_ROUTERREPLYPRINTER, api_spoolss_RouterReplyPrinter},
7525
{"SPOOLSS_REPLYCLOSEPRINTER", NDR_SPOOLSS_REPLYCLOSEPRINTER, api_spoolss_ReplyClosePrinter},
7526
{"SPOOLSS_ADDPORTEX", NDR_SPOOLSS_ADDPORTEX, api_spoolss_AddPortEx},
7527
{"SPOOLSS_ROUTERFINDFIRSTPRINTERCHANGENOTIFICATION", NDR_SPOOLSS_ROUTERFINDFIRSTPRINTERCHANGENOTIFICATION, api_spoolss_RouterFindFirstPrinterChangeNotification},
7528
{"SPOOLSS_SPOOLERINIT", NDR_SPOOLSS_SPOOLERINIT, api_spoolss_SpoolerInit},
7529
{"SPOOLSS_RESETPRINTEREX", NDR_SPOOLSS_RESETPRINTEREX, api_spoolss_ResetPrinterEx},
7530
{"SPOOLSS_REMOTEFINDFIRSTPRINTERCHANGENOTIFYEX", NDR_SPOOLSS_REMOTEFINDFIRSTPRINTERCHANGENOTIFYEX, api_spoolss_RemoteFindFirstPrinterChangeNotifyEx},
7531
{"SPOOLSS_ROUTERREPLYPRINTEREX", NDR_SPOOLSS_ROUTERREPLYPRINTEREX, api_spoolss_RouterReplyPrinterEx},
7532
{"SPOOLSS_ROUTERREFRESHPRINTERCHANGENOTIFY", NDR_SPOOLSS_ROUTERREFRESHPRINTERCHANGENOTIFY, api_spoolss_RouterRefreshPrinterChangeNotify},
7533
{"SPOOLSS_44", NDR_SPOOLSS_44, api_spoolss_44},
7534
{"SPOOLSS_OPENPRINTEREX", NDR_SPOOLSS_OPENPRINTEREX, api_spoolss_OpenPrinterEx},
7535
{"SPOOLSS_ADDPRINTEREX", NDR_SPOOLSS_ADDPRINTEREX, api_spoolss_AddPrinterEx},
7536
{"SPOOLSS_47", NDR_SPOOLSS_47, api_spoolss_47},
7537
{"SPOOLSS_ENUMPRINTERDATA", NDR_SPOOLSS_ENUMPRINTERDATA, api_spoolss_EnumPrinterData},
7538
{"SPOOLSS_DELETEPRINTERDATA", NDR_SPOOLSS_DELETEPRINTERDATA, api_spoolss_DeletePrinterData},
7539
{"SPOOLSS_4A", NDR_SPOOLSS_4A, api_spoolss_4a},
7540
{"SPOOLSS_4B", NDR_SPOOLSS_4B, api_spoolss_4b},
7541
{"SPOOLSS_4C", NDR_SPOOLSS_4C, api_spoolss_4c},
7542
{"SPOOLSS_SETPRINTERDATAEX", NDR_SPOOLSS_SETPRINTERDATAEX, api_spoolss_SetPrinterDataEx},
7543
{"SPOOLSS_GETPRINTERDATAEX", NDR_SPOOLSS_GETPRINTERDATAEX, api_spoolss_GetPrinterDataEx},
7544
{"SPOOLSS_ENUMPRINTERDATAEX", NDR_SPOOLSS_ENUMPRINTERDATAEX, api_spoolss_EnumPrinterDataEx},
7545
{"SPOOLSS_ENUMPRINTERKEY", NDR_SPOOLSS_ENUMPRINTERKEY, api_spoolss_EnumPrinterKey},
7546
{"SPOOLSS_DELETEPRINTERDATAEX", NDR_SPOOLSS_DELETEPRINTERDATAEX, api_spoolss_DeletePrinterDataEx},
7547
{"SPOOLSS_DELETEPRINTERKEY", NDR_SPOOLSS_DELETEPRINTERKEY, api_spoolss_DeletePrinterKey},
7548
{"SPOOLSS_53", NDR_SPOOLSS_53, api_spoolss_53},
7549
{"SPOOLSS_DELETEPRINTERDRIVEREX", NDR_SPOOLSS_DELETEPRINTERDRIVEREX, api_spoolss_DeletePrinterDriverEx},
7550
{"SPOOLSS_55", NDR_SPOOLSS_55, api_spoolss_55},
7551
{"SPOOLSS_56", NDR_SPOOLSS_56, api_spoolss_56},
7552
{"SPOOLSS_57", NDR_SPOOLSS_57, api_spoolss_57},
7553
{"SPOOLSS_XCVDATA", NDR_SPOOLSS_XCVDATA, api_spoolss_XcvData},
7554
{"SPOOLSS_ADDPRINTERDRIVEREX", NDR_SPOOLSS_ADDPRINTERDRIVEREX, api_spoolss_AddPrinterDriverEx},
7555
{"SPOOLSS_5A", NDR_SPOOLSS_5A, api_spoolss_5a},
7556
{"SPOOLSS_5B", NDR_SPOOLSS_5B, api_spoolss_5b},
7557
{"SPOOLSS_5C", NDR_SPOOLSS_5C, api_spoolss_5c},
7558
{"SPOOLSS_5D", NDR_SPOOLSS_5D, api_spoolss_5d},
7559
{"SPOOLSS_5E", NDR_SPOOLSS_5E, api_spoolss_5e},
7560
{"SPOOLSS_5F", NDR_SPOOLSS_5F, api_spoolss_5f},
7563
void spoolss_get_pipe_fns(struct api_struct **fns, int *n_fns)
7565
*fns = api_spoolss_cmds;
7566
*n_fns = sizeof(api_spoolss_cmds) / sizeof(struct api_struct);
7569
NTSTATUS rpc_spoolss_dispatch(struct rpc_pipe_client *cli, TALLOC_CTX *mem_ctx, const struct ndr_interface_table *table, uint32_t opnum, void *_r)
7571
if (cli->pipes_struct == NULL) {
7572
return NT_STATUS_INVALID_PARAMETER;
7577
case NDR_SPOOLSS_ENUMPRINTERS: {
7578
struct spoolss_EnumPrinters *r = (struct spoolss_EnumPrinters *)_r;
7579
ZERO_STRUCT(r->out);
7580
r->out.count = talloc_zero(mem_ctx, uint32_t);
7581
if (r->out.count == NULL) {
7582
return NT_STATUS_NO_MEMORY;
7585
r->out.info = talloc_zero(mem_ctx, union spoolss_PrinterInfo *);
7586
if (r->out.info == NULL) {
7587
return NT_STATUS_NO_MEMORY;
7590
r->out.needed = talloc_zero(mem_ctx, uint32_t);
7591
if (r->out.needed == NULL) {
7592
return NT_STATUS_NO_MEMORY;
7595
r->out.result = _spoolss_EnumPrinters(cli->pipes_struct, r);
7596
return NT_STATUS_OK;
7599
case NDR_SPOOLSS_OPENPRINTER: {
7600
struct spoolss_OpenPrinter *r = (struct spoolss_OpenPrinter *)_r;
7601
ZERO_STRUCT(r->out);
7602
r->out.handle = talloc_zero(mem_ctx, struct policy_handle);
7603
if (r->out.handle == NULL) {
7604
return NT_STATUS_NO_MEMORY;
7607
r->out.result = _spoolss_OpenPrinter(cli->pipes_struct, r);
7608
return NT_STATUS_OK;
7611
case NDR_SPOOLSS_SETJOB: {
7612
struct spoolss_SetJob *r = (struct spoolss_SetJob *)_r;
7613
r->out.result = _spoolss_SetJob(cli->pipes_struct, r);
7614
return NT_STATUS_OK;
7617
case NDR_SPOOLSS_GETJOB: {
7618
struct spoolss_GetJob *r = (struct spoolss_GetJob *)_r;
7619
ZERO_STRUCT(r->out);
7620
r->out.info = talloc_zero(mem_ctx, union spoolss_JobInfo);
7621
if (r->out.info == NULL) {
7622
return NT_STATUS_NO_MEMORY;
7625
r->out.needed = talloc_zero(mem_ctx, uint32_t);
7626
if (r->out.needed == NULL) {
7627
return NT_STATUS_NO_MEMORY;
7630
r->out.result = _spoolss_GetJob(cli->pipes_struct, r);
7631
return NT_STATUS_OK;
7634
case NDR_SPOOLSS_ENUMJOBS: {
7635
struct spoolss_EnumJobs *r = (struct spoolss_EnumJobs *)_r;
7636
ZERO_STRUCT(r->out);
7637
r->out.count = talloc_zero(mem_ctx, uint32_t);
7638
if (r->out.count == NULL) {
7639
return NT_STATUS_NO_MEMORY;
7642
r->out.info = talloc_zero(mem_ctx, union spoolss_JobInfo *);
7643
if (r->out.info == NULL) {
7644
return NT_STATUS_NO_MEMORY;
7647
r->out.needed = talloc_zero(mem_ctx, uint32_t);
7648
if (r->out.needed == NULL) {
7649
return NT_STATUS_NO_MEMORY;
7652
r->out.result = _spoolss_EnumJobs(cli->pipes_struct, r);
7653
return NT_STATUS_OK;
7656
case NDR_SPOOLSS_ADDPRINTER: {
7657
struct spoolss_AddPrinter *r = (struct spoolss_AddPrinter *)_r;
7658
r->out.result = _spoolss_AddPrinter(cli->pipes_struct, r);
7659
return NT_STATUS_OK;
7662
case NDR_SPOOLSS_DELETEPRINTER: {
7663
struct spoolss_DeletePrinter *r = (struct spoolss_DeletePrinter *)_r;
7664
r->out.result = _spoolss_DeletePrinter(cli->pipes_struct, r);
7665
return NT_STATUS_OK;
7668
case NDR_SPOOLSS_SETPRINTER: {
7669
struct spoolss_SetPrinter *r = (struct spoolss_SetPrinter *)_r;
7670
r->out.result = _spoolss_SetPrinter(cli->pipes_struct, r);
7671
return NT_STATUS_OK;
7674
case NDR_SPOOLSS_GETPRINTER: {
7675
struct spoolss_GetPrinter *r = (struct spoolss_GetPrinter *)_r;
7676
ZERO_STRUCT(r->out);
7677
r->out.info = talloc_zero(mem_ctx, union spoolss_PrinterInfo);
7678
if (r->out.info == NULL) {
7679
return NT_STATUS_NO_MEMORY;
7682
r->out.needed = talloc_zero(mem_ctx, uint32_t);
7683
if (r->out.needed == NULL) {
7684
return NT_STATUS_NO_MEMORY;
7687
r->out.result = _spoolss_GetPrinter(cli->pipes_struct, r);
7688
return NT_STATUS_OK;
7691
case NDR_SPOOLSS_ADDPRINTERDRIVER: {
7692
struct spoolss_AddPrinterDriver *r = (struct spoolss_AddPrinterDriver *)_r;
7693
r->out.result = _spoolss_AddPrinterDriver(cli->pipes_struct, r);
7694
return NT_STATUS_OK;
7697
case NDR_SPOOLSS_ENUMPRINTERDRIVERS: {
7698
struct spoolss_EnumPrinterDrivers *r = (struct spoolss_EnumPrinterDrivers *)_r;
7699
ZERO_STRUCT(r->out);
7700
r->out.count = talloc_zero(mem_ctx, uint32_t);
7701
if (r->out.count == NULL) {
7702
return NT_STATUS_NO_MEMORY;
7705
r->out.info = talloc_zero(mem_ctx, union spoolss_DriverInfo *);
7706
if (r->out.info == NULL) {
7707
return NT_STATUS_NO_MEMORY;
7710
r->out.needed = talloc_zero(mem_ctx, uint32_t);
7711
if (r->out.needed == NULL) {
7712
return NT_STATUS_NO_MEMORY;
7715
r->out.result = _spoolss_EnumPrinterDrivers(cli->pipes_struct, r);
7716
return NT_STATUS_OK;
7719
case NDR_SPOOLSS_GETPRINTERDRIVER: {
7720
struct spoolss_GetPrinterDriver *r = (struct spoolss_GetPrinterDriver *)_r;
7721
r->out.result = _spoolss_GetPrinterDriver(cli->pipes_struct, r);
7722
return NT_STATUS_OK;
7725
case NDR_SPOOLSS_GETPRINTERDRIVERDIRECTORY: {
7726
struct spoolss_GetPrinterDriverDirectory *r = (struct spoolss_GetPrinterDriverDirectory *)_r;
7727
ZERO_STRUCT(r->out);
7728
r->out.info = talloc_zero(mem_ctx, union spoolss_DriverDirectoryInfo);
7729
if (r->out.info == NULL) {
7730
return NT_STATUS_NO_MEMORY;
7733
r->out.needed = talloc_zero(mem_ctx, uint32_t);
7734
if (r->out.needed == NULL) {
7735
return NT_STATUS_NO_MEMORY;
7738
r->out.result = _spoolss_GetPrinterDriverDirectory(cli->pipes_struct, r);
7739
return NT_STATUS_OK;
7742
case NDR_SPOOLSS_DELETEPRINTERDRIVER: {
7743
struct spoolss_DeletePrinterDriver *r = (struct spoolss_DeletePrinterDriver *)_r;
7744
r->out.result = _spoolss_DeletePrinterDriver(cli->pipes_struct, r);
7745
return NT_STATUS_OK;
7748
case NDR_SPOOLSS_ADDPRINTPROCESSOR: {
7749
struct spoolss_AddPrintProcessor *r = (struct spoolss_AddPrintProcessor *)_r;
7750
r->out.result = _spoolss_AddPrintProcessor(cli->pipes_struct, r);
7751
return NT_STATUS_OK;
7754
case NDR_SPOOLSS_ENUMPRINTPROCESSORS: {
7755
struct spoolss_EnumPrintProcessors *r = (struct spoolss_EnumPrintProcessors *)_r;
7756
ZERO_STRUCT(r->out);
7757
r->out.count = talloc_zero(mem_ctx, uint32_t);
7758
if (r->out.count == NULL) {
7759
return NT_STATUS_NO_MEMORY;
7762
r->out.info = talloc_zero(mem_ctx, union spoolss_PrintProcessorInfo *);
7763
if (r->out.info == NULL) {
7764
return NT_STATUS_NO_MEMORY;
7767
r->out.needed = talloc_zero(mem_ctx, uint32_t);
7768
if (r->out.needed == NULL) {
7769
return NT_STATUS_NO_MEMORY;
7772
r->out.result = _spoolss_EnumPrintProcessors(cli->pipes_struct, r);
7773
return NT_STATUS_OK;
7776
case NDR_SPOOLSS_GETPRINTPROCESSORDIRECTORY: {
7777
struct spoolss_GetPrintProcessorDirectory *r = (struct spoolss_GetPrintProcessorDirectory *)_r;
7778
ZERO_STRUCT(r->out);
7779
r->out.info = talloc_zero(mem_ctx, union spoolss_PrintProcessorDirectoryInfo);
7780
if (r->out.info == NULL) {
7781
return NT_STATUS_NO_MEMORY;
7784
r->out.needed = talloc_zero(mem_ctx, uint32_t);
7785
if (r->out.needed == NULL) {
7786
return NT_STATUS_NO_MEMORY;
7789
r->out.result = _spoolss_GetPrintProcessorDirectory(cli->pipes_struct, r);
7790
return NT_STATUS_OK;
7793
case NDR_SPOOLSS_STARTDOCPRINTER: {
7794
struct spoolss_StartDocPrinter *r = (struct spoolss_StartDocPrinter *)_r;
7795
ZERO_STRUCT(r->out);
7796
r->out.job_id = talloc_zero(mem_ctx, uint32_t);
7797
if (r->out.job_id == NULL) {
7798
return NT_STATUS_NO_MEMORY;
7801
r->out.result = _spoolss_StartDocPrinter(cli->pipes_struct, r);
7802
return NT_STATUS_OK;
7805
case NDR_SPOOLSS_STARTPAGEPRINTER: {
7806
struct spoolss_StartPagePrinter *r = (struct spoolss_StartPagePrinter *)_r;
7807
r->out.result = _spoolss_StartPagePrinter(cli->pipes_struct, r);
7808
return NT_STATUS_OK;
7811
case NDR_SPOOLSS_WRITEPRINTER: {
7812
struct spoolss_WritePrinter *r = (struct spoolss_WritePrinter *)_r;
7813
ZERO_STRUCT(r->out);
7814
r->out.num_written = talloc_zero(mem_ctx, uint32_t);
7815
if (r->out.num_written == NULL) {
7816
return NT_STATUS_NO_MEMORY;
7819
r->out.result = _spoolss_WritePrinter(cli->pipes_struct, r);
7820
return NT_STATUS_OK;
7823
case NDR_SPOOLSS_ENDPAGEPRINTER: {
7824
struct spoolss_EndPagePrinter *r = (struct spoolss_EndPagePrinter *)_r;
7825
r->out.result = _spoolss_EndPagePrinter(cli->pipes_struct, r);
7826
return NT_STATUS_OK;
7829
case NDR_SPOOLSS_ABORTPRINTER: {
7830
struct spoolss_AbortPrinter *r = (struct spoolss_AbortPrinter *)_r;
7831
r->out.result = _spoolss_AbortPrinter(cli->pipes_struct, r);
7832
return NT_STATUS_OK;
7835
case NDR_SPOOLSS_READPRINTER: {
7836
struct spoolss_ReadPrinter *r = (struct spoolss_ReadPrinter *)_r;
7837
ZERO_STRUCT(r->out);
7838
r->out.data = talloc_zero_array(mem_ctx, uint8_t, r->in.data_size);
7839
if (r->out.data == NULL) {
7840
return NT_STATUS_NO_MEMORY;
7843
r->out._data_size = talloc_zero(mem_ctx, uint32_t);
7844
if (r->out._data_size == NULL) {
7845
return NT_STATUS_NO_MEMORY;
7848
r->out.result = _spoolss_ReadPrinter(cli->pipes_struct, r);
7849
return NT_STATUS_OK;
7852
case NDR_SPOOLSS_ENDDOCPRINTER: {
7853
struct spoolss_EndDocPrinter *r = (struct spoolss_EndDocPrinter *)_r;
7854
r->out.result = _spoolss_EndDocPrinter(cli->pipes_struct, r);
7855
return NT_STATUS_OK;
7858
case NDR_SPOOLSS_ADDJOB: {
7859
struct spoolss_AddJob *r = (struct spoolss_AddJob *)_r;
7860
ZERO_STRUCT(r->out);
7861
r->out.buffer = r->in.buffer;
7862
r->out.needed = talloc_zero(mem_ctx, uint32_t);
7863
if (r->out.needed == NULL) {
7864
return NT_STATUS_NO_MEMORY;
7867
r->out.result = _spoolss_AddJob(cli->pipes_struct, r);
7868
return NT_STATUS_OK;
7871
case NDR_SPOOLSS_SCHEDULEJOB: {
7872
struct spoolss_ScheduleJob *r = (struct spoolss_ScheduleJob *)_r;
7873
r->out.result = _spoolss_ScheduleJob(cli->pipes_struct, r);
7874
return NT_STATUS_OK;
7877
case NDR_SPOOLSS_GETPRINTERDATA: {
7878
struct spoolss_GetPrinterData *r = (struct spoolss_GetPrinterData *)_r;
7879
ZERO_STRUCT(r->out);
7880
r->out.type = talloc_zero(mem_ctx, enum winreg_Type);
7881
if (r->out.type == NULL) {
7882
return NT_STATUS_NO_MEMORY;
7885
r->out.data = talloc_zero_array(mem_ctx, uint8_t, r->in.offered);
7886
if (r->out.data == NULL) {
7887
return NT_STATUS_NO_MEMORY;
7890
r->out.needed = talloc_zero(mem_ctx, uint32_t);
7891
if (r->out.needed == NULL) {
7892
return NT_STATUS_NO_MEMORY;
7895
r->out.result = _spoolss_GetPrinterData(cli->pipes_struct, r);
7896
return NT_STATUS_OK;
7899
case NDR_SPOOLSS_SETPRINTERDATA: {
7900
struct spoolss_SetPrinterData *r = (struct spoolss_SetPrinterData *)_r;
7901
r->out.result = _spoolss_SetPrinterData(cli->pipes_struct, r);
7902
return NT_STATUS_OK;
7905
case NDR_SPOOLSS_WAITFORPRINTERCHANGE: {
7906
struct spoolss_WaitForPrinterChange *r = (struct spoolss_WaitForPrinterChange *)_r;
7907
r->out.result = _spoolss_WaitForPrinterChange(cli->pipes_struct, r);
7908
return NT_STATUS_OK;
7911
case NDR_SPOOLSS_CLOSEPRINTER: {
7912
struct spoolss_ClosePrinter *r = (struct spoolss_ClosePrinter *)_r;
7913
ZERO_STRUCT(r->out);
7914
r->out.handle = r->in.handle;
7915
r->out.result = _spoolss_ClosePrinter(cli->pipes_struct, r);
7916
return NT_STATUS_OK;
7919
case NDR_SPOOLSS_ADDFORM: {
7920
struct spoolss_AddForm *r = (struct spoolss_AddForm *)_r;
7921
r->out.result = _spoolss_AddForm(cli->pipes_struct, r);
7922
return NT_STATUS_OK;
7925
case NDR_SPOOLSS_DELETEFORM: {
7926
struct spoolss_DeleteForm *r = (struct spoolss_DeleteForm *)_r;
7927
r->out.result = _spoolss_DeleteForm(cli->pipes_struct, r);
7928
return NT_STATUS_OK;
7931
case NDR_SPOOLSS_GETFORM: {
7932
struct spoolss_GetForm *r = (struct spoolss_GetForm *)_r;
7933
ZERO_STRUCT(r->out);
7934
r->out.info = talloc_zero(mem_ctx, union spoolss_FormInfo);
7935
if (r->out.info == NULL) {
7936
return NT_STATUS_NO_MEMORY;
7939
r->out.needed = talloc_zero(mem_ctx, uint32_t);
7940
if (r->out.needed == NULL) {
7941
return NT_STATUS_NO_MEMORY;
7944
r->out.result = _spoolss_GetForm(cli->pipes_struct, r);
7945
return NT_STATUS_OK;
7948
case NDR_SPOOLSS_SETFORM: {
7949
struct spoolss_SetForm *r = (struct spoolss_SetForm *)_r;
7950
r->out.result = _spoolss_SetForm(cli->pipes_struct, r);
7951
return NT_STATUS_OK;
7954
case NDR_SPOOLSS_ENUMFORMS: {
7955
struct spoolss_EnumForms *r = (struct spoolss_EnumForms *)_r;
7956
ZERO_STRUCT(r->out);
7957
r->out.count = talloc_zero(mem_ctx, uint32_t);
7958
if (r->out.count == NULL) {
7959
return NT_STATUS_NO_MEMORY;
7962
r->out.info = talloc_zero(mem_ctx, union spoolss_FormInfo *);
7963
if (r->out.info == NULL) {
7964
return NT_STATUS_NO_MEMORY;
7967
r->out.needed = talloc_zero(mem_ctx, uint32_t);
7968
if (r->out.needed == NULL) {
7969
return NT_STATUS_NO_MEMORY;
7972
r->out.result = _spoolss_EnumForms(cli->pipes_struct, r);
7973
return NT_STATUS_OK;
7976
case NDR_SPOOLSS_ENUMPORTS: {
7977
struct spoolss_EnumPorts *r = (struct spoolss_EnumPorts *)_r;
7978
ZERO_STRUCT(r->out);
7979
r->out.count = talloc_zero(mem_ctx, uint32_t);
7980
if (r->out.count == NULL) {
7981
return NT_STATUS_NO_MEMORY;
7984
r->out.info = talloc_zero(mem_ctx, union spoolss_PortInfo *);
7985
if (r->out.info == NULL) {
7986
return NT_STATUS_NO_MEMORY;
7989
r->out.needed = talloc_zero(mem_ctx, uint32_t);
7990
if (r->out.needed == NULL) {
7991
return NT_STATUS_NO_MEMORY;
7994
r->out.result = _spoolss_EnumPorts(cli->pipes_struct, r);
7995
return NT_STATUS_OK;
7998
case NDR_SPOOLSS_ENUMMONITORS: {
7999
struct spoolss_EnumMonitors *r = (struct spoolss_EnumMonitors *)_r;
8000
ZERO_STRUCT(r->out);
8001
r->out.count = talloc_zero(mem_ctx, uint32_t);
8002
if (r->out.count == NULL) {
8003
return NT_STATUS_NO_MEMORY;
8006
r->out.info = talloc_zero(mem_ctx, union spoolss_MonitorInfo *);
8007
if (r->out.info == NULL) {
8008
return NT_STATUS_NO_MEMORY;
8011
r->out.needed = talloc_zero(mem_ctx, uint32_t);
8012
if (r->out.needed == NULL) {
8013
return NT_STATUS_NO_MEMORY;
8016
r->out.result = _spoolss_EnumMonitors(cli->pipes_struct, r);
8017
return NT_STATUS_OK;
8020
case NDR_SPOOLSS_ADDPORT: {
8021
struct spoolss_AddPort *r = (struct spoolss_AddPort *)_r;
8022
r->out.result = _spoolss_AddPort(cli->pipes_struct, r);
8023
return NT_STATUS_OK;
8026
case NDR_SPOOLSS_CONFIGUREPORT: {
8027
struct spoolss_ConfigurePort *r = (struct spoolss_ConfigurePort *)_r;
8028
r->out.result = _spoolss_ConfigurePort(cli->pipes_struct, r);
8029
return NT_STATUS_OK;
8032
case NDR_SPOOLSS_DELETEPORT: {
8033
struct spoolss_DeletePort *r = (struct spoolss_DeletePort *)_r;
8034
r->out.result = _spoolss_DeletePort(cli->pipes_struct, r);
8035
return NT_STATUS_OK;
8038
case NDR_SPOOLSS_CREATEPRINTERIC: {
8039
struct spoolss_CreatePrinterIC *r = (struct spoolss_CreatePrinterIC *)_r;
8040
r->out.result = _spoolss_CreatePrinterIC(cli->pipes_struct, r);
8041
return NT_STATUS_OK;
8044
case NDR_SPOOLSS_PLAYGDISCRIPTONPRINTERIC: {
8045
struct spoolss_PlayGDIScriptOnPrinterIC *r = (struct spoolss_PlayGDIScriptOnPrinterIC *)_r;
8046
r->out.result = _spoolss_PlayGDIScriptOnPrinterIC(cli->pipes_struct, r);
8047
return NT_STATUS_OK;
8050
case NDR_SPOOLSS_DELETEPRINTERIC: {
8051
struct spoolss_DeletePrinterIC *r = (struct spoolss_DeletePrinterIC *)_r;
8052
r->out.result = _spoolss_DeletePrinterIC(cli->pipes_struct, r);
8053
return NT_STATUS_OK;
8056
case NDR_SPOOLSS_ADDPRINTERCONNECTION: {
8057
struct spoolss_AddPrinterConnection *r = (struct spoolss_AddPrinterConnection *)_r;
8058
r->out.result = _spoolss_AddPrinterConnection(cli->pipes_struct, r);
8059
return NT_STATUS_OK;
8062
case NDR_SPOOLSS_DELETEPRINTERCONNECTION: {
8063
struct spoolss_DeletePrinterConnection *r = (struct spoolss_DeletePrinterConnection *)_r;
8064
r->out.result = _spoolss_DeletePrinterConnection(cli->pipes_struct, r);
8065
return NT_STATUS_OK;
8068
case NDR_SPOOLSS_PRINTERMESSAGEBOX: {
8069
struct spoolss_PrinterMessageBox *r = (struct spoolss_PrinterMessageBox *)_r;
8070
r->out.result = _spoolss_PrinterMessageBox(cli->pipes_struct, r);
8071
return NT_STATUS_OK;
8074
case NDR_SPOOLSS_ADDMONITOR: {
8075
struct spoolss_AddMonitor *r = (struct spoolss_AddMonitor *)_r;
8076
r->out.result = _spoolss_AddMonitor(cli->pipes_struct, r);
8077
return NT_STATUS_OK;
8080
case NDR_SPOOLSS_DELETEMONITOR: {
8081
struct spoolss_DeleteMonitor *r = (struct spoolss_DeleteMonitor *)_r;
8082
r->out.result = _spoolss_DeleteMonitor(cli->pipes_struct, r);
8083
return NT_STATUS_OK;
8086
case NDR_SPOOLSS_DELETEPRINTPROCESSOR: {
8087
struct spoolss_DeletePrintProcessor *r = (struct spoolss_DeletePrintProcessor *)_r;
8088
r->out.result = _spoolss_DeletePrintProcessor(cli->pipes_struct, r);
8089
return NT_STATUS_OK;
8092
case NDR_SPOOLSS_ADDPRINTPROVIDOR: {
8093
struct spoolss_AddPrintProvidor *r = (struct spoolss_AddPrintProvidor *)_r;
8094
r->out.result = _spoolss_AddPrintProvidor(cli->pipes_struct, r);
8095
return NT_STATUS_OK;
8098
case NDR_SPOOLSS_DELETEPRINTPROVIDOR: {
8099
struct spoolss_DeletePrintProvidor *r = (struct spoolss_DeletePrintProvidor *)_r;
8100
r->out.result = _spoolss_DeletePrintProvidor(cli->pipes_struct, r);
8101
return NT_STATUS_OK;
8104
case NDR_SPOOLSS_ENUMPRINTPROCDATATYPES: {
8105
struct spoolss_EnumPrintProcDataTypes *r = (struct spoolss_EnumPrintProcDataTypes *)_r;
8106
ZERO_STRUCT(r->out);
8107
r->out.count = talloc_zero(mem_ctx, uint32_t);
8108
if (r->out.count == NULL) {
8109
return NT_STATUS_NO_MEMORY;
8112
r->out.info = talloc_zero(mem_ctx, union spoolss_PrintProcDataTypesInfo *);
8113
if (r->out.info == NULL) {
8114
return NT_STATUS_NO_MEMORY;
8117
r->out.needed = talloc_zero(mem_ctx, uint32_t);
8118
if (r->out.needed == NULL) {
8119
return NT_STATUS_NO_MEMORY;
8122
r->out.result = _spoolss_EnumPrintProcDataTypes(cli->pipes_struct, r);
8123
return NT_STATUS_OK;
8126
case NDR_SPOOLSS_RESETPRINTER: {
8127
struct spoolss_ResetPrinter *r = (struct spoolss_ResetPrinter *)_r;
8128
r->out.result = _spoolss_ResetPrinter(cli->pipes_struct, r);
8129
return NT_STATUS_OK;
8132
case NDR_SPOOLSS_GETPRINTERDRIVER2: {
8133
struct spoolss_GetPrinterDriver2 *r = (struct spoolss_GetPrinterDriver2 *)_r;
8134
ZERO_STRUCT(r->out);
8135
r->out.info = talloc_zero(mem_ctx, union spoolss_DriverInfo);
8136
if (r->out.info == NULL) {
8137
return NT_STATUS_NO_MEMORY;
8140
r->out.needed = talloc_zero(mem_ctx, uint32_t);
8141
if (r->out.needed == NULL) {
8142
return NT_STATUS_NO_MEMORY;
8145
r->out.server_major_version = talloc_zero(mem_ctx, uint32_t);
8146
if (r->out.server_major_version == NULL) {
8147
return NT_STATUS_NO_MEMORY;
8150
r->out.server_minor_version = talloc_zero(mem_ctx, uint32_t);
8151
if (r->out.server_minor_version == NULL) {
8152
return NT_STATUS_NO_MEMORY;
8155
r->out.result = _spoolss_GetPrinterDriver2(cli->pipes_struct, r);
8156
return NT_STATUS_OK;
8159
case NDR_SPOOLSS_FINDFIRSTPRINTERCHANGENOTIFICATION: {
8160
struct spoolss_FindFirstPrinterChangeNotification *r = (struct spoolss_FindFirstPrinterChangeNotification *)_r;
8161
r->out.result = _spoolss_FindFirstPrinterChangeNotification(cli->pipes_struct, r);
8162
return NT_STATUS_OK;
8165
case NDR_SPOOLSS_FINDNEXTPRINTERCHANGENOTIFICATION: {
8166
struct spoolss_FindNextPrinterChangeNotification *r = (struct spoolss_FindNextPrinterChangeNotification *)_r;
8167
r->out.result = _spoolss_FindNextPrinterChangeNotification(cli->pipes_struct, r);
8168
return NT_STATUS_OK;
8171
case NDR_SPOOLSS_FINDCLOSEPRINTERNOTIFY: {
8172
struct spoolss_FindClosePrinterNotify *r = (struct spoolss_FindClosePrinterNotify *)_r;
8173
r->out.result = _spoolss_FindClosePrinterNotify(cli->pipes_struct, r);
8174
return NT_STATUS_OK;
8177
case NDR_SPOOLSS_ROUTERFINDFIRSTPRINTERCHANGENOTIFICATIONOLD: {
8178
struct spoolss_RouterFindFirstPrinterChangeNotificationOld *r = (struct spoolss_RouterFindFirstPrinterChangeNotificationOld *)_r;
8179
r->out.result = _spoolss_RouterFindFirstPrinterChangeNotificationOld(cli->pipes_struct, r);
8180
return NT_STATUS_OK;
8183
case NDR_SPOOLSS_REPLYOPENPRINTER: {
8184
struct spoolss_ReplyOpenPrinter *r = (struct spoolss_ReplyOpenPrinter *)_r;
8185
ZERO_STRUCT(r->out);
8186
r->out.handle = talloc_zero(mem_ctx, struct policy_handle);
8187
if (r->out.handle == NULL) {
8188
return NT_STATUS_NO_MEMORY;
8191
r->out.result = _spoolss_ReplyOpenPrinter(cli->pipes_struct, r);
8192
return NT_STATUS_OK;
8195
case NDR_SPOOLSS_ROUTERREPLYPRINTER: {
8196
struct spoolss_RouterReplyPrinter *r = (struct spoolss_RouterReplyPrinter *)_r;
8197
r->out.result = _spoolss_RouterReplyPrinter(cli->pipes_struct, r);
8198
return NT_STATUS_OK;
8201
case NDR_SPOOLSS_REPLYCLOSEPRINTER: {
8202
struct spoolss_ReplyClosePrinter *r = (struct spoolss_ReplyClosePrinter *)_r;
8203
ZERO_STRUCT(r->out);
8204
r->out.handle = r->in.handle;
8205
r->out.result = _spoolss_ReplyClosePrinter(cli->pipes_struct, r);
8206
return NT_STATUS_OK;
8209
case NDR_SPOOLSS_ADDPORTEX: {
8210
struct spoolss_AddPortEx *r = (struct spoolss_AddPortEx *)_r;
8211
r->out.result = _spoolss_AddPortEx(cli->pipes_struct, r);
8212
return NT_STATUS_OK;
8215
case NDR_SPOOLSS_ROUTERFINDFIRSTPRINTERCHANGENOTIFICATION: {
8216
struct spoolss_RouterFindFirstPrinterChangeNotification *r = (struct spoolss_RouterFindFirstPrinterChangeNotification *)_r;
8217
r->out.result = _spoolss_RouterFindFirstPrinterChangeNotification(cli->pipes_struct, r);
8218
return NT_STATUS_OK;
8221
case NDR_SPOOLSS_SPOOLERINIT: {
8222
struct spoolss_SpoolerInit *r = (struct spoolss_SpoolerInit *)_r;
8223
r->out.result = _spoolss_SpoolerInit(cli->pipes_struct, r);
8224
return NT_STATUS_OK;
8227
case NDR_SPOOLSS_RESETPRINTEREX: {
8228
struct spoolss_ResetPrinterEx *r = (struct spoolss_ResetPrinterEx *)_r;
8229
r->out.result = _spoolss_ResetPrinterEx(cli->pipes_struct, r);
8230
return NT_STATUS_OK;
8233
case NDR_SPOOLSS_REMOTEFINDFIRSTPRINTERCHANGENOTIFYEX: {
8234
struct spoolss_RemoteFindFirstPrinterChangeNotifyEx *r = (struct spoolss_RemoteFindFirstPrinterChangeNotifyEx *)_r;
8235
r->out.result = _spoolss_RemoteFindFirstPrinterChangeNotifyEx(cli->pipes_struct, r);
8236
return NT_STATUS_OK;
8239
case NDR_SPOOLSS_ROUTERREPLYPRINTEREX: {
8240
struct spoolss_RouterReplyPrinterEx *r = (struct spoolss_RouterReplyPrinterEx *)_r;
8241
ZERO_STRUCT(r->out);
8242
r->out.reply_result = talloc_zero(mem_ctx, uint32_t);
8243
if (r->out.reply_result == NULL) {
8244
return NT_STATUS_NO_MEMORY;
8247
r->out.result = _spoolss_RouterReplyPrinterEx(cli->pipes_struct, r);
8248
return NT_STATUS_OK;
8251
case NDR_SPOOLSS_ROUTERREFRESHPRINTERCHANGENOTIFY: {
8252
struct spoolss_RouterRefreshPrinterChangeNotify *r = (struct spoolss_RouterRefreshPrinterChangeNotify *)_r;
8253
ZERO_STRUCT(r->out);
8254
r->out.info = talloc_zero(mem_ctx, struct spoolss_NotifyInfo *);
8255
if (r->out.info == NULL) {
8256
return NT_STATUS_NO_MEMORY;
8259
r->out.result = _spoolss_RouterRefreshPrinterChangeNotify(cli->pipes_struct, r);
8260
return NT_STATUS_OK;
8263
case NDR_SPOOLSS_44: {
8264
struct spoolss_44 *r = (struct spoolss_44 *)_r;
8265
r->out.result = _spoolss_44(cli->pipes_struct, r);
8266
return NT_STATUS_OK;
8269
case NDR_SPOOLSS_OPENPRINTEREX: {
8270
struct spoolss_OpenPrinterEx *r = (struct spoolss_OpenPrinterEx *)_r;
8271
ZERO_STRUCT(r->out);
8272
r->out.handle = talloc_zero(mem_ctx, struct policy_handle);
8273
if (r->out.handle == NULL) {
8274
return NT_STATUS_NO_MEMORY;
8277
r->out.result = _spoolss_OpenPrinterEx(cli->pipes_struct, r);
8278
return NT_STATUS_OK;
8281
case NDR_SPOOLSS_ADDPRINTEREX: {
8282
struct spoolss_AddPrinterEx *r = (struct spoolss_AddPrinterEx *)_r;
8283
ZERO_STRUCT(r->out);
8284
r->out.handle = talloc_zero(mem_ctx, struct policy_handle);
8285
if (r->out.handle == NULL) {
8286
return NT_STATUS_NO_MEMORY;
8289
r->out.result = _spoolss_AddPrinterEx(cli->pipes_struct, r);
8290
return NT_STATUS_OK;
8293
case NDR_SPOOLSS_47: {
8294
struct spoolss_47 *r = (struct spoolss_47 *)_r;
8295
r->out.result = _spoolss_47(cli->pipes_struct, r);
8296
return NT_STATUS_OK;
8299
case NDR_SPOOLSS_ENUMPRINTERDATA: {
8300
struct spoolss_EnumPrinterData *r = (struct spoolss_EnumPrinterData *)_r;
8301
ZERO_STRUCT(r->out);
8302
r->out.value_name = talloc_zero_array(mem_ctx, const char, r->in.value_offered / 2);
8303
if (r->out.value_name == NULL) {
8304
return NT_STATUS_NO_MEMORY;
8307
r->out.value_needed = talloc_zero(mem_ctx, uint32_t);
8308
if (r->out.value_needed == NULL) {
8309
return NT_STATUS_NO_MEMORY;
8312
r->out.type = talloc_zero(mem_ctx, enum winreg_Type);
8313
if (r->out.type == NULL) {
8314
return NT_STATUS_NO_MEMORY;
8317
r->out.data = talloc_zero_array(mem_ctx, uint8_t, r->in.data_offered);
8318
if (r->out.data == NULL) {
8319
return NT_STATUS_NO_MEMORY;
8322
r->out.data_needed = talloc_zero(mem_ctx, uint32_t);
8323
if (r->out.data_needed == NULL) {
8324
return NT_STATUS_NO_MEMORY;
8327
r->out.result = _spoolss_EnumPrinterData(cli->pipes_struct, r);
8328
return NT_STATUS_OK;
8331
case NDR_SPOOLSS_DELETEPRINTERDATA: {
8332
struct spoolss_DeletePrinterData *r = (struct spoolss_DeletePrinterData *)_r;
8333
r->out.result = _spoolss_DeletePrinterData(cli->pipes_struct, r);
8334
return NT_STATUS_OK;
8337
case NDR_SPOOLSS_4A: {
8338
struct spoolss_4a *r = (struct spoolss_4a *)_r;
8339
r->out.result = _spoolss_4a(cli->pipes_struct, r);
8340
return NT_STATUS_OK;
8343
case NDR_SPOOLSS_4B: {
8344
struct spoolss_4b *r = (struct spoolss_4b *)_r;
8345
r->out.result = _spoolss_4b(cli->pipes_struct, r);
8346
return NT_STATUS_OK;
8349
case NDR_SPOOLSS_4C: {
8350
struct spoolss_4c *r = (struct spoolss_4c *)_r;
8351
r->out.result = _spoolss_4c(cli->pipes_struct, r);
8352
return NT_STATUS_OK;
8355
case NDR_SPOOLSS_SETPRINTERDATAEX: {
8356
struct spoolss_SetPrinterDataEx *r = (struct spoolss_SetPrinterDataEx *)_r;
8357
r->out.result = _spoolss_SetPrinterDataEx(cli->pipes_struct, r);
8358
return NT_STATUS_OK;
8361
case NDR_SPOOLSS_GETPRINTERDATAEX: {
8362
struct spoolss_GetPrinterDataEx *r = (struct spoolss_GetPrinterDataEx *)_r;
8363
ZERO_STRUCT(r->out);
8364
r->out.type = talloc_zero(mem_ctx, enum winreg_Type);
8365
if (r->out.type == NULL) {
8366
return NT_STATUS_NO_MEMORY;
8369
r->out.data = talloc_zero_array(mem_ctx, uint8_t, r->in.offered);
8370
if (r->out.data == NULL) {
8371
return NT_STATUS_NO_MEMORY;
8374
r->out.needed = talloc_zero(mem_ctx, uint32_t);
8375
if (r->out.needed == NULL) {
8376
return NT_STATUS_NO_MEMORY;
8379
r->out.result = _spoolss_GetPrinterDataEx(cli->pipes_struct, r);
8380
return NT_STATUS_OK;
8383
case NDR_SPOOLSS_ENUMPRINTERDATAEX: {
8384
struct spoolss_EnumPrinterDataEx *r = (struct spoolss_EnumPrinterDataEx *)_r;
8385
ZERO_STRUCT(r->out);
8386
r->out.count = talloc_zero(mem_ctx, uint32_t);
8387
if (r->out.count == NULL) {
8388
return NT_STATUS_NO_MEMORY;
8391
r->out.info = talloc_zero(mem_ctx, struct spoolss_PrinterEnumValues *);
8392
if (r->out.info == NULL) {
8393
return NT_STATUS_NO_MEMORY;
8396
r->out.needed = talloc_zero(mem_ctx, uint32_t);
8397
if (r->out.needed == NULL) {
8398
return NT_STATUS_NO_MEMORY;
8401
r->out.result = _spoolss_EnumPrinterDataEx(cli->pipes_struct, r);
8402
return NT_STATUS_OK;
8405
case NDR_SPOOLSS_ENUMPRINTERKEY: {
8406
struct spoolss_EnumPrinterKey *r = (struct spoolss_EnumPrinterKey *)_r;
8407
ZERO_STRUCT(r->out);
8408
r->out._ndr_size = talloc_zero(mem_ctx, uint32_t);
8409
if (r->out._ndr_size == NULL) {
8410
return NT_STATUS_NO_MEMORY;
8413
r->out.key_buffer = talloc_zero(mem_ctx, union spoolss_KeyNames);
8414
if (r->out.key_buffer == NULL) {
8415
return NT_STATUS_NO_MEMORY;
8418
r->out.needed = talloc_zero(mem_ctx, uint32_t);
8419
if (r->out.needed == NULL) {
8420
return NT_STATUS_NO_MEMORY;
8423
r->out.result = _spoolss_EnumPrinterKey(cli->pipes_struct, r);
8424
return NT_STATUS_OK;
8427
case NDR_SPOOLSS_DELETEPRINTERDATAEX: {
8428
struct spoolss_DeletePrinterDataEx *r = (struct spoolss_DeletePrinterDataEx *)_r;
8429
r->out.result = _spoolss_DeletePrinterDataEx(cli->pipes_struct, r);
8430
return NT_STATUS_OK;
8433
case NDR_SPOOLSS_DELETEPRINTERKEY: {
8434
struct spoolss_DeletePrinterKey *r = (struct spoolss_DeletePrinterKey *)_r;
8435
r->out.result = _spoolss_DeletePrinterKey(cli->pipes_struct, r);
8436
return NT_STATUS_OK;
8439
case NDR_SPOOLSS_53: {
8440
struct spoolss_53 *r = (struct spoolss_53 *)_r;
8441
r->out.result = _spoolss_53(cli->pipes_struct, r);
8442
return NT_STATUS_OK;
8445
case NDR_SPOOLSS_DELETEPRINTERDRIVEREX: {
8446
struct spoolss_DeletePrinterDriverEx *r = (struct spoolss_DeletePrinterDriverEx *)_r;
8447
r->out.result = _spoolss_DeletePrinterDriverEx(cli->pipes_struct, r);
8448
return NT_STATUS_OK;
8451
case NDR_SPOOLSS_55: {
8452
struct spoolss_55 *r = (struct spoolss_55 *)_r;
8453
r->out.result = _spoolss_55(cli->pipes_struct, r);
8454
return NT_STATUS_OK;
8457
case NDR_SPOOLSS_56: {
8458
struct spoolss_56 *r = (struct spoolss_56 *)_r;
8459
r->out.result = _spoolss_56(cli->pipes_struct, r);
8460
return NT_STATUS_OK;
8463
case NDR_SPOOLSS_57: {
8464
struct spoolss_57 *r = (struct spoolss_57 *)_r;
8465
r->out.result = _spoolss_57(cli->pipes_struct, r);
8466
return NT_STATUS_OK;
8469
case NDR_SPOOLSS_XCVDATA: {
8470
struct spoolss_XcvData *r = (struct spoolss_XcvData *)_r;
8471
ZERO_STRUCT(r->out);
8472
r->out.status_code = r->in.status_code;
8473
r->out.out_data = talloc_zero_array(mem_ctx, uint8_t, r->in.out_data_size);
8474
if (r->out.out_data == NULL) {
8475
return NT_STATUS_NO_MEMORY;
8478
r->out.needed = talloc_zero(mem_ctx, uint32_t);
8479
if (r->out.needed == NULL) {
8480
return NT_STATUS_NO_MEMORY;
8483
r->out.result = _spoolss_XcvData(cli->pipes_struct, r);
8484
return NT_STATUS_OK;
8487
case NDR_SPOOLSS_ADDPRINTERDRIVEREX: {
8488
struct spoolss_AddPrinterDriverEx *r = (struct spoolss_AddPrinterDriverEx *)_r;
8489
r->out.result = _spoolss_AddPrinterDriverEx(cli->pipes_struct, r);
8490
return NT_STATUS_OK;
8493
case NDR_SPOOLSS_5A: {
8494
struct spoolss_5a *r = (struct spoolss_5a *)_r;
8495
r->out.result = _spoolss_5a(cli->pipes_struct, r);
8496
return NT_STATUS_OK;
8499
case NDR_SPOOLSS_5B: {
8500
struct spoolss_5b *r = (struct spoolss_5b *)_r;
8501
r->out.result = _spoolss_5b(cli->pipes_struct, r);
8502
return NT_STATUS_OK;
8505
case NDR_SPOOLSS_5C: {
8506
struct spoolss_5c *r = (struct spoolss_5c *)_r;
8507
r->out.result = _spoolss_5c(cli->pipes_struct, r);
8508
return NT_STATUS_OK;
8511
case NDR_SPOOLSS_5D: {
8512
struct spoolss_5d *r = (struct spoolss_5d *)_r;
8513
r->out.result = _spoolss_5d(cli->pipes_struct, r);
8514
return NT_STATUS_OK;
8517
case NDR_SPOOLSS_5E: {
8518
struct spoolss_5e *r = (struct spoolss_5e *)_r;
8519
r->out.result = _spoolss_5e(cli->pipes_struct, r);
8520
return NT_STATUS_OK;
8523
case NDR_SPOOLSS_5F: {
8524
struct spoolss_5f *r = (struct spoolss_5f *)_r;
8525
r->out.result = _spoolss_5f(cli->pipes_struct, r);
8526
return NT_STATUS_OK;
8530
return NT_STATUS_NOT_IMPLEMENTED;
8534
NTSTATUS rpc_spoolss_init(void)
8536
return rpc_srv_register(SMB_RPC_INTERFACE_VERSION, "spoolss", "spoolss", &ndr_table_spoolss, api_spoolss_cmds, sizeof(api_spoolss_cmds) / sizeof(struct api_struct));