зеркало из https://github.com/mozilla/gecko-dev.git
Parse out the actual type from the content-type argument passed to
document.open(). Bug 295652, r+sr=jst, a=shaver
This commit is contained in:
Родитель
67150fef30
Коммит
a511b11a65
|
@ -6453,7 +6453,9 @@ nsHTMLDocumentSH::DocumentOpen(JSContext *cx, JSObject *obj, uintN argc,
|
|||
nsAutoString type;
|
||||
type.Assign(nsDependentJSString(jsstr));
|
||||
ToLowerCase(type);
|
||||
if (!type.EqualsLiteral("text/html")) {
|
||||
nsCAutoString actualType, dummy;
|
||||
NS_ParseContentType(NS_ConvertUTF16toUTF8(type), actualType, dummy);
|
||||
if (!actualType.EqualsLiteral("text/html")) {
|
||||
contentType = "text/plain";
|
||||
}
|
||||
}
|
||||
|
|
Загрузка…
Ссылка в новой задаче