starmath: Spare unnecessary assignments

Change-Id: I8ddc1c04a76475d63a39dc21d36cda7a7aa26b9e
Reviewed-on: https://gerrit.libreoffice.org/49921
Tested-by: Jenkins <ci@libreoffice.org>
Reviewed-by: Takeshi Abe <tabe@fixedpoint.jp>
This commit is contained in:
Takeshi Abe
2018-02-19 00:55:54 +01:00
parent 4f97bfb3c2
commit 6893d8b193
+4 -3
View File
@@ -266,12 +266,13 @@ public:
{
//Resize subnodes array
maSubNodes.resize(nIndex + 1);
//Set new slots to NULL
for (size_t i = size; i < nIndex+1; i++)
//Set new slots to NULL except at nIndex
for (size_t i = size; i < nIndex; i++)
maSubNodes[i] = nullptr;
}
maSubNodes[nIndex] = pNode;
ClaimPaternity();
if (pNode)
pNode->SetParent(this);
}
private: