From 6de0067382d434ce42850a4becbedfb81c96b9e3 Mon Sep 17 00:00:00 2001 From: skl Date: Wed, 16 Sep 2009 06:13:07 +0000 Subject: [PATCH] Changed for 0019296 (Evaluation). --- src/StdMeshers/StdMeshers_MEFISTO_2D.cxx | 15 +++++++++++---- 1 file changed, 11 insertions(+), 4 deletions(-) diff --git a/src/StdMeshers/StdMeshers_MEFISTO_2D.cxx b/src/StdMeshers/StdMeshers_MEFISTO_2D.cxx index 6a84ee7b8..ca1ef9e11 100644 --- a/src/StdMeshers/StdMeshers_MEFISTO_2D.cxx +++ b/src/StdMeshers/StdMeshers_MEFISTO_2D.cxx @@ -332,10 +332,17 @@ bool StdMeshers_MEFISTO_2D::Evaluate(SMESH_Mesh & aMesh, P1 = P2; } } - if ( NbSeg > 0 ) - aLen = aLen/NbSeg; // middle length - else - aLen = Precision::Infinite(); + if(NbSeg<1) { + std::vector aResVec(SMDSEntity_Last); + for(int i=SMDSEntity_Node; iGetComputeError(); + smError.reset( new SMESH_ComputeError(COMPERR_ALGO_FAILED, + "Submesh can not be evaluated",this)); + return false; + } + aLen = aLen/NbSeg; // middle length _edgeLength = Precision::Infinite(); double tmpLength = Min( _edgeLength, aLen ); -- 2.39.2