[vlc-devel] [PATCH 1/9] audio_output: fix potential null-dereference
Rémi Denis-Courmont
remi at remlab.net
Thu Sep 1 11:28:06 CEST 2016
Le torstaina 1. syyskuuta 2016, 10.54.08 EEST Thomas Guillem a écrit :
> It can happen when a converter returns NULL in pf_audio_filter.
> ---
> src/audio_output/filters.c | 2 ++
> 1 file changed, 2 insertions(+)
>
> diff --git a/src/audio_output/filters.c b/src/audio_output/filters.c
> index 83e8646..e70f248 100644
> --- a/src/audio_output/filters.c
> +++ b/src/audio_output/filters.c
> @@ -573,6 +573,8 @@ block_t *aout_FiltersPlay (aout_filters_t *filters,
> block_t *block, int rate) }
>
> block = aout_FiltersPipelinePlay (filters->tab, filters->count, block);
> + if (block == NULL)
> + return NULL;
> if (filters->resampler != NULL)
> { /* NOTE: the resampler needs to run even if resampling is 0.
> * The decoder and output rates can still be different. */
I think this causes necessary code to no longer run (regardless of block being
NULL).
--
Rémi Denis-Courmont
http://www.remlab.net/
More information about the vlc-devel
mailing list