From e9e4c009b470056dce05cae386860494b0734678 Mon Sep 17 00:00:00 2001 From: Diva Canto Date: Wed, 11 May 2011 20:44:03 -0700 Subject: This makes compression of fatpacks actually work. Previously they always failed. See comment in WebUtil. --- OpenSim/Server/Handlers/Simulation/AgentHandlers.cs | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) (limited to 'OpenSim/Server/Handlers/Simulation/AgentHandlers.cs') diff --git a/OpenSim/Server/Handlers/Simulation/AgentHandlers.cs b/OpenSim/Server/Handlers/Simulation/AgentHandlers.cs index ad74b9b..e8ae05b 100644 --- a/OpenSim/Server/Handlers/Simulation/AgentHandlers.cs +++ b/OpenSim/Server/Handlers/Simulation/AgentHandlers.cs @@ -283,6 +283,7 @@ namespace OpenSim.Server.Handlers.Simulation StreamReader reader = new StreamReader(inputStream, encoding); string requestBody = reader.ReadToEnd(); + reader.Close(); keysvals.Add("body", requestBody); httpResponse.StatusCode = 200; @@ -463,15 +464,13 @@ namespace OpenSim.Server.Handlers.Simulation if (httpRequest.ContentType == "application/x-gzip") inputStream = new GZipStream(request, CompressionMode.Decompress); else - { - m_log.DebugFormat("[XXX]: Update called with {0}", httpRequest.ContentType); inputStream = request; - } Encoding encoding = Encoding.UTF8; StreamReader reader = new StreamReader(inputStream, encoding); string requestBody = reader.ReadToEnd(); + reader.Close(); keysvals.Add("body", requestBody); httpResponse.StatusCode = 200; -- cgit v1.1