lottie: --minor memory leak

This commit is contained in:
Hermet Park 2024-11-19 01:13:19 +09:00 committed by Hermet Park
parent b66ce727ff
commit b7888c2ff3

View file

@ -1519,7 +1519,10 @@ bool LottieParser::apply(LottieSlot* slot, bool byDefault)
default: break; default: break;
} }
if (!obj || Invalid()) return false; if (!obj || Invalid()) {
delete(obj);
return false;
}
slot->assign(obj, byDefault); slot->assign(obj, byDefault);