summaryrefslogtreecommitdiff
path: root/source4/torture
diff options
context:
space:
mode:
authorAndreas Schneider <asn@samba.org>2013-02-19 09:32:30 +0100
committerAlexander Bokovoy <ab@samba.org>2013-02-22 16:36:13 +0100
commitaff301d9ebc4f5c1be059838a8a6ef6b38129f88 (patch)
tree7b21f59627ba85aba20deaf982392d7a42ef2aaa /source4/torture
parentb510e5e6c4332356067331c7afff47f7dbf587fc (diff)
downloadsamba-aff301d9ebc4f5c1be059838a8a6ef6b38129f88.tar.gz
samba-aff301d9ebc4f5c1be059838a8a6ef6b38129f88.tar.bz2
samba-aff301d9ebc4f5c1be059838a8a6ef6b38129f88.zip
torture: Fix array access in spoolss test.
Reviewed-by: Alexander Bokovoy <ab@samba.org>
Diffstat (limited to 'source4/torture')
-rw-r--r--source4/torture/rpc/spoolss.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/source4/torture/rpc/spoolss.c b/source4/torture/rpc/spoolss.c
index f08e93bfaa..7d9ae99465 100644
--- a/source4/torture/rpc/spoolss.c
+++ b/source4/torture/rpc/spoolss.c
@@ -679,8 +679,8 @@ static bool test_EnumPrinterDrivers(struct torture_context *tctx,
for (i=0;i<ARRAY_SIZE(levels);i++) {
int level = levels[i];
- for (j=0;j<ctx->driver_count[level];j++) {
- union spoolss_DriverInfo *cur = &ctx->drivers[level][j];
+ for (j=0;j<ctx->driver_count[level - 1];j++) {
+ union spoolss_DriverInfo *cur = &ctx->drivers[level - 1][j];
union spoolss_DriverInfo *ref = &ctx->drivers[8][j];
switch (level) {