]> git.sesse.net Git - ffmpeg/blobdiff - libavformat/mpeg.c
Merge commit 'c869fcdeac3b7cd71a852b928902daadeca55685'
[ffmpeg] / libavformat / mpeg.c
index 90434a1437d5a701a8a836f59a5b35d56f66841d..1777283939cacfe12382cccef31a02a9e9cf6f11 100644 (file)
@@ -193,6 +193,8 @@ static long mpegps_psm_parse(MpegDemuxContext *m, AVIOContext *pb)
     /* skip program_stream_info */
     avio_skip(pb, ps_info_length);
     es_map_length = avio_rb16(pb);
+    /* Ignore es_map_length, trust psm_length */
+    es_map_length = psm_length - ps_info_length - 10;
 
     /* at least one es available? */
     while (es_map_length >= 4){