mirror of
https://invent.kde.org/frameworks/kimageformats.git
synced 2025-06-03 17:08:08 -04:00
psd: Don't assert on broken files
oss-fuzz/46407
This commit is contained in:
parent
72fc32aefc
commit
384f78a13c
@ -211,8 +211,11 @@ static PSDImageResourceSection readImageResourceSection(QDataStream &s, bool *ok
|
|||||||
}
|
}
|
||||||
|
|
||||||
#ifdef QT_DEBUG
|
#ifdef QT_DEBUG
|
||||||
if (auto dev = s.device())
|
if (auto dev = s.device()) {
|
||||||
Q_ASSERT((dev->pos()-pos) == sectioSize);
|
if ((dev->pos() - pos) != sectioSize) {
|
||||||
|
*ok = false;
|
||||||
|
}
|
||||||
|
}
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
return irs;
|
return irs;
|
||||||
|
Loading…
x
Reference in New Issue
Block a user