From eaf67336aa5770499716681cacedd8c8544d2277 Mon Sep 17 00:00:00 2001 From: tatiana-kondakova Date: Tue, 7 Nov 2017 14:54:47 +0300 Subject: [PATCH] Fix transit to pedestrian connection --- routing/transit_world_graph.cpp | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/routing/transit_world_graph.cpp b/routing/transit_world_graph.cpp index d776993ed5..971a485f5f 100644 --- a/routing/transit_world_graph.cpp +++ b/routing/transit_world_graph.cpp @@ -52,10 +52,11 @@ void TransitWorldGraph::GetEdgeList(Segment const & segment, bool isOutgoing, bo vector fakeFromReal; for (auto const & edge : edges) { - for (auto const & s : transitGraph.GetFake(edge.GetTarget())) + auto const & edgeSegment = edge.GetTarget(); + for (auto const & s : transitGraph.GetFake(edgeSegment)) { - bool const haveSameFront = GetJunction(segment, true /* front */) == GetJunction(s, true); - bool const haveSameBack = GetJunction(segment, false /* front */) == GetJunction(s, false); + bool const haveSameFront = GetJunction(edgeSegment, true /* front */) == GetJunction(s, true); + bool const haveSameBack = GetJunction(edgeSegment, false /* front */) == GetJunction(s, false); if ((isOutgoing && haveSameBack) || (!isOutgoing && haveSameFront)) fakeFromReal.emplace_back(s, edge.GetWeight()); }