1
Fork 0
mirror of https://github.com/RGBCube/uutils-coreutils synced 2025-07-29 12:07:46 +00:00

uucore: fix utility name in coreopts parsing error messages

This commit is contained in:
Nathan Ross 2016-08-13 22:46:59 -04:00
parent d0b5b9a9fd
commit cb1b32cda1

View file

@ -41,7 +41,9 @@ impl<'a> CoreOptions<'a> {
let matches = match self.options.parse(&args[1..]) {
Ok(m) => { Some(m) },
Err(f) => {
crash!(1, "{}", f);
pipe_write!(&mut ::std::io::stderr(), "{}: error: ", self.help_text.name);
pipe_writeln!(&mut ::std::io::stderr(), "{}", f);
::std::process::exit(1);
}
}.unwrap();
if matches.opt_present("help") {