diff --git a/src/client.rs b/src/client.rs index d240e3e..26b1fd1 100644 --- a/src/client.rs +++ b/src/client.rs @@ -222,9 +222,9 @@ impl Client { let mut failed = false; // Manager will not start the tests until children reply the Ready command - self.base.process_ready_command(&mut failed); + let exit = self.base.process_ready_command(&mut failed); - if !failed { + if !exit && !failed { if let Ok(tcp_stream) = self.connect_tcp_stream(&mut failed) { self.base.configure_tcp_stream(&tcp_stream); diff --git a/src/server.rs b/src/server.rs index fb1dd18..b603452 100644 --- a/src/server.rs +++ b/src/server.rs @@ -183,14 +183,13 @@ impl Server { let mut stream_id = 1; let mut tcp_stream_trials = 0; - let mut exit; let mut failed = false; // nonblocking is necessary to get the next stream (connection) server.set_nonblocking(true).unwrap(); // Manager will not start the tests until children reply the Ready command - exit = self.base.process_ready_command(&mut failed); + let mut exit = self.base.process_ready_command(&mut failed); if !exit && !failed { self.base.cmd_trials = 0; diff --git a/src/testend.rs b/src/testend.rs index e03361b..801dfea 100644 --- a/src/testend.rs +++ b/src/testend.rs @@ -570,6 +570,7 @@ impl TestEndBase { if e == CommandError::Fail { *failed = true; } else if e == CommandError::Disconnect { + // Actually CommandError::Disconnect error is never set while processing the ready command break false; } break true;