From f36132a8370096adc953a7fcec69f55070eb2e71 Mon Sep 17 00:00:00 2001 From: stoffu Date: Sun, 15 Apr 2018 14:52:53 +0900 Subject: wallet cli/rpc: terminate execution with code 0 when --help or --version is given --- src/gen_multisig/gen_multisig.cpp | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) (limited to 'src/gen_multisig/gen_multisig.cpp') diff --git a/src/gen_multisig/gen_multisig.cpp b/src/gen_multisig/gen_multisig.cpp index 943589b4a..03e0a7946 100644 --- a/src/gen_multisig/gen_multisig.cpp +++ b/src/gen_multisig/gen_multisig.cpp @@ -174,7 +174,9 @@ int main(int argc, char* argv[]) command_line::add_arg(desc_params, arg_stagenet); command_line::add_arg(desc_params, arg_create_address_file); - const auto vm = wallet_args::main( + boost::optional vm; + bool should_terminate = false; + std::tie(vm, should_terminate) = wallet_args::main( argc, argv, "monero-gen-multisig [(--testnet|--stagenet)] [--filename-base=] [--scheme=M/N] [--threshold=M] [--participants=N]", genms::tr("This program generates a set of multisig wallets - use this simpler scheme only if all the participants trust each other"), @@ -185,6 +187,8 @@ int main(int argc, char* argv[]) ); if (!vm) return 1; + if (should_terminate) + return 0; bool testnet, stagenet; uint32_t threshold = 0, total = 0; -- cgit v1.2.3