diff --git a/src/libslic3r/SupportMaterial.cpp b/src/libslic3r/SupportMaterial.cpp index 796a8a22a..cdbd4d25b 100644 --- a/src/libslic3r/SupportMaterial.cpp +++ b/src/libslic3r/SupportMaterial.cpp @@ -192,8 +192,8 @@ static Polygons contours_simplified(const Vec2i &grid_size, const double pixel_s // Fill in empty cells, which have a left / right neighbor filled. // Fill in empty cells, which have the top / bottom neighbor filled. - std::vector cell_inside_data; - std::vector &cell_inside = fill_holes ? cell_inside_data : grid; + std::vector cell_inside_data; + const std::vector &cell_inside = fill_holes ? cell_inside_data : grid; if (fill_holes) { cell_inside_data = grid; for (int r = 1; r + 1 < grid_size.y(); ++ r) {