[PATCH] dbwrap: Print wait times with full precision

Christof Schmitt cs at samba.org
Thu Jun 26 12:09:45 MDT 2014


>From 874921a62a52c7bafefe7af67f6e9994538783dd Mon Sep 17 00:00:00 2001
From: Volker Lendecke <vl at samba.org>
Date: Thu, 6 Mar 2014 07:27:36 +0100
Subject: [PATCH] dbwrap: Print wait times with full precision

Signed-off-by: Volker Lendecke <vl at samba.org>
Reviewed-by: Christof Schmitt <cs at samba.org>
---
 source3/lib/dbwrap/dbwrap_ctdb.c |    6 +++---
 1 files changed, 3 insertions(+), 3 deletions(-)

diff --git a/source3/lib/dbwrap/dbwrap_ctdb.c b/source3/lib/dbwrap/dbwrap_ctdb.c
index ca33c8f..0b30d9f 100644
--- a/source3/lib/dbwrap/dbwrap_ctdb.c
+++ b/source3/lib/dbwrap/dbwrap_ctdb.c
@@ -1168,15 +1168,15 @@ again:
 
 		DEBUG(0, ("db_ctdb_fetch_locked for %s key %s, chain %d "
 			  "needed %d attempts, %d milliseconds, "
-			  "chainlock: %d ms, CTDB %d ms\n",
+			  "chainlock: %f ms, CTDB %f ms\n",
 			  tdb_name(ctx->wtdb->tdb),
 			  hex_encode_talloc(talloc_tos(),
 					    (unsigned char *)key.dptr,
 					    key.dsize),
 			  chain,
 			  migrate_attempts, duration_msecs,
-			  (int) chainlock_time * 1000,
-			  (int) ctdb_time * 1000));
+			  chainlock_time * 1000.0,
+			  ctdb_time * 1000.0));
 	}
 
 	GetTimeOfDay(&crec->lock_time);
-- 
1.7.1



More information about the samba-technical mailing list