зеркало из https://github.com/mozilla/gecko-dev.git
bug 806200 - process gzip responses without considering accept-encoding r=honzab
This commit is contained in:
Родитель
1bb82bc587
Коммит
a5eb97036a
|
@ -405,6 +405,11 @@ nsHttpHandler::IsAcceptableEncoding(const char *enc)
|
|||
if (!PL_strncasecmp(enc, "x-", 2))
|
||||
enc += 2;
|
||||
|
||||
// gzip and deflate are inherently acceptable in modern HTTP - always
|
||||
// process them if a stream converter can also be found.
|
||||
if (!PL_strcasecmp(enc, "gzip") || !PL_strcasecmp(enc, "deflate"))
|
||||
return true;
|
||||
|
||||
return nsHttp::FindToken(mAcceptEncodings.get(), enc, HTTP_LWS ",") != nullptr;
|
||||
}
|
||||
|
||||
|
|
Загрузка…
Ссылка в новой задаче