aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/OpenSim/Services
diff options
context:
space:
mode:
Diffstat (limited to 'OpenSim/Services')
-rw-r--r--OpenSim/Services/GridService/HypergridLinker.cs10
1 files changed, 10 insertions, 0 deletions
diff --git a/OpenSim/Services/GridService/HypergridLinker.cs b/OpenSim/Services/GridService/HypergridLinker.cs
index 12ea453..585d088 100644
--- a/OpenSim/Services/GridService/HypergridLinker.cs
+++ b/OpenSim/Services/GridService/HypergridLinker.cs
@@ -65,6 +65,7 @@ namespace OpenSim.Services.GridService
65 protected UUID m_ScopeID = UUID.Zero; 65 protected UUID m_ScopeID = UUID.Zero;
66 protected bool m_Check4096 = true; 66 protected bool m_Check4096 = true;
67 protected string m_MapTileDirectory = string.Empty; 67 protected string m_MapTileDirectory = string.Empty;
68 protected string m_ThisGatekeeper = string.Empty;
68 69
69 // Hyperlink regions are hyperlinks on the map 70 // Hyperlink regions are hyperlinks on the map
70 public readonly Dictionary<UUID, GridRegion> m_HyperlinkRegions = new Dictionary<UUID, GridRegion>(); 71 public readonly Dictionary<UUID, GridRegion> m_HyperlinkRegions = new Dictionary<UUID, GridRegion>();
@@ -123,6 +124,8 @@ namespace OpenSim.Services.GridService
123 124
124 m_MapTileDirectory = gridConfig.GetString("MapTileDirectory", "maptiles"); 125 m_MapTileDirectory = gridConfig.GetString("MapTileDirectory", "maptiles");
125 126
127 m_ThisGatekeeper = gridConfig.GetString("Gatekeeper", string.Empty);
128
126 m_GatekeeperConnector = new GatekeeperServiceConnector(m_AssetService); 129 m_GatekeeperConnector = new GatekeeperServiceConnector(m_AssetService);
127 130
128 m_log.Debug("[HYPERGRID LINKER]: Loaded all services..."); 131 m_log.Debug("[HYPERGRID LINKER]: Loaded all services...");
@@ -266,6 +269,13 @@ namespace OpenSim.Services.GridService
266 regInfo.ScopeID = scopeID; 269 regInfo.ScopeID = scopeID;
267 regInfo.EstateOwner = ownerID; 270 regInfo.EstateOwner = ownerID;
268 271
272 // Make sure we're not hyperlinking to regions on this grid!
273 if (regInfo.ServerURI.Trim(new char[]{'/', ' '}) == m_ThisGatekeeper.Trim(new char[]{'/', ' '}))
274 {
275 reason = "Cannot hyperlink to regions on the same grid";
276 return false;
277 }
278
269 // Check for free coordinates 279 // Check for free coordinates
270 GridRegion region = m_GridService.GetRegionByPosition(regInfo.ScopeID, regInfo.RegionLocX, regInfo.RegionLocY); 280 GridRegion region = m_GridService.GetRegionByPosition(regInfo.ScopeID, regInfo.RegionLocX, regInfo.RegionLocY);
271 if (region != null) 281 if (region != null)