sw/source/uibase/uno/unotxdoc.cxx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
New commits: commit 476bc04e6a9cde9b7424f118d6ef9422975be84a Author: Tamás Zolnai <tamas.zol...@collabora.com> AuthorDate: Mon Dec 28 14:28:06 2020 +0100 Commit: Tamás Zolnai <tamas.zol...@collabora.com> CommitDate: Tue Dec 29 08:32:26 2020 +0100 Fix crash in SwXTextDocument::getSelection() method. pWrtShell was nullptr. This crash was triggered by an collaborative editing use case. Change-Id: Id64298b424f5ac4d96df97581c6fe3067e799eb3 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/108417 Tested-by: Jenkins Reviewed-by: Tamás Zolnai <tamas.zol...@collabora.com> diff --git a/sw/source/uibase/uno/unotxdoc.cxx b/sw/source/uibase/uno/unotxdoc.cxx index 18f84f8c64df..338230b1173e 100644 --- a/sw/source/uibase/uno/unotxdoc.cxx +++ b/sw/source/uibase/uno/unotxdoc.cxx @@ -3581,7 +3581,7 @@ uno::Reference<datatransfer::XTransferable> SwXTextDocument::getSelection() uno::Reference<datatransfer::XTransferable> xTransferable; SwWrtShell* pWrtShell = m_pDocShell->GetWrtShell(); - if (SdrView* pSdrView = pWrtShell->GetDrawView()) + if (SdrView* pSdrView = pWrtShell ? pWrtShell->GetDrawView() : nullptr) { if (pSdrView->GetTextEditObject()) { _______________________________________________ Libreoffice-commits mailing list libreoffice-comm...@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits