From 6f488fc5ab32c41566882de58d2cc7a2b74e7337 Mon Sep 17 00:00:00 2001 From: Caolán McNamara Date: Mon, 30 Apr 2018 09:13:10 +0100 Subject: crashtesting: ooo43029-4.odg initial j of 0 decremented wraps around MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit since commit 2815499d7c0b32fa05fcd697e7b2c2d897f78dfb Date: Fri Apr 27 05:21:29 2018 +0200 tdf#105913: Fix applying DX array to ligatures Change-Id: I989aa70d5e8a99061a1b0e4db63c47c7c92d92da Reviewed-on: https://gerrit.libreoffice.org/53647 Reviewed-by: Khaled Hosny Reviewed-by: Caolán McNamara Tested-by: Caolán McNamara --- vcl/source/gdi/CommonSalLayout.cxx | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/vcl/source/gdi/CommonSalLayout.cxx b/vcl/source/gdi/CommonSalLayout.cxx index 9002d76a7c62..ddb3986b277d 100644 --- a/vcl/source/gdi/CommonSalLayout.cxx +++ b/vcl/source/gdi/CommonSalLayout.cxx @@ -945,8 +945,9 @@ void CommonSalLayout::ApplyDXArray(ImplLayoutArgs& rArgs) // Adjust the X position of all glyphs in the cluster. size_t j = i; - while (j-- > 0) + while (j > 0) { + --j; if (!m_GlyphItems[j].IsInCluster()) break; m_GlyphItems[j].maLinearPos.AdjustX(nDelta + nDiff); -- cgit