Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Exception when using SortedDirectoryIterator #1926

Closed
pcipriano opened this issue Oct 6, 2017 · 0 comments
Closed

Exception when using SortedDirectoryIterator #1926

pcipriano opened this issue Oct 6, 2017 · 0 comments
Assignees
Milestone

Comments

@pcipriano
Copy link

void SortedDirectoryIterator::scan()

The function above suffers of the same problem mentioned in #236. I fixed the problem by wrapping the isDirectory call in a try/catch block like this:

bool isDir = false;
try
{
    isDir = (*this)->isDirectory();
}
catch (...)
{
}

if (isDir)
    _directories.push_back(_path.toString());
else
    _files.push_back(_path.toString());        

DirectoryIterator::operator++();
@aleks-f aleks-f self-assigned this Oct 6, 2017
@aleks-f aleks-f added this to the Release 2.0.0 milestone Oct 6, 2017
@aleks-f aleks-f added the bug label Oct 6, 2017
@aleks-f aleks-f modified the milestones: Release 2.0.0, Release 1.8.0 Oct 6, 2017
@aleks-f aleks-f added the fixed label Oct 6, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants