Bug 729048 - Part 2: Replace calls to nsParserService::CheckQName with nsContentUtils::CheckQName in nsDocument.cpp. r=hsivonen
authorMatias Juntunen <matias.juntunen@gmail.com>
Thu, 29 Mar 2012 17:31:40 -0400
changeset 90645 7af2fcef270f45302408bcb65565aaa87b4d7d10
parent 90644 11ef97686043964c0c0305f64fefddd57cf772af
child 90646 c2d8ac6bb09cbd96ead468c6c6f1cb0884d89a5f
push id7773
push userryanvm@gmail.com
push dateThu, 29 Mar 2012 21:31:45 +0000
treeherdermozilla-inbound@2c149ce94c49 [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewershsivonen
bugs729048
milestone14.0a1
first release with
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
last release without
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
Bug 729048 - Part 2: Replace calls to nsParserService::CheckQName with nsContentUtils::CheckQName in nsDocument.cpp. r=hsivonen
content/base/src/nsDocument.cpp
--- a/content/base/src/nsDocument.cpp
+++ b/content/base/src/nsDocument.cpp
@@ -1415,22 +1415,19 @@ nsDOMImplementation::CreateDocument(cons
                                     const nsAString& aQualifiedName,
                                     nsIDOMDocumentType* aDoctype,
                                     nsIDOMDocument** aReturn)
 {
   *aReturn = nsnull;
 
   nsresult rv;
   if (!aQualifiedName.IsEmpty()) {
-    nsIParserService *parserService = nsContentUtils::GetParserService();
-    NS_ENSURE_TRUE(parserService, NS_ERROR_FAILURE);
-
     const nsAFlatString& qName = PromiseFlatString(aQualifiedName);
     const PRUnichar *colon;
-    rv = parserService->CheckQName(qName, true, &colon);
+    rv = nsContentUtils::CheckQName(qName, true, &colon);
     NS_ENSURE_SUCCESS(rv, rv);
 
     if (colon &&
         (DOMStringIsNull(aNamespaceURI) ||
          (Substring(qName.get(), colon).EqualsLiteral("xml") &&
           !aNamespaceURI.EqualsLiteral("http://www.w3.org/XML/1998/namespace")))) {
       return NS_ERROR_DOM_NAMESPACE_ERR;
     }