diff options
Diffstat (limited to 'gdb')
-rw-r--r-- | gdb/ChangeLog | 7 | ||||
-rw-r--r-- | gdb/python/py-exitedevent.c | 2 | ||||
-rw-r--r-- | gdb/python/py-infevents.c | 2 |
3 files changed, 9 insertions, 2 deletions
diff --git a/gdb/ChangeLog b/gdb/ChangeLog index eed367a..468bbc6 100644 --- a/gdb/ChangeLog +++ b/gdb/ChangeLog @@ -1,5 +1,12 @@ 2020-09-15 Tom Tromey <tromey@adacore.com> + * python/py-infevents.c (create_register_changed_event_object): + Use gdb_py_object_from_longest. + * python/py-exitedevent.c (create_exited_event_object): Use + gdb_py_object_from_longest. + +2020-09-15 Tom Tromey <tromey@adacore.com> + * python/python.c (gdbpy_parameter_value): Use gdb_py_object_from_longest. * python/py-type.c (convert_field, typy_range): Use diff --git a/gdb/python/py-exitedevent.c b/gdb/python/py-exitedevent.c index 9912b26..b19cc95 100644 --- a/gdb/python/py-exitedevent.c +++ b/gdb/python/py-exitedevent.c @@ -30,7 +30,7 @@ create_exited_event_object (const LONGEST *exit_code, struct inferior *inf) if (exit_code) { - gdbpy_ref<> exit_code_obj (PyLong_FromLongLong (*exit_code)); + gdbpy_ref<> exit_code_obj = gdb_py_object_from_longest (*exit_code); if (exit_code_obj == NULL) return NULL; diff --git a/gdb/python/py-infevents.c b/gdb/python/py-infevents.c index f303c39..b653e4a 100644 --- a/gdb/python/py-infevents.c +++ b/gdb/python/py-infevents.c @@ -76,7 +76,7 @@ create_register_changed_event_object (struct frame_info *frame, if (evpy_add_attribute (event.get (), "frame", frame_obj.get ()) < 0) return NULL; - gdbpy_ref<> regnum_obj (PyLong_FromLongLong (regnum)); + gdbpy_ref<> regnum_obj = gdb_py_object_from_longest (regnum); if (regnum_obj == NULL) return NULL; |