Signed-off-by: James Almer <[email protected]>
---
libavformat/mov.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/libavformat/mov.c b/libavformat/mov.c
index a935ef7326..9fca402896 100644
--- a/libavformat/mov.c
+++ b/libavformat/mov.c
@@ -5025,7 +5025,7 @@ static int mov_read_keys(MOVContext *c, AVIOContext *pb,
MOVAtom atom)
avio_skip(pb, 4);
count = avio_rb32(pb);
atom.size -= 8;
- if (count > UINT_MAX / sizeof(*c->meta_keys) - 1) {
+ if (count + 1LL > UINT_MAX / sizeof(*c->meta_keys)) {
av_log(c->fc, AV_LOG_ERROR,
"The 'keys' atom with the invalid key count: %"PRIu32"\n",
count);
return AVERROR_INVALIDDATA;
--
2.44.0
_______________________________________________
ffmpeg-devel mailing list
[email protected]
https://ffmpeg.org/mailman/listinfo/ffmpeg-devel
To unsubscribe, visit link above, or email
[email protected] with subject "unsubscribe".