From c242822eebb75bcf0b0e10102d3cc49e9044a658 Mon Sep 17 00:00:00 2001 From: chickenleaf Date: Sun, 20 Oct 2024 02:33:03 +0530 Subject: [PATCH] Fix GC borrow hazard in HTMLImageElement::finish_reacting_to_environment_change (#33904) * Fix GC borrow hazard in HTMLImageElement::finish_reacting_to_environment_change Signed-off-by: L Ashwin B * Fixed clippy error Signed-off-by: L Ashwin B --------- Signed-off-by: L Ashwin B --- components/script/dom/htmlimageelement.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/components/script/dom/htmlimageelement.rs b/components/script/dom/htmlimageelement.rs index d2bfff7721d..39fded6b07e 100644 --- a/components/script/dom/htmlimageelement.rs +++ b/components/script/dom/htmlimageelement.rs @@ -1271,8 +1271,8 @@ impl HTMLImageElement { // Step 15.5 mem::swap(&mut this.current_request.borrow_mut(), &mut pending_request); - this.abort_request(State::Unavailable, ImageRequestPhase::Pending, CanGc::note()); } + this.abort_request(State::Unavailable, ImageRequestPhase::Pending, CanGc::note()); // Step 15.6 this.upcast::().dirty(NodeDamage::OtherNodeDamage);