Salome HOME
projects
/
modules
/
smesh.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Merge 'master' branch into 'V9_dev' branch.
[modules/smesh.git]
/
src
/
SMDS
/
SMDS_MeshIDFactory.cxx
diff --git
a/src/SMDS/SMDS_MeshIDFactory.cxx
b/src/SMDS/SMDS_MeshIDFactory.cxx
index 74e5e401df8fe78adc9c8fc3cef9dcd840ae3439..ea74aa5769c265c08db96911ad816ab0563c6bd5 100644
(file)
--- a/
src/SMDS/SMDS_MeshIDFactory.cxx
+++ b/
src/SMDS/SMDS_MeshIDFactory.cxx
@@
-20,7
+20,7
@@
// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
//
// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
//
-// SMESH SMDS : implementaion of Salome mesh data structure
+// SMESH SMDS : implementa
t
ion of Salome mesh data structure
// File : SMDS_MeshIDFactory.cxx
// Author : Jean-Michel BOULCOURT
// Module : SMESH
// File : SMDS_MeshIDFactory.cxx
// Author : Jean-Michel BOULCOURT
// Module : SMESH
@@
-50,8
+50,8
@@
int SMDS_MeshIDFactory::GetFreeID()
else
{
set<int>::iterator i = myPoolOfID.begin();
else
{
set<int>::iterator i = myPoolOfID.begin();
- newid = *i;
//myPoolOfID.top();
- myPoolOfID.erase( i );
//myPoolOfID.pop();
+ newid = *i;
+ myPoolOfID.erase( i );
}
return newid;
}
}
return newid;
}
@@
-77,11
+77,13
@@
void SMDS_MeshIDFactory::ReleaseID(int ID, int vtkId)
while ( i != myPoolOfID.begin() && myMaxID == *i ) {
--myMaxID; --i;
}
while ( i != myPoolOfID.begin() && myMaxID == *i ) {
--myMaxID; --i;
}
- if ( myMaxID == *i )
+ if ( myMaxID == *i )
{
--myMaxID; // begin of myPoolOfID reached
--myMaxID; // begin of myPoolOfID reached
- else
- ++i;
- myPoolOfID.erase( i, myPoolOfID.end() );
+ myPoolOfID.clear();
+ }
+ else if ( myMaxID < ID-1 ) {
+ myPoolOfID.erase( ++i, myPoolOfID.end() );
+ }
}
}
}
}
}
}