From d2ca5dd0f33b0fdbb5d2a7429c8f71ff1dffffb7 Mon Sep 17 00:00:00 2001 From: Nicolas George Date: Sun, 29 Jul 2012 00:14:27 +0200 Subject: [PATCH] loco: fix return value. The return value was the number of bytes left, it is supposed to be the number of bytes used. --- libavcodec/loco.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/libavcodec/loco.c b/libavcodec/loco.c index cc8ce21c12..b4f8ad4424 100644 --- a/libavcodec/loco.c +++ b/libavcodec/loco.c @@ -233,7 +233,7 @@ stop: *data_size = sizeof(AVFrame); *(AVFrame*)data = l->pic; - return buf_size < 0 ? -1 : buf_size; + return buf_size < 0 ? -1 : avpkt->size - buf_size; } static av_cold int decode_init(AVCodecContext *avctx){