[PATCH] fix gencache_stabilize

Michael Adam obnox at samba.org
Wed Feb 4 06:58:32 MST 2015


review / push appreciated

Thanks - Michael

-------------- next part --------------
From de9071471743be584935f489578215f8fd6bd1ac Mon Sep 17 00:00:00 2001
From: Michael Adam <obnox at samba.org>
Date: Wed, 4 Feb 2015 14:47:20 +0100
Subject: [PATCH] gencache: don't fail gencache_stabilize if there were records
 to delete.

Signed-off-by: Michael Adam <obnox at samba.org>
---
 source3/lib/gencache.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/source3/lib/gencache.c b/source3/lib/gencache.c
index baedf85..d9cc081 100644
--- a/source3/lib/gencache.c
+++ b/source3/lib/gencache.c
@@ -691,7 +691,7 @@ bool gencache_stabilize(void)
 	}
 
 	res = tdb_traverse(cache_notrans->tdb, wipe_fn, NULL);
-	if (res != 0) {
+	if (res < 0) {
 		DEBUG(10, ("tdb_traverse with wipe_fn on gencache_notrans.tdb "
 			  "failed: %s\n",
 			   tdb_errorstr_compat(cache_notrans->tdb)));
-- 
2.1.0

-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 198 bytes
Desc: not available
URL: <http://lists.samba.org/pipermail/samba-technical/attachments/20150204/f9f553b9/attachment.pgp>


More information about the samba-technical mailing list