1
0
Fork 0
mirror of https://github.com/AquariaOSE/Aquaria.git synced 2024-12-25 06:05:45 +00:00

Fix crash in RenderObjectLayer::moveToBack()

This commit is contained in:
fgenesis 2012-10-09 00:57:34 +02:00
parent 66d3b90473
commit 6f05249fdc

View file

@ -314,7 +314,8 @@ void RenderObjectLayer::moveToBack(RenderObject *r)
for (int i = newSize - 1; i >= sizeDiff; i--)
{
renderObjects[i] = renderObjects[i - sizeDiff];
renderObjects[i]->setIdx(i); // Known to be non-NULL.
if(renderObjects[i])
renderObjects[i]->setIdx(i);
}
for (int i = 0; i < newIdx; i++)
renderObjects[i] = 0;