summaryrefslogtreecommitdiff
path: root/source4/librpc/ndr/ndr_spoolss_buf.c
diff options
context:
space:
mode:
authorTim Potter <tpot@samba.org>2003-11-28 05:02:32 +0000
committerTim Potter <tpot@samba.org>2003-11-28 05:02:32 +0000
commitd419464d87127c9464d1a00976a36774835d196d (patch)
tree60c398e4fd2f0ba5cd8b35c36f8eda43237083e3 /source4/librpc/ndr/ndr_spoolss_buf.c
parent07fdc2c73e03dad5b6030db0e8e488a3834796f5 (diff)
downloadsamba-d419464d87127c9464d1a00976a36774835d196d.tar.gz
samba-d419464d87127c9464d1a00976a36774835d196d.tar.bz2
samba-d419464d87127c9464d1a00976a36774835d196d.zip
Added EnumJobs, GetJob, SetJob RPCs.
(This used to be commit a06cbbbf1fa1e873bb13bc86d14694b2af791e22)
Diffstat (limited to 'source4/librpc/ndr/ndr_spoolss_buf.c')
-rw-r--r--source4/librpc/ndr/ndr_spoolss_buf.c17
1 files changed, 17 insertions, 0 deletions
diff --git a/source4/librpc/ndr/ndr_spoolss_buf.c b/source4/librpc/ndr/ndr_spoolss_buf.c
index 6c12ab2ae5..cd251112c0 100644
--- a/source4/librpc/ndr/ndr_spoolss_buf.c
+++ b/source4/librpc/ndr/ndr_spoolss_buf.c
@@ -57,3 +57,20 @@ NTSTATUS pull_spoolss_FormInfoArray(DATA_BLOB *blob, TALLOC_CTX *mem_ctx,
}
return NT_STATUS_OK;
}
+
+NTSTATUS pull_spoolss_JobInfoArray(DATA_BLOB *blob, TALLOC_CTX *mem_ctx,
+ uint32 level, uint32 count,
+ union spoolss_JobInfo **info)
+{
+ int i;
+ struct ndr_pull *ndr;
+ ndr = ndr_pull_init_blob(blob, mem_ctx);
+ if (!ndr) {
+ return NT_STATUS_NO_MEMORY;
+ }
+ NDR_ALLOC_N(ndr, *info, count);
+ for (i=0;i<count;i++) {
+ NDR_CHECK(ndr_pull_spoolss_JobInfo(ndr, NDR_SCALARS|NDR_BUFFERS, level, &(*info)[i]));
+ }
+ return NT_STATUS_OK;
+}