RFC: dbwrap_ctdb and empty vs deleted records
Ralph Böhme
slow at samba.org
Wed Jul 20 13:17:03 UTC 2016
On Wed, Jul 20, 2016 at 03:14:02PM +0200, Ralph Böhme wrote:
> Meanwhile, here's a patch that paves over the underlying issue in the
> caller.
>
> Please review&push if ok.
gnah, ENOPATCH.
Cheerio!
-slow
-------------- next part --------------
From ddcfc40639ccd42cbdfd45f678656445b1f625ca Mon Sep 17 00:00:00 2001
From: Ralph Boehme <slow at samba.org>
Date: Wed, 20 Jul 2016 12:36:24 +0200
Subject: [PATCH] smbd: ignore ctdb tombstone records in
fetch_share_mode_unlocked_parser()
dbwrap_parse_record() can return ctdb tombstone records from the lctdb,
ignore them.
Bug: https://bugzilla.samba.org/show_bug.cgi?id=12005
Signed-off-by: Ralph Boehme <slow at samba.org>
---
source3/locking/share_mode_lock.c | 6 ++++++
1 file changed, 6 insertions(+)
diff --git a/source3/locking/share_mode_lock.c b/source3/locking/share_mode_lock.c
index b5a63f8..f738323 100644
--- a/source3/locking/share_mode_lock.c
+++ b/source3/locking/share_mode_lock.c
@@ -628,6 +628,12 @@ static void fetch_share_mode_unlocked_parser(
struct share_mode_lock *lck = talloc_get_type_abort(
private_data, struct share_mode_lock);
+ if (data.dsize == 0) {
+ /* Likely a ctdb tombstone record, ignore it */
+ lck->data = NULL;
+ return;
+ }
+
lck->data = parse_share_modes(lck, key, data);
}
--
2.7.4
More information about the samba-technical
mailing list