X-Git-Url: https://git.verplant.org/?a=blobdiff_plain;ds=inline;f=src%2Futils_fbhash.c;h=41f640af5a835652b73fb943523cb352dff726fd;hb=2ce1db8202b1eba6da45b347c0c81a508f8c088a;hp=cbd150610205255a8a20478a324175a7feebd35a;hpb=0532336600cf2abe1d25af8fbf5ad3cf3b6b31e0;p=collectd.git diff --git a/src/utils_fbhash.c b/src/utils_fbhash.c index cbd15061..41f640af 100644 --- a/src/utils_fbhash.c +++ b/src/utils_fbhash.c @@ -27,8 +27,6 @@ #include "collectd.h" #include "plugin.h" -#include - #include "utils_fbhash.h" #include "utils_avltree.h" @@ -209,10 +207,9 @@ fbhash_t *fbh_create (const char *file) /* {{{ */ if (file == NULL) return (NULL); - h = malloc (sizeof (*h)); + h = calloc (1, sizeof (*h)); if (h == NULL) return (NULL); - memset (h, 0, sizeof (*h)); h->filename = strdup (file); if (h->filename == NULL)