[Libreoffice-commits] core.git: sw/source

Chris Sherlock chris.sherlock79 at gmail.com
Thu May 1 09:06:33 PDT 2014


 sw/source/core/crsr/crsrsh.cxx |    3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

New commits:
commit 6b431b1f0d397067504b5300d49e10e232936836
Author: Chris Sherlock <chris.sherlock79 at gmail.com>
Date:   Fri May 2 02:01:24 2014 +1000

    coverity#708922 Use after free
    
    Change-Id: I54c098ca4744d33d2f8e1a7799ba6bd5620ed987

diff --git a/sw/source/core/crsr/crsrsh.cxx b/sw/source/core/crsr/crsrsh.cxx
index fe86bd3..c2d2639 100644
--- a/sw/source/core/crsr/crsrsh.cxx
+++ b/sw/source/core/crsr/crsrsh.cxx
@@ -2511,8 +2511,9 @@ void SwCrsrShell::_ParkPams( SwPaM* pDelRg, SwShellCrsr** ppDelRing )
             }
             pTmpDel = 0;
         }
-        if( bGoNext )
+        if( bGoNext && !bDelete )
             pTmp = (SwPaM*)pTmp->GetNext();
+
     } while( !bGoNext || *ppDelRing != pTmp );
 }
 


More information about the Libreoffice-commits mailing list