[ox/fs] Fix PathIterator::valid to check iterator against max size

(synced from 00339ee4fd)
This commit is contained in:
2018-07-30 21:01:07 -05:00
parent 72979b7545
commit f9e14193d0
+1 -1
View File
@@ -178,7 +178,7 @@ bool PathIterator::hasNext() const {
}
bool PathIterator::valid() const {
return m_path[m_iterator] != 0;
return m_iterator < m_maxSize && m_path[m_iterator] != 0;
}
PathIterator PathIterator::operator+(int i) const {