summaryrefslogtreecommitdiff
path: root/core/src
diff options
context:
space:
mode:
authorLei Zhang <thestig@chromium.org>2015-12-24 02:47:07 -0800
committerLei Zhang <thestig@chromium.org>2015-12-24 02:47:07 -0800
commit25ae22692cdd5b4ae4783ecb27eba79b3c794b2c (patch)
treea424dc974f8a96d371356a5664893b3343df22e0 /core/src
parent026ddb228b8107b345b6d0a48bffc62fd17b6adb (diff)
downloadpdfium-25ae22692cdd5b4ae4783ecb27eba79b3c794b2c.tar.xz
Merge to XFA: Call CheckLinearizedFirstPage() when loading the first linearized page.
Otherwise CheckLinearizedFirstPage() has no other callers. BUG=pdfium:330 TBR=jun_fang@foxitsoftware.com Review URL: https://codereview.chromium.org/1543193002 . (cherry picked from commit bab9a98b71f351cf9f4eb39138bca55e3be4ef15) Review URL: https://codereview.chromium.org/1543353002 .
Diffstat (limited to 'core/src')
-rw-r--r--core/src/fpdfapi/fpdf_parser/fpdf_parser_parser.cpp2
1 files changed, 2 insertions, 0 deletions
diff --git a/core/src/fpdfapi/fpdf_parser/fpdf_parser_parser.cpp b/core/src/fpdfapi/fpdf_parser/fpdf_parser_parser.cpp
index 2a271f1179..05f407bfd3 100644
--- a/core/src/fpdfapi/fpdf_parser/fpdf_parser_parser.cpp
+++ b/core/src/fpdfapi/fpdf_parser/fpdf_parser_parser.cpp
@@ -4381,6 +4381,8 @@ int CPDF_DataAvail::IsPageAvail(int32_t iPage, IFX_DownloadHints* pHints) {
if (m_bLinearized) {
if ((FX_DWORD)iPage == m_dwFirstPageNo) {
+ if (!CheckLinearizedFirstPage(iPage, pHints))
+ return DataNotAvailable;
m_pagesLoadState.insert(iPage);
return DataAvailable;
}