diff --git a/libavcodec/aptxdec.c b/libavcodec/aptxdec.c index 878c9ffe1b..d254b3026b 100644 --- a/libavcodec/aptxdec.c +++ b/libavcodec/aptxdec.c @@ -151,7 +151,7 @@ static int aptx_decode_frame(AVCodecContext *avctx, AVFrame *frame, /* get output buffer */ frame->ch_layout.nb_channels = NB_CHANNELS; frame->format = AV_SAMPLE_FMT_S32P; - frame->nb_samples = 4 * avpkt->size / s->block_size; + frame->nb_samples = 4 * (avpkt->size / s->block_size); if ((ret = ff_get_buffer(avctx, frame, 0)) < 0) return ret;