[Pkg-mozext-commits] [adblock-plus-element-hiding-helper] 438/483: Fixed dead object reference on dialog close
David Prévot
taffit at moszumanska.debian.org
Thu Jan 22 21:42:04 UTC 2015
This is an automated email from the git hooks/post-receive script.
taffit pushed a commit to branch master
in repository adblock-plus-element-hiding-helper.
commit 873bc75df849ca38e99f50f15cf99e6988496138
Author: Andrey Novikov <andrey at adblockplus.org>
Date: Fri Nov 9 16:40:09 2012 +0400
Fixed dead object reference on dialog close
---
chrome/content/composer.js | 13 +++++++++++--
1 file changed, 11 insertions(+), 2 deletions(-)
diff --git a/chrome/content/composer.js b/chrome/content/composer.js
index e3dad25..77b180d 100644
--- a/chrome/content/composer.js
+++ b/chrome/content/composer.js
@@ -555,8 +555,17 @@ function togglePreview(preview) {
previewStyle.textContent = stylesheetData;
}
else {
- if (previewStyle && previewStyle.parentNode)
- previewStyle.parentNode.removeChild(previewStyle);
+ try
+ {
+ if (previewStyle && previewStyle.parentNode)
+ previewStyle.parentNode.removeChild(previewStyle);
+ }
+ catch (e)
+ {
+ // if the window was closed (reloaded) we end up with dead object reference
+ // https://bugzilla.mozilla.org/show_bug.cgi?id=695480
+ // just ignore this case
+ }
previewStyle = null;
}
}
--
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/pkg-mozext/adblock-plus-element-hiding-helper.git
More information about the Pkg-mozext-commits
mailing list