From c1d8d4e4003440d529eb25ee8ab9ca1b5e3703ed Mon Sep 17 00:00:00 2001 From: kervala Date: Thu, 14 Jan 2016 23:47:24 +0100 Subject: [PATCH] Changed: Invert version and help checks --HG-- branch : develop --- code/nel/src/misc/cmd_args.cpp | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/code/nel/src/misc/cmd_args.cpp b/code/nel/src/misc/cmd_args.cpp index 39f4cb849..82863ba1b 100644 --- a/code/nel/src/misc/cmd_args.cpp +++ b/code/nel/src/misc/cmd_args.cpp @@ -321,13 +321,6 @@ bool CCmdArgs::parse(const std::vector &argv) } } - // process help if requested or if required arguments are missing - if (haveLongArg("help") || (needRequiredArg() && !haveRequiredArg())) - { - displayHelp(); - return false; - } - // process version if (haveLongArg("version")) { @@ -335,6 +328,13 @@ bool CCmdArgs::parse(const std::vector &argv) return false; } + // process help if requested or if required arguments are missing + if (haveLongArg("help") || (needRequiredArg() && !haveRequiredArg())) + { + displayHelp(); + return false; + } + return true; }