aboutsummaryrefslogtreecommitdiff
path: root/gdb/python/py-threadevent.c
diff options
context:
space:
mode:
Diffstat (limited to 'gdb/python/py-threadevent.c')
-rw-r--r--gdb/python/py-threadevent.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/gdb/python/py-threadevent.c b/gdb/python/py-threadevent.c
index 0fcf3e1..3be86b7 100644
--- a/gdb/python/py-threadevent.c
+++ b/gdb/python/py-threadevent.c
@@ -27,7 +27,9 @@ py_get_event_thread (ptid_t ptid)
{
if (non_stop)
{
- thread_info *thread = find_thread_ptid (ptid);
+ thread_info *thread
+ = find_thread_ptid (current_inferior ()->process_target (),
+ ptid);
if (thread != nullptr)
return thread_to_thread_object (thread);
PyErr_SetString (PyExc_RuntimeError, "Could not find event thread");