Skip to content

Commit

Permalink
Added cancellation checks
Browse files Browse the repository at this point in the history
  • Loading branch information
JoBuRo committed Oct 15, 2024
1 parent dd76bdb commit 42be542
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions src/engine/PathSearch.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -322,6 +322,7 @@ PathsLimited PathSearch::findPaths(const Id& source,
}

while (!edgeStack.empty()) {
checkCancellation();
auto edge = edgeStack.back();
edgeStack.pop_back();

Expand Down Expand Up @@ -404,6 +405,7 @@ void PathSearch::pathsToResultTable(IdTable& tableDyn,
}

for (size_t edgeIndex = 0; edgeIndex < path.size(); edgeIndex++) {
checkCancellation();
auto edge = path.edges_[edgeIndex];
table.emplace_back();
table(rowIndex, getStartIndex()) = edge.start_;
Expand Down

0 comments on commit 42be542

Please sign in to comment.