]> SALOME platform Git repositories - modules/smesh.git/commitdiff
Salome HOME
fix TSplitMethod for OS Windows
authorViktor Uzlov <viktor.uzlov@opencascade.com>
Wed, 31 Mar 2021 09:29:04 +0000 (12:29 +0300)
committerViktor Uzlov <viktor.uzlov@opencascade.com>
Wed, 31 Mar 2021 09:29:04 +0000 (12:29 +0300)
src/SMESH/SMESH_MeshEditor.cxx

index 8a872c724a31cc12e95979eecd8275a20282378d..966e3e4aa7a183f85bf7e9a799afe38cb0be3c26 100644 (file)
@@ -1808,6 +1808,17 @@ namespace
     TSplitMethod( int nbTet=0, const int* conn=0, bool addNode=false)
       : _nbSplits(nbTet), _nbCorners(4), _connectivity(conn), _baryNode(addNode), _ownConn(false) {}
     ~TSplitMethod() { if ( _ownConn ) delete [] _connectivity; _connectivity = 0; }
+       TSplitMethod(TSplitMethod &splitMethod)
+               : _nbSplits(splitMethod._nbSplits),
+               _nbCorners(splitMethod._nbCorners),
+               _baryNode(splitMethod._baryNode),
+               _ownConn(splitMethod._ownConn),
+               _faceBaryNode(splitMethod._faceBaryNode)
+       {
+               _connectivity = splitMethod._connectivity;
+               splitMethod._connectivity = nullptr;
+               splitMethod._ownConn = false;
+       }
     bool hasFacet( const TTriangleFacet& facet ) const
     {
       if ( _nbCorners == 4 )
@@ -2265,7 +2276,7 @@ void SMESH_MeshEditor::SplitVolumes (const TFacetOfElem & theElems,
     TSplitMethod splitMethod = ( facetToSplit < 0  ?
                                  getTetraSplitMethod( volTool, theMethodFlags ) :
                                  getPrismSplitMethod( volTool, theMethodFlags, facetToSplit ));
-    if ( splitMethod._nbSplits < 1 ) continue;
+       if ( splitMethod._nbSplits < 1 ) continue;
 
     // find submesh to add new tetras to
     if ( !subMesh || !subMesh->Contains( elem ))