]> git.sur5r.net Git - openldap/commitdiff
In mdb_audit, change assert to fprintf
authorHoward Chu <hyc@symas.com>
Mon, 27 Aug 2012 21:45:16 +0000 (14:45 -0700)
committerHoward Chu <hyc@symas.com>
Mon, 27 Aug 2012 21:45:16 +0000 (14:45 -0700)
libraries/libmdb/mdb.c

index 67ffff35cf59fb37d3f644c2eeba5288a5ff805d..a2d0cd2e0ab0ddbe11439c1974a5b34271682dd5 100644 (file)
@@ -1137,7 +1137,10 @@ static void mdb_audit(MDB_txn *txn)
                        while (mdb_cursor_sibling(&mc, 1) == 0);
                }
        }
-       assert(freecount + count + 2 /* metapages */ == txn->mt_next_pgno);
+       if (freecount + count + 2 /* metapages */ != txn->mt_next_pgno) {
+               fprintf(stderr, "audit: %lu freecount: %lu count: %lu total: %lu next_pgno: %lu\n",
+                       txn->mt_txnid, freecount, count+2, freecount+count+2, txn->mt_next_pgno);
+       }
 }
 #endif