Make sure QList is large enough before calling at() (#1074)

This commit is contained in:
in1tiate 2025-01-23 03:17:27 -06:00 committed by GitHub
parent 0d6b89fa1f
commit c71f30a452
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -488,7 +488,10 @@ void CharacterAnimationLayer::setFrameEffects(QStringList data)
for (const QString &raw_effect : std::as_const(emote_effects))
{
QStringList frame_data = raw_effect.split("=");
if (frame_data.size() < 2)
{
continue;
}
const int frame_number = frame_data.at(0).toInt();
FrameEffect effect;