Unit test bustage fix following bug 733802 - return null instead of throwing, as xpconnect pushes an error to the console for functions that throw, even though that's handled correctly in the c (this upsets some of the tests that check for no errors on the console). a=bustage fix
authorMark Banner <bugzilla@standard8.plus.com>
Tue, 20 Mar 2012 15:16:28 +0000
changeset 11122 eb3c266e224e47e5dad6ae7dc868886047447740
parent 11121 a42983902c5d76402b949a2399f94fa5f2a51d6e
child 11123 62d1ea4c543ccee291d168f88cb9b8b8d247d81a
push id463
push userbugzilla@standard8.plus.com
push dateTue, 24 Apr 2012 17:34:51 +0000
treeherdercomm-beta@e53588e8f7b0 [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersbustage
bugs733802
Unit test bustage fix following bug 733802 - return null instead of throwing, as xpconnect pushes an error to the console for functions that throw, even though that's handled correctly in the c (this upsets some of the tests that check for no errors on the console). a=bustage fix
mail/components/webSearchProvider.js
--- a/mail/components/webSearchProvider.js
+++ b/mail/components/webSearchProvider.js
@@ -102,17 +102,17 @@ UnionEnumerator.prototype = {
 function WebSearchProvider() {}
 WebSearchProvider.prototype = {
   classDescription: "Web Search Provider",
   classID: Components.ID("{76a80bff-8c3f-4b78-ad2c-80099e35375d}"),
   QueryInterface: XPCOMUtils.generateQI([Ci.nsIDirectoryServiceProvider,
                                          Ci.nsIDirectoryServiceProvider2]),
 
   getFile: function() {
-    throw Components.results.NS_ERROR_NOT_IMPLEMENTED;
+    return null;
   },
 
   getFiles: function(prop) {
     if (prop != NS_APP_SEARCH_DIR_LIST)
       return null;
 
     /**
      * We want to preserve the following order, since the search service loads