From 6c4570d9c72569b8301ad5b0be6530ab1ef0f439 Mon Sep 17 00:00:00 2001 From: David Disseldorp Date: Wed, 3 Dec 2014 18:44:37 +0100 Subject: [PATCH] torture/spoolss: issue GetJob after StartDocPrinter This reflects Windows XP spoolss client behaviour. This fails if the job is not yet instantiated on the server, and prior to the bso#10984 fix resulted in an unsable DCERPC pipe. Signed-off-by: David Disseldorp Reviewed-by: Andreas Schneider Autobuild-User(master): Andreas Schneider Autobuild-Date(master): Fri Dec 19 18:03:20 CET 2014 on sn-devel-104 --- source4/torture/rpc/spoolss.c | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/source4/torture/rpc/spoolss.c b/source4/torture/rpc/spoolss.c index 20e86fc16a7..23f501d7401 100644 --- a/source4/torture/rpc/spoolss.c +++ b/source4/torture/rpc/spoolss.c @@ -3446,6 +3446,9 @@ static bool test_DoPrintTest_add_one_job_common(struct torture_context *tctx, torture_assert_werr_ok(tctx, s.out.result, "StartDocPrinter failed"); for (i=1; i < 4; i++) { + union spoolss_JobInfo ginfo; + bool ok; + torture_comment(tctx, "Testing StartPagePrinter: Page[%d], JobId[%d]\n", i, *job_id); sp.in.handle = handle; @@ -3455,6 +3458,11 @@ static bool test_DoPrintTest_add_one_job_common(struct torture_context *tctx, "dcerpc_spoolss_StartPagePrinter failed"); torture_assert_werr_ok(tctx, sp.out.result, "StartPagePrinter failed"); + ok = test_GetJob_args(tctx, b, handle, *job_id, 1, &ginfo); + if (!ok) { + torture_comment(tctx, "test_GetJob failed for JobId[%d]\n", *job_id); + } + torture_comment(tctx, "Testing WritePrinter: Page[%d], JobId[%d]\n", i, *job_id); w.in.handle = handle; -- 2.34.1