Re: [Patch][gdb] Initialise quiet flag for "info functions"

Philippe Waroquiers
2018-11-02T13:31:21Z

Thanks for the analysis and fix,
I have pushed the below fix as obvious (and an equivalent fix in stack.c)
as d54cfd762b06.

Philippe

On Fri, 2018-11-02 at 11:30 +0000, Matthew Malcomson wrote:
> With this flag unset, using 'info functions' without a set quiet flag
> was not deterministic and was causing some flaky test failures.
>
> Failures seen in (at least).
> gdb.base/info_qt.exp
> gdb.dwarf2/dw2-case-insensitive.exp
> gdb.base/info-fun.exp
>
> Ok for trunk?
> I don't have commit rights.
>
> gdb/ChangeLog:
>
> 2018-11-02 Matthew Malcomson <matthew.malcomson@arm.com>
>
> * symtab.c (info_functions_command): Initialise quiet flag.
>
>
>
> ############### Attachment also inlined for ease of reply ###############
>
>
> diff --git a/gdb/symtab.c b/gdb/symtab.c
> index cd27a75e8ca2370a9d11ae6057d051ca6ce13f90..7649908d9c9341ad695626e0a22a085f2af302ef 100644
> --- a/gdb/symtab.c
> +++ b/gdb/symtab.c
> @@ -4760,7 +4760,7 @@ info_functions_command (const char *args, int from_tty)
> {
> std::string regexp;
> std::string t_regexp;
> - bool quiet;
> + bool quiet = false;
>
> while (args != NULL
> && extract_info_print_args (&args, &quiet, &regexp, &t_regexp))
>