[Libreoffice-commits] core.git: sw/source
Aron Budea (via logerrit)
logerrit at kemper.freedesktop.org
Thu Oct 15 19:56:48 UTC 2020
sw/source/uibase/sidebar/WriterInspectorTextPanel.cxx | 6 +++---
1 file changed, 3 insertions(+), 3 deletions(-)
New commits:
commit df74aef7159d7155addf78cfc4d139485945d794
Author: Aron Budea <aron.budea at collabora.com>
AuthorDate: Thu Oct 15 08:19:39 2020 +0200
Commit: Aron Budea <aron.budea at collabora.com>
CommitDate: Thu Oct 15 21:56:12 2020 +0200
tdf#137105: crash in table with Style Inspector active
xParaEnum->nextElement() is not an XTextRange then, it'd be
an XTextTable. Since the Style Inspector doesn't support
inspecting table properties, yet, simply avoid that case.
Change-Id: I4ae211713433ccc30d397c04f6cbf7f1f4d1f9e7
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/104327
Tested-by: Jenkins
Reviewed-by: Aron Budea <aron.budea at collabora.com>
diff --git a/sw/source/uibase/sidebar/WriterInspectorTextPanel.cxx b/sw/source/uibase/sidebar/WriterInspectorTextPanel.cxx
index d7b3990aa5e3..6dfaf8ccd966 100644
--- a/sw/source/uibase/sidebar/WriterInspectorTextPanel.cxx
+++ b/sw/source/uibase/sidebar/WriterInspectorTextPanel.cxx
@@ -500,9 +500,9 @@ static void UpdateTree(SwDocShell* pDocSh, std::vector<svx::sidebar::TreeNode>&
// Collect paragraph direct formatting
uno::Reference<container::XEnumerationAccess> xParaEnumAccess(xRange, uno::UNO_QUERY_THROW);
uno::Reference<container::XEnumeration> xParaEnum = xParaEnumAccess->createEnumeration();
- uno::Reference<text::XTextRange> xThisParagraphRange(xParaEnum->nextElement(),
- uno::UNO_QUERY_THROW);
- InsertValues(xThisParagraphRange, aIsDefined, aParaDFNode, false, aHiddenProperties);
+ uno::Reference<text::XTextRange> xThisParagraphRange(xParaEnum->nextElement(), uno::UNO_QUERY);
+ if (xThisParagraphRange.is())
+ InsertValues(xThisParagraphRange, aIsDefined, aParaDFNode, false, aHiddenProperties);
xStyleFamily.set(xStyleFamilies->getByName("ParagraphStyles"), uno::UNO_QUERY_THROW);
More information about the Libreoffice-commits
mailing list