Fix usage of temporary string (#185)
This commit is contained in:
parent
c325cb1b3a
commit
c6b770eec8
@ -488,7 +488,7 @@ void StandardCalculatorViewModel::HandleUpdatedOperandData(Command cmdenum)
|
|||||||
m_selectedExpressionLastData = L"";
|
m_selectedExpressionLastData = L"";
|
||||||
if (ch == 'x')
|
if (ch == 'x')
|
||||||
{
|
{
|
||||||
temp = L'\0';
|
temp[0] = L'\0';
|
||||||
commandIndex = 0;
|
commandIndex = 0;
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
@ -505,7 +505,7 @@ void StandardCalculatorViewModel::HandleUpdatedOperandData(Command cmdenum)
|
|||||||
{
|
{
|
||||||
if (commandIndex == 0)
|
if (commandIndex == 0)
|
||||||
{
|
{
|
||||||
delete temp;
|
delete [] temp;
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user