diff --git a/AABB_tree/examples/AABB_tree/AABB_ray_shooting_example.cpp b/AABB_tree/examples/AABB_tree/AABB_ray_shooting_example.cpp index 0804ae9a9e5..c06e26e0dc5 100644 --- a/AABB_tree/examples/AABB_tree/AABB_ray_shooting_example.cpp +++ b/AABB_tree/examples/AABB_tree/AABB_ray_shooting_example.cpp @@ -34,7 +34,7 @@ struct Skip { bool operator()(const face_descriptor& t) const { if(t == fd){ - std::cerr << "ignore" << t <(&(intersection->first))){ const Point* p = boost::get(&(intersection->first) ); diff --git a/AABB_tree/include/CGAL/internal/AABB_tree/AABB_ray_intersection.h b/AABB_tree/include/CGAL/internal/AABB_tree/AABB_ray_intersection.h index 0733051ed88..4f4c6f2b059 100644 --- a/AABB_tree/include/CGAL/internal/AABB_tree/AABB_ray_intersection.h +++ b/AABB_tree/include/CGAL/internal/AABB_tree/AABB_ray_intersection.h @@ -187,10 +187,11 @@ private: typename AABB_traits::Geom_traits::Vector_3 v = ray->to_vector(); for(int i = 0; i < 3; ++i) { - if(v[0] != FT(0.)) { - return x[0] / v[0]; + if(v[i] != FT(0.)) { + return x[i] / v[i]; } } + CGAL_assertion(false); // should never end-up here return FT(0.); }