band aid, wrap our attempt to get the phishing warden in a try/catch

git-svn-id: svn://10.0.0.236/trunk@216241 18797224-902f-48f8-a5cc-f745e15eee43
This commit is contained in:
scott%scott-macgregor.org 2006-12-01 08:32:52 +00:00
parent 0dd72d58fc
commit 2acffb210e

View File

@ -53,6 +53,7 @@ var gPhishingDetector = {
*/
init: function()
{
try {
// set up the anti phishing service
var appContext = Components.classes["@mozilla.org/phishingprotection/application;1"]
.getService().wrappedJSObject;
@ -69,6 +70,7 @@ var gPhishingDetector = {
// Download/update lists if we're in non-enhanced mode
this.mPhishingWarden.maybeToggleUpdateChecking();
} catch (ex) { dump('unable to create the phishing warde: ' + ex + '\n');}
},
/**
@ -147,7 +149,10 @@ var gPhishingDetector = {
// Lookup the url against our local list. We want to do this even if the url fails our static
// test checks because the url might be in the white list.
if (this.mPhishingWarden)
this.mPhishingWarden.isEvilURL(GetLoadedMessage(), failsStaticTests, aUrl, this.localListCallback);
else
this.localListCallback(GetLoadedMessage(), failsStaticTests, aUrl, 2 /* not found */);
}
},