summary | shortlog | log | commit | commitdiff | tree
raw | patch | inline | side by side (parent: 5770214)
raw | patch | inline | side by side (parent: 5770214)
author | Ruben Kerkhof <ruben@rubenkerkhof.com> | |
Fri, 1 Apr 2016 16:20:59 +0000 (18:20 +0200) | ||
committer | Ruben Kerkhof <ruben@rubenkerkhof.com> | |
Fri, 1 Apr 2016 16:20:59 +0000 (18:20 +0200) |
src/tail_csv.c | patch | blob | history |
diff --git a/src/tail_csv.c b/src/tail_csv.c
index 15c083ea40d29c52f9b8667d8920d171d8c1d2d1..2d794fc7880fccf310ce4e44b6179937b7657599 100644 (file)
--- a/src/tail_csv.c
+++ b/src/tail_csv.c
int status;
int i;
- md = malloc(sizeof(*md));
+ md = calloc(1, sizeof(*md));
if (md == NULL)
return (-1);
- memset(md, 0, sizeof(*md));
md->name = NULL;
md->type = NULL;
md->instance = NULL;
char cb_name[DATA_MAX_NAME_LEN];
user_data_t cb_data;
- id = malloc(sizeof(*id));
+ id = calloc(1, sizeof(*id));
if (id == NULL)
return (-1);
- memset(id, 0, sizeof(*id));
id->instance = NULL;
id->path = NULL;
id->metric_list = NULL;