diff options
author | Caolán McNamara <caolanm@redhat.com> | 2018-02-20 21:14:08 +0000 |
---|---|---|
committer | Caolán McNamara <caolanm@redhat.com> | 2018-02-21 18:22:01 +0100 |
commit | 34627ad7d03f93b89689b2e48a3985574d10f965 (patch) | |
tree | 08f82b3c9370d68b7e288df47d0a0c7a701ab3e0 | |
parent | ddbb78caa78085673b07dbea6f53288ec6237764 (diff) |
forcepoint #3
Thanks to Antti Levomäki and Christian Jalio from Forcepoint.
Change-Id: I5681f9123a21fee100a2eda1e8284e559ede51b4
Reviewed-on: https://gerrit.libreoffice.org/50064
Reviewed-by: Caolán McNamara <caolanm@redhat.com>
Tested-by: Caolán McNamara <caolanm@redhat.com>
-rw-r--r-- | sw/source/core/layout/ftnfrm.cxx | 13 |
1 files changed, 5 insertions, 8 deletions
diff --git a/sw/source/core/layout/ftnfrm.cxx b/sw/source/core/layout/ftnfrm.cxx index e8eddce278c1..206e9deac04e 100644 --- a/sw/source/core/layout/ftnfrm.cxx +++ b/sw/source/core/layout/ftnfrm.cxx @@ -792,14 +792,11 @@ bool SwFrame::IsFootnoteAllowed() const if ( !IsInDocBody() ) return false; - if ( IsInTab() ) - { - // no footnotes in repeated headlines - const SwTabFrame *pTab = const_cast<SwFrame*>(this)->ImplFindTabFrame(); - assert(pTab); - if ( pTab->IsFollow() ) - return !pTab->IsInHeadline( *this ); - } + // no footnotes in repeated headlines + const SwTabFrame *pTab = IsInTab() ? const_cast<SwFrame*>(this)->ImplFindTabFrame() : nullptr; + if (pTab && pTab->IsFollow()) + return !pTab->IsInHeadline( *this ); + return true; } |