Skip to content

Commit 2aad24a

Browse files
committed
deps: V8: cherry-pick 6c1b7a313b81
Signed-off-by: ulofiai <monsterking@tutamail.com>
1 parent aed4eaf commit 2aad24a

1 file changed

Lines changed: 3 additions & 0 deletions

File tree

deps/v8/src/handles/persistent-handles.cc

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -124,6 +124,9 @@ void PersistentHandlesList::Remove(PersistentHandles* persistent_handles) {
124124

125125
void PersistentHandlesList::Iterate(RootVisitor* visitor, Isolate* isolate) {
126126
isolate->heap()->safepoint()->AssertActive();
127+
// Use the lock here because PersistentHandles could be dropped from threads
128+
// without a LocalHeap.
129+
base::MutexGuard guard(&persistent_handles_mutex_);
127130
for (PersistentHandles* current = persistent_handles_head_; current;
128131
current = current->next_) {
129132
current->Iterate(visitor);

0 commit comments

Comments
 (0)