summaryrefslogtreecommitdiff
path: root/sw/source
diff options
context:
space:
mode:
authorCaolán McNamara <caolanm@redhat.com>2016-06-16 14:17:42 +0100
committerCaolán McNamara <caolanm@redhat.com>2016-06-16 14:18:57 +0100
commitf04c48a7e764775bdd98715e5d17845f1786bd44 (patch)
treebddb5136cf7a02891db375b1da965a587a951a04 /sw/source
parent8132c691dea66f9e402161ff8fac8e31f313b72d (diff)
Resolves: tdf#100422 crash if you exit mail merge wizard...
after loading previous document or template Change-Id: I3bdd1159e367b0297aee84763bf5c4312e9e91fa
Diffstat (limited to 'sw/source')
-rw-r--r--sw/source/uibase/app/apphdl.cxx17
1 files changed, 10 insertions, 7 deletions
diff --git a/sw/source/uibase/app/apphdl.cxx b/sw/source/uibase/app/apphdl.cxx
index 8f93cdb42cc7..9bc5ec11cec6 100644
--- a/sw/source/uibase/app/apphdl.cxx
+++ b/sw/source/uibase/app/apphdl.cxx
@@ -592,16 +592,19 @@ IMPL_STATIC_LINK_TYPED(SwMailMergeWizardExecutor, DestroyWizardHdl, void*, pDial
IMPL_LINK_NOARG_TYPED(SwMailMergeWizardExecutor, CancelHdl, void*, void)
{
- SwMailMergeConfigItem* pMMConfig = m_pView->GetMailMergeConfigItem();
- if (pMMConfig->GetTargetView())
+ if (SwMailMergeConfigItem* pMMConfig = m_pView->GetMailMergeConfigItem())
{
- pMMConfig->GetTargetView()->GetViewFrame()->DoClose();
- pMMConfig->SetTargetView(nullptr);
+ if (pMMConfig->GetTargetView())
+ {
+ pMMConfig->GetTargetView()->GetViewFrame()->DoClose();
+ pMMConfig->SetTargetView(nullptr);
+ }
+ if (pMMConfig->GetSourceView())
+ pMMConfig->GetSourceView()->GetViewFrame()->GetFrame().AppearWithUpdate();
+
+ pMMConfig->Commit();
}
- if (pMMConfig->GetSourceView())
- pMMConfig->GetSourceView()->GetViewFrame()->GetFrame().AppearWithUpdate();
- pMMConfig->Commit();
delete m_pWizard;
m_pWizard = nullptr;
release();