summaryrefslogtreecommitdiff
path: root/xfa/fgas/layout/cfx_rtfbreak.cpp
diff options
context:
space:
mode:
authorDan Sinclair <dsinclair@chromium.org>2017-11-29 20:08:10 +0000
committerChromium commit bot <commit-bot@chromium.org>2017-11-29 20:08:10 +0000
commitb7e2ae6a5fd44f5e181937aeca202a45aed07215 (patch)
tree5c7f475bddf2845f43c67580ac05cf5639b6f03c /xfa/fgas/layout/cfx_rtfbreak.cpp
parentebbc08b858b4bb3e0a2cb69eb43c51b740515b9a (diff)
downloadpdfium-b7e2ae6a5fd44f5e181937aeca202a45aed07215.tar.xz
Remove CollectionSize from fx_bidi
Bug: pdfium:774 Change-Id: I2056583c270f1bb0046250ce2ec53a2cbe46b893 Reviewed-on: https://pdfium-review.googlesource.com/19672 Reviewed-by: Tom Sepez <tsepez@chromium.org> Commit-Queue: dsinclair <dsinclair@chromium.org>
Diffstat (limited to 'xfa/fgas/layout/cfx_rtfbreak.cpp')
-rw-r--r--xfa/fgas/layout/cfx_rtfbreak.cpp8
1 files changed, 5 insertions, 3 deletions
diff --git a/xfa/fgas/layout/cfx_rtfbreak.cpp b/xfa/fgas/layout/cfx_rtfbreak.cpp
index 0b556d89eb..761bd2fc03 100644
--- a/xfa/fgas/layout/cfx_rtfbreak.cpp
+++ b/xfa/fgas/layout/cfx_rtfbreak.cpp
@@ -363,10 +363,12 @@ void CFX_RTFBreak::EndBreak_BidiLine(std::deque<FX_TPO>* tpos,
std::vector<CFX_Char>& chars = m_pCurLine->m_LineChars;
int32_t iCount = m_pCurLine->CountChars();
if (!m_bPagination && m_pCurLine->m_iArabicChars > 0) {
- int32_t iBidiNum = 0;
- for (int32_t i = 0; i < iCount; ++i) {
+ ASSERT(iCount >= 0);
+
+ size_t iBidiNum = 0;
+ for (size_t i = 0; i < static_cast<size_t>(iCount); ++i) {
pTC = &chars[i];
- pTC->m_iBidiPos = i;
+ pTC->m_iBidiPos = static_cast<int32_t>(i);
if (pTC->GetCharType() != FX_CHARTYPE_Control)
iBidiNum = i;
if (i == 0)