Exit code 1 on wallet send fail (#1550)

Fixes #1504
This commit is contained in:
Roy Blankman 2018-09-18 17:59:41 -04:00 committed by Ignotus Peverell
parent c291c48436
commit db7b686073

View file

@ -39,6 +39,8 @@ extern crate grin_wallet;
mod cmd; mod cmd;
pub mod tui; pub mod tui;
use std::process::exit;
use clap::{App, Arg, SubCommand}; use clap::{App, Arg, SubCommand};
use config::config::{SERVER_CONFIG_FILE_NAME, WALLET_CONFIG_FILE_NAME}; use config::config::{SERVER_CONFIG_FILE_NAME, WALLET_CONFIG_FILE_NAME};
@ -355,7 +357,7 @@ fn main() {
if let ("init", Some(_)) = wallet_args.subcommand() { if let ("init", Some(_)) = wallet_args.subcommand() {
} else { } else {
println!("Wallet seed file doesn't exist. Run `grin wallet -p [password] init` first"); println!("Wallet seed file doesn't exist. Run `grin wallet -p [password] init` first");
return; exit(1);
} }
} }
let mut l = w.members.as_mut().unwrap().logging.clone().unwrap(); let mut l = w.members.as_mut().unwrap().logging.clone().unwrap();