mirror of
https://github.com/espressif/binutils-gdb.git
synced 2025-06-03 13:23:00 +08:00
Use gdbpy_enter in py-objfile.c
Change py-objfile.c to use gdbpy_enter. 2017-01-10 Tom Tromey <tom@tromey.com> * python/py-objfile.c (py_free_objfile): Use gdbpy_enter.
This commit is contained in:
@ -1,3 +1,7 @@
|
|||||||
|
2017-01-10 Tom Tromey <tom@tromey.com>
|
||||||
|
|
||||||
|
* python/py-objfile.c (py_free_objfile): Use gdbpy_enter.
|
||||||
|
|
||||||
2017-01-10 Tom Tromey <tom@tromey.com>
|
2017-01-10 Tom Tromey <tom@tromey.com>
|
||||||
|
|
||||||
* python/py-inferior.c (python_on_normal_stop, python_on_resume)
|
* python/py-inferior.c (python_on_normal_stop, python_on_resume)
|
||||||
|
@ -612,13 +612,11 @@ gdbpy_lookup_objfile (PyObject *self, PyObject *args, PyObject *kw)
|
|||||||
static void
|
static void
|
||||||
py_free_objfile (struct objfile *objfile, void *datum)
|
py_free_objfile (struct objfile *objfile, void *datum)
|
||||||
{
|
{
|
||||||
struct cleanup *cleanup;
|
|
||||||
objfile_object *object = (objfile_object *) datum;
|
objfile_object *object = (objfile_object *) datum;
|
||||||
|
|
||||||
cleanup = ensure_python_env (get_objfile_arch (objfile), current_language);
|
gdbpy_enter enter_py (get_objfile_arch (objfile), current_language);
|
||||||
object->objfile = NULL;
|
object->objfile = NULL;
|
||||||
Py_DECREF ((PyObject *) object);
|
Py_DECREF ((PyObject *) object);
|
||||||
do_cleanups (cleanup);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
/* Return a borrowed reference to the Python object of type Objfile
|
/* Return a borrowed reference to the Python object of type Objfile
|
||||||
|
Reference in New Issue
Block a user