sc/source/ui/unoobj/viewuno.cxx |    2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

New commits:
commit 71835fd8b5b04651e5be38b3b26a8dc80f5c3355
Author: Markus Mohrhard <markus.mohrh...@googlemail.com>
Date:   Sat Jul 30 03:03:55 2016 +0200

    missing nullptr check
    
    See
    
http://crashreport.libreoffice.org/stats/signature/ScPreviewObj::getSelectedSheets%28%29
    
    Change-Id: I210426b8ac23fdf6b1195afe7dbc388802335e71
    Reviewed-on: https://gerrit.libreoffice.org/27711
    Tested-by: Jenkins <c...@libreoffice.org>
    Reviewed-by: Markus Mohrhard <markus.mohrh...@googlemail.com>

diff --git a/sc/source/ui/unoobj/viewuno.cxx b/sc/source/ui/unoobj/viewuno.cxx
index 4c2ffcb..f9081072 100644
--- a/sc/source/ui/unoobj/viewuno.cxx
+++ b/sc/source/ui/unoobj/viewuno.cxx
@@ -2343,7 +2343,7 @@ void ScPreviewObj::Notify(SfxBroadcaster&, const SfxHint& 
rHint)
 uno::Sequence<sal_Int32> ScPreviewObj::getSelectedSheets()
     throw (uno::RuntimeException, std::exception)
 {
-    ScPreview* p = mpViewShell->GetPreview();
+    ScPreview* p = mpViewShell ? mpViewShell->GetPreview() : nullptr;
     if (!p)
         return uno::Sequence<sal_Int32>();
 
_______________________________________________
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits

Reply via email to