diff options
author | Caolán McNamara <caolanm@redhat.com> | 2022-02-25 12:33:13 +0000 |
---|---|---|
committer | Aron Budea <aron.budea@collabora.com> | 2022-08-11 05:45:31 +0200 |
commit | cc6b572e6ba9a8714a57cdfeadb3c24ab1844ffc (patch) | |
tree | b8b6a988f286dd6aab657f2c03c6f30f1db6c084 | |
parent | fail more gracefully if m_aTmpPosition is empty (diff) | |
download | core-cc6b572e6ba9a8714a57cdfeadb3c24ab1844ffc.tar.gz core-cc6b572e6ba9a8714a57cdfeadb3c24ab1844ffc.zip |
lastPoint might be 0xFFFF
LIBREOFFICE-KYYAZMB9
Change-Id: Ic0d95bd39a01dc1e5e0fec83dcc2c40b3f23b747
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/130462
Tested-by: Jenkins
Reviewed-by: Xisco Fauli <xiscofauli@libreoffice.org>
(cherry picked from commit 21ea1eacd214dbaac8d0ce7f437580d535871415)
-rw-r--r-- | vcl/source/fontsubset/sft.cxx | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/vcl/source/fontsubset/sft.cxx b/vcl/source/fontsubset/sft.cxx index 9fcf26f97d9c..c505b43c0344 100644 --- a/vcl/source/fontsubset/sft.cxx +++ b/vcl/source/fontsubset/sft.cxx @@ -381,7 +381,7 @@ static int GetSimpleTTOutline(AbstractTrueTypeFont const *ttf, sal_uInt32 glyphI const sal_uInt8* p = ptr + nOffset; const sal_uInt32 nBytesRemaining = nTableSize - nOffset; - const sal_uInt16 palen = lastPoint+1; + const sal_uInt32 palen = lastPoint+1; //at a minimum its one byte per entry if (palen > nBytesRemaining || lastPoint > nBytesRemaining-1) |