summaryrefslogtreecommitdiff
path: root/platform/windows/godot_win.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'platform/windows/godot_win.cpp')
-rw-r--r--platform/windows/godot_win.cpp9
1 files changed, 7 insertions, 2 deletions
diff --git a/platform/windows/godot_win.cpp b/platform/windows/godot_win.cpp
index df2d96e516..d2ac6ecb50 100644
--- a/platform/windows/godot_win.cpp
+++ b/platform/windows/godot_win.cpp
@@ -3,7 +3,7 @@
/*************************************************************************/
/* This file is part of: */
/* GODOT ENGINE */
-/* http://www.godotengine.org */
+/* https://godotengine.org */
/*************************************************************************/
/* Copyright (c) 2007-2017 Juan Linietsky, Ariel Manzur. */
/* Copyright (c) 2014-2017 Godot Engine contributors (cf. AUTHORS.md) */
@@ -136,8 +136,13 @@ int widechar_main(int argc, wchar_t **argv) {
Error err = Main::setup(argv_utf8[0], argc - 1, &argv_utf8[1]);
- if (err != OK)
+ if (err != OK) {
+ for (int i = 0; i < argc; ++i) {
+ delete[] argv_utf8[i];
+ }
+ delete[] argv_utf8;
return 255;
+ }
if (Main::start())
os.run();