From 08187cb59920f6def1e531f6bb62b3beb1b65a28 Mon Sep 17 00:00:00 2001 From: UbitUmarov Date: Fri, 11 Sep 2015 20:40:10 +0100 Subject: inventory mess return to the state before divas cache issue --- .../ClientStack/Linden/Caps/FetchInventory2Module.cs | 20 ++++++-------------- 1 file changed, 6 insertions(+), 14 deletions(-) (limited to 'OpenSim/Region/ClientStack/Linden/Caps/FetchInventory2Module.cs') diff --git a/OpenSim/Region/ClientStack/Linden/Caps/FetchInventory2Module.cs b/OpenSim/Region/ClientStack/Linden/Caps/FetchInventory2Module.cs index 87d3d1c..e0a11cc 100644 --- a/OpenSim/Region/ClientStack/Linden/Caps/FetchInventory2Module.cs +++ b/OpenSim/Region/ClientStack/Linden/Caps/FetchInventory2Module.cs @@ -25,20 +25,16 @@ * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. */ -using System; -using System.Collections; -using System.Reflection; -using log4net; -using Nini.Config; using Mono.Addins; +using Nini.Config; using OpenMetaverse; -using OpenSim.Framework; +using OpenSim.Capabilities.Handlers; using OpenSim.Framework.Servers.HttpServer; using OpenSim.Region.Framework.Interfaces; using OpenSim.Region.Framework.Scenes; using OpenSim.Services.Interfaces; +using System; using Caps = OpenSim.Framework.Capabilities.Caps; -using OpenSim.Capabilities.Handlers; namespace OpenSim.Region.ClientStack.Linden { @@ -58,8 +54,6 @@ namespace OpenSim.Region.ClientStack.Linden private string m_fetchInventory2Url; - private FetchInventory2Handler m_fetchHandler; - #region ISharedRegionModule Members public void Initialise(IConfigSource source) @@ -98,10 +92,6 @@ namespace OpenSim.Region.ClientStack.Linden m_inventoryService = m_scene.InventoryService; - // We'll reuse the same handler for all requests. - if (m_fetchInventory2Url == "localhost") - m_fetchHandler = new FetchInventory2Handler(m_inventoryService); - m_scene.EventManager.OnRegisterCaps += RegisterCaps; } @@ -131,9 +121,11 @@ namespace OpenSim.Region.ClientStack.Linden { capUrl = "/CAPS/" + UUID.Random(); + FetchInventory2Handler fetchHandler = new FetchInventory2Handler(m_inventoryService, agentID); + IRequestHandler reqHandler = new RestStreamHandler( - "POST", capUrl, m_fetchHandler.FetchInventoryRequest, capName, agentID.ToString()); + "POST", capUrl, fetchHandler.FetchInventoryRequest, capName, agentID.ToString()); caps.RegisterHandler(capName, reqHandler); } -- cgit v1.1