summaryrefslogtreecommitdiff
path: root/dom/events/DOMEventTargetHelper.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'dom/events/DOMEventTargetHelper.cpp')
-rw-r--r--dom/events/DOMEventTargetHelper.cpp5
1 files changed, 3 insertions, 2 deletions
diff --git a/dom/events/DOMEventTargetHelper.cpp b/dom/events/DOMEventTargetHelper.cpp
index ef5b29fa5c..458d85215f 100644
--- a/dom/events/DOMEventTargetHelper.cpp
+++ b/dom/events/DOMEventTargetHelper.cpp
@@ -52,11 +52,12 @@ NS_IMPL_CYCLE_COLLECTION_UNLINK_BEGIN(DOMEventTargetHelper)
NS_IMPL_CYCLE_COLLECTION_UNLINK_END
NS_IMPL_CYCLE_COLLECTION_CAN_SKIP_BEGIN(DOMEventTargetHelper)
- if (tmp->IsBlack() || tmp->IsCertainlyAliveForCC()) {
+ bool isBlack = tmp->IsBlack();
+ if (isBlack || tmp->IsCertainlyAliveForCC()) {
if (tmp->mListenerManager) {
tmp->mListenerManager->MarkForCC();
}
- if (!tmp->IsBlack() && tmp->PreservingWrapper()) {
+ if (!isBlack && tmp->PreservingWrapper()) {
// This marks the wrapper black.
tmp->GetWrapper();
}