Merge branch 'master' into presence-refactor

This brings presence-refactor up to master again
This commit is contained in:
Melanie
2010-02-22 03:00:59 +00:00
39 changed files with 405 additions and 5161 deletions

View File

@@ -69,7 +69,7 @@ namespace OpenSim.Framework
private static UUID HAIR_ASSET = new UUID("d342e6c0-b9d2-11dc-95ff-0800200c9a66");
private static UUID HAIR_ITEM = new UUID("d342e6c1-b9d2-11dc-95ff-0800200c9a66");
public readonly static int VISUALPARAM_COUNT = 218;
public readonly static int VISUALPARAM_COUNT = 218;
protected UUID m_owner;
@@ -361,7 +361,7 @@ namespace OpenSim.Framework
// This sets Visual Params with *less* weirder values then default. Instead of a ugly alien, it looks like a fat scientist
SetDefaultParams(m_visualparams);
SetDefaultWearables();
m_texture = GetDefaultTexture();
m_texture = GetDefaultTexture();
}
public AvatarAppearance(UUID avatarID, AvatarWearable[] wearables, byte[] visualParams)

View File

@@ -38,7 +38,7 @@ namespace OpenSim.Framework.Console
{
/// <summary>
/// A console that uses cursor control and color
/// </summary>
/// </summary>
public class LocalConsole : CommandConsole
{
// private static readonly ILog m_log = LogManager.GetLogger(MethodBase.GetCurrentMethod().DeclaringType);
@@ -100,8 +100,8 @@ namespace OpenSim.Framework.Console
private int SetCursorTop(int top)
{
// From at least mono 2.4.2.3, window resizing can give mono an invalid row and column values. If we try
// to set a cursor row position with a currently invalid column, mono will throw an exception.
// Therefore, we need to make sure that the column position is valid first.
// to set a cursor row position with a currently invalid column, mono will throw an exception.
// Therefore, we need to make sure that the column position is valid first.
int left = System.Console.CursorLeft;
if (left < 0)
@@ -129,12 +129,12 @@ namespace OpenSim.Framework.Console
/// </param>
/// <returns>
/// The new cursor column.
/// </returns>
/// </returns>
private int SetCursorLeft(int left)
{
// From at least mono 2.4.2.3, window resizing can give mono an invalid row and column values. If we try
// to set a cursor column position with a currently invalid row, mono will throw an exception.
// Therefore, we need to make sure that the row position is valid first.
// to set a cursor column position with a currently invalid row, mono will throw an exception.
// Therefore, we need to make sure that the row position is valid first.
int top = System.Console.CursorTop;
if (top < 0)
@@ -183,7 +183,7 @@ namespace OpenSim.Framework.Console
System.Console.Write("{0}", prompt);
SetCursorTop(new_y);
SetCursorLeft(new_x);
SetCursorLeft(new_x);
}
}

View File

@@ -302,9 +302,9 @@ namespace OpenSim.Framework.Console
if (!UUID.TryParse(post["ID"].ToString(), out id))
return reply;
lock(m_Connections)
lock (m_Connections)
{
if(!m_Connections.ContainsKey(id))
if (!m_Connections.ContainsKey(id))
return reply;
}

View File

@@ -483,7 +483,6 @@ namespace OpenSim.Framework
else
m_externalHostName = externalName;
m_regionType = config.GetString("RegionType", String.Empty);
// Prim stuff

View File

@@ -589,11 +589,17 @@ namespace OpenSim.Framework
public static IPAddress GetLocalHost()
{
string dnsAddress = "localhost";
IPAddress[] iplist = GetLocalHosts();
IPAddress[] hosts = Dns.GetHostEntry(dnsAddress).AddressList;
if (iplist.Length == 0) // No accessible external interfaces
{
IPAddress[] loopback = Dns.GetHostAddresses("localhost");
IPAddress localhost = loopback[0];
foreach (IPAddress host in hosts)
return localhost;
}
foreach (IPAddress host in iplist)
{
if (!IPAddress.IsLoopback(host) && host.AddressFamily == AddressFamily.InterNetwork)
{
@@ -601,15 +607,15 @@ namespace OpenSim.Framework
}
}
if (hosts.Length > 0)
if (iplist.Length > 0)
{
foreach (IPAddress host in hosts)
foreach (IPAddress host in iplist)
{
if (host.AddressFamily == AddressFamily.InterNetwork)
return host;
}
// Well all else failed...
return hosts[0];
return iplist[0];
}
return null;