mirror of
https://github.com/bitcoin/bitcoin.git
synced 2025-12-20 04:36:08 +01:00
[moveonly] Extract HelpRequested to dry up the help options testing
This ensures consistency across interfaces and makes the version handling more clear.
This commit is contained in:
@@ -613,8 +613,7 @@ int main(int argc, char *argv[])
|
||||
|
||||
// Show help message immediately after parsing command-line options (for "-lang") and setting locale,
|
||||
// but before showing splash screen.
|
||||
if (gArgs.IsArgSet("-?") || gArgs.IsArgSet("-h") || gArgs.IsArgSet("-help") || gArgs.IsArgSet("-version"))
|
||||
{
|
||||
if (HelpRequested(gArgs) || gArgs.IsArgSet("-version")) {
|
||||
HelpMessageDialog help(nullptr, gArgs.IsArgSet("-version"));
|
||||
help.showOrPrint();
|
||||
return EXIT_SUCCESS;
|
||||
|
||||
Reference in New Issue
Block a user