aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorNicolas George <nicolas.george@normalesup.org>2012-07-28 19:36:21 +0200
committerNicolas George <nicolas.george@normalesup.org>2012-07-31 17:22:23 +0200
commit3d5dc7d87df4753967591b803c1bddb13033ffc3 (patch)
treef1ecfe7d83e525b6f17314ea0653b2bbc59075bb
parentcc7eff1fa0b13cede7df176927616d5c3675a020 (diff)
downloadffmpeg-3d5dc7d87df4753967591b803c1bddb13033ffc3.tar.gz
mmvideo: count preamble size in return value.
MM_PREAMBLE_SIZE is subtracted from buf_size almost immediately. The original size is still in avpkt->size.
-rw-r--r--libavcodec/mmvideo.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/libavcodec/mmvideo.c b/libavcodec/mmvideo.c
index abba29fb75..c79099471b 100644
--- a/libavcodec/mmvideo.c
+++ b/libavcodec/mmvideo.c
@@ -194,7 +194,7 @@ static int mm_decode_frame(AVCodecContext *avctx,
}
switch(type) {
- case MM_TYPE_PALETTE : res = mm_decode_pal(s); return buf_size;
+ case MM_TYPE_PALETTE : res = mm_decode_pal(s); return avpkt->size;
case MM_TYPE_INTRA : res = mm_decode_intra(s, 0, 0); break;
case MM_TYPE_INTRA_HH : res = mm_decode_intra(s, 1, 0); break;
case MM_TYPE_INTRA_HHV : res = mm_decode_intra(s, 1, 1); break;
@@ -213,7 +213,7 @@ static int mm_decode_frame(AVCodecContext *avctx,
*data_size = sizeof(AVFrame);
*(AVFrame*)data = s->frame;
- return buf_size;
+ return avpkt->size;
}
static av_cold int mm_decode_end(AVCodecContext *avctx)