Skip to content

Commit 8035161

Browse files
committed
fix
1 parent b66dfb5 commit 8035161

File tree

1 file changed

+4
-2
lines changed

1 file changed

+4
-2
lines changed

src/analysis/network/qgslinevectorlayerdirector.cpp

+4-2
Original file line numberDiff line numberDiff line change
@@ -335,18 +335,20 @@ void QgsLineVectorLayerDirector::makeGraph( QgsGraphBuilderInterface *builder, c
335335
if ( pointLengthIt != pointLengthMap.end() )
336336
{
337337
QVector< TiePointInfo >::iterator it;
338-
for ( it = pointLengthIt; it - pointLengthMap.begin() > 0; --it )
338+
for ( it = pointLengthIt; it - pointLengthMap.begin() >= 0; --it )
339339
{
340340
if ( it->mFirstPoint == pt1 && it->mLastPoint == pt2 )
341341
{
342+
std::cout << "op1\n";
342343
pointsOnArc[ pt1.sqrDist( it->mTiedPoint ) ] = it->mTiedPoint;
343344
}
344345
}
345346
for ( it = pointLengthIt+1; it != pointLengthMap.end(); ++it )
346347
{
347348
if ( it->mFirstPoint == pt1 && it->mLastPoint == pt2 )
348349
{
349-
pointsOnArc[ pt2.sqrDist( it->mTiedPoint ) ] = it->mTiedPoint;
350+
std::cout << "op2\n";
351+
pointsOnArc[ pt1.sqrDist( it->mTiedPoint ) ] = it->mTiedPoint;
350352
}
351353
}
352354
}

0 commit comments

Comments
 (0)