avcodec/smvjpegdec: return the packet size instead of 0

Most decoders return the amount of data used.
This is more consistent

Reviewed-by: Paul B Mahol <onemda@gmail.com>
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
This commit is contained in:
Michael Niedermayer 2016-12-15 20:09:48 +01:00
parent 0888c5a242
commit c869e00f88

View File

@ -200,9 +200,11 @@ static int smvjpeg_decode_frame(AVCodecContext *avctx, void *data, int *data_siz
s->picture[1]->linesize[i] = mjpeg_data->linesize[i];
ret = av_frame_ref(data, s->picture[1]);
if (ret < 0)
return ret;
}
return ret;
return avpkt->size;
}
static const AVClass smvjpegdec_class = {