Bug 770253 - Various compilation fixes for different --enable options. r=terrence
authorSteve Fink <sfink@mozilla.com>
Mon, 02 Jul 2012 09:07:57 -0700
changeset 106821 de0930a5e8ee11278535b30a766934a6bd559991
parent 106820 4a517a831ec94ac16c3d609dd4914d07a96ebbba
child 106822 b1830b933f15845bd19d2e411a911dc2a4644413
push id74
push usershu@rfrn.org
push dateTue, 18 Sep 2012 19:23:47 +0000
reviewersterrence
bugs770253
milestone18.0a1
Bug 770253 - Various compilation fixes for different --enable options. r=terrence
js/src/gc/Root.h
js/src/jscntxt.cpp
--- a/js/src/gc/Root.h
+++ b/js/src/gc/Root.h
@@ -385,17 +385,17 @@ typedef Rooted<Value>        RootedValue
 /*
  * Mark a stack location as a root for the rooting analysis, without actually
  * rooting it in release builds. This should only be used for stack locations
  * of GC things that cannot be relocated by a garbage collection, and that
  * are definitely reachable via another path.
  */
 class SkipRoot
 {
-#if defined(DEBUG) && defined(JSGC_ROOT_ANALYSIS)
+#if defined(DEBUG) && defined(JS_GC_ZEAL) && defined(JSGC_ROOT_ANALYSIS) && !defined(JS_THREADSAFE)
 
     SkipRoot **stack, *prev;
     const uint8_t *start;
     const uint8_t *end;
 
     template <typename T>
     void init(ContextFriendFields *cx, const T *ptr, size_t count)
     {
--- a/js/src/jscntxt.cpp
+++ b/js/src/jscntxt.cpp
@@ -1204,17 +1204,17 @@ JSContext::JSContext(JSRuntime *rt)
 #ifdef DEBUG
     stackIterAssertionEnabled(true),
 #endif
     activeCompilations(0)
 {
     PodZero(&link);
 #ifdef JSGC_ROOT_ANALYSIS
     PodArrayZero(thingGCRooters);
-#ifdef DEBUG
+#if defined(JS_GC_ZEAL) && defined(DEBUG) && !defined(JS_THREADSAFE)
     skipGCRooters = NULL;
 #endif
 #endif
 }
 
 JSContext::~JSContext()
 {
     /* Free the stuff hanging off of cx. */