DCMathSegmentMaker: Resolve a segfault in MCSFT::find3DSegments
The existing code incorrectly removes elements from a std::vector while iterating over it. While it is possible to safely remove elements from a vector it is unintuitive and error-prone. The old code caused segmentation faults by iterating out of the vector's allocated memory. In addition, it fails to achieve its goal of clearing the vector completely. We resolve this bug by using the std::vector::clear method which is safer and easier to understand.