summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--src/mir_app/src/options.cpp3
1 files changed, 3 insertions, 0 deletions
diff --git a/src/mir_app/src/options.cpp b/src/mir_app/src/options.cpp
index 1514647c0b..e1a0fa1c97 100644
--- a/src/mir_app/src/options.cpp
+++ b/src/mir_app/src/options.cpp
@@ -226,6 +226,9 @@ struct OptionsPageData : public MZeroedObject
~OptionsPageData()
{
+ // if a dialog has window, it will be killed by WM_CLOSE event
+ if (pDialog && !pDialog->GetHwnd())
+ delete pDialog;
}
CDlgBase *pDialog;