From bc334f39ec4479e43e6aecd3925bd3dc516e26b8 Mon Sep 17 00:00:00 2001 From: Robin Dunn Date: Tue, 27 Apr 2004 20:02:41 +0000 Subject: [PATCH] Fixes Bug [ 930200 ] Async does not work Because the wxConsoleAppTraits was being created for GUI apps wxExecute would fail if the wxEXEC_ASYNC flags was used. git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@26991 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775 --- src/common/appbase.cpp | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/src/common/appbase.cpp b/src/common/appbase.cpp index a0d2dd9157..2917c634c1 100644 --- a/src/common/appbase.cpp +++ b/src/common/appbase.cpp @@ -109,6 +109,13 @@ wxAppConsole::wxAppConsole() #ifdef __WXDEBUG__ SetTraceMasks(); +#if wxUSE_UNICODE + // In unicode mode the SetTraceMasks call can cause an apptraits to be + // created, but since we are still in the constructor the wrong kind will + // be created for GUI apps. Destroy it so it can be created again later. + delete m_traits; + m_traits = NULL; +#endif #endif } -- 2.45.2