[Libreoffice-commits] core.git: Branch 'libreoffice-5-4' - sw/source

Caolán McNamara caolanm at redhat.com
Thu Dec 7 21:12:25 UTC 2017


 sw/source/core/tox/ToxTextGenerator.cxx |    4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

New commits:
commit 534fd9aacd3eea10070a3ee88fc654eb9791aa24
Author: Caolán McNamara <caolanm at redhat.com>
Date:   Wed Dec 6 17:05:24 2017 +0000

    table of objects crashes on first update with object in document
    
    Change-Id: Ia25a09060f16e5d286dff2bbc3facba5ac68cdc4
    Reviewed-on: https://gerrit.libreoffice.org/45973
    Tested-by: Jenkins <ci at libreoffice.org>
    Reviewed-by: Michael Stahl <mstahl at redhat.com>

diff --git a/sw/source/core/tox/ToxTextGenerator.cxx b/sw/source/core/tox/ToxTextGenerator.cxx
index 2aa7f657d82d..9acb74b6a772 100644
--- a/sw/source/core/tox/ToxTextGenerator.cxx
+++ b/sw/source/core/tox/ToxTextGenerator.cxx
@@ -303,8 +303,8 @@ ToxTextGenerator::HandleTextToken(const SwTOXSortTabBase& source, SwAttrPool& po
     if( source.aTOXSources.empty() )
         return result;
 
-    const SwTextNode* pSrc = source.aTOXSources.at(0).pNd->GetTextNode();
-    if (!pSrc->HasHints()) {
+    const SwTextNode* pSrc = source.aTOXSources.front().pNd->GetTextNode();
+    if (!pSrc || !pSrc->HasHints()) {
         return result;
     }
     const SwpHints& hints = pSrc->GetSwpHints();


More information about the Libreoffice-commits mailing list