diff options
Diffstat (limited to 'gdb/python/py-symtab.c')
-rw-r--r-- | gdb/python/py-symtab.c | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/gdb/python/py-symtab.c b/gdb/python/py-symtab.c index b6f45e6d8d8..21a172cadd8 100644 --- a/gdb/python/py-symtab.c +++ b/gdb/python/py-symtab.c @@ -470,7 +470,10 @@ del_objfile_sal (struct objfile *objfile, void *datum) { sal_object *next = obj->next; - obj->symtab = NULL; + Py_DECREF (obj->symtab); + obj->symtab = (symtab_object *) Py_None; + Py_INCREF (Py_None); + obj->next = NULL; obj->prev = NULL; xfree (obj->sal); |