From 08989e30ede130f0ec29ddf0d4f36a71211bdcee Mon Sep 17 00:00:00 2001 From: Dimitri Schoolwerth Date: Tue, 6 Apr 2004 17:18:20 +0000 Subject: [PATCH] applied patch #928786: "Fix memory leak produced by ConvertArgsToUnicode()" git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@26640 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775 --- src/common/init.cpp | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/common/init.cpp b/src/common/init.cpp index e6d803cbe4..407fe5cb3e 100644 --- a/src/common/init.cpp +++ b/src/common/init.cpp @@ -181,6 +181,7 @@ static void ConvertArgsToUnicode(int argc, char **argv) gs_initData.argv[i] = wxStrdup(wxConvLocal.cMB2WX(argv[i])); } + gs_initData.argc = argc; gs_initData.argv[argc] = NULL; } @@ -195,6 +196,7 @@ static void FreeConvertedArgs() delete [] gs_initData.argv; gs_initData.argv = NULL; + gs_initData.argc = 0; } }