summaryrefslogtreecommitdiff
path: root/libavformat
diff options
context:
space:
mode:
authorCarl Eugen Hoyos <cehoyos@ag.or.at>2015-05-21 00:43:38 +0200
committerCarl Eugen Hoyos <cehoyos@ag.or.at>2015-05-21 00:43:38 +0200
commit8f6b919d99687416deaedb2df6b8b5f49645a291 (patch)
treedd68e455355a5341eb5c75dd9c7f64fa8b176a87 /libavformat
parent642355712b970c4b17a207cc0ea42ea6adaba39f (diff)
lavf/mkv: Only skip prores header if the packet is large enough.
Fixes a possible endless loop.
Diffstat (limited to 'libavformat')
-rw-r--r--libavformat/matroskaenc.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/libavformat/matroskaenc.c b/libavformat/matroskaenc.c
index 7cbba0b002..c4c58f4d09 100644
--- a/libavformat/matroskaenc.c
+++ b/libavformat/matroskaenc.c
@@ -1575,7 +1575,7 @@ static void mkv_write_block(AVFormatContext *s, AVIOContext *pb,
} else
data = pkt->data;
- if (codec->codec_id == AV_CODEC_ID_PRORES) {
+ if (codec->codec_id == AV_CODEC_ID_PRORES && size >= 8) {
/* Matroska specification requires to remove the first QuickTime atom
*/
size -= 8;