bug 1116382 accept abstract strings in NewURIFromString() r=bholley
authorKarl Tomlinson <karlt+@karlt.net>
Fri, 22 May 2015 17:12:13 +1200
changeset 247333 0c077afa1fbf37e572d8b1e650d963b5327dcff6
parent 247332 bd44786e85f4e012d961e89a5ca49fd85d84ade8
child 247334 6e1078de459056a3eaee55d60b0212ee8a4afe7c
push id28864
push userkwierso@gmail.com
push dateFri, 05 Jun 2015 21:49:37 +0000
treeherdermozilla-central@97a39c939c51 [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersbholley
bugs1116382
milestone41.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 1116382 accept abstract strings in NewURIFromString() r=bholley
dom/html/nsGenericHTMLElement.cpp
dom/html/nsGenericHTMLElement.h
--- a/dom/html/nsGenericHTMLElement.cpp
+++ b/dom/html/nsGenericHTMLElement.cpp
@@ -3189,17 +3189,17 @@ nsGenericHTMLElement::IsEventAttributeNa
   return nsContentUtils::IsEventAttributeName(aName, EventNameType_HTML);
 }
 
 /**
  * Construct a URI from a string, as an element.src attribute
  * would be set to. Helper for the media elements.
  */
 nsresult
-nsGenericHTMLElement::NewURIFromString(const nsAutoString& aURISpec,
+nsGenericHTMLElement::NewURIFromString(const nsAString& aURISpec,
                                        nsIURI** aURI)
 {
   NS_ENSURE_ARG_POINTER(aURI);
 
   *aURI = nullptr;
 
   nsCOMPtr<nsIDocument> doc = OwnerDoc();
 
--- a/dom/html/nsGenericHTMLElement.h
+++ b/dom/html/nsGenericHTMLElement.h
@@ -1006,17 +1006,17 @@ protected:
 
   virtual const nsAttrName* InternalGetExistingAttrNameFromQName(const nsAString& aStr) const override;
 
   /**
    * Create a URI for the given aURISpec string.
    * Returns INVALID_STATE_ERR and nulls *aURI if aURISpec is empty
    * and the document's URI matches the element's base URI.
    */
-  nsresult NewURIFromString(const nsAutoString& aURISpec, nsIURI** aURI);
+  nsresult NewURIFromString(const nsAString& aURISpec, nsIURI** aURI);
 
   void GetHTMLAttr(nsIAtom* aName, nsAString& aResult) const
   {
     GetAttr(kNameSpaceID_None, aName, aResult);
   }
   void GetHTMLAttr(nsIAtom* aName, mozilla::dom::DOMString& aResult) const
   {
     GetAttr(kNameSpaceID_None, aName, aResult);