summaryrefslogtreecommitdiff
path: root/sw/source
diff options
context:
space:
mode:
authorJan-Marek Glogowski <glogow@fbihome.de>2016-01-08 18:51:54 +0100
committerJan-Marek Glogowski <glogow@fbihome.de>2016-03-24 22:40:42 +0100
commit88761228addde6ac0425dd56381caf86922f7117 (patch)
treec5a41ca4e19293bc838709ae96c1242c48b48465 /sw/source
parentd97029895b3e3e6299e759e52629c04b1eac217f (diff)
MM: some assertion on MM input
Change-Id: Id29ede49acf86ad6109eab88fbae5d9bbb2d8720
Diffstat (limited to 'sw/source')
-rw-r--r--sw/source/uibase/dbui/dbmgr.cxx14
1 files changed, 13 insertions, 1 deletions
diff --git a/sw/source/uibase/dbui/dbmgr.cxx b/sw/source/uibase/dbui/dbmgr.cxx
index 8331a44637d1..fa9b346405c5 100644
--- a/sw/source/uibase/dbui/dbmgr.cxx
+++ b/sw/source/uibase/dbui/dbmgr.cxx
@@ -950,7 +950,19 @@ bool SwDBManager::MergeMailFiles(SwWrtShell* pSourceShell,
//check if the doc is synchronized and contains at least one linked section
const bool bSynchronizedDoc = pSourceShell->IsLabelDoc() && pSourceShell->GetSectionFormatCount() > 1;
const bool bNeedsTempFiles = ( bMT_EMAIL || bMT_FILE );
- const bool bCreateSingleFile = rMergeDescriptor.bCreateSingleFile;
+
+ bool bCheckSingleFile_ = rMergeDescriptor.bCreateSingleFile;
+ if( bMT_EMAIL )
+ {
+ assert( bMT_EMAIL && !bCheckSingleFile_ );
+ bCheckSingleFile_ = false;
+ }
+ else if( bMT_SHELL )
+ {
+ assert( bMT_SHELL && bCheckSingleFile_ );
+ bCheckSingleFile_ = true;
+ }
+ const bool bCreateSingleFile = bCheckSingleFile_;
// Setup for dumping debugging documents
static const char *sMaxDumpDocs = nullptr;