summaryrefslogtreecommitdiff
path: root/lib/tdb/common
diff options
context:
space:
mode:
Diffstat (limited to 'lib/tdb/common')
-rw-r--r--lib/tdb/common/lock.c5
1 files changed, 4 insertions, 1 deletions
diff --git a/lib/tdb/common/lock.c b/lib/tdb/common/lock.c
index b89cb2dd32..7155a9f470 100644
--- a/lib/tdb/common/lock.c
+++ b/lib/tdb/common/lock.c
@@ -374,7 +374,10 @@ static int tdb_lock_list(struct tdb_context *tdb, int list, int ltype,
return tdb_lock_covered_by_allrecord_lock(tdb, ltype);
}
- /* Only check when we grab first data lock. */
+ /*
+ * Check for recoveries: Someone might have kill -9'ed a process
+ * during a commit.
+ */
check = !have_data_locks(tdb);
ret = tdb_nest_lock(tdb, lock_offset(list), ltype, waitflag);