]> git.saurik.com Git - wxWidgets.git/commitdiff
fix 10.2 shared builds from crashing
authorRyan Norton <wxprojects@comcast.net>
Sun, 17 Apr 2005 18:39:07 +0000 (18:39 +0000)
committerRyan Norton <wxprojects@comcast.net>
Sun, 17 Apr 2005 18:39:07 +0000 (18:39 +0000)
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@33719 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775

src/common/appbase.cpp
src/mac/carbon/thread.cpp

index ee78eb257c32e94ca252aff8bdde098feb24df2d..118feac7adbf3aaf5485c211920827c49b6bb642 100644 (file)
@@ -269,6 +269,9 @@ wxMessageOutput *wxAppConsole::CreateMessageOutput()
 
 void wxAppConsole::ProcessPendingEvents()
 {
+    if ( !wxPendingEventsLocker )
+        return;
+    
     // ensure that we're the only thread to modify the pending events list
     wxENTER_CRIT_SECT( *wxPendingEventsLocker );
 
index 3700a9a375845a004f49ae571596eb86d267e22c..cb8ecb4c2d523b4ef4540c070d309843ff65b583 100644 (file)
@@ -1721,6 +1721,9 @@ void WXDLLIMPEXP_BASE wxMutexGuiLeaveOrEnter()
     wxASSERT_MSG( wxThread::IsMain(),
                   wxT("only main thread may call wxMutexGuiLeaveOrEnter()!") );
 
+    if( !gs_critsectWaitingForGui )
+        return;
+        
     wxCriticalSectionLocker enter(*gs_critsectWaitingForGui);
 
     if ( gs_nWaitingForGui == 0 )