Catch exception when signal is used in the non-main thread

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/branches/WX_2_4_BRANCH@23835 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
Robin Dunn
2003-09-22 22:26:08 +00:00
parent 78856556a9
commit 52245f7a59
2 changed files with 10 additions and 4 deletions

View File

@@ -976,8 +976,11 @@ of your Mac."""
# KeyboardInterrupt???) but will later segfault on exit. By
# setting the default handler then the app will exit, as
# expected (depending on platform.)
import signal
signal.signal(signal.SIGINT, signal.SIG_DFL)
try:
import signal
signal.signal(signal.SIGINT, signal.SIG_DFL)
except:
pass
# this initializes wxWindows and then calls our OnInit
_wxStart(self.OnInit)