# HG changeset patch # User Peter Kovacs # Date 2008-11-06 23:12:57 # Node ID 00c8843d491d53848439decbb302abdb8525f173 # Parent 6dbd5184c6a99e936a7de899e64c114e30c0f94f Critical bug fix in SmartDigraph::split() #170 diff --git a/lemon/smart_graph.h b/lemon/smart_graph.h --- a/lemon/smart_graph.h +++ b/lemon/smart_graph.h @@ -305,7 +305,9 @@ Node b = addNode(); nodes[b._id].first_out=nodes[n._id].first_out; nodes[n._id].first_out=-1; - for(int i=nodes[b._id].first_out;i!=-1;i++) arcs[i].source=b._id; + for(int i=nodes[b._id].first_out; i!=-1; i=arcs[i].next_out) { + arcs[i].source=b._id; + } if(connect) addArc(n,b); return b; }