From 52e477b41f137ff2a0775722dcbaaa64fa5f3bc3 Mon Sep 17 00:00:00 2001 From: Diva Canto Date: Fri, 25 Sep 2009 06:02:41 -0700 Subject: Better guards on RegisterRegion in GridService. Added serverPort to the fields that get stored (I think this is the UDP port). --- OpenSim/Services/Interfaces/IGridService.cs | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) (limited to 'OpenSim/Services/Interfaces/IGridService.cs') diff --git a/OpenSim/Services/Interfaces/IGridService.cs b/OpenSim/Services/Interfaces/IGridService.cs index 513b1b0..ce432ab 100644 --- a/OpenSim/Services/Interfaces/IGridService.cs +++ b/OpenSim/Services/Interfaces/IGridService.cs @@ -267,6 +267,7 @@ namespace OpenSim.Services.Interfaces kvp["serverIP"] = ExternalHostName; //ExternalEndPoint.Address.ToString(); kvp["serverHttpPort"] = HttpPort.ToString(); kvp["serverURI"] = ServerURI; + kvp["serverPort"] = InternalEndPoint.Port.ToString(); return kvp; } @@ -287,7 +288,7 @@ namespace OpenSim.Services.Interfaces if (kvp.ContainsKey("serverIP")) { - int port = 0; + //int port = 0; //Int32.TryParse((string)kvp["serverPort"], out port); //IPEndPoint ep = new IPEndPoint(IPAddress.Parse((string)kvp["serverIP"]), port); ExternalHostName = (string)kvp["serverIP"]; @@ -295,6 +296,13 @@ namespace OpenSim.Services.Interfaces else ExternalHostName = "127.0.0.1"; + if (kvp.ContainsKey("serverPort")) + { + Int32 port = 0; + Int32.TryParse((string)kvp["serverPort"], out port); + InternalEndPoint = new IPEndPoint(IPAddress.Parse("0.0.0.0"), port); + } + if (kvp.ContainsKey("serverHttpPort")) { UInt32 port = 0; -- cgit v1.1