Set an explicit "Accept" header when doing the MIME type probe. This prevents LLHTTPClient from adding an "Accept: application/llsd+xml", which is just wrong.

meow-7.2.2
Monroe Linden 2009-12-17 11:11:45 -08:00
parent 1f377c6b53
commit 0f7e49dea1
1 changed files with 6 additions and 1 deletions

View File

@ -1653,7 +1653,12 @@ void LLViewerMediaImpl::navigateInternal()
if(scheme.empty() || "http" == scheme || "https" == scheme)
{
LLHTTPClient::getHeaderOnly( mMediaURL, new LLMimeDiscoveryResponder(this), 10.0f);
// If we don't set an Accept header, LLHTTPClient will add one like this:
// Accept: application/llsd+xml
// which is really not what we want.
LLSD headers = LLSD::emptyMap();
headers["Accept"] = "*/*";
LLHTTPClient::getHeaderOnly( mMediaURL, new LLMimeDiscoveryResponder(this), headers, 10.0f);
}
else if("data" == scheme || "file" == scheme || "about" == scheme)
{