summaryrefslogtreecommitdiffstats
path: root/source3/lib/dbwrap
diff options
context:
space:
mode:
authorChristof Schmitt <cs@samba.org>2014-01-14 14:23:04 -0700
committerVolker Lendecke <vl@samba.org>2014-01-16 11:19:39 +0100
commit55b431fad575b0ea4bf2b7b2e940f5fcf66751df (patch)
tree0e9dad8ad8306393925f5bec12c5bf3116825ab1 /source3/lib/dbwrap
parent32f232d9ad05d476933641a72cc5899d49cbb220 (diff)
downloadsamba-55b431fad575b0ea4bf2b7b2e940f5fcf66751df.tar.gz
samba-55b431fad575b0ea4bf2b7b2e940f5fcf66751df.tar.xz
samba-55b431fad575b0ea4bf2b7b2e940f5fcf66751df.zip
s3:dbwrap: Use milliseconds for "Held tdb lock" message
This is consistent with the parameter using milliseconds and the other warnings in the same file also using milliseconds. Signed-off-by: Christof Schmitt <cs@samba.org> Reviewed-by: Volker Lendecke <vl@samba.org> Autobuild-User(master): Volker Lendecke <vl@samba.org> Autobuild-Date(master): Thu Jan 16 11:19:39 CET 2014 on sn-devel-104
Diffstat (limited to 'source3/lib/dbwrap')
-rw-r--r--source3/lib/dbwrap/dbwrap_ctdb.c11
1 files changed, 6 insertions, 5 deletions
diff --git a/source3/lib/dbwrap/dbwrap_ctdb.c b/source3/lib/dbwrap/dbwrap_ctdb.c
index a81b97aeb5..98a9138f32 100644
--- a/source3/lib/dbwrap/dbwrap_ctdb.c
+++ b/source3/lib/dbwrap/dbwrap_ctdb.c
@@ -986,16 +986,17 @@ static int db_ctdb_record_destr(struct db_record* data)
threshold = crec->ctdb_ctx->warn_locktime_msecs;
if (threshold != 0) {
- timediff = timeval_elapsed(&crec->lock_time);
- if ((timediff * 1000) > threshold) {
+ timediff = timeval_elapsed(&crec->lock_time) * 1000;
+ if (timediff > threshold) {
const char *key;
key = hex_encode_talloc(data,
(unsigned char *)data->key.dptr,
data->key.dsize);
- DEBUG(0, ("Held tdb lock on db %s, key %s %f seconds\n",
- tdb_name(crec->ctdb_ctx->wtdb->tdb), key,
- timediff));
+ DEBUG(0, ("Held tdb lock on db %s, key %s "
+ "%f milliseconds\n",
+ tdb_name(crec->ctdb_ctx->wtdb->tdb),
+ key, timediff));
}
}