From 0a4f0758fa4279739b09ff3002b2fa9f2d81dcc4 Mon Sep 17 00:00:00 2001 From: root Date: Mon, 11 Mar 2019 23:40:55 +0000 Subject: [PATCH] Should have been in the last commit --- .../Server/Handlers/Map/MapGetServerConnector.cs | 15 ++++++++++++--- 1 file changed, 12 insertions(+), 3 deletions(-) diff --git a/OpenSim/Server/Handlers/Map/MapGetServerConnector.cs b/OpenSim/Server/Handlers/Map/MapGetServerConnector.cs index 1ae669cc80..017927a759 100644 --- a/OpenSim/Server/Handlers/Map/MapGetServerConnector.cs +++ b/OpenSim/Server/Handlers/Map/MapGetServerConnector.cs @@ -98,11 +98,20 @@ namespace OpenSim.Server.Handlers.MapImage // UUID scopeID = new UUID("07f8d88e-cd5e-4239-a0ed-843f75d09992"); UUID scopeID = UUID.Zero; + // This will be map/tilefile.ext, but on multitenancy it will be + // map/scope/teilefile.ext string[] bits = path.Trim('/').Split(new char[] {'/'}); - if (bits.Length > 1) + if (bits.Length > 2) { - scopeID = new UUID(bits[0]); - path = bits[1]; + try + { + scopeID = new UUID(bits[1]); + } + catch + { + return new byte[9]; + } + path = bits[2]; } result = m_MapService.GetMapTile(path.Trim('/'), scopeID, out format); if (result.Length > 0)