aboutsummaryrefslogtreecommitdiff
path: root/gdb/python
diff options
context:
space:
mode:
Diffstat (limited to 'gdb/python')
-rw-r--r--gdb/python/py-auto-load.c2
-rw-r--r--gdb/python/py-objfile.c2
-rw-r--r--gdb/python/py-progspace.c2
3 files changed, 2 insertions, 4 deletions
diff --git a/gdb/python/py-auto-load.c b/gdb/python/py-auto-load.c
index 044d968..538e06d 100644
--- a/gdb/python/py-auto-load.c
+++ b/gdb/python/py-auto-load.c
@@ -395,8 +395,6 @@ auto_load_new_objfile (struct objfile *objfile)
clear_section_scripts ();
return;
}
- if (!objfile->name)
- return;
load_auto_scripts_for_objfile (objfile);
}
diff --git a/gdb/python/py-objfile.c b/gdb/python/py-objfile.c
index 1aa6a4d..1473503 100644
--- a/gdb/python/py-objfile.c
+++ b/gdb/python/py-objfile.c
@@ -46,7 +46,7 @@ objfpy_get_filename (PyObject *self, void *closure)
{
objfile_object *obj = (objfile_object *) self;
- if (obj->objfile && obj->objfile->name)
+ if (obj->objfile)
return PyString_Decode (obj->objfile->name, strlen (obj->objfile->name),
host_charset (), NULL);
Py_RETURN_NONE;
diff --git a/gdb/python/py-progspace.c b/gdb/python/py-progspace.c
index 8724532..2c8a677 100644
--- a/gdb/python/py-progspace.c
+++ b/gdb/python/py-progspace.c
@@ -52,7 +52,7 @@ pspy_get_filename (PyObject *self, void *closure)
{
struct objfile *objfile = obj->pspace->symfile_object_file;
- if (objfile && objfile->name)
+ if (objfile)
return PyString_Decode (objfile->name, strlen (objfile->name),
host_charset (), NULL);
}