Skip to content

Commit f2c9fed

Browse files
kanavinrpurdie
authored andcommitted
lib/oeqa/utils/sshcontrol: correct condition for ending the select() loop
This was set backwards; per https://docs.python.org/3/library/subprocess.html#subprocess.Popen.returncode a return code of None indicates the process is still running, and so the code entered a busyloop that ended on timeout 5 minutes later, lengthening selftests significantly. Signed-off-by: Alexander Kanavin <alex@linutronix.de> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
1 parent 8d2680b commit f2c9fed

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

meta/lib/oeqa/utils/sshcontrol.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -58,7 +58,7 @@ def _run(self, command, timeout=None, logfile=None):
5858
data = os.read(self.process.stdout.fileno(), 1024)
5959
if not data:
6060
self.process.poll()
61-
if self.process.returncode is None:
61+
if self.process.returncode is not None:
6262
self.process.stdout.close()
6363
eof = True
6464
else:

0 commit comments

Comments
 (0)