diff --git a/Source/Contents/NavigationGraph.cpp b/Source/Contents/NavigationGraph.cpp index 10a91380..2e830ddb 100644 --- a/Source/Contents/NavigationGraph.cpp +++ b/Source/Contents/NavigationGraph.cpp @@ -180,9 +180,9 @@ done: // OFFSET: 0x00B8A720 // FUNCTION: fn_19394 void CNaviData::ResetLinkDepths() { - for (CNaviInfo* destination : this->destinations) { - std::vector::iterator end = destination->LinksEnd(); - for (std::vector::iterator it = destination->LinksBegin(); it != end; ++it) { + for (CNaviInfo*& destination : this->destinations) { + std::vector::const_iterator end = destination->LinksEnd(); + for (std::vector::const_iterator it = destination->LinksBegin(); it != end; ++it) { (*it)->SetDepth(-1); } }