HACK ALERT! There's some underlying bug in the HTTP server that makes requests come up with Accept headers from previous requests. Until that gets fixed, this hack goes in.

0.7.0.1-release
Diva Canto 2010-08-06 10:57:52 -07:00
parent dc08e1cbf9
commit db629af6d3
1 changed files with 7 additions and 0 deletions

View File

@ -319,6 +319,13 @@ namespace OpenSim.Framework.Servers.HttpServer
OSHttpRequest req = new OSHttpRequest(context, request); OSHttpRequest req = new OSHttpRequest(context, request);
OSHttpResponse resp = new OSHttpResponse(new HttpResponse(context, request),context); OSHttpResponse resp = new OSHttpResponse(new HttpResponse(context, request),context);
HandleRequest(req, resp); HandleRequest(req, resp);
// !!!HACK ALERT!!!
// There seems to be a bug in the underlying http code that makes subsequent requests
// come up with trash in Accept headers. Until that gets fixed, we're cleaning them up here.
if (request.AcceptTypes != null)
for (int i = 0; i < request.AcceptTypes.Length; i++)
request.AcceptTypes[i] = string.Empty;
} }
// public void ConvertIHttpClientContextToOSHttp(object stateinfo) // public void ConvertIHttpClientContextToOSHttp(object stateinfo)