git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@16868
c3d73ce0-8a6f-49c7-b76d-
6d57e0e08775
wxLogMessage( wxT("----- Memory dump -----") );
}
}
wxLogMessage( wxT("----- Memory dump -----") );
}
}
TraverseList ((PmSFV)&wxMemStruct::Dump, (checkPoint ? checkPoint->m_next : (wxMemStruct*)NULL));
wxLogMessage( wxT("") );
TraverseList ((PmSFV)&wxMemStruct::Dump, (checkPoint ? checkPoint->m_next : (wxMemStruct*)NULL));
wxLogMessage( wxT("") );
-static bool memSectionOk = false;
+static bool memSectionOk = FALSE;
class MemoryCriticalSection : public wxCriticalSection
{
public:
MemoryCriticalSection() {
class MemoryCriticalSection : public wxCriticalSection
{
public:
MemoryCriticalSection() {
inline MemoryCriticalSectionLocker(wxCriticalSection& critsect)
: m_critsect(critsect), m_locked(memSectionOk) { if(m_locked) m_critsect.Enter(); }
inline ~MemoryCriticalSectionLocker() { if(m_locked) m_critsect.Leave(); }
inline MemoryCriticalSectionLocker(wxCriticalSection& critsect)
: m_critsect(critsect), m_locked(memSectionOk) { if(m_locked) m_critsect.Enter(); }
inline ~MemoryCriticalSectionLocker() { if(m_locked) m_critsect.Leave(); }
private:
// no assignment operator nor copy ctor
MemoryCriticalSectionLocker(const MemoryCriticalSectionLocker&);
MemoryCriticalSectionLocker& operator=(const MemoryCriticalSectionLocker&);
private:
// no assignment operator nor copy ctor
MemoryCriticalSectionLocker(const MemoryCriticalSectionLocker&);
MemoryCriticalSectionLocker& operator=(const MemoryCriticalSectionLocker&);
wxCriticalSection& m_critsect;
bool m_locked;
};
wxCriticalSection& m_critsect;
bool m_locked;
};
#if wxUSE_THREADS
MemoryCriticalSectionLocker lock(memLocker);
#endif
#if wxUSE_THREADS
MemoryCriticalSectionLocker lock(memLocker);
#endif
// If not in debugging allocation mode, do the normal thing
// so we don't leave any trace of ourselves in the node list.
// If not in debugging allocation mode, do the normal thing
// so we don't leave any trace of ourselves in the node list.
#if wxUSE_THREADS
MemoryCriticalSectionLocker lock(memLocker);
#endif
#if wxUSE_THREADS
MemoryCriticalSectionLocker lock(memLocker);
#endif