From 840657b11cca8689aab2d3f96dc417aac5ab5076 Mon Sep 17 00:00:00 2001 From: cncfanatics Date: Sun, 29 Aug 2010 16:01:09 +0200 Subject: [PATCH] Don't let PyDeadObjectError get through, they're harmless anyway on closing the app --- gui/mainFrame.py | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/gui/mainFrame.py b/gui/mainFrame.py index f89b6cbbf..169fc123b 100644 --- a/gui/mainFrame.py +++ b/gui/mainFrame.py @@ -27,6 +27,7 @@ from gui.statsPane import StatsPane from gui.shipBrowser import ShipBrowser from wx.lib.wordwrap import wordwrap import aboutData +from wx._core import PyDeadObjectError class MainFrame(wx.Frame): __instance = None @@ -87,7 +88,10 @@ class MainFrame(wx.Frame): self.notebookBrowsers.SetSelection(tab) def ExitApp(self, evt): - self.Close() + try: + self.Close() + except PyDeadObjectError: + pass def ShowAboutBox(self, evt): info = wx.AboutDialogInfo()