r14916: print errno so I can work out why OpenBSD is failing the test for tdb
authorAndrew Tridgell <tridge@samba.org>
Wed, 5 Apr 2006 03:51:43 +0000 (03:51 +0000)
committerStefan Metzmacher <metze@sernet.de>
Fri, 8 Feb 2008 15:09:12 +0000 (16:09 +0100)
in the build farm. msync() is failing.
(cherry picked from commit 4c3f3c414135c2b8fa9ea11a156246b56285b84f)

source/lib/tdb/common/transaction.c

index 6960a02ad833b3713a1a0b24bab8dc08ee89c882..aa54c4ae3c89ca937737084782645a1ae02db7d3 100644 (file)
@@ -544,7 +544,8 @@ static int transaction_sync(struct tdb_context *tdb, tdb_off_t offset, tdb_len_t
                if (msync(moffset + (char *)tdb->map_ptr, 
                          length + (offset - moffset), MS_SYNC) != 0) {
                        tdb->ecode = TDB_ERR_IO;
-                       TDB_LOG((tdb, 0, "tdb_transaction: msync failed\n"));
+                       TDB_LOG((tdb, 0, "tdb_transaction: msync failed - %s\n",
+                                strerror(errno)));
                        return -1;
                }
        }