diff options
Diffstat (limited to 'gdb/dwarf2/index-write.c')
-rw-r--r-- | gdb/dwarf2/index-write.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/gdb/dwarf2/index-write.c b/gdb/dwarf2/index-write.c index f42a253..6cfe415 100644 --- a/gdb/dwarf2/index-write.c +++ b/gdb/dwarf2/index-write.c @@ -1693,7 +1693,8 @@ write_psymtabs_to_index (dwarf2_per_objfile *per_objfile, const char *dir, if (per_objfile->per_bfd->types.size () > 1) error (_("Cannot make an index when the file has multiple .debug_types sections")); - if (!per_bfd->partial_symtabs->psymtabs + if (per_bfd->partial_symtabs == nullptr + || !per_bfd->partial_symtabs->psymtabs || !per_bfd->partial_symtabs->psymtabs_addrmap) return; |