From 34e7d960d0065a51b5524630a6699834c9b362b1 Mon Sep 17 00:00:00 2001 From: Kelly Yeoh Date: Wed, 25 Jan 2012 14:58:44 +1100 Subject: ldbedit: prevent a transaction warning on failure if a modify fails then cancel the transaction to prevent a dangling transaction error Signed-off-by: Andrew Tridgell Autobuild-User: Andrew Tridgell Autobuild-Date: Wed Jan 25 07:06:40 CET 2012 on sn-devel-104 --- lib/ldb/tools/ldbedit.c | 1 + 1 file changed, 1 insertion(+) (limited to 'lib/ldb/tools') diff --git a/lib/ldb/tools/ldbedit.c b/lib/ldb/tools/ldbedit.c index aaf6d80352..cf4ab3f8ec 100644 --- a/lib/ldb/tools/ldbedit.c +++ b/lib/ldb/tools/ldbedit.c @@ -152,6 +152,7 @@ static int merge_edits(struct ldb_context *ldb, if (ret != -1) { modifies += (unsigned int) ret; } else { + ldb_transaction_cancel(ldb); return -1; } } -- cgit