mirror of
https://github.com/keepassxreboot/keepassxc.git
synced 2025-12-31 16:20:22 -05:00
Use EXIT_FAILURE/SUCCESS
This commit is contained in:
parent
bf9b23539e
commit
9b92e7f8e8
3 changed files with 25 additions and 21 deletions
|
|
@ -15,13 +15,14 @@
|
|||
* along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
*/
|
||||
|
||||
#include <cli/Merge.h>
|
||||
#include <cli/Extract.h>
|
||||
#include <cstdlib>
|
||||
|
||||
#include <QCommandLineParser>
|
||||
#include <QCoreApplication>
|
||||
#include <QStringList>
|
||||
|
||||
#include <cli/Merge.h>
|
||||
#include <cli/Extract.h>
|
||||
#include "config-keepassx.h"
|
||||
#include "core/Tools.h"
|
||||
#include "crypto/Crypto.h"
|
||||
|
|
@ -34,7 +35,7 @@ int main(int argc, char **argv)
|
|||
|
||||
if (!Crypto::init()) {
|
||||
qFatal("Fatal error while testing the cryptographic functions:\n%s", qPrintable(Crypto::errorString()));
|
||||
return 1;
|
||||
return EXIT_FAILURE;
|
||||
}
|
||||
|
||||
QCoreApplication app(argc, argv);
|
||||
|
|
@ -51,7 +52,7 @@ int main(int argc, char **argv)
|
|||
const QStringList args = parser.positionalArguments();
|
||||
if (args.size() < 1) {
|
||||
parser.showHelp();
|
||||
return 1;
|
||||
return EXIT_FAILURE;
|
||||
}
|
||||
|
||||
QString commandName = args.at(0);
|
||||
|
|
@ -74,6 +75,6 @@ int main(int argc, char **argv)
|
|||
|
||||
qCritical("Invalid command %s.", qPrintable(commandName));
|
||||
parser.showHelp();
|
||||
return 1;
|
||||
return EXIT_FAILURE;
|
||||
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue