tdf#151283 calc hangs when try to open XLS file
regression from
commit 258a8d133d
Author: Noel Grandin <noel.grandin@collabora.co.uk>
tdf#150034 very slow opening pathological chart
if nNewLen is < 10, we can get stuck in an infinite loop
because the calculation will not actually decrement nNewLen
Change-Id: I98920deaa087713c44531a7f6506d1d5d32b2e98
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/140949
Tested-by: Jenkins
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
This commit is contained in:
parent
0ab5a5ee6e
commit
a36173359d
1 changed files with 1 additions and 1 deletions
|
@ -448,7 +448,7 @@ awt::Size lcl_placeLegendEntries(
|
|||
DrawModelWrapper::removeShape(xEntry);
|
||||
// The intention here is to make pathological cases with extremely large labels
|
||||
// converge a little faster
|
||||
if (std::abs(nRemainingSpace) > nSumHeight / 10)
|
||||
if (nNewLen > 10 && std::abs(nRemainingSpace) > nSumHeight / 10)
|
||||
nNewLen -= nNewLen / 10;
|
||||
else
|
||||
--nNewLen;
|
||||
|
|
Loading…
Reference in a new issue