diff --git a/algorithm/tarjan.h b/algorithm/tarjan.h index b6223d7..fcd0ab2 100644 --- a/algorithm/tarjan.h +++ b/algorithm/tarjan.h @@ -56,7 +56,7 @@ void Tarjan::strongConnect(const T& v) { std::vector SCC; bool finished = false; do { - const auto& w = S.top(); + const auto w = S.top(); S.pop(); vp[w].onStack = false; SCC.push_back(w);