]> git.saurik.com Git - wxWidgets.git/blobdiff - src/common/object.cpp
Added missing test in wxObject::Ref() for already
[wxWidgets.git] / src / common / object.cpp
index 1fe178f04f95efbd4d6b588647fbd164a4e47fbf..01047a1f73d308a6bf96934f9d43da9e36527b05 100644 (file)
@@ -230,6 +230,10 @@ void wxObject::Ref(const wxObject& clone)
     DEBUG_PRINTF(wxObject::Ref)
 #endif
 
+    // nothing to be done
+    if (m_refData == clone.m_refData)
+        return;
+
     // delete reference to old data
     UnRef();