diff options
author | Reimar Döffinger <Reimar.Doeffinger@gmx.de> | 2006-04-20 10:38:15 +0000 |
---|---|---|
committer | Reimar Döffinger <Reimar.Doeffinger@gmx.de> | 2006-04-20 10:38:15 +0000 |
commit | 50a6c318b2d00a103297f2aa6256a7404b0f64f8 (patch) | |
tree | d5c4c025c39fe9633007e4826dbe57e320edd5f0 | |
parent | 2d5545c30206f3c84bb2cdd7df70bb290ffb4158 (diff) | |
download | ffmpeg-50a6c318b2d00a103297f2aa6256a7404b0f64f8.tar.gz |
Avoid crash if there is a rtjpeg quant header but no video stream in file
Originally committed as revision 5305 to svn://svn.ffmpeg.org/ffmpeg/trunk
-rw-r--r-- | libavformat/nuv.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/libavformat/nuv.c b/libavformat/nuv.c index 04bae8f771..e707854ef3 100644 --- a/libavformat/nuv.c +++ b/libavformat/nuv.c @@ -65,7 +65,7 @@ static int get_codec_data(ByteIOContext *pb, AVStream *vst, subtype = get_byte(pb); url_fskip(pb, 6); size = PKTSIZE(get_le32(pb)); - if (subtype == 'R') { + if (vst && subtype == 'R') { vst->codec->extradata_size = size; vst->codec->extradata = av_malloc(size); get_buffer(pb, vst->codec->extradata, size); |