[FFmpeg-cvslog] cdxl demux: do not create packets with uninitialized data at EOF.

Reimar Döffinger git at videolan.org
Sun Feb 26 19:40:27 CET 2012


ffmpeg | branch: master | Reimar Döffinger <Reimar.Doeffinger at gmx.de> | Sun Feb 26 17:08:38 2012 +0100| [d7804de351da059bf0c41c2bc2bbc02dbb755c0f] | committer: Reimar Döffinger

cdxl demux: do not create packets with uninitialized data at EOF.

Fixes a failure in cdxl-pal8 test for the valgrind FATE instance.

Signed-off-by: Reimar Döffinger <Reimar.Doeffinger at gmx.de>

> http://git.videolan.org/gitweb.cgi/ffmpeg.git/?a=commit;h=d7804de351da059bf0c41c2bc2bbc02dbb755c0f
---

 libavformat/cdxl.c |    1 +
 1 files changed, 1 insertions(+), 0 deletions(-)

diff --git a/libavformat/cdxl.c b/libavformat/cdxl.c
index b056d69..ed795e4 100644
--- a/libavformat/cdxl.c
+++ b/libavformat/cdxl.c
@@ -142,6 +142,7 @@ static int cdxl_read_packet(AVFormatContext *s, AVPacket *pkt)
             av_free_packet(pkt);
             return ret;
         }
+        av_shrink_packet(pkt, CDXL_HEADER_SIZE + ret);
         pkt->stream_index  = cdxl->video_stream_index;
         pkt->flags        |= AV_PKT_FLAG_KEY;
         pkt->pos           = pos;



More information about the ffmpeg-cvslog mailing list