summaryrefslogtreecommitdiff
path: root/core/fpdfapi/font/cpdf_cmap.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'core/fpdfapi/font/cpdf_cmap.cpp')
-rw-r--r--core/fpdfapi/font/cpdf_cmap.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/core/fpdfapi/font/cpdf_cmap.cpp b/core/fpdfapi/font/cpdf_cmap.cpp
index 659139f687..0d3745e44a 100644
--- a/core/fpdfapi/font/cpdf_cmap.cpp
+++ b/core/fpdfapi/font/cpdf_cmap.cpp
@@ -253,12 +253,12 @@ void CPDF_CMap::LoadPredefined(CPDF_CMapManager* pMgr,
m_PredefinedCMap = bsName;
if (m_PredefinedCMap == "Identity-H" || m_PredefinedCMap == "Identity-V") {
m_Coding = CIDCODING_CID;
- m_bVertical = bsName[9] == 'V';
+ m_bVertical = bsName.Last() == 'V';
m_bLoaded = true;
return;
}
CFX_ByteString cmapid = m_PredefinedCMap;
- m_bVertical = cmapid.Right(1) == "V";
+ m_bVertical = cmapid.Last() == 'V';
if (cmapid.GetLength() > 2) {
cmapid = cmapid.Left(cmapid.GetLength() - 2);
}