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

New commits:
commit 96c97930d8914d4cfca165c50106308aa9fbf1bb
Author:     Caolán McNamara <[email protected]>
AuthorDate: Mon Jul 18 09:07:49 2022 +0100
Commit:     Caolán McNamara <[email protected]>
CommitDate: Mon Jul 18 11:46:56 2022 +0200

    cid#1507355 Dereference after null check
    
    we always derefed pSObj before:
    
    commit 1d3d2a995239c3c71432006cb795324c56a0412a
    Date:   Mon Jun 20 17:27:53 2022 +0200
    
        tdf#148687 tdf#149173 tdf#149546 sw: fix crash with textboxes
    
    so lets assume that state was sensible and drop the additional null
    check introduced there
    
    Change-Id: Ief8ce89e729d6fc51a9d8b7ae2dca18452667cb2
    Reviewed-on: https://gerrit.libreoffice.org/c/core/+/137165
    Tested-by: Jenkins
    Reviewed-by: Caolán McNamara <[email protected]>

diff --git a/sw/source/core/edit/edundo.cxx b/sw/source/core/edit/edundo.cxx
index 2614e500543b..dc32e7bef4cc 100644
--- a/sw/source/core/edit/edundo.cxx
+++ b/sw/source/core/edit/edundo.cxx
@@ -66,7 +66,7 @@ void SwEditShell::HandleUndoRedoContext(::sw::UndoRedoContext 
& rContext)
 
             // Before layout calc, inline anchored textboxes have to be synced 
unless crash.
             if (pSelFormat->GetAnchor().GetAnchorId() == RndStdIds::FLY_AS_CHAR
-                && pSelFormat->GetOtherTextBoxFormats() && pSObj)
+                && pSelFormat->GetOtherTextBoxFormats())
                 
SwTextBoxHelper::synchronizeGroupTextBoxProperty(SwTextBoxHelper::changeAnchor,
                                                                  pSelFormat, 
pSObj);
 

Reply via email to