summaryrefslogtreecommitdiff
path: root/sw
diff options
context:
space:
mode:
authorMichael Stahl <Michael.Stahl@cib.de>2018-12-19 12:45:20 +0100
committerMichael Stahl <Michael.Stahl@cib.de>2018-12-19 15:53:07 +0100
commit6996cddfb8b1aa45c77caf6cdc973b1e548cfe86 (patch)
treee1bb64d65f6ebb68f035c8d292efddc84eeb6325 /sw
parent422b12bc13b34f4e99f79b2571b89296873ebe89 (diff)
sw: fix assert in SwViewShell::FillPrtDoc()
The point node isn't necessarily the start node; this will assert in SwTextFrame::MapModelToView: Assertion `SwFrame::GetDep() == pNode' failed when selecting a table and then File->Print->Print Selection. Thanks Samuel for the hint. (regression from 067a53bbcd209d7458b04142f989e1ff7ec1f785) Change-Id: I7f58b79e068e8b7817261e81f999721ebfcfdcf1 Reviewed-on: https://gerrit.libreoffice.org/65421 Tested-by: Jenkins Reviewed-by: Michael Stahl <Michael.Stahl@cib.de>
Diffstat (limited to 'sw')
-rw-r--r--sw/source/core/view/vprint.cxx3
1 files changed, 2 insertions, 1 deletions
diff --git a/sw/source/core/view/vprint.cxx b/sw/source/core/view/vprint.cxx
index 9fe798916ceb..c70574c85933 100644
--- a/sw/source/core/view/vprint.cxx
+++ b/sw/source/core/view/vprint.cxx
@@ -358,7 +358,8 @@ void SwViewShell::FillPrtDoc( SwDoc *pPrtDoc, const SfxPrinter* pPrt)
{
SwShellTableCursor* pShellTableCursor = pFESh->GetTableCursor();
- const SwContentNode* pContentNode = pShellTableCursor->GetNode().GetContentNode();
+ const SwContentNode *const pContentNode =
+ pShellTableCursor->Start()->nNode.GetNode().GetContentNode();
const SwContentFrame *const pContentFrame = pContentNode ? pContentNode->getLayoutFrame(GetLayout(), pShellTableCursor->Start()) : nullptr;
if( pContentFrame )
{