diff --git a/lib/ansible/executor/playbook_executor.py b/lib/ansible/executor/playbook_executor.py index 0c18ad3c89..4e77838559 100644 --- a/lib/ansible/executor/playbook_executor.py +++ b/lib/ansible/executor/playbook_executor.py @@ -120,7 +120,6 @@ class PlaybookExecutor: if len(batch) == 0: self._tqm.send_callback('v2_playbook_on_play_start', new_play) self._tqm.send_callback('v2_playbook_on_no_hosts_matched') - result = 1 break # restrict the inventory to the hosts in the serialized batch self._inventory.restrict_to_hosts(batch) diff --git a/lib/ansible/plugins/strategies/linear.py b/lib/ansible/plugins/strategies/linear.py index e92f10eb37..b60a922f83 100644 --- a/lib/ansible/plugins/strategies/linear.py +++ b/lib/ansible/plugins/strategies/linear.py @@ -122,9 +122,8 @@ class StrategyModule(StrategyBase): moving on to the next task ''' - result = True - # iteratate over each task, while there is one left to run + result = True work_to_do = True while work_to_do and not self._tqm._terminated: