From 8f86bc5c54efd2763deb5e34e69512db650e5658 Mon Sep 17 00:00:00 2001 From: "Steinar H. Gunderson" Date: Sat, 28 Oct 2017 13:01:15 +0200 Subject: [PATCH] Fix compilation with older FFmpeg. --- ffmpeg_capture.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ffmpeg_capture.cpp b/ffmpeg_capture.cpp index d2b1cb5..1ffa9d5 100644 --- a/ffmpeg_capture.cpp +++ b/ffmpeg_capture.cpp @@ -685,7 +685,7 @@ void FFmpegCapture::convert_audio(const AVFrame *audio_avframe, FrameAllocator:: uint8_t *data = audio_frame->data + audio_frame->len; int out_samples = avresample_convert(resampler, &data, 0, num_samples_room, - audio_avframe->data, audio_avframe->linesize[0], audio_avframe->nb_samples); + const_cast(audio_avframe->data), audio_avframe->linesize[0], audio_avframe->nb_samples); if (out_samples < 0) { fprintf(stderr, "Audio conversion failed.\n"); exit(1); -- 2.39.2