diff options
author | Jan Haller <bromeon@gmail.com> | 2022-07-02 01:05:20 +0200 |
---|---|---|
committer | Jan Haller <bromeon@gmail.com> | 2022-07-02 01:17:35 +0200 |
commit | d38d76d039a20bfcbc0a8612fee1c9a37cc21c78 (patch) | |
tree | b37c34b08060ca85c12720d7587178defd425658 /platform/linuxbsd/godot_linuxbsd.cpp | |
parent | a2459c7d35eeaeea8b1d4fa9ce6c9cbe74f11643 (diff) |
Fix exit code of --help and --version, and test them in CI
Corrects prior regression which caused ERROR output and exit code of 1.
Diffstat (limited to 'platform/linuxbsd/godot_linuxbsd.cpp')
-rw-r--r-- | platform/linuxbsd/godot_linuxbsd.cpp | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/platform/linuxbsd/godot_linuxbsd.cpp b/platform/linuxbsd/godot_linuxbsd.cpp index 9fe00568fb..91a260182e 100644 --- a/platform/linuxbsd/godot_linuxbsd.cpp +++ b/platform/linuxbsd/godot_linuxbsd.cpp @@ -61,6 +61,10 @@ int main(int argc, char *argv[]) { Error err = Main::setup(argv[0], argc - 1, &argv[1]); if (err != OK) { free(cwd); + + if (err == ERR_HELP) { // Returned by --help and --version, so success. + return 0; + } return 255; } |