Displaying errors on stderr (#3116)
This commit is contained in:
parent
5ae737f307
commit
7fb39d1511
@ -114,7 +114,7 @@ mod user_defaults;
|
|||||||
mod stratum;
|
mod stratum;
|
||||||
|
|
||||||
use std::{process, env};
|
use std::{process, env};
|
||||||
use std::io::BufReader;
|
use std::io::{self as stdio, BufReader, Write};
|
||||||
use std::fs::File;
|
use std::fs::File;
|
||||||
use util::sha3::sha3;
|
use util::sha3::sha3;
|
||||||
use cli::Args;
|
use cli::Args;
|
||||||
@ -213,7 +213,7 @@ fn main() {
|
|||||||
info!("{}", result);
|
info!("{}", result);
|
||||||
},
|
},
|
||||||
Err(err) => {
|
Err(err) => {
|
||||||
info!("{}", err);
|
writeln!(&mut stdio::stderr(), "{}", err).expect("StdErr available; qed");
|
||||||
process::exit(1);
|
process::exit(1);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user