Bug 860435 - Don't use an iterator that's already at the end of the stack. r=terrence