Bug 579744. Extract the actual content type from the attribute value before using it as a type hint for the channel. r=jst

This commit is contained in:
Boris Zbarsky
2010-07-22 17:33:38 -04:00
parent dfba6f3e24
commit b6f4222313
2 changed files with 14 additions and 2 deletions

View File

@@ -11087,6 +11087,10 @@ nsDocShell::OnLinkClickSync(nsIContent *aContent,
nsCOMPtr<nsIDOMHTMLAnchorElement> anchor(do_QueryInterface(aContent));
if (anchor) {
anchor->GetType(typeHint);
NS_ConvertUTF16toUTF8 utf8Hint(typeHint);
nsCAutoString type, dummy;
NS_ParseContentType(utf8Hint, type, dummy);
CopyUTF8toUTF16(type, typeHint);
}
nsresult rv = InternalLoad(aURI, // New URI