Calculation of remaining VMs seemed to have been messed up in some of
the earlier design changes. Iterate over all VMs instead of check the
terminated VM context data multiple times.
Signed-off-by: Jouni Malinen <quic_jouni@quicinc.com>
if test_queue:
num_vm = 0
for i in range(num_servers):
- if _vm['proc']:
+ if vm[i]['proc']:
num_vm += 1
if len(test_queue) > num_vm:
if _vm['idx'] + 1 < status_line:
scr.addstr("unexpected exit")
- logger.info("VM[%d] unexpected exit" % i)
+ logger.info("VM[%d] unexpected exit" % _vm['idx'])
updated = True
return updated