Skip to content

Commit

Permalink
Don't proceed if we have uninitialized min/max values
Browse files Browse the repository at this point in the history
  • Loading branch information
starseeker committed Jun 30, 2023
1 parent 4a768e1 commit e970d31
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions src/libbrep/cdt/fast.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -517,6 +517,10 @@ getSurfacePoints(const ON_BrepFace &face,
}
}

// Sanity
if (!bGrowBox)
return;

ON_BoundingBox tight_bbox;
if (brep->GetTightBoundingBox(tight_bbox)) {
dist = DIST_PNT_PNT(tight_bbox.m_min, tight_bbox.m_max);
Expand Down

0 comments on commit e970d31

Please sign in to comment.