Fix fatal bug in ArgsArray(wchar_t**) ctor.

The input pointer was modified before being used again leading to out of bound
array access.

Closes #11979.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@64098 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
Vadim Zeitlin
2010-04-22 11:20:37 +00:00
parent 3328e0ca26
commit 64d029f155

View File

@@ -394,7 +394,7 @@ public:
ArgsArray(wchar_t **wargv) ArgsArray(wchar_t **wargv)
{ {
int argc = 0; int argc = 0;
while ( *wargv++ ) while ( wargv[argc] )
argc++; argc++;
Init(argc); Init(argc);