mirror of
https://github.com/opensim/opensim.git
synced 2026-08-04 16:22:50 +08:00
Fix issue 1582. The maximum allowable length for a string passed to SimChat is 1500. If it was longer than 1500, it was being truncated to 1501 characters. This caused an exception and prevented the errors from reaching the console and the user in-world.
This commit is contained in:
@@ -152,7 +152,7 @@ namespace OpenSim.Region.ScriptEngine.DotNetEngine
|
||||
// DISPLAY ERROR INWORLD
|
||||
string text = "Error compiling script:\r\n" + e.Message.ToString();
|
||||
if (text.Length > 1500)
|
||||
text = text.Substring(0, 1500);
|
||||
text = text.Substring(0, 1499); // 0-1499 is 1500 characters
|
||||
World.SimChat(Helpers.StringToField(text), ChatTypeEnum.DebugChannel, 2147483647,
|
||||
m_host.AbsolutePosition, m_host.Name, m_host.UUID, false);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user