diff options
author | Paul B Mahol <onemda@gmail.com> | 2022-08-31 18:36:04 +0200 |
---|---|---|
committer | Paul B Mahol <onemda@gmail.com> | 2022-08-31 23:10:41 +0200 |
commit | 319e8a49b5bcfa80fcb6f50f0dd78c6408c972ae (patch) | |
tree | 4571d2cd6a41b3198b605b20adc8d985caad88fc | |
parent | 1f1a368169ef9d945dc4b4764f5c60ba9bbc9134 (diff) | |
download | ffmpeg-319e8a49b5bcfa80fcb6f50f0dd78c6408c972ae.tar.gz |
avcodec/amr*bdec: return only number of consumed bytes
-rw-r--r-- | libavcodec/amrnbdec.c | 2 | ||||
-rw-r--r-- | libavcodec/amrwbdec.c | 2 |
2 files changed, 2 insertions, 2 deletions
diff --git a/libavcodec/amrnbdec.c b/libavcodec/amrnbdec.c index dcf66c1dde..e07c01923e 100644 --- a/libavcodec/amrnbdec.c +++ b/libavcodec/amrnbdec.c @@ -1091,7 +1091,7 @@ static int amrnb_decode_frame(AVCodecContext *avctx, AVFrame *frame, *got_frame_ptr = 1; - return avpkt->size; + return buf - avpkt->data; } diff --git a/libavcodec/amrwbdec.c b/libavcodec/amrwbdec.c index f9a67c43b7..1e537e1a3b 100644 --- a/libavcodec/amrwbdec.c +++ b/libavcodec/amrwbdec.c @@ -1288,7 +1288,7 @@ static int amrwb_decode_frame(AVCodecContext *avctx, AVFrame *frame, *got_frame_ptr = 1; - return avpkt->size; + return buf - avpkt->data; } const FFCodec ff_amrwb_decoder = { |