Fixed crash when resolving multipatches with missing textures

https://forum.zdoom.org/viewtopic.php?t=59088
This commit is contained in:
alexey.lysiuk 2018-01-13 12:41:19 +02:00
parent d9ddd50c98
commit d95ac93376

View file

@ -1369,7 +1369,7 @@ void FMultiPatchTexture::ResolvePatches()
{
if (Parts[i].Texture == nullptr)
{
memcpy(&Parts[i], &Parts[i + 1], NumParts - i - 1);
memcpy(&Parts[i], &Parts[i + 1], (NumParts - i - 1) * sizeof(TexPart));
i--;
NumParts--;
}