* Fix mantis 975 - prim text > 255 chars

0.6.0-stable
Justin Clarke Casey 2008-04-15 22:56:18 +00:00
parent e65b6f4dcd
commit 550ed7b9ec
1 changed files with 8 additions and 0 deletions

View File

@ -1985,7 +1985,15 @@ namespace OpenSim.Region.ClientStack
outPacket.ObjectData[0].ID = localID;
outPacket.ObjectData[0].FullID = objectID;
outPacket.ObjectData[0].OwnerID = ownerID;
// Anything more than 255 will cause libsecondlife to barf
if (text.Length > 255)
{
text = text.Remove(255);
}
outPacket.ObjectData[0].Text = Helpers.StringToField(text);
outPacket.ObjectData[0].TextColor[0] = color[0];
outPacket.ObjectData[0].TextColor[1] = color[1];
outPacket.ObjectData[0].TextColor[2] = color[2];