From 6177295e1d9a9ebba5acc68df4800d8557b22cab Mon Sep 17 00:00:00 2001
From: Einar Egilsson
Date: Fri, 16 Oct 2009 07:23:54 +0000
Subject: Before using XPCOMUtils
git-svn-id: http://einaregilsson.googlecode.com/svn/mozilla/redirector/trunk@269 119bf307-c92d-0410-89bd-8f53e6181181
---
chrome/content/log.html | 7 ++++++-
1 file changed, 6 insertions(+), 1 deletion(-)
(limited to 'chrome/content/log.html')
diff --git a/chrome/content/log.html b/chrome/content/log.html
index a70d9f4..a4f04d1 100644
--- a/chrome/content/log.html
+++ b/chrome/content/log.html
@@ -13,7 +13,12 @@
var prefix = 'REDIRECTOR:';
if (msg.message.substr(0, prefix.length) == prefix)
{
- document.body.innerHTML += msg.message.substr(prefix.length) + '
';
+ if (document) {
+ document.body.innerHTML += msg.message.substr(prefix.length) + '
';
+ } else {
+ //Been destroyed and we're still getting message, lets try to unsubscribe...
+ try { unload(); } catch(e) {}
+ }
}
}
};
--
cgit v1.2.3-70-g09d2