From 03a280c1cbecaa782b2929a3fc8da22068a683f6 Mon Sep 17 00:00:00 2001 From: Matthew Fernandez Date: Wed, 21 Dec 2022 19:08:15 -0800 Subject: [PATCH] neatogen embed_graph: fix memory leak of queue Every call to `mkQueue` is intended to be paired with a call to `freeQueue`. This function was missing its call to the free function. --- lib/neatogen/embed_graph.c | 1 + 1 file changed, 1 insertion(+) diff --git a/lib/neatogen/embed_graph.c b/lib/neatogen/embed_graph.c index b1d4c222b..47d56591e 100644 --- a/lib/neatogen/embed_graph.c +++ b/lib/neatogen/embed_graph.c @@ -91,6 +91,7 @@ void embed_graph(vtx_data * graph, int n, int dim, DistType *** Coords, } free(dist); + freeQueue(&Q); if (reweight_graph) { restore_old_weights(graph, n, old_weights); -- 2.40.0