mirror of
https://github.com/opensim/opensim.git
synced 2026-07-31 05:45:37 +08:00
some conditional dispose on http requests inputstream
This commit is contained in:
@@ -86,6 +86,9 @@ namespace OpenSim.Framework.Servers.HttpServer
|
||||
|
||||
byte[] buffer = server.DoHTTPGruntWork(responsedata, response);
|
||||
|
||||
if(Request.Body.CanRead)
|
||||
Request.Body.Dispose();
|
||||
|
||||
response.SendChunked = false;
|
||||
response.ContentLength64 = buffer.Length;
|
||||
response.ContentEncoding = Encoding.UTF8;
|
||||
@@ -111,6 +114,9 @@ namespace OpenSim.Framework.Servers.HttpServer
|
||||
OSHttpResponse response
|
||||
= new OSHttpResponse(new HttpResponse(HttpContext, Request), HttpContext);
|
||||
|
||||
if(Request.Body.CanRead)
|
||||
Request.Body.Dispose();
|
||||
|
||||
response.SendChunked = false;
|
||||
response.ContentLength64 = 0;
|
||||
response.ContentEncoding = Encoding.UTF8;
|
||||
|
||||
Reference in New Issue
Block a user