Changeset View
Changeset View
Standalone View
Standalone View
src/bitcoin-tx.cpp
Show First 20 Lines • Show All 108 Lines • ▼ Show 20 Lines | static int AppInitRawTx(int argc, char *argv[]) { | ||||
SetupBitcoinTxArgs(); | SetupBitcoinTxArgs(); | ||||
std::string error; | std::string error; | ||||
if (!gArgs.ParseParameters(argc, argv, error)) { | if (!gArgs.ParseParameters(argc, argv, error)) { | ||||
tfm::format(std::cerr, "Error parsing command line arguments: %s\n", | tfm::format(std::cerr, "Error parsing command line arguments: %s\n", | ||||
error.c_str()); | error.c_str()); | ||||
return EXIT_FAILURE; | return EXIT_FAILURE; | ||||
} | } | ||||
// Check for -testnet or -regtest parameter (Params() calls are only valid | // Check for -chain, -testnet or -regtest parameter (Params() calls are only | ||||
// after this clause) | // valid after this clause) | ||||
try { | try { | ||||
SelectParams(gArgs.GetChainName()); | SelectParams(gArgs.GetChainName()); | ||||
} catch (const std::exception &e) { | } catch (const std::exception &e) { | ||||
tfm::format(std::cerr, "Error: %s\n", e.what()); | tfm::format(std::cerr, "Error: %s\n", e.what()); | ||||
return EXIT_FAILURE; | return EXIT_FAILURE; | ||||
} | } | ||||
fCreateBlank = gArgs.GetBoolArg("-create", false); | fCreateBlank = gArgs.GetBoolArg("-create", false); | ||||
▲ Show 20 Lines • Show All 781 Lines • Show Last 20 Lines |