[FFmpeg-cvslog] avformat/a64: Avoid segfault in a64_write_header() when stream codec is not open

Andrey Myznikov git at videolan.org
Mon Aug 18 19:49:45 CEST 2014


ffmpeg | branch: master | Andrey Myznikov <andrey.myznikov at gmail.com> | Mon Aug 18 20:03:31 2014 +0300| [79593096c43c13a4524822fceffca7e4647ff67d] | committer: Michael Niedermayer

avformat/a64: Avoid segfault in a64_write_header() when stream codec is not open

Signed-off-by: Michael Niedermayer <michaelni at gmx.at>

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

 libavformat/a64.c |    2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/libavformat/a64.c b/libavformat/a64.c
index 03679b2..a7f93a2 100644
--- a/libavformat/a64.c
+++ b/libavformat/a64.c
@@ -40,7 +40,7 @@ static int a64_write_header(AVFormatContext *s)
         return AVERROR_INVALIDDATA;
     }
 
-    switch (avctx->codec->id) {
+    switch (avctx->codec_id) {
     case AV_CODEC_ID_A64_MULTI:
         header[2] = 0x00;
         header[3] = AV_RB32(avctx->extradata+0);



More information about the ffmpeg-cvslog mailing list