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

Caolán McNamara caolanm at redhat.com
Sat Jun 11 10:08:26 UTC 2016


 sw/source/core/doc/DocumentContentOperationsManager.cxx |    9 ++++++---
 1 file changed, 6 insertions(+), 3 deletions(-)

New commits:
commit 63c693a09f9fc816c8d392d82855fab6f561392c
Author: Caolán McNamara <caolanm at redhat.com>
Date:   Fri Jun 10 14:56:54 2016 +0100

    Resolves: tdf#100275 makeMark may return null under some circumstances
    
    Change-Id: If3b83413c028c6cd1c055e632b6f050ec7f2475d
    (cherry picked from commit 5c1a1d1c66aff497702abc20df5832fa348f1008)
    (cherry picked from commit 61a98b7bb14986f6c7c218effacabbe4b925f6b6)
    Reviewed-on: https://gerrit.libreoffice.org/26166
    Tested-by: Jenkins <ci at libreoffice.org>
    Reviewed-by: Markus Mohrhard <markus.mohrhard at googlemail.com>

diff --git a/sw/source/core/doc/DocumentContentOperationsManager.cxx b/sw/source/core/doc/DocumentContentOperationsManager.cxx
index 2138bf3e6..7894515 100644
--- a/sw/source/core/doc/DocumentContentOperationsManager.cxx
+++ b/sw/source/core/doc/DocumentContentOperationsManager.cxx
@@ -253,9 +253,12 @@ namespace
                 aTmpPam,
                 pMark->GetName(),
                 IDocumentMarkAccess::GetType(*pMark));
-            // Explicitly try to get exactly the same name as in the source
-            // because NavigatorReminders, DdeBookmarks etc. ignore the proposed name
-            pDestDoc->getIDocumentMarkAccess()->renameMark(pNewMark, pMark->GetName());
+            if (pNewMark)
+            {
+                // Explicitly try to get exactly the same name as in the source
+                // because NavigatorReminders, DdeBookmarks etc. ignore the proposed name
+                pDestDoc->getIDocumentMarkAccess()->renameMark(pNewMark, pMark->GetName());
+            }
 
             // copying additional attributes for bookmarks or fieldmarks
             ::sw::mark::IBookmark* const pNewBookmark =


More information about the Libreoffice-commits mailing list