index 4265286bdaf899dcb2bba34e97a712876d5455b0..60273382dec81950cfa61a2273d3103f79a8f664 100644 (file)
--- a/src/daemon/utils_llist.c
+++ b/src/daemon/utils_llist.c
* Florian Forster <octo at collectd.org>
*/
-#include "config.h"
-
#include <stdlib.h>
#include <string.h>
{
llist_t *ret;
- ret = (llist_t *) malloc (sizeof (llist_t));
+ ret = calloc (1, sizeof (*ret));
if (ret == NULL)
return (NULL);
- memset (ret, '\0', sizeof (llist_t));
-
return (ret);
}
{
llentry_t *e;
- e = (llentry_t *) malloc (sizeof (llentry_t));
+ e = malloc (sizeof (*e));
if (e)
{
e->key = key;