From: north Date: Wed, 1 Feb 2006 20:59:32 +0000 (+0000) Subject: Fix for accidentally creating parallel edge in constraint graph X-Git-Tag: LAST_LIBGRAPH~32^2~6807 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=e261e87ac4d448a8672afdb6428486c459dc517f;p=graphviz Fix for accidentally creating parallel edge in constraint graph when a cluster has a label. --- diff --git a/lib/dotgen/position.c b/lib/dotgen/position.c index 67e40ca48..ce123ec84 100644 --- a/lib/dotgen/position.c +++ b/lib/dotgen/position.c @@ -346,10 +346,14 @@ static void make_edge_pairs(graph_t * g) static void contain_clustnodes(graph_t * g) { int c; + edge_t *e; if (g != g->root) { contain_nodes(g); - make_aux_edge(GD_ln(g), GD_rn(g), 1, 128); /* clust compaction edge */ + if ((e = find_fast_edge(GD_ln(g),GD_rn(g)))) /* maybe from lrvn()?*/ + ED_weight(e) += 128; + else + make_aux_edge(GD_ln(g), GD_rn(g), 1, 128); /* clust compaction edge */ } for (c = 1; c <= GD_n_cluster(g); c++) contain_clustnodes(GD_clust(g)[c]);