COIN-OR::LEMON - Graph Library

Ignore:
File:
1 edited

Legend:

Unmodified
Added
Removed
  • lemon/smart_graph.h

    r317 r337  
    306306      nodes[b._id].first_out=nodes[n._id].first_out;
    307307      nodes[n._id].first_out=-1;
    308       for(int i=nodes[b._id].first_out;i!=-1;i++) arcs[i].source=b._id;
     308      for(int i=nodes[b._id].first_out; i!=-1; i=arcs[i].next_out) {
     309        arcs[i].source=b._id;
     310      }
    309311      if(connect) addArc(n,b);
    310312      return b;
     
    729731        dir.push_back(arcFromId(n-1));
    730732        Parent::notifier(Arc()).erase(dir);
    731         nodes[arcs[n].target].first_out=arcs[n].next_out;
    732         nodes[arcs[n-1].target].first_out=arcs[n-1].next_out;
     733        nodes[arcs[n-1].target].first_out=arcs[n].next_out;
     734        nodes[arcs[n].target].first_out=arcs[n-1].next_out;
    733735        arcs.pop_back();
    734736        arcs.pop_back();
Note: See TracChangeset for help on using the changeset viewer.