diff options
author | Andrew Tridgell <tridge@samba.org> | 2009-10-20 10:59:40 +1100 |
---|---|---|
committer | Stefan Metzmacher <metze@samba.org> | 2009-12-16 08:03:49 +0100 |
commit | 805ef91707e70177ab2c9bf9c7280a1e1be8f476 (patch) | |
tree | fa074eadd78225dfa11040e3e71afaddaf181ddd /ctdb | |
parent | 8fd54bbbe1cb1e34db0c4f58f02f2eb0de5b1b43 (diff) | |
download | samba-805ef91707e70177ab2c9bf9c7280a1e1be8f476.tar.gz samba-805ef91707e70177ab2c9bf9c7280a1e1be8f476.tar.xz samba-805ef91707e70177ab2c9bf9c7280a1e1be8f476.zip |
tdb: fixed the intermittent failure of tdbtorture in the build farm
There was a race condition that caused the torture.tdb to be left in a
state that needed recovery. The torture code thought that any message
from the tdb code was an error, so the "recovered" message, which is a
TDB_DEBUG_TRACE message, marked the run as being an error when it
isn't.
(cherry picked from samba commit 5dcf0069b68149575fe6166019dd90b73885926b)
Signed-off-by: Stefan Metzmacher <metze@samba.org>
(This used to be ctdb commit 43c97b259b19c42b4edc7f83dbfc5e486568b4e3)
Diffstat (limited to 'ctdb')
-rw-r--r-- | ctdb/lib/tdb/tools/tdbtorture.c | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/ctdb/lib/tdb/tools/tdbtorture.c b/ctdb/lib/tdb/tools/tdbtorture.c index 9265cf07aa..4e73fdd3a2 100644 --- a/ctdb/lib/tdb/tools/tdbtorture.c +++ b/ctdb/lib/tdb/tools/tdbtorture.c @@ -35,8 +35,11 @@ static void tdb_log(struct tdb_context *tdb, enum tdb_debug_level level, const c static void tdb_log(struct tdb_context *tdb, enum tdb_debug_level level, const char *format, ...) { va_list ap; - - error_count++; + + /* trace level messages do not indicate an error */ + if (level != TDB_DEBUG_TRACE) { + error_count++; + } va_start(ap, format); vfprintf(stdout, format, ap); |