From a9e828fa5bdf1f6dabf65d5de0791a28e5863587 Mon Sep 17 00:00:00 2001 From: lucasmerlin Date: Mon, 23 Mar 2026 14:26:07 +0100 Subject: [PATCH] Fix stackoverflow on display handle clone call --- crates/egui-wgpu/src/setup.rs | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/crates/egui-wgpu/src/setup.rs b/crates/egui-wgpu/src/setup.rs index 29a04e8bc..749d3cf84 100644 --- a/crates/egui-wgpu/src/setup.rs +++ b/crates/egui-wgpu/src/setup.rs @@ -25,7 +25,8 @@ pub trait EguiDisplayHandle: impl Clone for Box { fn clone(&self) -> Self { - self.clone_display_handle() + // We need to deref here, otherwise this causes infinite recursion stack overflow. + (**self).clone_display_handle() } }