]> git.ipfire.org Git - thirdparty/samba.git/commitdiff
ctdb-recovery: Terminate if recovery fails without any banning credits
authorAmitay Isaacs <amitay@gmail.com>
Thu, 23 Jun 2016 11:07:37 +0000 (21:07 +1000)
committerMartin Schwenke <martins@samba.org>
Fri, 24 Jun 2016 07:56:23 +0000 (09:56 +0200)
In case of database recovery failure, if there are no banning credits
assigned, then the async computation is never terminated.  The else
condition is missing in (max_credits >= NUM_RETRIES) check.

Signed-off-by: Amitay Isaacs <amitay@gmail.com>
Reviewed-by: Martin Schwenke <martin@meltin.net>
Autobuild-User(master): Martin Schwenke <martins@samba.org>
Autobuild-Date(master): Fri Jun 24 09:56:23 CEST 2016 on sn-devel-144

ctdb/server/ctdb_recovery_helper.c

index 691196e57010bc4ba95410b3de142d807d5f4e5e..6b487b9b852c8709b7bf4e65478b5329147e096a 100644 (file)
@@ -2609,6 +2609,8 @@ static void recovery_db_recovery_done(struct tevent_req *subreq)
                        }
                        tevent_req_set_callback(subreq, recovery_failed_done,
                                                req);
+               } else {
+                       tevent_req_error(req, EIO);
                }
                return;
        }