diff --git a/ApplicationCode/ReservoirDataModel/RigWellPathIntersectionTools.cpp b/ApplicationCode/ReservoirDataModel/RigWellPathIntersectionTools.cpp index 9dd270db65..335ac59864 100644 --- a/ApplicationCode/ReservoirDataModel/RigWellPathIntersectionTools.cpp +++ b/ApplicationCode/ReservoirDataModel/RigWellPathIntersectionTools.cpp @@ -48,7 +48,7 @@ std::vector RigWellPathIntersectionTools::findCell size_t cellIndex; WellPathCellDirection direction; - auto& intersection = intersections.cbegin(); + auto intersection = intersections.cbegin(); if (includeStartCell) {