Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/FFmpeg/FFmpeg.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorPaul B Mahol <onemda@gmail.com>2012-11-02 20:21:17 +0400
committerPaul B Mahol <onemda@gmail.com>2012-11-02 20:32:51 +0400
commitc39fb308162020ee82310613bf88271c1417d226 (patch)
treedb155824958586ce9cc45ee831e1b292d6c3066d /libavformat/smjpegdec.c
parent805b57001f80237e24dc2d225c1b9e116566d247 (diff)
smjpegdec: set nb_frames for video stream
Signed-off-by: Paul B Mahol <onemda@gmail.com>
Diffstat (limited to 'libavformat/smjpegdec.c')
-rw-r--r--libavformat/smjpegdec.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/libavformat/smjpegdec.c b/libavformat/smjpegdec.c
index 0cd993f8eb..ceb29c9b5f 100644
--- a/libavformat/smjpegdec.c
+++ b/libavformat/smjpegdec.c
@@ -106,10 +106,10 @@ static int smjpeg_read_header(AVFormatContext *s)
hlength = avio_rb32(pb);
if (hlength < 12)
return AVERROR_INVALIDDATA;
- avio_skip(pb, 4); // number of frames
vst = avformat_new_stream(s, 0);
if (!vst)
return AVERROR(ENOMEM);
+ vst->nb_frames = avio_rb32(pb);
vst->codec->codec_type = AVMEDIA_TYPE_VIDEO;
vst->codec->width = avio_rb16(pb);
vst->codec->height = avio_rb16(pb);