diff options
| author | andreykproductengine <akleshchev@productengine.com> | 2016-06-27 17:21:14 +0300 |
|---|---|---|
| committer | andreykproductengine <akleshchev@productengine.com> | 2016-06-27 17:21:14 +0300 |
| commit | 9ce396442f5e958cc3f01327812f4fbc08e4e952 (patch) | |
| tree | 4e864093685c18e94f9994faa7cd16cf41d93eae /indra/newview/llchatbar.cpp | |
| parent | 9e985120feb848409e99a27d5c21c12d1b029814 (diff) | |
MAINT-6518 allow negative numbered chat channels
Diffstat (limited to 'indra/newview/llchatbar.cpp')
| -rw-r--r-- | indra/newview/llchatbar.cpp | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/indra/newview/llchatbar.cpp b/indra/newview/llchatbar.cpp index 00fa6dd979..54c6c985d6 100644 --- a/indra/newview/llchatbar.cpp +++ b/indra/newview/llchatbar.cpp @@ -311,7 +311,8 @@ LLWString LLChatBar::stripChannelNumber(const LLWString &mesg, S32* channel) } else if (mesg[0] == '/' && mesg[1] - && LLStringOps::isDigit(mesg[1])) + && (LLStringOps::isDigit(mesg[1]) + || (mesg[1] == '-' && mesg[2] && LLStringOps::isDigit(mesg[2])))) { // This a special "/20" speak on a channel S32 pos = 0; @@ -325,7 +326,7 @@ LLWString LLChatBar::stripChannelNumber(const LLWString &mesg, S32* channel) channel_string.push_back(c); pos++; } - while(c && pos < 64 && LLStringOps::isDigit(c)); + while(c && pos < 64 && (LLStringOps::isDigit(c) || (pos == 1 && c == '-'))); // Move the pointer forward to the first non-whitespace char // Check isspace before looping, so we can handle "/33foo" |
