diff options
author | Andrei Karas <akaras@inbox.ru> | 2013-03-11 00:38:20 +0300 |
---|---|---|
committer | Andrei Karas <akaras@inbox.ru> | 2013-03-11 00:38:20 +0300 |
commit | de579c6f0d298bc551addf02b001addea6b698ed (patch) | |
tree | 8db4cd39e35ea4af000f16c3865bed3c042b56b5 /src | |
parent | b38844700debb737dad4090774ad0426a0ebcc02 (diff) | |
download | manaplus-de579c6f0d298bc551addf02b001addea6b698ed.tar.gz manaplus-de579c6f0d298bc551addf02b001addea6b698ed.tar.bz2 manaplus-de579c6f0d298bc551addf02b001addea6b698ed.tar.xz manaplus-de579c6f0d298bc551addf02b001addea6b698ed.zip |
Fix termination with using help and version command line switches.
Diffstat (limited to 'src')
-rw-r--r-- | src/main.cpp | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/src/main.cpp b/src/main.cpp index d9c726a2c..8e9105b64 100644 --- a/src/main.cpp +++ b/src/main.cpp @@ -27,6 +27,7 @@ #include <getopt.h> #include <iostream> +#include <unistd.h> #include "utils/gettext.h" #ifdef ANDROID @@ -238,12 +239,12 @@ int main(int argc, char *argv[]) if (options.printHelp) { printHelp(); - return 0; + _exit(0); } else if (options.printVersion) { printVersion(); - return 0; + _exit(0); } // Initialize PhysicsFS |