diff options
Diffstat (limited to 'indra/llui/lltextparser.cpp')
-rw-r--r-- | indra/llui/lltextparser.cpp | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/indra/llui/lltextparser.cpp b/indra/llui/lltextparser.cpp index 8e2bfe6ac2..6a867fc759 100644 --- a/indra/llui/lltextparser.cpp +++ b/indra/llui/lltextparser.cpp @@ -73,11 +73,11 @@ S32 LLTextParser::findPattern(const std::string &text, LLSD highlight) found = (! ltext.find(pattern) ? 0 : std::string::npos); break; case ENDS_WITH: - S32 pos = ltext.rfind(pattern); + auto pos = ltext.rfind(pattern); if (pos >= 0 && (ltext.length()-pattern.length()==pos)) found = pos; break; } - return found; + return static_cast<S32>(found); } LLSD LLTextParser::parsePartialLineHighlights(const std::string &text, const LLColor4 &color, EHighlightPosition part, S32 index) @@ -99,8 +99,8 @@ LLSD LLTextParser::parsePartialLineHighlights(const std::string &text, const LLC S32 start = findPattern(text,mHighlights[i]); if (start >= 0 ) { - S32 end = std::string(mHighlights[i]["pattern"]).length(); - S32 len = text.length(); + auto end = std::string(mHighlights[i]["pattern"]).length(); + auto len = text.length(); EHighlightPosition newpart; if (start==0) { |