diff options
author | Michael Stahl <mstahl@redhat.com> | 2015-10-28 14:15:01 +0100 |
---|---|---|
committer | Miklos Vajna <vmiklos@collabora.co.uk> | 2015-11-02 08:40:55 +0000 |
commit | e0b9abe1f9cfcf6b43ea3bfc7ae47f649c0992bb (patch) | |
tree | 39cc4f5bdb661407d9d73463ea51e4ff389c0196 /sw/source | |
parent | f4e658ec2e0b6885ec461d5c3e2bc0e2b1d5c649 (diff) |
tdf#94871: sw: fix a frame formatting regression that affects help
The early return must also be taken if the anchor is neither AT_CHAR nor
AT_PARA.
(regression from a219bbb62f974020fac0799143fbc51c385bb460)
(cherry picked from commit 9092f96c63c05833ee5319935da1078afe216b55)
Change-Id: I4eccb1f80401ba620ef87342f40c1a896918f3d3
Reviewed-on: https://gerrit.libreoffice.org/19687
Reviewed-by: Miklos Vajna <vmiklos@collabora.co.uk>
Tested-by: Miklos Vajna <vmiklos@collabora.co.uk>
Diffstat (limited to 'sw/source')
-rw-r--r-- | sw/source/core/text/itratr.cxx | 14 |
1 files changed, 8 insertions, 6 deletions
diff --git a/sw/source/core/text/itratr.cxx b/sw/source/core/text/itratr.cxx index 2a97c4481b1e..4ee3b7f363f5 100644 --- a/sw/source/core/text/itratr.cxx +++ b/sw/source/core/text/itratr.cxx @@ -435,15 +435,17 @@ static void lcl_MinMaxNode( SwFrmFmt* pNd, SwMinMaxNodeArgs* pIn ) { const SwFmtAnchor& rFmtA = pNd->GetAnchor(); - if ((FLY_AT_PARA == rFmtA.GetAnchorId()) || - (FLY_AT_CHAR == rFmtA.GetAnchorId())) + if ((FLY_AT_PARA != rFmtA.GetAnchorId()) && + (FLY_AT_CHAR != rFmtA.GetAnchorId())) { - const SwPosition *pPos = rFmtA.GetCntntAnchor(); - OSL_ENSURE(pPos && pIn, "Unexpected NULL arguments"); - if (!pPos || !pIn || pIn->nIndx != pPos->nNode.GetIndex()) - return; + return; } + const SwPosition *pPos = rFmtA.GetCntntAnchor(); + OSL_ENSURE(pPos && pIn, "Unexpected NULL arguments"); + if (!pPos || !pIn || pIn->nIndx != pPos->nNode.GetIndex()) + return; + long nMin, nMax; SwHTMLTableLayout *pLayout = 0; const bool bIsDrawFrmFmt = pNd->Which()==RES_DRAWFRMFMT; |