diff options
| author | Andrew Chow <[email protected]> | 2018-06-11 14:23:13 -0700 |
|---|---|---|
| committer | Andrew Chow <[email protected]> | 2018-06-12 14:33:35 -0700 |
| commit | c2dfbb4a97513557fe923b7810ea8639c320fefd (patch) | |
| tree | d8cb0e73ee160938f7d5cead7b86ee25753a27b9 /src/util.cpp | |
| parent | Merge #13230: Simplify include analysis by enforcing the developer guide's in... (diff) | |
| download | discoin-c2dfbb4a97513557fe923b7810ea8639c320fefd.tar.xz discoin-c2dfbb4a97513557fe923b7810ea8639c320fefd.zip | |
Add unavailable options to hidden options category
Options that are not available (but known in the source code) will
cause an error if they are specified.
Make these options "available" by adding them to the hidden options
category to prevent conf files from failing when shared between binaries
that have different options available.
Diffstat (limited to 'src/util.cpp')
| -rw-r--r-- | src/util.cpp | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/src/util.cpp b/src/util.cpp index 48d64e3ee..ab262b406 100644 --- a/src/util.cpp +++ b/src/util.cpp @@ -585,6 +585,13 @@ void ArgsManager::AddArg(const std::string& name, const std::string& help, const assert(ret.second); // Make sure an insertion actually happened } +void ArgsManager::AddHiddenArgs(const std::vector<std::string>& names) +{ + for (const std::string& name : names) { + AddArg(name, "", false, OptionsCategory::HIDDEN); + } +} + std::string ArgsManager::GetHelpMessage() { const bool show_debug = gArgs.GetBoolArg("-help-debug", false); |