From 389a8d52d9961f89c0b2847b30ee1ca59a8fdc80 Mon Sep 17 00:00:00 2001 From: Caolán McNamara Date: Thu, 1 Jun 2023 20:49:22 +0100 Subject: Related: tdf#122081 null-deref of SwFootnoteFrame MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit load doc, ctrl+end, ctrl+home, ctrl+6 enter 29, return, wheel scroll down 7 or 8 times and this null-deref Change-Id: I1963a89e3223de89f3414e435accd8d8ebfe80a9 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/152511 Tested-by: Jenkins Reviewed-by: Caolán McNamara --- sw/source/core/text/txtftn.cxx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'sw/source') diff --git a/sw/source/core/text/txtftn.cxx b/sw/source/core/text/txtftn.cxx index c86c1bc4ab0d..035158e2bd25 100644 --- a/sw/source/core/text/txtftn.cxx +++ b/sw/source/core/text/txtftn.cxx @@ -664,7 +664,7 @@ void SwTextFrame::ConnectFootnote( SwTextFootnote *pFootnote, const SwTwips nDea mbInFootnoteConnect = false; return; } - else if( pSrcFrame ) + else if (pSrcFrame && pFootnoteFrame) { SwFootnoteBossFrame *pFootnoteBoss = pFootnoteFrame->FindFootnoteBossFrame(); if( !pFootnoteBoss->IsInSct() || -- cgit