X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/efbfda9d66e2de907cc773531c434583fbe1ad66..5955710c8bd346e8be675bd1dbbd427723a57920:/src/common/appcmn.cpp diff --git a/src/common/appcmn.cpp b/src/common/appcmn.cpp index d3d562d3e6..0f013b66d3 100644 --- a/src/common/appcmn.cpp +++ b/src/common/appcmn.cpp @@ -140,10 +140,10 @@ void wxAppBase::CleanUp() delete wxTheColourDatabase; wxTheColourDatabase = NULL; -#if wxUSE_THREADS delete wxPendingEvents; wxPendingEvents = NULL; +#if wxUSE_THREADS delete wxPendingEventsLocker; wxPendingEventsLocker = NULL; @@ -270,7 +270,7 @@ void wxAppBase::ExitMainLoop() #if wxUSE_EVTLOOP_IN_APP // we should exit from the main event loop, not just any currently active // (e.g. modal dialog) event loop - if ( m_mainLoop ) + if ( m_mainLoop && m_mainLoop->IsRunning() ) { m_mainLoop->Exit(0); }