diff options
author | Günther Deschner <gd@samba.org> | 2009-02-06 12:32:57 +0100 |
---|---|---|
committer | Günther Deschner <gd@samba.org> | 2009-02-06 14:59:21 +0100 |
commit | 0d4dbe6012ee6f15256de14f8d4d6b32eb4ca313 (patch) | |
tree | 6f56c8f07b22d3392a9177d47f27029ef6ad2344 | |
parent | b970eb791cdf8893881bab3c113fdd5f2ff9866e (diff) | |
download | samba-0d4dbe6012ee6f15256de14f8d4d6b32eb4ca313.tar.gz samba-0d4dbe6012ee6f15256de14f8d4d6b32eb4ca313.tar.bz2 samba-0d4dbe6012ee6f15256de14f8d4d6b32eb4ca313.zip |
s4-smbtorture: fix test_GetPrinterDriverDirectory.
Guenther
-rw-r--r-- | source4/torture/rpc/spoolss.c | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/source4/torture/rpc/spoolss.c b/source4/torture/rpc/spoolss.c index a2965ad05f..3c5fcabbd2 100644 --- a/source4/torture/rpc/spoolss.c +++ b/source4/torture/rpc/spoolss.c @@ -191,6 +191,7 @@ static bool test_GetPrinterDriverDirectory(struct torture_context *tctx, } }; int i; + uint32_t needed; for (i=0;i<ARRAY_SIZE(levels);i++) { int level = levels[i].level; @@ -201,6 +202,7 @@ static bool test_GetPrinterDriverDirectory(struct torture_context *tctx, r.in.level = level; r.in.buffer = NULL; r.in.offered = 0; + r.out.needed = &needed; torture_comment(tctx, "Testing GetPrinterDriverDirectory level %u\n", r.in.level); @@ -210,10 +212,10 @@ static bool test_GetPrinterDriverDirectory(struct torture_context *tctx, torture_assert_werr_equal(tctx, r.out.result, WERR_INSUFFICIENT_BUFFER, "GetPrinterDriverDirectory unexpected return code"); - blob = data_blob_talloc(ctx, NULL, r.out.needed); + blob = data_blob_talloc(ctx, NULL, needed); data_blob_clear(&blob); r.in.buffer = &blob; - r.in.offered = r.out.needed; + r.in.offered = needed; status = dcerpc_spoolss_GetPrinterDriverDirectory(p, ctx, &r); torture_assert_ntstatus_ok(tctx, status, "dcerpc_spoolss_GetPrinterDriverDirectory failed"); |