From c1202057eb9161a86af27d867703235fee7b7555 Mon Sep 17 00:00:00 2001 From: Nick Clifton Date: Wed, 10 Apr 2019 15:49:36 +0100 Subject: Pull in patch for libiberty that fixes a stack exhaustion bug when demangling a pathalogically constructed mangled name. PR 89394 * cp-demangle.c (cplus_demangle_fill_name): Reject negative lengths. (d_count_templates_scopes): Replace num_templates and num_scopes parameters with a struct d_print_info pointer parameter. Adjust body of the function accordingly. Add recursion counter and check that the recursion limit is not reached. (d_print_init): Pass dpi parameter to d_count_templates_scopes. Reset recursion counter afterwards, unless the recursion limit was reached. --- ChangeLog | 16 ++++++++++++++++ 1 file changed, 16 insertions(+) (limited to 'ChangeLog') diff --git a/ChangeLog b/ChangeLog index cd631a1..4df3aaa 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,19 @@ +2019-04-10 Nick Clifton + + * libiberty: Sync with gcc. Bring in: + 2019-04-10 Nick Clifton + + PR 89394 + * cp-demangle.c (cplus_demangle_fill_name): Reject negative + lengths. + (d_count_templates_scopes): Replace num_templates and num_scopes + parameters with a struct d_print_info pointer parameter. Adjust + body of the function accordingly. Add recursion counter and check + that the recursion limit is not reached. + (d_print_init): Pass dpi parameter to d_count_templates_scopes. + Reset recursion counter afterwards, unless the recursion limit was + reached. + 2018-06-24 Nick Clifton 2.32 branch created. -- cgit v1.1