summaryrefslogtreecommitdiff
path: root/platform/windows
diff options
context:
space:
mode:
authorJan Haller <bromeon@gmail.com>2022-07-02 01:05:20 +0200
committerJan Haller <bromeon@gmail.com>2022-07-02 01:17:35 +0200
commitd38d76d039a20bfcbc0a8612fee1c9a37cc21c78 (patch)
treeb37c34b08060ca85c12720d7587178defd425658 /platform/windows
parenta2459c7d35eeaeea8b1d4fa9ce6c9cbe74f11643 (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/windows')
-rw-r--r--platform/windows/godot_windows.cpp4
1 files changed, 4 insertions, 0 deletions
diff --git a/platform/windows/godot_windows.cpp b/platform/windows/godot_windows.cpp
index 8de3ef294a..72920d2816 100644
--- a/platform/windows/godot_windows.cpp
+++ b/platform/windows/godot_windows.cpp
@@ -166,6 +166,10 @@ int widechar_main(int argc, wchar_t **argv) {
delete[] argv_utf8[i];
}
delete[] argv_utf8;
+
+ if (err == ERR_HELP) { // Returned by --help and --version, so success.
+ return 0;
+ }
return 255;
}