torture: Fix raw.open.chained-openx
authorVolker Lendecke <vl@samba.org>
Thu, 27 Nov 2014 20:44:18 +0000 (21:44 +0100)
committerRalph Böhme <slow@samba.org>
Fri, 28 Nov 2014 12:30:18 +0000 (13:30 +0100)
sizeof(buf) is 5. On FreeBSD10/clang this overwrites "ret". Not good.

Signed-off-by: Volker Lendecke <vl@samba.org>
Reviewed-by: Ralph Boehme <slow@samba.org>
Autobuild-User(master): Ralph Böhme <slow@samba.org>
Autobuild-Date(master): Fri Nov 28 13:30:18 CET 2014 on sn-devel-104

source4/torture/raw/open.c

index 679a7c24f7e824e5e78a6e3eaf3b4435890bce87..616ba5c16efa1df75b13c691b9c807db3c605b77 100644 (file)
@@ -1386,8 +1386,8 @@ static bool test_chained(struct torture_context *tctx, struct smbcli_state *cli)
        io.openxreadx.in.timeout = 0;
        
        io.openxreadx.in.offset = 0;
-       io.openxreadx.in.mincnt = sizeof(buf);
-       io.openxreadx.in.maxcnt = sizeof(buf);
+       io.openxreadx.in.mincnt = sizeof(buf2);
+       io.openxreadx.in.maxcnt = sizeof(buf2);
        io.openxreadx.in.remaining = 0;
        io.openxreadx.out.data = (uint8_t *)buf2;