diff mbox series

[mickledore,11/13] qemurunner: avoid leaking server_socket

Message ID fb1de20b22119fd62b338ab69cd2b6a6c4e9dd8f.1685672395.git.steve@sakoman.com
State New
Headers show
Series [mickledore,01/13] linux-yocto/5.15: update to v5.15.109 | expand

Commit Message

Steve Sakoman June 2, 2023, 2:22 a.m. UTC
From: Mikko Rapeli <mikko.rapeli@linaro.org>

close() the server_socket before qemusock replaces

Signed-off-by: Mikko Rapeli <mikko.rapeli@linaro.org>
Signed-off-by: Alexandre Belloni <alexandre.belloni@bootlin.com>
(cherry picked from commit be7bbbeeb44158b181d1abc5a4d7871a9045fdd6)
Signed-off-by: Steve Sakoman <steve@sakoman.com>
 meta/lib/oeqa/utils/qemurunner.py | 1 +
 1 file changed, 1 insertion(+)
diff mbox series


diff --git a/meta/lib/oeqa/utils/qemurunner.py b/meta/lib/oeqa/utils/qemurunner.py
index 6734cee48d..8bb35f5a8b 100644
--- a/meta/lib/oeqa/utils/qemurunner.py
+++ b/meta/lib/oeqa/utils/qemurunner.py
@@ -483,6 +483,7 @@  class QemuRunner:
                         decodedlog = self.decode_qemulog(bootlog)
                         if self.boot_patterns['search_reached_prompt'] in decodedlog:
+                            self.server_socket.close()
                             self.server_socket = qemusock
                             stopread = True
                             reachedlogin = True