summaryrefslogtreecommitdiff
path: root/source3
diff options
context:
space:
mode:
authorAndrew Tridgell <tridge@samba.org>1998-04-12 02:53:17 +0000
committerAndrew Tridgell <tridge@samba.org>1998-04-12 02:53:17 +0000
commitfc9065b3606cbe1b11fe009b117195abbcf07fad (patch)
treef17e1f6a44586ff1ad6dd89ff58072ccd797568a /source3
parent77da897307806830ecf36f0e4de41cf51d826e79 (diff)
downloadsamba-fc9065b3606cbe1b11fe009b117195abbcf07fad.tar.gz
samba-fc9065b3606cbe1b11fe009b117195abbcf07fad.tar.bz2
samba-fc9065b3606cbe1b11fe009b117195abbcf07fad.zip
some hacks to the torture code
(This used to be commit 02786747ee6774f617d95b08a5c5912bf86e7586)
Diffstat (limited to 'source3')
-rw-r--r--source3/utils/torture.c11
1 files changed, 10 insertions, 1 deletions
diff --git a/source3/utils/torture.c b/source3/utils/torture.c
index 049a414eb9..c7fded6b3f 100644
--- a/source3/utils/torture.c
+++ b/source3/utils/torture.c
@@ -116,7 +116,8 @@ static BOOL rw_torture(struct cli_state *c, int numops)
int fnum;
int fnum2;
int pid2, pid = getpid();
- int i;
+ int i, j;
+ char buf[1024];
fnum2 = cli_open(c, lockfname, O_RDWR | O_CREAT | O_EXCL,
DENY_NONE);
@@ -149,6 +150,14 @@ static BOOL rw_torture(struct cli_state *c, int numops)
printf("write failed (%s)\n", cli_errstr(c));
}
+ for (j=0;j<50;j++) {
+ if (cli_write(c, fnum, (char *)buf,
+ sizeof(pid)+(j*sizeof(buf)),
+ sizeof(buf)) != sizeof(buf)) {
+ printf("write failed (%s)\n", cli_errstr(c));
+ }
+ }
+
pid2 = 0;
if (cli_read(c, fnum, (char *)&pid2, 0, sizeof(pid)) != sizeof(pid)) {