summaryrefslogtreecommitdiff
path: root/source3
diff options
context:
space:
mode:
authorRusty Russell <rusty@rustcorp.com.au>2011-09-14 07:13:13 +0930
committerRusty Russell <rusty@rustcorp.com.au>2011-09-14 07:13:13 +0930
commit376511ed4defeeeabcfaa83acd230afd4a46b6fd (patch)
tree645c7363da2368089f947d872f14f98bb6752a00 /source3
parentab61a57e0177ff50a22a8feea38abbf02edfd5da (diff)
downloadsamba-376511ed4defeeeabcfaa83acd230afd4a46b6fd.tar.gz
samba-376511ed4defeeeabcfaa83acd230afd4a46b6fd.tar.bz2
samba-376511ed4defeeeabcfaa83acd230afd4a46b6fd.zip
tdb_compat: adapt to tdb2 API change.
Add the ecode arg to all the log functions, and log it. Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
Diffstat (limited to 'source3')
-rw-r--r--source3/lib/util_tdb.c7
1 files changed, 4 insertions, 3 deletions
diff --git a/source3/lib/util_tdb.c b/source3/lib/util_tdb.c
index 93842e4126..1ba5ed4120 100644
--- a/source3/lib/util_tdb.c
+++ b/source3/lib/util_tdb.c
@@ -472,10 +472,11 @@ int tdb_unpack(const uint8 *buf, int bufsize, const char *fmt, ...)
#ifdef BUILD_TDB2
static void tdb_log(TDB_CONTEXT *tdb, enum tdb_log_level level,
- const char *message, void *unused)
+ enum TDB_ERROR ecode, const char *message, void *unused)
{
- DEBUG((int)level, ("tdb(%s): %s",
- tdb_name(tdb) ? tdb_name(tdb) : "unnamed", message));
+ DEBUG((int)level, ("tdb(%s):%s: %s",
+ tdb_name(tdb) ? tdb_name(tdb) : "unnamed",
+ tdb_errorstr(ecode), message));
}
#else
static void tdb_log(TDB_CONTEXT *tdb, enum tdb_debug_level level, const char *format, ...)