[Pkg-mozext-commits] [requestpolicy] 133/280: ScriptLoader: catch NS_ERROR_FILE_NOT_FOUND
David Prévot
taffit at moszumanska.debian.org
Sat May 2 20:30:11 UTC 2015
This is an automated email from the git hooks/post-receive script.
taffit pushed a commit to branch master
in repository requestpolicy.
commit 5a8818b51ef29fc232a2cbfae8a1504574e744c7
Author: Martin Kimmerle <dev at 256k.de>
Date: Wed Jan 7 16:38:12 2015 +0100
ScriptLoader: catch NS_ERROR_FILE_NOT_FOUND
catch NS_ERROR_FILE_NOT_FOUND explicitly
---
src/content/lib/script-loader.jsm | 6 +++++-
1 file changed, 5 insertions(+), 1 deletion(-)
diff --git a/src/content/lib/script-loader.jsm b/src/content/lib/script-loader.jsm
index 42135aa..39f396c 100644
--- a/src/content/lib/script-loader.jsm
+++ b/src/content/lib/script-loader.jsm
@@ -24,6 +24,7 @@
const Ci = Components.interfaces;
const Cc = Components.classes;
const Cu = Components.utils;
+const Cr = Components.results;
let EXPORTED_SYMBOLS = ["ScriptLoader"];
@@ -105,8 +106,11 @@ let ScriptLoader = (function() {
if (moduleID in modulesCurrentlyBeingImported) {
delete modulesCurrentlyBeingImported[moduleID];
}
+ } catch (e if e.result === Cr.NS_ERROR_FILE_NOT_FOUND) {
+ logSevereError("Failed to import module with ID \"" + moduleID + "\", the " +
+ "file was not found! ", e.stack);
} catch (e) {
- logSevereError("Failed to import module \"" + moduleID + "\": " + e,
+ logSevereError("Failed to import module with ID \"" + moduleID + "\": " + e,
e.stack);
}
return scope;
--
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/pkg-mozext/requestpolicy.git
More information about the Pkg-mozext-commits
mailing list