Backed out changeset 1023659e3413 (bug 1203463) for w(7) and m(4) bustage
authorWes Kocher <wkocher@mozilla.com>
Tue, 15 Sep 2015 10:58:14 -0700
changeset 262623 27cdeffa4ae126a34f50413a73fffb66b272b114
parent 262622 408c024f3dc010f61ac698b505f268999448fe8a
child 262624 2ad7f8d8c0421a8dcccafabb71a807a9337d2abc
push id15198
push userkwierso@gmail.com
push dateWed, 16 Sep 2015 00:21:31 +0000
treeherderfx-team@dbfddd6efb5d [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
bugs1203463
milestone43.0a1
backs out1023659e341377d894b12f030226afcdab35dbb5
Backed out changeset 1023659e3413 (bug 1203463) for w(7) and m(4) bustage
dom/base/URL.cpp
dom/base/test/test_url.html
--- a/dom/base/URL.cpp
+++ b/dom/base/URL.cpp
@@ -418,25 +418,18 @@ URL::SetPort(const nsAString& aPort, Err
 
 void
 URL::GetPathname(nsAString& aPathname, ErrorResult& aRv) const
 {
   aPathname.Truncate();
 
   nsCOMPtr<nsIURL> url(do_QueryInterface(mURI));
   if (!url) {
-    nsAutoCString path;
-    nsresult rv = mURI->GetPath(path);
-    if (NS_FAILED(rv)){
-      // Do not throw!  Not having a valid URI or URL should result in an empty
-      // string.
-      return;
-    }
-
-    CopyUTF8toUTF16(path, aPathname);
+    // Do not throw!  Not having a valid URI or URL should result in an empty
+    // string.
     return;
   }
 
   nsAutoCString file;
   nsresult rv = url->GetFilePath(file);
   if (NS_SUCCEEDED(rv)) {
     CopyUTF8toUTF16(file, aPathname);
   }
--- a/dom/base/test/test_url.html
+++ b/dom/base/test/test_url.html
@@ -204,24 +204,16 @@
       error: false,
       protocol: 'wss:',
     },
     { url: 'foo://foo.something.net',
       base: undefined,
       error: false,
       protocol: 'foo:',
     },
-
-    { url: 'about:blank',
-      base: undefined,
-      error: false,
-      protocol: 'about:',
-      pathname: 'blank',
-      skip_setters: false,
-    },
   ];
 
   while(tests.length) {
     var test = tests.shift();
 
     var error = false;
     var url;
     try {
@@ -246,21 +238,16 @@
     if ('password' in test) is(url.password, test.password, "password");
     if ('host' in test) is(url.host, test.host, "host");
     if ('hostname' in test) is(url.hostname, test.hostname, "hostname");
     if ('port' in test) is(url.port, test.port, "port");
     if ('pathname' in test) is(url.pathname, test.pathname, "pathname");
     if ('search' in test) is(url.search, test.search, "search");
     if ('hash' in test) is(url.hash, test.hash, "hash");
 
-    if ('skip_setters' in test && test.skip_setters == false) {
-      info("Skip setter methods for URL: " + test);
-      continue;
-    }
-
     url = new URL('https://www.example.net/what#foo?bar');
     ok(url, "Url exists!");
 
     if ('href' in test) url.href = test.href;
     if ('protocol' in test) url.protocol = test.protocol;
     if ('username' in test && test.username) url.username = test.username;
     if ('password' in test && test.password) url.password = test.password;
     if ('host' in test) url.host = test.host;