summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJulien Nabet <serval2412@yahoo.fr>2014-05-23 22:55:41 +0200
committerJulien Nabet <serval2412@yahoo.fr>2014-05-23 22:55:41 +0200
commit06afd4067f7bc321d7dd0a4e8c235b0b21e3d49a (patch)
treeb2671787445d4bc17d5d7f0d241c4f496579de73
parentb36ccf58432cf794c66ce272fcb23f79400adff5 (diff)
Resolves: fdo#79139 Crash in SwDropCapCache::CalcFontSize
Minimum of nMaxFontHeight must be at least 1 Change-Id: I35462fc069c7026958e597c2e0605345ed009c91
-rw-r--r--sw/source/core/text/txtdrop.cxx2
1 files changed, 1 insertions, 1 deletions
diff --git a/sw/source/core/text/txtdrop.cxx b/sw/source/core/text/txtdrop.cxx
index 98556aa2f1b4..563a1ffefd1c 100644
--- a/sw/source/core/text/txtdrop.cxx
+++ b/sw/source/core/text/txtdrop.cxx
@@ -703,7 +703,7 @@ void SwDropCapCache::CalcFontSize( SwDropPortion* pDrop, SwTxtFormatInfo &rInf )
long nWishedHeight = pDrop->GetDropHeight();
// find out biggest font size for initial scaling factor
- long nMaxFontHeight = 0;
+ long nMaxFontHeight = 1;
while ( pCurrPart )
{
const SwFont& rFnt = pCurrPart->GetFont();