add "no texture" marker to prevent SKYDEFS crash with empty texture name

This commit is contained in:
Roman Fomin 2024-12-12 11:57:35 +07:00
parent f16bbb7877
commit 78491e0340

View File

@ -50,6 +50,7 @@ static boolean ParseSkyTex(json_t *json, skytex_t *out)
json_t *name = JS_GetObject(json, "name");
if (!JS_IsString(name))
{
out->name = "-"; // no texture
return false;
}
out->name = M_StringDuplicate(JS_GetString(name));