From: Matthew Fernandez Date: Wed, 18 Jan 2023 16:30:16 +0000 (-0800) Subject: neatogen compute_new_weights: remove redundant zeroing X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=bbbc2b462f328ac9191da108645b0d6ad87f1030;p=graphviz neatogen compute_new_weights: remove redundant zeroing The `gv_calloc` allocation does this for us. --- diff --git a/lib/neatogen/kkutils.c b/lib/neatogen/kkutils.c index bf0246bab..4f93386cf 100644 --- a/lib/neatogen/kkutils.c +++ b/lib/neatogen/kkutils.c @@ -244,10 +244,6 @@ void compute_new_weights(vtx_data * graph, int n) } float *weights = gv_calloc(nedges, sizeof(float)); - for (i = 0; i < n; i++) { - vtx_vec[i] = 0; - } - for (i = 0; i < n; i++) { graph[i].ewgts = weights; fill_neighbors_vec_unweighted(graph, i, vtx_vec);