summaryrefslogtreecommitdiff
path: root/platform/linuxbsd
diff options
context:
space:
mode:
authorRĂ©mi Verschelde <remi@verschelde.fr>2022-07-02 10:25:03 +0200
committerGitHub <noreply@github.com>2022-07-02 10:25:03 +0200
commitec1348a72a510f68dfd2698bc368b29e2c72cbae (patch)
tree268019c51b5832ff48d135e761fc6af10f027bc7 /platform/linuxbsd
parent04bdd7eb9354c10abaa47e095dd45e89dc02cd0e (diff)
parentd38d76d039a20bfcbc0a8612fee1c9a37cc21c78 (diff)
Merge pull request #62618 from Bromeon/bugfix/exit-code
Fix exit code of --help and --version, and test them in CI
Diffstat (limited to 'platform/linuxbsd')
-rw-r--r--platform/linuxbsd/godot_linuxbsd.cpp4
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;
}