PATCH: Return error in readelf.c

Thiemo Seufer ica2_ts@csv.ica.uni-stuttgart.de
Tue Aug 7 10:41:00 GMT 2001


H . J . Lu wrote:
[snip]
> 	* readelf.c (process_file): Return 0 if OK, otherwise return 1.

[snip]
> @@ -8871,11 +8875,12 @@ main (argc, argv)
>    if (optind < (argc - 1))
>      show_name = 1;
>  
> +  err = 0;
>    while (optind < argc)
> -    process_file (argv [optind ++]);
> +    err += process_file (argv [optind ++]);
>  
>    if (dump_sects != NULL)
>      free (dump_sects);
>  
> -  return 0;
> +  return err;
>  }

This doesn't fit together. It returns the count of files failed
to process.


Thiemo



More information about the Binutils mailing list