diff --git a/libavcodec/ac3dec.c b/libavcodec/ac3dec.c
index 1c8bec885046349b101d1f6719120d6e58ca5d71..72bd109f70fd02511d9e32e47eb0cabe4a447daf 100644
--- a/libavcodec/ac3dec.c
+++ b/libavcodec/ac3dec.c
@@ -1125,7 +1125,8 @@ static int ac3_parse_audio_block(AC3DecodeContext *s, int blk)
 /**
  * Decode a single AC-3 frame.
  */
-static int ac3_decode_frame(AVCodecContext * avctx, void *data, int *data_size, uint8_t *buf, int buf_size)
+static int ac3_decode_frame(AVCodecContext * avctx, void *data, int *data_size,
+                            const uint8_t *buf, int buf_size)
 {
     AC3DecodeContext *s = avctx->priv_data;
     int16_t *out_samples = (int16_t *)data;