diff --git a/content/html/content/src/nsHTMLOptionElement.cpp b/content/html/content/src/nsHTMLOptionElement.cpp
index 7b90633d748e..ddb7c92a4469 100644
--- a/content/html/content/src/nsHTMLOptionElement.cpp
+++ b/content/html/content/src/nsHTMLOptionElement.cpp
@@ -152,7 +152,7 @@ NS_NewHTMLOptionElement(nsINodeInfo *aNodeInfo, PRBool aFromParser)
NS_ENSURE_TRUE(doc, nsnull);
nodeInfo = doc->NodeInfoManager()->GetNodeInfo(nsGkAtoms::option, nsnull,
- kNameSpaceID_None);
+ kNameSpaceID_XHTML);
NS_ENSURE_TRUE(nodeInfo, nsnull);
}
diff --git a/content/html/content/src/nsHTMLStyleElement.cpp b/content/html/content/src/nsHTMLStyleElement.cpp
index 8c624506962a..fd1b3bfab8d4 100644
--- a/content/html/content/src/nsHTMLStyleElement.cpp
+++ b/content/html/content/src/nsHTMLStyleElement.cpp
@@ -319,7 +319,8 @@ nsHTMLStyleElement::GetStyleSheetURL(PRBool* aIsInline,
if (*aIsInline) {
return;
}
- if (mNodeInfo->NamespaceEquals(kNameSpaceID_XHTML)) {
+ if (GetOwnerDoc() && // XXX clean up after bug 335998 lands
+ !(GetOwnerDoc()->IsCaseSensitive())) {
// We stopped supporting