Merge branch 'master' of brain.opensimulator.org:/var/git/opensim

0.9.1.0-post-fixes
Melanie 2019-10-06 16:12:54 +01:00
commit 09d8da7e77
1 changed files with 5 additions and 7 deletions

View File

@ -117,7 +117,6 @@ namespace OpenSim.Region.ClientStack.Linden
m_GetAssetURL = config.GetString("Cap_GetAsset", string.Empty); m_GetAssetURL = config.GetString("Cap_GetAsset", string.Empty);
if (m_GetAssetURL != string.Empty) if (m_GetAssetURL != string.Empty)
m_Enabled = true; m_Enabled = true;
} }
public void AddRegion(Scene pScene) public void AddRegion(Scene pScene)
@ -387,6 +386,7 @@ namespace OpenSim.Region.ClientStack.Linden
protocol = "https"; protocol = "https";
} }
IExternalCapsModule handler = m_scene.RequestModuleInterface<IExternalCapsModule>();
string baseURL = String.Format("{0}://{1}:{2}", protocol, hostName, port); string baseURL = String.Format("{0}://{1}:{2}", protocol, hostName, port);
if (m_GetTextureURL == "localhost") if (m_GetTextureURL == "localhost")
@ -399,7 +399,6 @@ namespace OpenSim.Region.ClientStack.Linden
args.Type = PollServiceEventArgs.EventType.Texture; args.Type = PollServiceEventArgs.EventType.Texture;
MainServer.Instance.AddPollServiceHTTPHandler(capUrl, args); MainServer.Instance.AddPollServiceHTTPHandler(capUrl, args);
IExternalCapsModule handler = m_scene.RequestModuleInterface<IExternalCapsModule>();
if (handler != null) if (handler != null)
handler.RegisterExternalUserCapsHandler(agentID, caps, "GetTexture", capUrl); handler.RegisterExternalUserCapsHandler(agentID, caps, "GetTexture", capUrl);
else else
@ -420,7 +419,6 @@ namespace OpenSim.Region.ClientStack.Linden
args.Type = PollServiceEventArgs.EventType.Mesh; args.Type = PollServiceEventArgs.EventType.Mesh;
MainServer.Instance.AddPollServiceHTTPHandler(capUrl, args); MainServer.Instance.AddPollServiceHTTPHandler(capUrl, args);
IExternalCapsModule handler = m_scene.RequestModuleInterface<IExternalCapsModule>();
if (handler != null) if (handler != null)
handler.RegisterExternalUserCapsHandler(agentID, caps, "GetMesh", capUrl); handler.RegisterExternalUserCapsHandler(agentID, caps, "GetMesh", capUrl);
else else
@ -438,7 +436,7 @@ namespace OpenSim.Region.ClientStack.Linden
PollServiceAssetEventArgs args = new PollServiceAssetEventArgs(capUrl, agentID, m_scene); PollServiceAssetEventArgs args = new PollServiceAssetEventArgs(capUrl, agentID, m_scene);
args.Type = PollServiceEventArgs.EventType.Mesh2; args.Type = PollServiceEventArgs.EventType.Mesh2;
MainServer.Instance.AddPollServiceHTTPHandler(capUrl, args); MainServer.Instance.AddPollServiceHTTPHandler(capUrl, args);
IExternalCapsModule handler = m_scene.RequestModuleInterface<IExternalCapsModule>();
if (handler != null) if (handler != null)
handler.RegisterExternalUserCapsHandler(agentID, caps, "GetMesh2", capUrl); handler.RegisterExternalUserCapsHandler(agentID, caps, "GetMesh2", capUrl);
else else
@ -448,6 +446,7 @@ namespace OpenSim.Region.ClientStack.Linden
else if (m_GetMesh2URL != string.Empty) else if (m_GetMesh2URL != string.Empty)
caps.RegisterHandler("GetMesh2", m_GetMesh2URL); caps.RegisterHandler("GetMesh2", m_GetMesh2URL);
//ViewerAsset //ViewerAsset
if (m_GetAssetURL == "localhost") if (m_GetAssetURL == "localhost")
{ {
@ -456,7 +455,7 @@ namespace OpenSim.Region.ClientStack.Linden
PollServiceAssetEventArgs args = new PollServiceAssetEventArgs(capUrl, agentID, m_scene); PollServiceAssetEventArgs args = new PollServiceAssetEventArgs(capUrl, agentID, m_scene);
args.Type = PollServiceEventArgs.EventType.Asset; args.Type = PollServiceEventArgs.EventType.Asset;
MainServer.Instance.AddPollServiceHTTPHandler(capUrl, args); MainServer.Instance.AddPollServiceHTTPHandler(capUrl, args);
IExternalCapsModule handler = m_scene.RequestModuleInterface<IExternalCapsModule>();
if (handler != null) if (handler != null)
handler.RegisterExternalUserCapsHandler(agentID, caps, "ViewerAsset", capUrl); handler.RegisterExternalUserCapsHandler(agentID, caps, "ViewerAsset", capUrl);
else else
@ -464,8 +463,7 @@ namespace OpenSim.Region.ClientStack.Linden
m_capsDictGetAsset[agentID] = capUrl; m_capsDictGetAsset[agentID] = capUrl;
} }
else if (m_GetAssetURL != string.Empty) else if (m_GetAssetURL != string.Empty)
caps.RegisterHandler("ViewerAsset", m_GetMesh2URL); caps.RegisterHandler("ViewerAsset", m_GetAssetURL);
} }
private void DeregisterCaps(UUID agentID, Caps caps) private void DeregisterCaps(UUID agentID, Caps caps)