From 4854979c2c3a2c67081f4e8a0b397e47bf4448bf Mon Sep 17 00:00:00 2001 From: erg Date: Thu, 16 Apr 2009 16:49:40 +0000 Subject: [PATCH] Memory for nodes and edges wasn't being freed in agdelnode and agdeledge. --- lib/cgraph/edge.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/lib/cgraph/edge.c b/lib/cgraph/edge.c index f0c6615b0..fe1b18990 100644 --- a/lib/cgraph/edge.c +++ b/lib/cgraph/edge.c @@ -355,8 +355,7 @@ int agdeledge(Agraph_t * g, Agedge_t * e) agrecclose((Agobj_t *) e); agfreeid(g, AGEDGE, AGID(e)); } - if (agapply - (g, (Agobj_t *) e, (agobjfn_t) agdeledgeimage, NILedge, FALSE)) { + if (agapply (g, (Agobj_t *) e, (agobjfn_t) agdeledgeimage, NILedge, FALSE) == SUCCESS) { agfree(g, e); return SUCCESS; } else -- 2.40.0