From 8513150bdf34cbc7345131730209dda3be03379f Mon Sep 17 00:00:00 2001 From: Wim Taymans Date: Fri, 8 May 2020 16:13:34 +0200 Subject: [PATCH] resample: use calloc to make sure fields are 0 --- spa/plugins/audioconvert/resample-native.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/spa/plugins/audioconvert/resample-native.c b/spa/plugins/audioconvert/resample-native.c index 709df55f8..3543a91e9 100644 --- a/spa/plugins/audioconvert/resample-native.c +++ b/spa/plugins/audioconvert/resample-native.c @@ -353,7 +353,7 @@ int resample_native_init(struct resample *r) history_stride = SPA_ROUND_UP_N(2 * n_taps * sizeof(float), 64); history_size = r->channels * history_stride; - d = malloc(sizeof(struct native_data) + + d = calloc(1, sizeof(struct native_data) + filter_size + history_size + (r->channels * sizeof(float*)) +