tpaviot/oce — Issue #256: segfault when cutting and refining two circles
Author: hmeyer
Created: 2012-02-26 09:18:49+00:00
State: open

The following code results in SegFault.
compile like:
g++ test.cpp -o test -I /usr/include/oce/ -lTKBRep -lTKernel -lTKMath -lTKG2d -lTKPrim -lTKTopAlgo -lTKBO
```
#include
#include
#include
#include

int main(int argc, char **argv){
TopoDS_Shape c1,c2;
c1 = BRepBuilderAPI_MakeEdge2d( Geom2d_Circle( gp::OX2d(), 1 ).Circ2d() ).Shape();
c2 = BRepBuilderAPI_MakeEdge2d( Geom2d_Circle( gp::OX2d(), 2 ).Circ2d() ).Shape();
BRepAlgoAPI_Cut cut(c1,c2);
cut.RefineEdges();
return 1;
}
```