aboutsummaryrefslogtreecommitdiff
path: root/gdb/python/py-newobjfileevent.c
diff options
context:
space:
mode:
Diffstat (limited to 'gdb/python/py-newobjfileevent.c')
-rw-r--r--gdb/python/py-newobjfileevent.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/gdb/python/py-newobjfileevent.c b/gdb/python/py-newobjfileevent.c
index 34e8e49..2068d39 100644
--- a/gdb/python/py-newobjfileevent.c
+++ b/gdb/python/py-newobjfileevent.c
@@ -93,14 +93,14 @@ emit_free_objfile_event (struct objfile *objfile)
/* Subroutine of emit_clear_objfiles_event to simplify it. */
static gdbpy_ref<>
-create_clear_objfiles_event_object (void)
+create_clear_objfiles_event_object (program_space *pspace)
{
gdbpy_ref<> objfile_event
= create_event_object (&clear_objfiles_event_object_type);
if (objfile_event == NULL)
return NULL;
- gdbpy_ref<> py_progspace = pspace_to_pspace_object (current_program_space);
+ gdbpy_ref<> py_progspace = pspace_to_pspace_object (pspace);
if (py_progspace == NULL || evpy_add_attribute (objfile_event.get (),
"progspace",
py_progspace.get ()) < 0)
@@ -115,12 +115,12 @@ create_clear_objfiles_event_object (void)
Return -1 if emit fails. */
int
-emit_clear_objfiles_event (void)
+emit_clear_objfiles_event (program_space *pspace)
{
if (evregpy_no_listeners_p (gdb_py_events.clear_objfiles))
return 0;
- gdbpy_ref<> event = create_clear_objfiles_event_object ();
+ gdbpy_ref<> event = create_clear_objfiles_event_object (pspace);
if (event != NULL)
return evpy_emit_event (event.get (), gdb_py_events.clear_objfiles);
return -1;