Skip to Content.
Sympa Menu

cgal-discuss - [cgal-discuss] Arr_vertical_decomposition_2.h

Subject: CGAL users discussion list

List archive

[cgal-discuss] Arr_vertical_decomposition_2.h


Chronological Thread 
  • From: "Jannis Warnat" <>
  • To: <>
  • Subject: [cgal-discuss] Arr_vertical_decomposition_2.h
  • Date: Fri, 20 Feb 2009 16:16:28 +0100

Hi,
 
there is a bug in Arr_vertical_decomposition_2.h from CGAL 3.4 in the following code snippet (line 85):
 
// Go over all isolated vertices and collect their points. To each point
// we attach its vertex handle.
std::vector<Vd_point_2> iso_pts_vec (arr.number_of_isolated_vertices());
Vertex_const_iterator vit;
Vertex_const_handle iso_v;
i = 0;
for (vit = arr.vertices_begin(); vit != arr.vertices_end(); ++vit, ++i)
{
// Associate isolated point with the vertex that represents it.
if (vit->is_isolated())
{
iso_v = vit;
iso_pts_vec[i] = Vd_point_2 (vit->point(), iso_v);
}
}
 
The "++i" should be moved to the end of the if-clause. Otherwise i goes up to arr.number_of_vertices() while the vector iso_pts_vec is initialized for arr.number_of_isolated_vertices() elements.
 
Kind regards,
 
Jannis Warnat
 



Archive powered by MHonArc 2.6.16.

Top of Page