diff options
author | Caolán McNamara <caolanm@redhat.com> | 2022-05-18 10:43:48 +0100 |
---|---|---|
committer | Caolán McNamara <caolanm@redhat.com> | 2022-08-26 22:44:56 +0200 |
commit | 327a87f51d5a35d6dee0e9038b26f989052f6e0c (patch) | |
tree | e54fda2c3f2132726a2a84524beb6462a96fc2fe /sw | |
parent | 872ea3ac4a45700f1cd23fec48b700ee10fda613 (diff) |
tdf#124300 survive update all
unsatisfactorily just route-one avoiding null derefs
Change-Id: I66153f3a16d53f245d538c407c512557b5ececc1
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/134518
Tested-by: Jenkins
Reviewed-by: Caolán McNamara <caolanm@redhat.com>
Diffstat (limited to 'sw')
-rw-r--r-- | sw/source/core/layout/findfrm.cxx | 4 | ||||
-rw-r--r-- | sw/source/core/layout/ftnfrm.cxx | 2 |
2 files changed, 3 insertions, 3 deletions
diff --git a/sw/source/core/layout/findfrm.cxx b/sw/source/core/layout/findfrm.cxx index 3d92f2a9ce0e..d6a70186231a 100644 --- a/sw/source/core/layout/findfrm.cxx +++ b/sw/source/core/layout/findfrm.cxx @@ -462,8 +462,8 @@ SwFootnoteBossFrame* SwFrame::FindFootnoteBossFrame( bool bFootnotes ) SwFrame *pRet = this; // Footnote bosses can't exist inside a table; also sections with columns // don't contain footnote texts there - if( pRet->IsInTab() ) - pRet = pRet->FindTabFrame(); + if (SwFrame *pTabFrame = pRet->IsInTab() ? pRet->FindTabFrame() : nullptr) + pRet = pTabFrame; // tdf139336: put the footnotes into the page frame (instead of a column frame) // to avoid maximizing the section to the full page.... if: diff --git a/sw/source/core/layout/ftnfrm.cxx b/sw/source/core/layout/ftnfrm.cxx index a6204e4008fe..9cc83c1bfc18 100644 --- a/sw/source/core/layout/ftnfrm.cxx +++ b/sw/source/core/layout/ftnfrm.cxx @@ -1181,7 +1181,7 @@ const SwFootnoteFrame *SwFootnoteBossFrame::FindFirstFootnote( SwContentFrame co if ( pRet ) { const SwFootnoteBossFrame* pBoss = pRet->GetRef()->FindFootnoteBossFrame(); - if( pBoss->GetPhyPageNum() != nPageNum || + if( !pBoss || pBoss->GetPhyPageNum() != nPageNum || nColNum != lcl_ColumnNum( pBoss ) ) pRet = nullptr; } |