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>
pull/242/head
Michael Niedermayer 8 years ago
parent 0888c5a242
commit c869e00f88
  1. 4
      libavcodec/smvjpegdec.c

@ -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 = {

Loading…
Cancel
Save