mirror of
https://github.com/fergalmoran/ladybird.git
synced 2026-01-07 00:56:14 +00:00
LibWeb: Do not store resize observer entries in a plain vector
This is not safe from GC. Unfortunately we cannot add a test to capture the issue, as the allocation which may trigger GC is internal and not observable from JS.
This commit is contained in:
committed by
Alexander Kalenik
parent
be1d400369
commit
04648d93d4
@@ -97,7 +97,7 @@ void ResizeObserver::disconnect()
|
||||
m_active_targets.clear();
|
||||
}
|
||||
|
||||
void ResizeObserver::invoke_callback(Vector<JS::NonnullGCPtr<ResizeObserverEntry>>& entries) const
|
||||
void ResizeObserver::invoke_callback(ReadonlySpan<JS::NonnullGCPtr<ResizeObserverEntry>> entries) const
|
||||
{
|
||||
auto& callback = *m_callback;
|
||||
auto& realm = callback.callback_context->realm();
|
||||
|
||||
Reference in New Issue
Block a user