summaryrefslogtreecommitdiff
path: root/indra
diff options
context:
space:
mode:
authorMnikolenko ProductEngine <mnikolenko@productengine.com>2014-01-13 12:08:00 +0200
committerMnikolenko ProductEngine <mnikolenko@productengine.com>2014-01-13 12:08:00 +0200
commitc934710f766223e56c892b3ab7acd02321a8b47e (patch)
treec1c3fe7a61af147f98cd2896916e645976b82fe8 /indra
parenta1e986e2b0fefa2b8ecc995c5449c0a1b8556675 (diff)
MAINT-3621 FIXED Set name to "Unnamed" if object's name consists of whitespaces.
Diffstat (limited to 'indra')
-rwxr-xr-xindra/newview/llviewermessage.cpp6
1 files changed, 6 insertions, 0 deletions
diff --git a/indra/newview/llviewermessage.cpp b/indra/newview/llviewermessage.cpp
index dd744be4eb..c532134763 100755
--- a/indra/newview/llviewermessage.cpp
+++ b/indra/newview/llviewermessage.cpp
@@ -3521,6 +3521,12 @@ void process_chat_from_simulator(LLMessageSystem *msg, void **user_data)
}
else
{
+ // make sure that we don't have an empty or all-whitespace name
+ LLStringUtil::trim(from_name);
+ if (from_name.empty())
+ {
+ from_name = LLTrans::getString("Unnamed");
+ }
chat.mFromName = from_name;
}