[FFmpeg-cvslog] zmbv: return meaningful error code

Paul B Mahol git at videolan.org
Sat Jul 27 22:23:41 CEST 2013


ffmpeg | branch: master | Paul B Mahol <onemda at gmail.com> | Sat Jul 27 20:21:33 2013 +0000| [0909f3edbdfaf480ba720f59f3743f5d95e3c059] | committer: Paul B Mahol

zmbv: return meaningful error code

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

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

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

diff --git a/libavcodec/zmbv.c b/libavcodec/zmbv.c
index 7f3b326..215e87a 100644
--- a/libavcodec/zmbv.c
+++ b/libavcodec/zmbv.c
@@ -493,7 +493,7 @@ static int decode_frame(AVCodecContext *avctx, void *data, int *got_frame, AVPac
         c->bx = (c->width + c->bw - 1) / c->bw;
         c->by = (c->height+ c->bh - 1) / c->bh;
         if (!c->cur || !c->prev)
-            return -1;
+            return AVERROR(ENOMEM);
         memset(c->cur, 0, avctx->width * avctx->height * (c->bpp / 8));
         memset(c->prev, 0, avctx->width * avctx->height * (c->bpp / 8));
         c->decode_intra= decode_intra;



More information about the ffmpeg-cvslog mailing list