Releasing the lock when the iterator is at end - otherwise a finished iterator could still block the layout (potential Ruby GC issue)

This commit is contained in:
Matthias Koefferlein 2024-10-25 00:40:42 +02:00
parent c1757c472e
commit bea707a9df
1 changed files with 6 additions and 0 deletions

View File

@ -695,6 +695,12 @@ RecursiveShapeIterator::next (RecursiveShapeReceiver *receiver)
next_shape (receiver);
}
if (at_end ()) {
// release the layout lock if at end - this way, the shape iterator can be
// held further, without blocking the layout.
m_locker = db::LayoutLocker ();
}
}
}