mirror of
https://github.com/opensim/opensim.git
synced 2026-08-07 17:55:48 +08:00
* Added patch for SYSTEMIP handling when an IPv6 address is the primary address of the system. (as is the case on Windows Vista)
This commit is contained in:
@@ -177,7 +177,16 @@ namespace OpenSim.Framework.Types
|
||||
System.Net.IPAddress[] ips = System.Net.Dns.GetHostAddresses(localhostname);
|
||||
try
|
||||
{
|
||||
this.CommsIPListenAddr = ips[0].ToString();
|
||||
this.CommsIPListenAddr = "0.0.0.0"; // Incase a IPv4 address isnt found
|
||||
|
||||
foreach (System.Net.IPAddress ip in ips)
|
||||
{
|
||||
if (ip.AddressFamily.ToString() == System.Net.Sockets.ProtocolFamily.InterNetwork.ToString())
|
||||
{
|
||||
this.CommsIPListenAddr = ip.ToString();
|
||||
break;
|
||||
}
|
||||
}
|
||||
}
|
||||
catch (Exception e)
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user