summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorLuke Dashjr <[email protected]>2019-04-21 23:46:48 +0900
committerMichele Calgaro <[email protected]>2019-04-21 23:54:57 +0900
commit54a0f4558722d57bd826f3ae916701213c435a8d (patch)
treea652cdf77b6c12f4774973921dd7dff33c40a1a3
parentb7254a04f13cc63478bb5c97e65fff66f0e08d68 (diff)
downloadtdepim-54a0f4558722d57bd826f3ae916701213c435a8d.tar.gz
tdepim-54a0f4558722d57bd826f3ae916701213c435a8d.zip
Bugfix: KMail: Detach from message observation when destructing KMReaderWin
Signed-off-by: Luke Dashjr <[email protected]> (cherry picked from commit e53303b9298bc47bd864caea6725ff09c5c6e6bb)
-rw-r--r--kmail/kmreaderwin.cpp3
1 files changed, 3 insertions, 0 deletions
diff --git a/kmail/kmreaderwin.cpp b/kmail/kmreaderwin.cpp
index 6c5acd10c..b3c435703 100644
--- a/kmail/kmreaderwin.cpp
+++ b/kmail/kmreaderwin.cpp
@@ -780,6 +780,9 @@ void KMReaderWin::slotCycleAttachmentStrategy() {
//-----------------------------------------------------------------------------
KMReaderWin::~KMReaderWin()
{
+ if (message()) {
+ message()->detach( this );
+ }
clearBodyPartMementos();
delete mHtmlWriter; mHtmlWriter = 0;
delete mCSSHelper;