mirror of
https://github.com/RGBCube/serenity
synced 2025-07-27 10:07:44 +00:00
AK: Fix NonnullRefPtr<T>::operator=(NonnullRefPtr<U>).
This commit is contained in:
parent
d6cd98cfa1
commit
fc9a1a1328
1 changed files with 1 additions and 1 deletions
|
@ -102,7 +102,7 @@ public:
|
|||
template<typename U>
|
||||
NonnullRefPtr& operator=(const NonnullRefPtr<U>& other)
|
||||
{
|
||||
if (m_ptr != other.m_ptr) {
|
||||
if (m_ptr != other.ptr()) {
|
||||
deref_if_not_null(m_ptr);
|
||||
m_ptr = const_cast<T*>(static_cast<const T*>(other.ptr()));
|
||||
m_ptr->ref();
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue