Author: obnox
Date: 2007-07-19 14:22:24 +0000 (Thu, 19 Jul 2007)
New Revision: 23975

WebSVN: 
http://websvn.samba.org/cgi-bin/viewcvs.cgi?view=rev&root=samba&rev=23975

Log:
Enhance some debug output.


Modified:
   branches/SAMBA_3_2/source/lib/util_tdb.c
   branches/SAMBA_3_2_0/source/lib/util_tdb.c


Changeset:
Modified: branches/SAMBA_3_2/source/lib/util_tdb.c
===================================================================
--- branches/SAMBA_3_2/source/lib/util_tdb.c    2007-07-19 14:08:01 UTC (rev 
23974)
+++ branches/SAMBA_3_2/source/lib/util_tdb.c    2007-07-19 14:22:24 UTC (rev 
23975)
@@ -1145,7 +1145,8 @@
        struct tdb_copy_data *data = (struct tdb_copy_data *)private_data;
 
        if (tdb_store(data->dst, key, dbuf, TDB_INSERT) != 0) {
-               DEBUG(4, ("Failed to insert into %s\n", tdb_name(data->dst)));
+               DEBUG(4, ("Failed to insert into %s: %s\n", tdb_name(data->dst),
+                         strerror(errno)));
                data->success = False;
                return 1;
        }
@@ -1217,7 +1218,8 @@
 
        count1 = tdb_copy(src_tdb, dst_tdb);
        if (count1 < 0) {
-               DEBUG(3, ("Failed to copy tdb '%s'\n", src_path));
+               DEBUG(3, ("Failed to copy tdb '%s': %s\n", src_path,
+                         strerror(errno)));
                tdb_close(dst_tdb);
                goto done;
        }

Modified: branches/SAMBA_3_2_0/source/lib/util_tdb.c
===================================================================
--- branches/SAMBA_3_2_0/source/lib/util_tdb.c  2007-07-19 14:08:01 UTC (rev 
23974)
+++ branches/SAMBA_3_2_0/source/lib/util_tdb.c  2007-07-19 14:22:24 UTC (rev 
23975)
@@ -1145,7 +1145,8 @@
        struct tdb_copy_data *data = (struct tdb_copy_data *)private_data;
 
        if (tdb_store(data->dst, key, dbuf, TDB_INSERT) != 0) {
-               DEBUG(4, ("Failed to insert into %s\n", tdb_name(data->dst)));
+               DEBUG(4, ("Failed to insert into %s: %s\n", tdb_name(data->dst),
+                         strerror(errno)));
                data->success = False;
                return 1;
        }
@@ -1217,7 +1218,8 @@
 
        count1 = tdb_copy(src_tdb, dst_tdb);
        if (count1 < 0) {
-               DEBUG(3, ("Failed to copy tdb '%s'\n", src_path));
+               DEBUG(3, ("Failed to copy tdb '%s': %s\n", src_path,
+                         strerror(errno)));
                tdb_close(dst_tdb);
                goto done;
        }

Reply via email to