diff --git a/js/src/vm/TraceLogging.cpp b/js/src/vm/TraceLogging.cpp index 751840c3b00c..348dae49e56a 100644 --- a/js/src/vm/TraceLogging.cpp +++ b/js/src/vm/TraceLogging.cpp @@ -703,8 +703,8 @@ TraceLogger::stopEvent(uint32_t id) { #ifdef DEBUG TreeEntry entry; - MOZ_ASSERT(getTreeEntry(stack.current().treeId(), &entry)); - MOZ_ASSERT(entry.textId() == id); + MOZ_ASSERT_IF(stack.current().active(), getTreeEntry(stack.current().treeId(), &entry)); + MOZ_ASSERT_IF(stack.current().active(), entry.textId() == id); #endif stopEvent(); } diff --git a/js/src/vm/TraceLogging.h b/js/src/vm/TraceLogging.h index 9a7801f90cd0..c6a7fd920967 100644 --- a/js/src/vm/TraceLogging.h +++ b/js/src/vm/TraceLogging.h @@ -306,7 +306,7 @@ class TraceLogger stop_ = stop; } void setTextId(uint32_t textId) { - MOZ_ASSERT(textId < (1<<31) ); + MOZ_ASSERT(textId < uint32_t(1<<31) ); u.s.textId_ = textId; } void setHasChildren(bool hasChildren) { @@ -352,7 +352,7 @@ class TraceLogger lastChildId_ = lastChildId; } void setTextId(uint32_t textId) { - MOZ_ASSERT(textId < (1<<31) ); + MOZ_ASSERT(textId < uint32_t(1<<31) ); s.textId_ = textId; } void setActive(bool active) {