* cp-demangle.c (d_print_comp): Guard against null.

From-SVN: r127139
This commit is contained in:
Michael Snyder 2007-08-01 21:29:40 +00:00 committed by DJ Delorie
parent 870c06b9d5
commit ac847e32a0
2 changed files with 10 additions and 0 deletions

View file

@ -1,3 +1,7 @@
2007-07-31 Michael Snyder <msnyder@access-company.com>
* cp-demangle.c (d_print_comp): Guard against null.
2007-07-25 Ben Elliston <bje@au.ibm.com>
* Makefile.in (CFILES): Remove ternary.c.

View file

@ -2912,6 +2912,12 @@ d_print_comp (struct d_print_info *dpi,
typed_name = d_left (typed_name);
}
if (typed_name == NULL)
{
d_print_error (dpi);
return;
}
/* If typed_name is a template, then it applies to the
function type as well. */
if (typed_name->type == DEMANGLE_COMPONENT_TEMPLATE)