[Pkg-mozext-commits] [requestpolicy] 46/280: report catched errors to the browser console
David Prévot
taffit at moszumanska.debian.org
Sat May 2 20:29:58 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 b3d116555f2fa1fd5b5d5c76e8cd863f2df006dd
Author: Martin Kimmerle <dev at 256k.de>
Date: Fri Dec 5 05:56:58 2014 +0100
report catched errors to the browser console
---
src/content/lib/logger.jsm | 7 ++++++-
1 file changed, 6 insertions(+), 1 deletion(-)
diff --git a/src/content/lib/logger.jsm b/src/content/lib/logger.jsm
index 34d528f..d517230 100644
--- a/src/content/lib/logger.jsm
+++ b/src/content/lib/logger.jsm
@@ -150,13 +150,18 @@ let Logger = (function() {
self.printFunc("[RequestPolicy] [" + levelName + "] [" + typeName + "] "
+ aMessage + stack + "\n");
+ if (aError) {
+ // if an error was provided, report it to the browser console
+ Cu.reportError(aError);
+ }
+
// TODO: remove the following after finishing e10s
if (aLevel == self.LEVEL_SEVERE && aType == self.TYPE_ERROR) {
let windowtype = 'navigator:browser';
let mostRecentWindow = Services.wm.getMostRecentWindow(windowtype);
if (mostRecentWindow) {
- mostRecentWindow.alert("Sorry, RequestPolicy crashed! " + message);
+ mostRecentWindow.alert("Sorry, RequestPolicy crashed! " + aMessage);
}
}
}
--
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