summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJulien Nabet <serval2412@yahoo.fr>2015-06-28 12:43:19 +0200
committerCaolán McNamara <caolanm@redhat.com>2015-07-02 15:50:49 +0000
commitde43a2fd64085c6887c66fede95ee9cdf0e431d4 (patch)
tree3941a1751666852a27a76f355b26ea3b3d5d808d
parent9ecdfc2a6d912eb8edcff76e85c999a6d2acae83 (diff)
tdf#92386: Writer crashes in print preview if document in 2 windows
2 changes for the 2 following bts First bt: see https://bugs.documentfoundation.org/attachment.cgi?id=116883 Second bt: see https://bugs.documentfoundation.org/attachment.cgi?id=116888 Reviewed-on: https://gerrit.libreoffice.org/16557 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Caolán McNamara <caolanm@redhat.com> Tested-by: Caolán McNamara <caolanm@redhat.com> (cherry picked from commit cb813b392d1f59ad8927b87e899d8a33d1db2504) Change-Id: I92ed3b7305bb5b714532f2dcffd615a8337db8b6 Reviewed-on: https://gerrit.libreoffice.org/16618 Reviewed-by: Caolán McNamara <caolanm@redhat.com> Tested-by: Caolán McNamara <caolanm@redhat.com>
-rw-r--r--sw/source/uibase/app/docsh.cxx6
1 files changed, 6 insertions, 0 deletions
diff --git a/sw/source/uibase/app/docsh.cxx b/sw/source/uibase/app/docsh.cxx
index 1879e7e00d5c..eb680fa9817c 100644
--- a/sw/source/uibase/app/docsh.cxx
+++ b/sw/source/uibase/app/docsh.cxx
@@ -1270,11 +1270,17 @@ const ::sfx2::IXmlIdRegistry* SwDocShell::GetXmlIdRegistry() const
bool SwDocShell::IsChangeRecording() const
{
+ if (!mpWrtShell)
+ return false;
+
return (mpWrtShell->GetRedlineMode() & nsRedlineMode_t::REDLINE_ON) != 0;
}
bool SwDocShell::HasChangeRecordProtection() const
{
+ if (!mpWrtShell)
+ return false;
+
return mpWrtShell->getIDocumentRedlineAccess()->GetRedlinePassword().getLength() > 0;
}