This causes gdb to crash in strlen.
Happens if init_complex_type is called for a type created by
dbx_init_float_type in stabsread.c.
gdb/ChangeLog:
2020-10-22 Hannes Domani <ssbssa@yahoo.de>
* gdbtypes.c (init_complex_type): Check target type name.
+2020-10-22 Hannes Domani <ssbssa@yahoo.de>
+
+ * gdbtypes.c (init_complex_type): Check target type name.
+
2020-10-22 Simon Marchi <simon.marchi@polymtl.ca>
* target-debug.h (target_debug_print_struct_target_ops_p):
if (TYPE_MAIN_TYPE (target_type)->flds_bnds.complex_type == nullptr)
{
- if (name == nullptr)
+ if (name == nullptr && target_type->name () != nullptr)
{
char *new_name
= (char *) TYPE_ALLOC (target_type,