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

Michael Stahl mstahl at redhat.com
Mon May 18 03:33:37 PDT 2015


 sw/source/core/doc/docbm.cxx |    2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

New commits:
commit 277945413e8f8ba0573be143db877007f8517221
Author: Michael Stahl <mstahl at redhat.com>
Date:   Fri May 15 23:57:04 2015 +0200

    tdf#90808: sw: fix detection of duplicate CrossRefBookmarks
    
    The check for existing bookmark positions is using the wrong position.
    It must use the Start of the pam, because the constructor of
    CrossRefBookmark only uses the Start of the pam.
    
    (cherry picked from commit 9d0c51daea67104349cac26de9839afa8baeb099)
    
    Conflicts:
    	sw/source/core/doc/docbm.cxx
    
    Change-Id: I343f1c0e3571847a965a27571f01136810e83485
    Reviewed-on: https://gerrit.libreoffice.org/15745
    Reviewed-by: Caolán McNamara <caolanm at redhat.com>
    Tested-by: Caolán McNamara <caolanm at redhat.com>

diff --git a/sw/source/core/doc/docbm.cxx b/sw/source/core/doc/docbm.cxx
index 9567c3a..ce0ff19 100644
--- a/sw/source/core/doc/docbm.cxx
+++ b/sw/source/core/doc/docbm.cxx
@@ -377,7 +377,7 @@ namespace sw { namespace mark
             " - more than USHRT_MAX marks are not supported correctly");
         // There should only be one CrossRefBookmark per Textnode per Type
         if ((eType == CROSSREF_NUMITEM_BOOKMARK || eType == CROSSREF_HEADING_BOOKMARK)
-            && (lcl_FindMarkAtPos(m_vBookmarks, *rPaM.GetPoint(), eType) != m_vBookmarks.end()))
+            && (lcl_FindMarkAtPos(m_vBookmarks, *rPaM.Start(), eType) != m_vBookmarks.end()))
         {   // this can happen via UNO API
             SAL_WARN("sw.core", "MarkManager::makeMark(..)"
                 " - refusing to create duplicate CrossRefBookmark");


More information about the Libreoffice-commits mailing list