diff --git a/Mesh/meshGRegionExtruded.cpp b/Mesh/meshGRegionExtruded.cpp index 110b0696f3e635f89529628d698ca244c04dc5ea..9c80ec162cfbb8f99d8bb0878fd5e60877a83d71 100644 --- a/Mesh/meshGRegionExtruded.cpp +++ b/Mesh/meshGRegionExtruded.cpp @@ -488,9 +488,13 @@ int SubdivideExtrudedMesh(GModel *m) j = swap; } while(swap); - // delete "recombined" volume elements and create tetrahedra instead + // delete volume elements and create tetrahedra instead for(unsigned int i = 0; i < regions.size(); i++){ GRegion *gr = regions[i]; + + for(unsigned int i = 0; i < gr->tetrahedra.size(); i++) + delete gr->tetrahedra[i]; + gr->tetrahedra.clear(); for(unsigned int i = 0; i < gr->hexahedra.size(); i++) delete gr->hexahedra[i]; gr->hexahedra.clear();