mirror of
https://github.com/RGBCube/serenity
synced 2025-07-26 10:57:34 +00:00
LibWeb: Protect XMLHttpRequest from GC in special circumstances
The XHR gives us a set of conditions where XHR objects must survive garbage collection, even when there are no pointers to them on the heap. This patch implements those conditions using the new cell self-protection mechanism in LibJS.
This commit is contained in:
parent
e0a08f2ab0
commit
e448c74736
2 changed files with 35 additions and 0 deletions
|
@ -65,6 +65,7 @@ public:
|
|||
|
||||
private:
|
||||
virtual void visit_edges(Cell::Visitor&) override;
|
||||
virtual bool must_survive_garbage_collection() const override;
|
||||
|
||||
void set_ready_state(ReadyState);
|
||||
void set_status(Fetch::Infrastructure::Status status) { m_status = status; }
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue