Applied memory allocation patch, and worked around bug that crashes memcheck.cpp
by using wxLogStderr. git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@8286 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
@@ -93,10 +93,17 @@ bool MyApp::OnInit(void)
|
||||
|
||||
const char *data = (const char*) thing ;
|
||||
|
||||
// On MSW, Dump() crashes if using wxLogGui,
|
||||
// so use wxLogStderr instead.
|
||||
wxLog* oldLog = wxLog::SetActiveTarget(new wxLogStderr);
|
||||
|
||||
wxDebugContext::PrintClasses();
|
||||
wxDebugContext::Dump();
|
||||
wxDebugContext::PrintStatistics();
|
||||
|
||||
// Set back to wxLogGui
|
||||
delete wxLog::SetActiveTarget(oldLog);
|
||||
|
||||
// Don't delete these objects, to force wxApp to flag a memory leak.
|
||||
// delete thing;
|
||||
// delete date;
|
||||
|
Reference in New Issue
Block a user