[FFmpeg-devel] [PATCH 05/25] avfilter/af_headphone: Don't overrun array

Paul B Mahol onemda at gmail.com
Wed Sep 9 03:51:00 EEST 2020


On Tue, Sep 08, 2020 at 11:18:36PM +0200, Andreas Rheinhardt wrote:
> The headphone filter stores the channel position of the ith HRIR stream
> in the ith element of an array of 64 elements; but because there is no
> check for duplicate channels, it is easy to write beyond the end of the
> array by simply repeating channels.
> 
> This commit adds a check for duplicate channels to rule this out.
> 
> Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt at gmail.com>
> ---
>  libavfilter/af_headphone.c | 14 ++++++++++----
>  1 file changed, 10 insertions(+), 4 deletions(-)
> 

LGTM


More information about the ffmpeg-devel mailing list