Fixed potential crash

Former-commit-id: df8cde180c157f08031cd04d37bb735aa266ee53
This commit is contained in:
Lynix
2015-01-16 12:46:27 +01:00
parent e85c6afa12
commit fbcdd6bb2b

View File

@@ -165,7 +165,8 @@ void NzForwardRenderQueue::Clear(bool fully)
for (auto& overlayPair : overlayMap)
{
const NzTexture* overlay = overlayPair.first;
overlay->RemoveResourceListener(this);
if (overlay)
overlay->RemoveResourceListener(this);
}
}
basicSprites.clear();