2
0
mirror of https://github.com/telegramdesktop/tdesktop synced 2025-08-31 06:26:18 +00:00

Fix possible crash on bad data.

This commit is contained in:
John Preston
2022-05-12 16:29:12 +04:00
parent 54fa16424d
commit 368468447f

View File

@@ -1194,7 +1194,9 @@ bool DocumentData::hasRemoteLocation() const {
}
bool DocumentData::useStreamingLoader() const {
if (const auto info = sticker()) {
if (size <= 0) {
return false;
} else if (const auto info = sticker()) {
return info->isWebm();
}
return isAnimation()