Special test for -testnet and -regtest args, because we * don't want to be confused by craziness like "[regtest] testnet=1" */
| 304 | * don't want to be confused by craziness like "[regtest] testnet=1" |
| 305 | */ |
| 306 | static inline bool GetNetBoolArg(const ArgsManager &am, const std::string& net_arg) |
| 307 | { |
| 308 | std::pair<bool,std::string> found_result(false,std::string()); |
| 309 | found_result = GetArgHelper(am.m_override_args, net_arg, true); |
| 310 | if (!found_result.first) { |
| 311 | found_result = GetArgHelper(am.m_config_args, net_arg, true); |
| 312 | if (!found_result.first) { |
| 313 | return false; // not set |
| 314 | } |
| 315 | } |
| 316 | return InterpretBool(found_result.second); // is set, so evaluate |
| 317 | } |
| 318 | }; |
| 319 | |
| 320 | /** |
nothing calls this directly
no test coverage detected