From a490b34b6e584119312bd1b9ee8c30c4b9f02c62 Mon Sep 17 00:00:00 2001 From: Justin Clark-Casey (justincc) Date: Fri, 22 Oct 2010 23:34:44 +0100 Subject: Revert "* more url / hg cleanup" This reverts commit 58f75fa19d9aea18283ecdbd44559efb81781c9d. --- OpenSim/Services/GridService/HypergridLinker.cs | 18 ++++++++++++++---- 1 file changed, 14 insertions(+), 4 deletions(-) (limited to 'OpenSim/Services/GridService') diff --git a/OpenSim/Services/GridService/HypergridLinker.cs b/OpenSim/Services/GridService/HypergridLinker.cs index 74e864b..11df7e0 100644 --- a/OpenSim/Services/GridService/HypergridLinker.cs +++ b/OpenSim/Services/GridService/HypergridLinker.cs @@ -198,8 +198,21 @@ namespace OpenSim.Services.GridService return null; } + + public bool TryCreateLink(UUID scopeID, int xloc, int yloc, string externalRegionName, string serverURI, out GridRegion regInfo, out string reason) + { + return TryCreateLink(scopeID, xloc, yloc, externalRegionName, 0, null, serverURI, out regInfo, out reason); + } + public bool TryCreateLink(UUID scopeID, int xloc, int yloc, string externalRegionName, uint externalPort, string externalHostName, out GridRegion regInfo, out string reason) { + return TryCreateLink(scopeID, xloc, yloc, externalRegionName, externalPort, externalHostName, null, out regInfo, out reason); + } + + // From the command line and the 2 above + public bool TryCreateLink(UUID scopeID, int xloc, int yloc, + string externalRegionName, uint externalPort, string externalHostName, string serverURI, out GridRegion regInfo, out string reason) + { m_log.DebugFormat("[HYPERGRID LINKER]: Link to {0}:{1}:{2}, in {3}-{4}", externalHostName, externalPort, externalRegionName, xloc, yloc); reason = string.Empty; @@ -213,11 +226,8 @@ namespace OpenSim.Services.GridService // Big HACK for Simian Grid !!! // We need to clean up all URLs used in OpenSim !!! - if (externalHostName.Contains("/")) { + if (externalHostName.Contains("/")) regInfo.ServerURI = externalHostName; - } else { - regInfo.ServerURI = "http://" + externalHostName + ":" + externalPort.ToString(); - } try { -- cgit v1.1