From bca4219dd0c8c1896a19ed5544b40656f5078b1b Mon Sep 17 00:00:00 2001 From: Bruno George de Moraes Date: Thu, 4 Sep 2014 20:44:51 -0300 Subject: malloc+memset(0) to calloc Signed-off-by: wm4 --- TOOLS/vf_dlopen/ildetect.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) (limited to 'TOOLS/vf_dlopen/ildetect.c') diff --git a/TOOLS/vf_dlopen/ildetect.c b/TOOLS/vf_dlopen/ildetect.c index ef4e45f013..d2f3d5bde5 100644 --- a/TOOLS/vf_dlopen/ildetect.c +++ b/TOOLS/vf_dlopen/ildetect.c @@ -267,8 +267,7 @@ int vf_dlopen_getcontext(struct vf_dlopen_context *ctx, int argc, const char **a (void) argc; (void) argv; - ildetect_data_t *il = malloc(sizeof(ildetect_data_t)); - memset(il, 0, sizeof(*il)); + ildetect_data_t *il = calloc(1,sizeof(ildetect_data_t)); #define A(i,d) ((argc>(i) && *argv[i]) ? atof(argv[i]) : (d)) il->method = A(0, 0); -- cgit v1.2.3