From: skl Date: Fri, 3 Aug 2007 06:06:22 +0000 (+0000) Subject: Corrected for bug IPAL12571. X-Git-Tag: T32x_16Aug2007_16h00m~8 X-Git-Url: http://git.salome-platform.org/gitweb/?a=commitdiff_plain;h=b087bb056bd1db1607dadfc3c7113fa781136fb0;p=modules%2Fsmesh.git Corrected for bug IPAL12571. --- diff --git a/src/SMESH/SMESH_Pattern.cxx b/src/SMESH/SMESH_Pattern.cxx index f9ad5a52a..5054f5549 100644 --- a/src/SMESH/SMESH_Pattern.cxx +++ b/src/SMESH/SMESH_Pattern.cxx @@ -4086,7 +4086,7 @@ void SMESH_Pattern::createElements(SMESH_Mesh* theMes SMESH_subMesh * subMesh; if ( !myShape.IsNull() ) { - subMesh = theMesh->GetSubMeshContaining( myShape ); + subMesh = theMesh->GetSubMesh( myShape ); if ( subMesh ) subMesh->ComputeStateEngine( SMESH_subMesh::CHECK_COMPUTE_STATE ); } diff --git a/src/StdMeshers/StdMeshers_Hexa_3D.cxx b/src/StdMeshers/StdMeshers_Hexa_3D.cxx index 129c270ee..c5a57cdba 100644 --- a/src/StdMeshers/StdMeshers_Hexa_3D.cxx +++ b/src/StdMeshers/StdMeshers_Hexa_3D.cxx @@ -254,6 +254,9 @@ bool StdMeshers_Hexa_3D::Compute(SMESH_Mesh & aMesh, ASSERT(quadAlgo); try { aQuads[i] = quadAlgo->CheckAnd2Dcompute(aMesh, aFace, _quadraticMesh); + if(!aQuads[i]) { + return error( quadAlgo->GetComputeError()); + } } catch(SALOME_Exception & S_ex) { return ClearAndReturn( aQuads, error(COMPERR_SLM_EXCEPTION,TComm(S_ex.what()) << diff --git a/src/StdMeshers/StdMeshers_Quadrangle_2D.cxx b/src/StdMeshers/StdMeshers_Quadrangle_2D.cxx index 6852c9edb..c880c9ce1 100644 --- a/src/StdMeshers/StdMeshers_Quadrangle_2D.cxx +++ b/src/StdMeshers/StdMeshers_Quadrangle_2D.cxx @@ -651,7 +651,12 @@ FaceQuadStruct *StdMeshers_Quadrangle_2D::CheckAnd2Dcompute if(!quad) return 0; // set normalized grid on unit square in parametric domain - SetNormalizedGrid(aMesh, aShape, quad); + bool stat = SetNormalizedGrid(aMesh, aShape, quad); + if(!stat) { + if(!quad) + delete quad; + quad = 0; + } return quad; } @@ -732,7 +737,8 @@ bool StdMeshers_Quadrangle_2D::SetNormalizedGrid (SMESH_Mesh & aMesh, const vector& uv_e3 = GetUVPtStructIn( quad, 3, nbvertic - 1 ); if ( uv_e0.empty() || uv_e1.empty() || uv_e2.empty() || uv_e3.empty() ) - return error( "Can't find nodes on sides"); + //return error( "Can't find nodes on sides"); + return error( COMPERR_BAD_INPUT_MESH ); // nodes Id on "in" edges if (! quad->isEdgeOut[0]) {