summaryrefslogtreecommitdiff
path: root/indra/llfilesystem
diff options
context:
space:
mode:
Diffstat (limited to 'indra/llfilesystem')
-rw-r--r--indra/llfilesystem/lldir.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/indra/llfilesystem/lldir.cpp b/indra/llfilesystem/lldir.cpp
index 483ef0fd02..85ae6d4d1d 100644
--- a/indra/llfilesystem/lldir.cpp
+++ b/indra/llfilesystem/lldir.cpp
@@ -881,10 +881,10 @@ std::string LLDir::getScrubbedFileName(const std::string uncleanFileName)
std::string name(uncleanFileName);
const std::string illegalChars(getForbiddenFileChars());
// replace any illegal file chars with and underscore '_'
- for( unsigned int i = 0; i < illegalChars.length(); i++ )
+ for( const char &ch : illegalChars)
{
std::string::size_type j = -1;
- while((j = name.find(illegalChars[i])) > std::string::npos)
+ while((j = name.find(ch)) != std::string::npos)
{
name[j] = '_';
}