summaryrefslogtreecommitdiff
path: root/source4
diff options
context:
space:
mode:
authorGünther Deschner <gd@samba.org>2010-12-13 15:46:05 +0100
committerGünther Deschner <gd@samba.org>2010-12-14 22:42:17 +0100
commit0990f6342ed3f765c482ddf0baddeac850422352 (patch)
treec4d9984e8fee2ad69ea5f4e687d661805fb23095 /source4
parent77c1747f2148cf9f84f41a974fab6fa534cb0a45 (diff)
downloadsamba-0990f6342ed3f765c482ddf0baddeac850422352.tar.gz
samba-0990f6342ed3f765c482ddf0baddeac850422352.tar.bz2
samba-0990f6342ed3f765c482ddf0baddeac850422352.zip
s4-smbtorture: paranoia check for architectures in request and reply for enumdrivers test.
Guenther
Diffstat (limited to 'source4')
-rw-r--r--source4/torture/rpc/spoolss.c10
1 files changed, 10 insertions, 0 deletions
diff --git a/source4/torture/rpc/spoolss.c b/source4/torture/rpc/spoolss.c
index 26e53eb252..925b703dd7 100644
--- a/source4/torture/rpc/spoolss.c
+++ b/source4/torture/rpc/spoolss.c
@@ -569,6 +569,7 @@ static bool test_EnumPrinterDrivers_findone(struct torture_context *tctx,
uint32_t count;
union spoolss_DriverInfo *info;
int i;
+ const char *environment_ret = NULL;
torture_assert(tctx,
test_EnumPrinterDrivers_args(tctx, b, server_name, environment, level, &count, &info),
@@ -582,28 +583,37 @@ static bool test_EnumPrinterDrivers_findone(struct torture_context *tctx,
break;
case 2:
driver_name_ret = info[i].info2.driver_name;
+ environment_ret = info[i].info2.architecture;
break;
case 3:
driver_name_ret = info[i].info3.driver_name;
+ environment_ret = info[i].info3.architecture;
break;
case 4:
driver_name_ret = info[i].info4.driver_name;
+ environment_ret = info[i].info4.architecture;
break;
case 5:
driver_name_ret = info[i].info5.driver_name;
+ environment_ret = info[i].info5.architecture;
break;
case 6:
driver_name_ret = info[i].info6.driver_name;
+ environment_ret = info[i].info6.architecture;
break;
case 7:
driver_name_ret = info[i].info7.driver_name;
break;
case 8:
driver_name_ret = info[i].info8.driver_name;
+ environment_ret = info[i].info8.architecture;
break;
default:
break;
}
+ if (environment_ret) {
+ torture_assert_str_equal(tctx, environment, environment_ret, "architecture mismatch");
+ }
if (strequal(driver_name, driver_name_ret)) {
return true;
}