[FFmpeg-cvslog] 4xm: return error code if decode_init() failed

Paul B Mahol git at videolan.org
Tue Nov 20 10:46:01 CET 2012


ffmpeg | branch: master | Paul B Mahol <onemda at gmail.com> | Tue Nov 20 09:42:32 2012 +0000| [a5e382ad7ffd8be810f3a614c4c447a1cd1936f2] | committer: Paul B Mahol

4xm: return error code if decode_init() failed

Signed-off-by: Paul B Mahol <onemda at gmail.com>

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

 libavcodec/4xm.c |    2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/libavcodec/4xm.c b/libavcodec/4xm.c
index bf0241a..85795f9 100644
--- a/libavcodec/4xm.c
+++ b/libavcodec/4xm.c
@@ -941,7 +941,7 @@ static av_cold int decode_init(AVCodecContext *avctx)
 
     if (avctx->extradata_size != 4 || !avctx->extradata) {
         av_log(avctx, AV_LOG_ERROR, "extradata wrong or missing\n");
-        return 1;
+        return AVERROR_INVALIDDATA;
     }
     if((avctx->width % 16) || (avctx->height % 16)) {
         av_log(avctx, AV_LOG_ERROR, "unsupported width/height\n");



More information about the ffmpeg-cvslog mailing list