fixed argv[0] out of bounds error (argc can be 0 when wxEntry is manually called in a plugin environment for example)
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@35888 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
@@ -241,7 +241,8 @@ void wxCmdLineParserData::SetArguments(const wxString& cmdLine)
|
||||
{
|
||||
m_arguments.clear();
|
||||
|
||||
m_arguments.push_back(wxTheApp ? wxTheApp->argv[0] : _T(""));
|
||||
m_arguments.push_back(
|
||||
(wxTheApp && wxTheApp->argc > 0) ? wxTheApp->argv[0] : wxEmptyString);
|
||||
|
||||
wxArrayString args = wxCmdLineParser::ConvertStringToArgs(cmdLine);
|
||||
|
||||
|
Reference in New Issue
Block a user