From: apo Date: Wed, 26 Jan 2005 06:49:06 +0000 (+0000) Subject: Improve checking of validity of mesh elements connectivity X-Git-Tag: V2_2_0b2~27 X-Git-Url: http://git.salome-platform.org/gitweb/?p=modules%2Fsmesh.git;a=commitdiff_plain;h=efdf984e40ba00513859a612721ebe25e711b851 Improve checking of validity of mesh elements connectivity --- diff --git a/src/DriverMED/DriverMED_R_SMESHDS_Mesh.cxx b/src/DriverMED/DriverMED_R_SMESHDS_Mesh.cxx index fe5100d4f..1433e3208 100644 --- a/src/DriverMED/DriverMED_R_SMESHDS_Mesh.cxx +++ b/src/DriverMED/DriverMED_R_SMESHDS_Mesh.cxx @@ -309,21 +309,35 @@ Driver_Mesh::Status DriverMED_R_SMESHDS_Mesh::Perform() break; } vector aNodeIds(aNbNodes); + bool anIsValidConnect = false; + + try{ #ifdef _EDF_NODE_IDS_ - if(anIsNodeNum) { - for(int i = 0; i < aNbNodes; i++){ - aNodeIds[i] = aNodeInfo->GetElemNum(aCellInfo->GetConn(iElem,i)-1); + if(anIsNodeNum) { + for(int i = 0; i < aNbNodes; i++){ + aNodeIds[i] = aNodeInfo->GetElemNum(aCellInfo->GetConn(iElem,i)-1); + } + }else{ + for(int i = 0; i < aNbNodes; i++){ + aNodeIds[i] = aCellInfo->GetConn(iElem,i); + } } - }else{ +#else for(int i = 0; i < aNbNodes; i++){ aNodeIds[i] = aCellInfo->GetConn(iElem,i); } - } -#else - for(int i = 0; i < aNbNodes; i++){ - aNodeIds[i] = aCellInfo->GetConn(iElem,i); - } #endif + anIsValidConnect = true; + }catch(const std::exception& exc){ + //INFOS("Follow exception was cought:\n\t"<