summaryrefslogtreecommitdiff
path: root/core
diff options
context:
space:
mode:
Diffstat (limited to 'core')
-rw-r--r--core/fpdftext/cpdf_textpage.cpp4
1 files changed, 1 insertions, 3 deletions
diff --git a/core/fpdftext/cpdf_textpage.cpp b/core/fpdftext/cpdf_textpage.cpp
index fd33fb2f2f..82778b1658 100644
--- a/core/fpdftext/cpdf_textpage.cpp
+++ b/core/fpdftext/cpdf_textpage.cpp
@@ -1355,9 +1355,7 @@ CPDF_TextPage::GenerateCharacter CPDF_TextPage::ProcessInsertObject(
}
WideString PrevStr =
m_pPreTextObj->GetFont()->UnicodeFromCharCode(PrevItem.m_CharCode);
- if (PrevStr.IsEmpty())
- return GenerateCharacter::None;
- wchar_t preChar = PrevStr[PrevStr.GetLength() - 1];
+ wchar_t preChar = PrevStr.Last();
CFX_Matrix matrix = pObj->GetTextMatrix();
matrix.Concat(formMatrix);