gcc: fix gcc --help -v opertion with linker flags and input files [PR108328]
Checks
Commit Message
PR gcc/108328
gcc/ChangeLog:
* gcc/gcc.cc: print help once and only once
---
gcc/gcc.cc | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
@@ -5414,9 +5414,9 @@ process_command (unsigned int decoded_options_count,
}
/* Ensure we only invoke each subprocess once. */
- if (n_infiles == 0
- && (print_subprocess_help || print_help_list || print_version))
+ if (print_subprocess_help || print_help_list || print_version)
{
+ n_infiles = 0;
/* Create a dummy input file, so that we can pass
the help option on to the various sub-processes. */
add_infile ("help-dummy", "c");