[INFER] Handle empty stack segments in AllFramesIter, bug 659473.
authorBrian Hackett <bhackett1024@gmail.com>
Tue, 24 May 2011 15:37:30 -0700
changeset 75103 4c7ebbb5287674548725c5fee97cb97747c0b413
parent 75102 3b0ae9af71945ab312470ceb474ee6d4ec052d93
child 75104 c3ed353baad4bfd19d83c699a379ab895e6d9d03
push id2
push userbsmedberg@mozilla.com
push dateFri, 19 Aug 2011 14:38:13 +0000
bugs659473
milestone6.0a1
[INFER] Handle empty stack segments in AllFramesIter, bug 659473.
js/src/vm/Stack.cpp
--- a/js/src/vm/Stack.cpp
+++ b/js/src/vm/Stack.cpp
@@ -752,15 +752,17 @@ AllFramesIter::AllFramesIter(JSContext *
 }
 
 AllFramesIter&
 AllFramesIter::operator++()
 {
     JS_ASSERT(!done());
     if (fp_ == seg_->initialFrame()) {
         seg_ = seg_->previousInMemory();
+        while (seg_ && seg_->empty())
+            seg_ = seg_->previousInMemory();
         fp_ = seg_ ? seg_->currentFrame() : NULL;
     } else {
         fp_ = fp_->prev();
     }
     return *this;
 }