From: "Daniel P. Berrangé" <berrange@redhat.com>
To: qemu-devel@nongnu.org
Cc: "Thomas Huth" <thuth@redhat.com>,
"Daniel P. Berrangé" <berrange@redhat.com>
Subject: [PATCH 5/6] tests/functional: close GDB socket in reverse debugging test
Date: Fri, 12 Sep 2025 19:21:59 +0100 [thread overview]
Message-ID: <20250912182200.643909-6-berrange@redhat.com> (raw)
In-Reply-To: <20250912182200.643909-1-berrange@redhat.com>
The GDB socket FD is leaked currently resulting in a warning from
python about the unclosed resource.
Signed-off-by: Daniel P. Berrangé <berrange@redhat.com>
---
tests/functional/qemu_test/gdb.py | 4 ++++
tests/functional/reverse_debugging.py | 2 ++
2 files changed, 6 insertions(+)
diff --git a/tests/functional/qemu_test/gdb.py b/tests/functional/qemu_test/gdb.py
index 913e3b65ab..1b463e8a82 100644
--- a/tests/functional/qemu_test/gdb.py
+++ b/tests/functional/qemu_test/gdb.py
@@ -231,3 +231,7 @@ def connect(self):
if self._extended_mode:
self.set_extended_mode()
+
+ def close(self):
+ self._socket.close()
+ self._socket = None
diff --git a/tests/functional/reverse_debugging.py b/tests/functional/reverse_debugging.py
index 9c89f5c897..fbb5adbcce 100644
--- a/tests/functional/reverse_debugging.py
+++ b/tests/functional/reverse_debugging.py
@@ -186,5 +186,7 @@ def reverse_debugging(self, shift=7, args=None):
self.check_pc(g, steps[-1])
logger.info('successfully reached %x' % steps[-1])
+ g.close()
+
logger.info('exiting gdb and qemu')
vm.shutdown()
--
2.50.1
next prev parent reply other threads:[~2025-09-12 18:23 UTC|newest]
Thread overview: 19+ messages / expand[flat|nested] mbox.gz Atom feed top
2025-09-12 18:21 [PATCH 0/6] tests/functional: remove last use of avocado.utils Daniel P. Berrangé
2025-09-12 18:21 ` [PATCH 1/6] tests/functional: import GDB remote code from avocado Daniel P. Berrangé
2025-09-15 10:06 ` Alex Bennée
2025-09-12 18:21 ` [PATCH 2/6] tests/functional: convert reverse debug test to local gdb module Daniel P. Berrangé
2025-09-15 10:06 ` Alex Bennée
2025-09-12 18:21 ` [PATCH 3/6] tests/functional: replace avocado process with subprocess Daniel P. Berrangé
2025-09-15 10:07 ` Alex Bennée
2025-09-12 18:21 ` [PATCH 4/6] tests/functional: drop datadrainer class in reverse debugging Daniel P. Berrangé
2025-09-15 10:18 ` Alex Bennée
2025-09-15 10:38 ` Daniel P. Berrangé
2025-09-15 12:04 ` Alex Bennée
2025-09-15 12:05 ` Alex Bennée
2025-09-12 18:21 ` Daniel P. Berrangé [this message]
2025-09-15 10:18 ` [PATCH 5/6] tests/functional: close GDB socket in reverse debugging test Alex Bennée
2025-09-12 18:22 ` [PATCH 6/6] tests/functional: use self.log for all logging Daniel P. Berrangé
2025-09-15 10:19 ` Alex Bennée
2025-09-15 10:39 ` Daniel P. Berrangé
2025-09-15 10:24 ` [PATCH 0/6] tests/functional: remove last use of avocado.utils Alex Bennée
2025-09-15 10:42 ` Daniel P. Berrangé
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20250912182200.643909-6-berrange@redhat.com \
--to=berrange@redhat.com \
--cc=qemu-devel@nongnu.org \
--cc=thuth@redhat.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.