summaryrefslogtreecommitdiff
path: root/source4
diff options
context:
space:
mode:
authorGünther Deschner <gd@samba.org>2010-03-05 20:32:16 +0100
committerKarolin Seeger <kseeger@samba.org>2010-03-29 09:41:03 +0200
commiteab076af34ab09429adc09b9e036cd10a029172b (patch)
tree6a8efe32cbb926480e095092e802b14cb3617470 /source4
parent20f63aa00b2cc4f5a09b531ddad22f0b814ac74c (diff)
downloadsamba-eab076af34ab09429adc09b9e036cd10a029172b.tar.gz
s4-smbtorture: fix RPC-SPOOLSS-WIN after PrinterData IDL changes.
Guenther (cherry picked from commit 58c9070746a3e0725f5d3a3ce6deda8fad0c5974) (cherry picked from commit 71a9d145d365d09588ecea1ad8a53535c3638b4f)
Diffstat (limited to 'source4')
-rw-r--r--source4/torture/rpc/spoolss_win.c7
1 files changed, 4 insertions, 3 deletions
diff --git a/source4/torture/rpc/spoolss_win.c b/source4/torture/rpc/spoolss_win.c
index 58344805b1a..8179e86f607 100644
--- a/source4/torture/rpc/spoolss_win.c
+++ b/source4/torture/rpc/spoolss_win.c
@@ -160,7 +160,7 @@ static bool test_GetPrinterData(struct torture_context *tctx,
struct spoolss_GetPrinterData gpd;
uint32_t needed;
enum winreg_Type type;
- union spoolss_PrinterData data;
+ uint8_t *data = talloc_zero_array(tctx, uint8_t, 4);
torture_comment(tctx, "Testing GetPrinterData(%s).\n", value_name);
gpd.in.handle = handle;
@@ -168,7 +168,7 @@ static bool test_GetPrinterData(struct torture_context *tctx,
gpd.in.offered = 4;
gpd.out.needed = &needed;
gpd.out.type = &type;
- gpd.out.data = &data;
+ gpd.out.data = data;
status = dcerpc_spoolss_GetPrinterData(p, tctx, &gpd);
torture_assert_ntstatus_ok(tctx, status, "GetPrinterData failed.");
@@ -176,7 +176,8 @@ static bool test_GetPrinterData(struct torture_context *tctx,
"GetPrinterData did not return expected error value.");
if (W_ERROR_IS_OK(expected_werr)) {
- torture_assert_int_equal(tctx, data.value,
+ uint32_t value = IVAL(data, 0);
+ torture_assert_int_equal(tctx, value,
expected_value,
talloc_asprintf(tctx, "GetPrinterData for %s did not return expected value.", value_name));
}