From fe4d96fafc2ff82371a55e04411c65e62721e48b Mon Sep 17 00:00:00 2001 From: Matthew Fernandez Date: Thu, 17 Nov 2022 17:14:41 -0800 Subject: [PATCH] neatogen triPath: use cgraph wrapper for allocation The lib/cgraph/alloc.h wrappers are similar to the older lib/common/memory.h wrappers except (1) they are header-only and (2) they live in a directory (cgraph) that is at the root of the dependency tree. The long term plan is to replace all use of lib/common/memory.h with lib/cgraph/alloc.h. --- lib/neatogen/multispline.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/neatogen/multispline.c b/lib/neatogen/multispline.c index 805c14b24..8f92127fc 100644 --- a/lib/neatogen/multispline.c +++ b/lib/neatogen/multispline.c @@ -1197,7 +1197,7 @@ triPath(tgraph * g, int n, int v0, int v1, PQ * pq) double d; tnode *np; tedge *e; - int *dad = N_NEW(n, int); + int *dad = gv_calloc(n, sizeof(int)); for (i = 0; i < pq->PQsize; i++) N_VAL(pq, i) = UNSEEN; -- 2.50.1