summaryrefslogtreecommitdiff
path: root/indra/llfilesystem/lldiriterator.cpp
diff options
context:
space:
mode:
authorJonathan "Geenz" Goodman <geenz@lindenlab.com>2026-09-22 17:35:03 -0400
committerGitHub <noreply@github.com>2026-09-22 17:35:03 -0400
commitf3fba78d9185a2385cc6c5226b7a87fddff826dd (patch)
tree4d04ad5876c69ec0b3203dec69c711161fa7f934 /indra/llfilesystem/lldiriterator.cpp
parentcc5d3dd3cd653971fff16cf2bc1d380edd5ea7f2 (diff)
parent125dfba5f94191fc99d1c511d190d6a9f2d9d2f1 (diff)
Merge pull request #6357 from secondlife/pepper/chat-merge-26.5
Merge `release/26.5` into `project/chat-modernization`
Diffstat (limited to 'indra/llfilesystem/lldiriterator.cpp')
-rw-r--r--indra/llfilesystem/lldiriterator.cpp21
1 files changed, 14 insertions, 7 deletions
diff --git a/indra/llfilesystem/lldiriterator.cpp b/indra/llfilesystem/lldiriterator.cpp
index 60b55c7bf3..ca00d25fb7 100644
--- a/indra/llfilesystem/lldiriterator.cpp
+++ b/indra/llfilesystem/lldiriterator.cpp
@@ -126,20 +126,27 @@ bool LLDirIterator::Impl::next(std::string &fname)
{
while (mIter != end_itr && !found)
{
- boost::smatch match;
- std::string name = mIter->path().filename().string();
- found = ll_regex_match(name, match, mFilterExp);
- if (found)
+ try
{
- fname = name;
+ boost::smatch match;
+ std::string name = fsyspath(mIter->path().filename()).string();
+ found = ll_regex_match(name, match, mFilterExp);
+ if (found)
+ {
+ fname = name;
+ }
+ }
+ catch (const std::system_error& e)
+ {
+ LL_WARNS() << "Exception accessing directory entry: " << e.what() << LL_ENDL;
}
++mIter;
}
}
- catch (const fs::filesystem_error& e)
+ catch (const std::system_error& e)
{
- LL_WARNS() << e.what() << LL_ENDL;
+ LL_WARNS() << "Exception iterating directory: " << e.what() << LL_ENDL;
}
return found;