Bug 488018: Avoid 'may be used uninitialized' error. (no r)
authorJim Blandy <jimb@mozilla.org>
Mon, 04 May 2009 16:46:15 -0700
changeset 28008 308fa16b3bfc4a07f9524845bdaeec3730681f18
parent 28007 38512deaca7e5ca4fcd39ca9c60f2640fa3ad773
child 28009 3065dcc6f64e6c04e2d4007dd6c9bb185daaccb9
child 28086 b8cf788763a09dd4dcc02969153a7352aad24dc0
push id6839
push userrsayre@mozilla.com
push dateTue, 05 May 2009 18:41:02 +0000
treeherdermozilla-central@3065dcc6f64e [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
bugs488018
milestone1.9.2a1pre
Bug 488018: Avoid 'may be used uninitialized' error. (no r)
js/src/jstracer.cpp
--- a/js/src/jstracer.cpp
+++ b/js/src/jstracer.cpp
@@ -4582,17 +4582,19 @@ TraceRecorder::monitorRecording(JSContex
        trace. We check for imacro-calling bytecodes inside each switch case to resolve
        the if (JSOP_IS_IMACOP(x)) conditions at compile time. */
 
     JSRecordingStatus status;
 #ifdef DEBUG
     bool wasInImacro = (cx->fp->imacpc != NULL);
 #endif
     switch (op) {
-      default: goto stop_recording;
+      default:
+          status = JSRS_ERROR;
+          goto stop_recording;
 # define OPDEF(x,val,name,token,length,nuses,ndefs,prec,format)               \
       case x:                                                                 \
         status = tr->record_##x();                                            \
         if (JSOP_IS_IMACOP(x))                                                \
             goto imacro;                                                      \
         break;
 # include "jsopcode.tbl"
 # undef OPDEF