From: Vadim Zeitlin Date: Sat, 13 Jun 2009 00:33:07 +0000 (+0000) Subject: fix compilation after wxRefCounter changes X-Git-Url: https://git.saurik.com/wxWidgets.git/commitdiff_plain/deff6d72e5521961b1e7c1dc42bbf0fa54d66373 fix compilation after wxRefCounter changes git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@61037 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775 --- diff --git a/src/common/object.cpp b/src/common/object.cpp index bfb7034487..622aa2f2eb 100644 --- a/src/common/object.cpp +++ b/src/common/object.cpp @@ -350,8 +350,10 @@ wxClassInfo::const_iterator wxClassInfo::end_classinfo() // wxObjectRefData // ---------------------------------------------------------------------------- -void wxObjectRefData::DecRef() +void wxRefCounter::DecRef() { + wxASSERT_MSG( m_count > 0, "invalid ref data count" ); + if ( --m_count == 0 ) delete this; } @@ -386,8 +388,6 @@ void wxObject::UnRef() { if ( m_refData ) { - wxASSERT_MSG( m_refData->m_count > 0, _T("invalid ref data count") ); - m_refData->DecRef(); m_refData = NULL; }