Fixed assert failure in TraceRecorder::setCallProp (bug 522570, r=dmandelin).
authorDavid Anderson <danderson@mozilla.com>
Fri, 30 Oct 2009 17:23:29 -0700
changeset 34560 8a8573ae1227452f1d6989b3b838b7156378f3bb
parent 34559 bd1b0c451b85d1e177ce0a775cc491fe7e35ad12
child 34561 35ec7012e9326473542d4a4fd1b4847c2f8e6e8c
push idunknown
push userunknown
push dateunknown
reviewersdmandelin
bugs522570
milestone1.9.3a1pre
Fixed assert failure in TraceRecorder::setCallProp (bug 522570, r=dmandelin).
js/src/jstracer.cpp
--- a/js/src/jstracer.cpp
+++ b/js/src/jstracer.cpp
@@ -11239,23 +11239,24 @@ TraceRecorder::setProp(jsval &l, JSPropC
 
 JS_REQUIRES_STACK RecordingStatus
 TraceRecorder::setCallProp(JSObject *callobj, LIns *callobj_ins, JSScopeProperty *sprop,
                            LIns *v_ins, jsval v)
 {
     // Set variables in on-trace-stack call objects by updating the tracker.
     JSStackFrame *fp = frameIfInRange(callobj);
     if (fp) {
-        jsint slot = JSVAL_TO_INT(SPROP_USERID(sprop));
         if (sprop->setter == SetCallArg) {
+            jsint slot = JSVAL_TO_INT(SPROP_USERID(sprop));
             jsval *vp2 = &fp->argv[slot];
             set(vp2, v_ins);
             return RECORD_CONTINUE;
         }
         if (sprop->setter == SetCallVar) {
+            jsint slot = JSVAL_TO_INT(SPROP_USERID(sprop));
             jsval *vp2 = &fp->slots[slot];
             set(vp2, v_ins);
             return RECORD_CONTINUE;
         }
         RETURN_STOP("can't trace special CallClass setter");
     }
 
     // Set variables in off-trace-stack call objects by calling standard builtins.