1.1 --- a/lemon/bellman_ford.h Fri Nov 20 14:18:33 2009 +0100
1.2 +++ b/lemon/bellman_ford.h Sun Dec 13 22:19:08 2009 +0100
1.3 @@ -237,7 +237,9 @@
1.4 _local_dist = true;
1.5 _dist = Traits::createDistMap(*_gr);
1.6 }
1.7 - _mask = new MaskMap(*_gr, false);
1.8 + if(!_mask) {
1.9 + _mask = new MaskMap(*_gr);
1.10 + }
1.11 }
1.12
1.13 public :
1.14 @@ -404,6 +406,10 @@
1.15 _process.push_back(it);
1.16 _mask->set(it, true);
1.17 }
1.18 + } else {
1.19 + for (NodeIt it(*_gr); it != INVALID; ++it) {
1.20 + _mask->set(it, false);
1.21 + }
1.22 }
1.23 }
1.24