From 604c7b87e054a9870a12c1d804eec332b6c7b5ad Mon Sep 17 00:00:00 2001 From: Amitay Isaacs Date: Wed, 14 Feb 2018 15:23:07 +1100 Subject: ctdb-vacuum: Remove unnecessary check for zero records in delete list Since no records are deleted from RB tree during step 1, there is no need for the check. Run step 2 unconditionally. BUG: https://bugzilla.samba.org/show_bug.cgi?id=13641 Signed-off-by: Amitay Isaacs Reviewed-by: Martin Schwenke (cherry picked from commit e15cdc652d76b37c58cd114215f00500991bc6b4) --- ctdb/server/ctdb_vacuum.c | 6 ------ 1 file changed, 6 deletions(-) (limited to 'ctdb') diff --git a/ctdb/server/ctdb_vacuum.c b/ctdb/server/ctdb_vacuum.c index 8faf803efb9..2194b7f4da7 100644 --- a/ctdb/server/ctdb_vacuum.c +++ b/ctdb/server/ctdb_vacuum.c @@ -854,10 +854,6 @@ static void ctdb_process_delete_list(struct ctdb_db_context *ctdb_db, } } - if (vdata->count.delete_list.left == 0) { - goto success; - } - /* * Step 2: * Delete the remaining records locally. @@ -873,8 +869,6 @@ static void ctdb_process_delete_list(struct ctdb_db_context *ctdb_db, "delete list for deletion.\n")); } -success: - if (vdata->count.delete_list.left != 0) { DEBUG(DEBUG_ERR, (__location__ " Vaccum db[%s] error: " "there are %u records left for deletion after " -- cgit v1.2.1