[Libreoffice-commits] core.git: sc/source
Eike Rathke
erack at redhat.com
Thu Jul 6 15:07:07 UTC 2017
sc/source/core/data/document.cxx | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
New commits:
commit d5020f35aec54f0241fa58557dc6caadc149f5a9
Author: Eike Rathke <erack at redhat.com>
Date: Thu Jul 6 17:06:14 2017 +0200
Attempt to blind fix tdf#108612 explicitly checking for clipboard document
It seems that for some yet unknown reason in an (un)certain constellation
ScDocument::IsClipboardSource() returns true because ScModule::GetClipDoc()
does not return the clipboard document but the actual document instead, so
destroying the clipboard document executes ScDocument::ClosingClipboardSource()
and (or in earlier versions) ScDocument::ForgetNoteCaptions() on the actual
document instead.
Check also that ScDocument::bIsClip is set, hopefully curing the symptom, the
real cause is something else.
Change-Id: I5ffd0706592d2737808e7004630a56c53115295b
diff --git a/sc/source/core/data/document.cxx b/sc/source/core/data/document.cxx
index c78e1db3acf9..93e75ed8e4c1 100644
--- a/sc/source/core/data/document.cxx
+++ b/sc/source/core/data/document.cxx
@@ -2543,7 +2543,7 @@ void ScDocument::SetClipParam(const ScClipParam& rParam)
bool ScDocument::IsClipboardSource() const
{
ScDocument* pClipDoc = ScModule::GetClipDoc();
- return xPoolHelper.is() && pClipDoc && pClipDoc->xPoolHelper.is() &&
+ return pClipDoc && pClipDoc->bIsClip && pClipDoc->xPoolHelper.is() && xPoolHelper.is() &&
xPoolHelper->GetDocPool() == pClipDoc->xPoolHelper->GetDocPool();
}
More information about the Libreoffice-commits
mailing list