diff --git a/AK/NonnullRefPtr.h b/AK/NonnullRefPtr.h index a055ccc681..9514a6da72 100644 --- a/AK/NonnullRefPtr.h +++ b/AK/NonnullRefPtr.h @@ -136,7 +136,7 @@ public: { if (this != static_cast(&other)) { deref_if_not_null(m_ptr); - m_ptr = &other.leak_ref(); + m_ptr = static_cast(&other.leak_ref()); } return *this; }