mirror of
https://github.com/espressif/binutils-gdb.git
synced 2025-06-19 00:59:15 +08:00
Sync libiberty with upstream GCC.
libiberty/ChangeLog: PR demangler/80513 * cp-demangle.c (d_number): Check for overflow. * cplus-dem.c (consume_count): Fix overflow check. (gnu_special): Check for underscore after thunk delta. * testsuite/demangle-expected: Add tests for overflows and invalid characters in thunks. * cp-demangle.c (MAX_RECURSION_COUNT): New constant. (struct d_print_info): Add recursion field. (d_print_init): Initialize recursion. (d_print_comp): Check and update d_print_info recursion depth. * cp-demangle.c (d_substitution): Return NULL if d_add_substitution fails. * cp-demangle.h (struct d_info): Remove did_subs field. * cp-demangle.c (struct d_info_checkpoint): Likewise. (d_template_param): Don't update did_subs. (d_substitution): Likewise. (d_checkpoint): Don't assign did_subs. (d_backtrack): Likewise. (cplus_demangle_init_info): Don't initialize did_subs.
This commit is contained in:
@ -111,10 +111,6 @@ struct d_info
|
||||
int next_sub;
|
||||
/* The number of available entries in the subs array. */
|
||||
int num_subs;
|
||||
/* The number of substitutions which we actually made from the subs
|
||||
array, plus the number of template parameter references we
|
||||
saw. */
|
||||
int did_subs;
|
||||
/* The last name we saw, for constructors and destructors. */
|
||||
struct demangle_component *last_name;
|
||||
/* A running total of the length of large expansions from the
|
||||
|
Reference in New Issue
Block a user