| Index: src/api.cc
|
| diff --git a/src/api.cc b/src/api.cc
|
| index 8bfc8f0e8214ebb446f41c44c5189c90ffeabdf0..d89170b83f2136abda4e424894d3f17a97a94fdc 100644
|
| --- a/src/api.cc
|
| +++ b/src/api.cc
|
| @@ -734,17 +734,17 @@ SealHandleScope::SealHandleScope(Isolate* isolate) {
|
| i::HandleScopeData* current = internal_isolate->handle_scope_data();
|
| prev_limit_ = current->limit;
|
| current->limit = current->next;
|
| - prev_level_ = current->level;
|
| - current->level = 0;
|
| + prev_sealed_level_ = current->sealed_level;
|
| + current->sealed_level = current->level;
|
| }
|
|
|
|
|
| SealHandleScope::~SealHandleScope() {
|
| i::HandleScopeData* current = isolate_->handle_scope_data();
|
| - DCHECK_EQ(0, current->level);
|
| - current->level = prev_level_;
|
| DCHECK_EQ(current->next, current->limit);
|
| current->limit = prev_limit_;
|
| + DCHECK_EQ(current->level, current->sealed_level);
|
| + current->sealed_level = prev_sealed_level_;
|
| }
|
|
|
|
|
|
|