diff --git a/src/osg/PagedLOD.cpp b/src/osg/PagedLOD.cpp index 3c15902fd..8fde29a86 100644 --- a/src/osg/PagedLOD.cpp +++ b/src/osg/PagedLOD.cpp @@ -205,14 +205,11 @@ bool PagedLOD::removeChild( Node *child ) void PagedLOD::removeExpiredChildren(double expiryTime,NodeList& removedChildren) { - for(unsigned int i=_children.size();i>_numChildrenThatCannotBeExpired;) + if (_children.size()>_numChildrenThatCannotBeExpired) { - --i; - if (!_perRangeDataList[i]._filename.empty() && _perRangeDataList[i]._timeStamp