summaryrefslogtreecommitdiff
path: root/source4
diff options
context:
space:
mode:
authorMatthias Dieter Wallnöfer <mdw@samba.org>2010-11-30 08:32:22 +0100
committerMatthias Dieter Wallnöfer <mdw@samba.org>2010-11-30 09:23:00 +0100
commit10d1cd7af7962a2ce012f426947e9b0538e9f653 (patch)
treefdc62cab205e56ef11bbbfe71a37219b384cab51 /source4
parent2a5daa7ddb67e103ed173559bd2ec60dbe06d816 (diff)
downloadsamba-10d1cd7af7962a2ce012f426947e9b0538e9f653.tar.gz
samba-10d1cd7af7962a2ce012f426947e9b0538e9f653.tar.bz2
samba-10d1cd7af7962a2ce012f426947e9b0538e9f653.zip
s4:torture - partially revert "s4:torture - prefer the termination "return"s at the end of two unittests"
This partially reverts commit 54a5c398aaa1d53b5892c9b0aa5539ae7da651da. As tridge pointed out I've overseen the nested loop in "run_iometer". Therefore we end in a infinite loop. Obviously it wasn't run by "make test" since then I would have detected it. Autobuild-User: Matthias Dieter Wallnöfer <mdw@samba.org> Autobuild-Date: Tue Nov 30 09:23:00 CET 2010 on sn-devel-104
Diffstat (limited to 'source4')
-rw-r--r--source4/torture/basic/base.c6
1 files changed, 2 insertions, 4 deletions
diff --git a/source4/torture/basic/base.c b/source4/torture/basic/base.c
index 0e168ed95b..995357302b 100644
--- a/source4/torture/basic/base.c
+++ b/source4/torture/basic/base.c
@@ -1340,7 +1340,7 @@ static bool run_iometer(struct torture_context *tctx,
for (i=0; i<num_reads; i++) {
ssize_t res;
if (ops++ > torture_numops) {
- break;
+ return true;
}
res = smbcli_read(cli->tree, fnum, buf,
random() % filesize, sizeof(buf));
@@ -1351,7 +1351,7 @@ static bool run_iometer(struct torture_context *tctx,
for (i=0; i<num_writes; i++) {
ssize_t res;
if (ops++ > torture_numops) {
- break;
+ return true;
}
res = smbcli_write(cli->tree, fnum, 0, buf,
random() % filesize, sizeof(buf));
@@ -1360,8 +1360,6 @@ static bool run_iometer(struct torture_context *tctx,
smbcli_errstr(cli->tree)));
}
}
-
- return true;
}
/**