[FFmpeg-cvslog] avformat/thp: check av_get_packet() for failure
Paul B Mahol
git at videolan.org
Fri Feb 6 10:47:03 CET 2015
ffmpeg | branch: master | Paul B Mahol <onemda at gmail.com> | Thu Feb 5 14:44:04 2015 +0000| [dc3c3758ce6368aa2f0a9a9b544bce2e130cc4e1] | committer: Paul B Mahol
avformat/thp: check av_get_packet() for failure
Signed-off-by: Paul B Mahol <onemda at gmail.com>
> http://git.videolan.org/gitweb.cgi/ffmpeg.git/?a=commit;h=dc3c3758ce6368aa2f0a9a9b544bce2e130cc4e1
---
libavformat/thp.c | 2 ++
1 file changed, 2 insertions(+)
diff --git a/libavformat/thp.c b/libavformat/thp.c
index 91fa90f..727fb50 100644
--- a/libavformat/thp.c
+++ b/libavformat/thp.c
@@ -176,6 +176,8 @@ static int thp_read_packet(AVFormatContext *s,
thp->frame++;
ret = av_get_packet(pb, pkt, size);
+ if (ret < 0)
+ return ret;
if (ret != size) {
av_free_packet(pkt);
return AVERROR(EIO);
More information about the ffmpeg-cvslog
mailing list