mirror of
https://git.salome-platform.org/gitpub/modules/smesh.git
synced 2024-11-15 10:08:34 +05:00
Fix for SIGSEGV on Mandriva2008 in optimize mode only
==21300== Invalid read of size 4 ==21300== at 0x1445EA23: StdMeshers_Penta_3D::MakeVolumeMesh() (StdMeshers_Penta_3D.cxx:681) while (aItNodes->more()) { It seems to be an error of optimization, aItNodes.px becomes invalid before aItNodes->more() returns false but after the loop code is performed for the last time.
This commit is contained in:
parent
23a1a900c3
commit
0bce8612a5
@ -676,22 +676,16 @@ void StdMeshers_Penta_3D::MakeVolumeMesh()
|
||||
if ( aN.size() < nbFaceNodes * 2 )
|
||||
aN.resize( nbFaceNodes * 2 );
|
||||
//
|
||||
k=0;
|
||||
aItNodes=pE0->nodesIterator();
|
||||
while (aItNodes->more()) {
|
||||
//const SMDS_MeshElement* pNode = aItNodes->next();
|
||||
const SMDS_MeshNode* pNode =
|
||||
static_cast<const SMDS_MeshNode*> (aItNodes->next());
|
||||
if(myTool->IsMedium(pNode))
|
||||
continue;
|
||||
for ( k=0; k<nbFaceNodes; ++k ) {
|
||||
const SMDS_MeshNode* pNode = pE0->GetNode(k);
|
||||
// if(myTool->IsMedium(pNode))
|
||||
// continue;
|
||||
aID0 = pNode->GetID();
|
||||
aJ[k] = GetIndexOnLayer(aID0);
|
||||
if (!myErrorStatus->IsOK()) {
|
||||
MESSAGE("StdMeshers_Penta_3D::MakeVolumeMesh");
|
||||
return;
|
||||
}
|
||||
//
|
||||
++k;
|
||||
}
|
||||
//
|
||||
bool forward = true;
|
||||
|
Loading…
Reference in New Issue
Block a user