Fix adding a scalar to the end of a list

This commit is contained in:
Melanie Thielker
2015-08-19 01:04:10 +02:00
parent 05d72f77ff
commit c61aee12d4

View File

@@ -714,8 +714,11 @@ namespace OpenSim.Region.ScriptEngine.Shared
private void ExtendAndAdd(object o)
{
Array.Resize(ref m_data, Length + 1);
m_data.SetValue(o, Length - 1);
object[] tmp;
tmp = new object[m_data.Length + 1];
m_data.CopyTo(tmp, 0);
tmp.SetValue(o, tmp.Length - 1);
m_data = tmp;
}
public static list operator +(list a, LSLString s)