diff options
author | Günther Deschner <gd@samba.org> | 2010-04-27 23:33:05 +0200 |
---|---|---|
committer | Günther Deschner <gd@samba.org> | 2010-04-28 00:10:41 +0200 |
commit | b87b1de83432611e511e511d0320b8c1c1a8b323 (patch) | |
tree | eaef793ce60cfe27a91af6fe175304bca370dfe8 | |
parent | 2af449391b28dda10ebb797fcf61e2319b36a0b0 (diff) | |
download | samba-b87b1de83432611e511e511d0320b8c1c1a8b323.tar.gz samba-b87b1de83432611e511e511d0320b8c1c1a8b323.tar.bz2 samba-b87b1de83432611e511e511d0320b8c1c1a8b323.zip |
s4-smbtorture: allow to pass down spoolss_JobInfoContainer to SetJob functions.
Guenther
-rw-r--r-- | source4/torture/rpc/spoolss.c | 12 |
1 files changed, 7 insertions, 5 deletions
diff --git a/source4/torture/rpc/spoolss.c b/source4/torture/rpc/spoolss.c index 05049c11ce..09bb4bd66b 100644 --- a/source4/torture/rpc/spoolss.c +++ b/source4/torture/rpc/spoolss.c @@ -2954,7 +2954,9 @@ static bool test_GetJob(struct torture_context *tctx, static bool test_SetJob(struct torture_context *tctx, struct dcerpc_binding_handle *b, - struct policy_handle *handle, uint32_t job_id, + struct policy_handle *handle, + uint32_t job_id, + struct spoolss_JobInfoContainer *ctr, enum spoolss_JobControl command) { NTSTATUS status; @@ -2962,7 +2964,7 @@ static bool test_SetJob(struct torture_context *tctx, r.in.handle = handle; r.in.job_id = job_id; - r.in.ctr = NULL; + r.in.ctr = ctr; r.in.command = command; switch (command) { @@ -3191,10 +3193,10 @@ static bool test_DoPrintTest_check_jobs(struct torture_context *tctx, } for (i=0; i < num_jobs; i++) { - if (!test_SetJob(tctx, b, handle, info[i].info1.job_id, SPOOLSS_JOB_CONTROL_PAUSE)) { + if (!test_SetJob(tctx, b, handle, info[i].info1.job_id, NULL, SPOOLSS_JOB_CONTROL_PAUSE)) { torture_warning(tctx, "failed to pause printjob\n"); } - if (!test_SetJob(tctx, b, handle, info[i].info1.job_id, SPOOLSS_JOB_CONTROL_RESUME)) { + if (!test_SetJob(tctx, b, handle, info[i].info1.job_id, NULL, SPOOLSS_JOB_CONTROL_RESUME)) { torture_warning(tctx, "failed to resume printjob\n"); } } @@ -3220,7 +3222,7 @@ static bool test_DoPrintTest(struct torture_context *tctx, ret &= test_DoPrintTest_check_jobs(tctx, b, handle, num_jobs, job_ids); for (i=0; i < num_jobs; i++) { - ret &= test_SetJob(tctx, b, handle, job_ids[i], SPOOLSS_JOB_CONTROL_DELETE); + ret &= test_SetJob(tctx, b, handle, job_ids[i], NULL, SPOOLSS_JOB_CONTROL_DELETE); } return ret; |