Fix warnings-as-errors breakage for bug 609523.
authorNicholas Nethercote <nnethercote@mozilla.com>
Mon, 21 Mar 2011 21:52:39 -0700
changeset 64329 5a2e69befff35501d28ad82f9653a53c295caa17
parent 64328 b4729e53ce456a5de572d9a7c96e9befa0632bb4
child 64330 cdcef9d0f76aa3401a56004d482622527fd399f5
push idunknown
push userunknown
push dateunknown
bugs609523
milestone2.0b13pre
Fix warnings-as-errors breakage for bug 609523.
js/src/jsopcode.cpp
js/src/jsscopeinlines.h
js/src/shell/jsworkers.cpp
--- a/js/src/jsopcode.cpp
+++ b/js/src/jsopcode.cpp
@@ -1858,17 +1858,17 @@ Decompile(SprintStack *ss, jsbytecode *p
     const JSCodeSpec *cs;
     jssrcnote *sn, *sn2;
     const char *lval, *rval, *xval, *fmt, *token;
     uintN nuses;
     jsint i, argc;
     char **argv;
     JSAtom *atom;
     JSObject *obj;
-    JSFunction *fun;
+    JSFunction *fun = NULL; /* init to shut GCC up */
     JSString *str;
     JSBool ok;
 #if JS_HAS_XML_SUPPORT
     JSBool foreach, inXML, quoteAttr;
 #else
 #define inXML JS_FALSE
 #endif
     jsval val;
--- a/js/src/jsscopeinlines.h
+++ b/js/src/jsscopeinlines.h
@@ -44,16 +44,17 @@
 #include "jsbool.h"
 #include "jscntxt.h"
 #include "jsdbgapi.h"
 #include "jsfun.h"
 #include "jsobj.h"
 #include "jsscope.h"
 
 #include "jscntxtinlines.h"
+#include "jsobjinlines.h"
 
 inline void
 js::Shape::freeTable(JSContext *cx)
 {
     if (hasTable()) {
         cx->destroy(getTable());
         setTable(NULL);
     }
--- a/js/src/shell/jsworkers.cpp
+++ b/js/src/shell/jsworkers.cpp
@@ -1092,17 +1092,17 @@ Worker::create(JSContext *parentcx, Work
         return NULL;
     }
     return w;
 }
 
 void
 Worker::processOneEvent()
 {
-    Event *event;
+    Event *event = NULL;    /* init to shut GCC up */
     {
         AutoLock hold1(lock);
         if (lockedCheckTermination() || events.empty())
             return;
 
         event = current = events.pop();
     }