From cb3a14436fe3d073ca1be4ad1e4aca2df32d318b Mon Sep 17 00:00:00 2001 From: Nick Gammon Date: Wed, 23 Jun 2010 12:36:49 +1000 Subject: [PATCH] Fixed memory leak in processing XML with paste button --- dialogs/world_prefs/genpropertypage.cpp | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/dialogs/world_prefs/genpropertypage.cpp b/dialogs/world_prefs/genpropertypage.cpp index 897553d2..5857101f 100644 --- a/dialogs/world_prefs/genpropertypage.cpp +++ b/dialogs/world_prefs/genpropertypage.cpp @@ -954,10 +954,11 @@ CString strContents; { iCount = m_doc->Load_World_XML (ar, m_iMask | XML_NO_PLUGINS); } - catch (CArchiveException* ) + catch (CArchiveException* e) { ::TMessageBox ("There was a problem parsing the XML on the clipboard. " "See the error window for more details"); + e->Delete (); } if (iCount == 0)