Remove the null checks altogether

avinationmerge
Melanie Thielker 2010-07-20 00:55:31 +02:00
parent 54da64acac
commit 191bee2ed0
2 changed files with 5 additions and 20 deletions

View File

@ -5027,15 +5027,8 @@ namespace OpenSim.Region.ScriptEngine.Shared.Api
{
m_host.AddScriptLPS(1);
if (src == null)
{
return 0;
}
else
{
return src.Length;
}
}
public LSL_Integer llList2Integer(LSL_List src, int index)
{

View File

@ -613,24 +613,16 @@ namespace OpenSim.Region.ScriptEngine.Shared
public static bool operator ==(list a, list b)
{
int la = -1;
int lb = -1;
if (a != null)
la = a.Length;
if (b != null)
lb = b.Length;
int la = a.Length;
int lb = b.Length;
return la == lb;
}
public static bool operator !=(list a, list b)
{
int la = -1;
int lb = -1;
if (a != null)
la = a.Length;
if (b != null)
lb = b.Length;
int la = a.Length;
int lb = b.Length;
return la != lb;
}