X-Git-Url: https://git.kernel.dk/?p=fio.git;a=blobdiff_plain;f=graph.c;h=7a174170c7562fe7b13b27506ba0b68709d3df00;hp=c49cdae14fb00e04154a8cf6669f0194bfd0570c;hb=HEAD;hpb=fc002f14a773b7fab28c92ff4d6eeba25c2951ea diff --git a/graph.c b/graph.c index c49cdae1..3d2b6c96 100644 --- a/graph.c +++ b/graph.c @@ -713,8 +713,7 @@ static void graph_label_add_value(struct graph_label *i, void *value, struct graph *g = i->parent; struct graph_value *x; - x = malloc(sizeof(*x)); - memset(x, 0, sizeof(*x)); + x = calloc(1, sizeof(*x)); INIT_FLIST_HEAD(&x->alias); INIT_FLIST_HEAD(&x->list); flist_add_tail(&x->list, &i->value_list);