mirror of https://git.ffmpeg.org/ffmpeg.git
swresample/resample: use av_malloc_array() where appropriate
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
(cherry picked from commit 5027f39712
)
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
This commit is contained in:
parent
15871a90aa
commit
9d8e231459
|
@ -95,7 +95,7 @@ static int build_filter(ResampleContext *c, void *filter, double factor, int tap
|
||||||
int filter_type, int kaiser_beta){
|
int filter_type, int kaiser_beta){
|
||||||
int ph, i;
|
int ph, i;
|
||||||
double x, y, w;
|
double x, y, w;
|
||||||
double *tab = av_malloc(tap_count * sizeof(*tab));
|
double *tab = av_malloc_array(tap_count, sizeof(*tab));
|
||||||
const int center= (tap_count-1)/2;
|
const int center= (tap_count-1)/2;
|
||||||
|
|
||||||
if (!tab)
|
if (!tab)
|
||||||
|
|
Loading…
Reference in New Issue