From 7f570636f8056ec24dd7f28207af62b44a8811ba Mon Sep 17 00:00:00 2001 From: Diva Canto Date: Sun, 4 May 2014 11:41:52 -0700 Subject: Please note: older simulators (0.7.6) still send the info about gzip in ContentType --- OpenSim/Server/Handlers/Simulation/AgentHandlers.cs | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'OpenSim/Server') diff --git a/OpenSim/Server/Handlers/Simulation/AgentHandlers.cs b/OpenSim/Server/Handlers/Simulation/AgentHandlers.cs index 0d7f259..06392f7 100644 --- a/OpenSim/Server/Handlers/Simulation/AgentHandlers.cs +++ b/OpenSim/Server/Handlers/Simulation/AgentHandlers.cs @@ -243,7 +243,7 @@ namespace OpenSim.Server.Handlers.Simulation } Stream inputStream = request; - if ((httpRequest.Headers["Content-Encoding"] == "gzip") || (httpRequest.Headers["X-Content-Encoding"] == "gzip")) + if ((httpRequest.ContentType == "application/x-gzip" || httpRequest.Headers["Content-Encoding"] == "gzip") || (httpRequest.Headers["X-Content-Encoding"] == "gzip")) inputStream = new GZipStream(inputStream, CompressionMode.Decompress); StreamReader reader = new StreamReader(inputStream, encoding); @@ -454,7 +454,7 @@ namespace OpenSim.Server.Handlers.Simulation keysvals.Add("querystringkeys", querystringkeys); Stream inputStream = request; - if ((httpRequest.Headers["Content-Encoding"] == "gzip") || (httpRequest.Headers["X-Content-Encoding"] == "gzip")) + if ((httpRequest.ContentType == "application/x-gzip" || httpRequest.Headers["Content-Encoding"] == "gzip") || (httpRequest.Headers["X-Content-Encoding"] == "gzip")) inputStream = new GZipStream(inputStream, CompressionMode.Decompress); Encoding encoding = Encoding.UTF8; -- cgit v1.1