Fixed crash with bangs through command-line and WM_COPYDATA

This commit is contained in:
Birunthan Mohanathas 2012-05-12 15:08:47 +03:00
parent c1c4256a68
commit 8a8aa98791

View File

@ -205,10 +205,8 @@ std::vector<std::wstring> CRainmeter::ParseString(LPCTSTR str, CConfigParser* pa
}
else // quote or space not found
{
newStr = arg;
addResult(arg, extra == 1);
arg.clear();
addResult(newStr, extra == 1);
break;
}
}
@ -2033,7 +2031,7 @@ void CRainmeter::ExecuteCommand(const WCHAR* command, CMeterWindow* meterWindow)
if (pos)
{
bang.assign(command, 0, pos - command);
args = ParseString(pos + 1, &meterWindow->GetParser());
args = ParseString(pos + 1, meterWindow ? &meterWindow->GetParser() : NULL);
}
else
{