diff options
author | MacroFake <falke.marco@gmail.com> | 2022-07-21 17:55:49 +0200 |
---|---|---|
committer | MacroFake <falke.marco@gmail.com> | 2022-08-02 15:28:10 +0200 |
commit | fa2a6b8516b24d7e9ca11926a49cf2b07f661e81 (patch) | |
tree | 1e7f675e3e66591bf4fe200b4eeb787afbab1ed4 /src/init.cpp | |
parent | fa477d32eefcc3dd2f06b452066290d9936d8c5d (diff) |
Combine datacarrier globals into one
Diffstat (limited to 'src/init.cpp')
-rw-r--r-- | src/init.cpp | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/src/init.cpp b/src/init.cpp index 49c7de7816..04873d1c29 100644 --- a/src/init.cpp +++ b/src/init.cpp @@ -975,8 +975,11 @@ bool AppInitParameterInteraction(const ArgsManager& args, bool use_syscall_sandb if (!g_wallet_init_interface.ParameterInteraction()) return false; - fAcceptDatacarrier = args.GetBoolArg("-datacarrier", DEFAULT_ACCEPT_DATACARRIER); - nMaxDatacarrierBytes = args.GetIntArg("-datacarriersize", nMaxDatacarrierBytes); + if (args.GetBoolArg("-datacarrier", DEFAULT_ACCEPT_DATACARRIER)) { + g_max_datacarrier_bytes = args.GetIntArg("-datacarriersize", MAX_OP_RETURN_RELAY); + } else { + g_max_datacarrier_bytes = std::nullopt; + } // Option to startup with mocktime set (used for regression testing): SetMockTime(args.GetIntArg("-mocktime", 0)); // SetMockTime(0) is a no-op |