diff options
author | Anton Khirnov <anton@khirnov.net> | 2013-05-26 10:47:22 +0200 |
---|---|---|
committer | Anton Khirnov <anton@khirnov.net> | 2013-05-28 08:03:57 +0200 |
commit | 35596bd4f4d3c39eed838cf3a2613817d62dda99 (patch) | |
tree | cd433a36c0ce50b5812145e3f80bb6dcc7e0be52 /libavcodec/wavpack.c | |
parent | d1bec4be2207738669874e02605e879ea9620974 (diff) | |
download | ffmpeg-35596bd4f4d3c39eed838cf3a2613817d62dda99.tar.gz |
wavpack: remove a useless parameter from wavpack_decode_block().
The decoder always returns output if an error does not occur.
Diffstat (limited to 'libavcodec/wavpack.c')
-rw-r--r-- | libavcodec/wavpack.c | 9 |
1 files changed, 4 insertions, 5 deletions
diff --git a/libavcodec/wavpack.c b/libavcodec/wavpack.c index d673ad454c..44cedd5e75 100644 --- a/libavcodec/wavpack.c +++ b/libavcodec/wavpack.c @@ -752,8 +752,7 @@ static av_cold int wavpack_decode_end(AVCodecContext *avctx) } static int wavpack_decode_block(AVCodecContext *avctx, int block_no, - uint8_t **data, int *got_frame_ptr, - const uint8_t *buf, int buf_size) + uint8_t **data, const uint8_t *buf, int buf_size) { WavpackContext *wc = avctx->priv_data; WavpackFrameContext *s; @@ -1128,8 +1127,6 @@ static int wavpack_decode_block(AVCodecContext *avctx, int block_no, memcpy(samples_r, samples_l, bpp * s->samples); } - *got_frame_ptr = 1; - return 0; } @@ -1215,7 +1212,7 @@ static int wavpack_decode_frame(AVCodecContext *avctx, void *data, return AVERROR_INVALIDDATA; } if ((ret = wavpack_decode_block(avctx, s->block, - frame->extended_data, got_frame_ptr, + frame->extended_data, buf, frame_size)) < 0) { wavpack_decode_flush(avctx); return ret; @@ -1225,6 +1222,8 @@ static int wavpack_decode_frame(AVCodecContext *avctx, void *data, buf_size -= frame_size; } + *got_frame_ptr = 1; + return avpkt->size; } |