File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -59,13 +59,13 @@ class Path {
5959 std::deque< Path_t > path;
6060 int64_t m_start_id;
6161 int64_t m_end_id;
62- double m_tot_cost;
62+ double m_tot_cost{ 0 } ;
6363
6464 public:
65- Path (): m_start_id(0 ), m_end_id( 0 ), m_tot_cost (0 )
65+ Path () : m_start_id(0 ), m_end_id(0 )
6666 {}
6767 Path (int64_t s_id, int64_t e_id)
68- : m_start_id(s_id), m_end_id(e_id), m_tot_cost( 0 )
68+ : m_start_id(s_id), m_end_id(e_id)
6969 {}
7070
7171 int64_t start_id () const {return m_start_id;}
@@ -178,8 +178,7 @@ class Path {
178178 const Path &original,
179179 bool only_cost) :
180180 m_start_id(original.m_start_id),
181- m_end_id(original.m_end_id),
182- m_tot_cost(0 ) {
181+ m_end_id(original.m_end_id) {
183182 if (original.path .empty ()) return ;
184183
185184 typename G::EO_i ei, ei_end;
Original file line number Diff line number Diff line change @@ -145,7 +145,7 @@ PgrCostFlowGraph::GetFlowEdges() const {
145145 if (((capacity[*e] - residual_capacity[*e]) > 0 ) &&
146146 ((*e).m_source != supersource) &&
147147 ((*e).m_target != supersink)) {
148- Flow_t edge;
148+ Flow_t edge{} ;
149149 edge.edge = GetEdgeId (*e);
150150 edge.source = GetVertexId ((*e).m_source );
151151 edge.target = GetVertexId ((*e).m_target );
You can’t perform that action at this time.
0 commit comments