add return

This commit is contained in:
2025-07-09 17:52:29 +08:00
parent 365134ce77
commit aff8d1531c

View File

@ -41,6 +41,8 @@ namespace Hazel
if (!data) if (!data)
{ {
HZ_CORE_ERROR("Failed to load texture {0}", path); HZ_CORE_ERROR("Failed to load texture {0}", path);
stbi_image_free(data);
return;
} }
m_Width = width; m_Width = width;
m_Height = height; m_Height = height;