diff options
author | Artem Strygin <art-snake@yandex-team.ru> | 2018-07-27 10:10:26 +0000 |
---|---|---|
committer | Chromium commit bot <commit-bot@chromium.org> | 2018-07-27 10:10:26 +0000 |
commit | b3bab6ce43cab8f4cd35e2205491c278a400d733 (patch) | |
tree | e6b8aaec5f6b1d83c0b5a9e81317b7147ec96dd2 /core/fpdfapi/parser/cpdf_hint_tables_unittest.cpp | |
parent | aa418e541589f6c1f6462b383f3f35d246d6eabe (diff) | |
download | pdfium-b3bab6ce43cab8f4cd35e2205491c278a400d733.tar.xz |
Parse obj nums range within Hint tables for shared groups.
Change-Id: Ib22db6c57d2066ef70c0ef12e44d1e5eee6611a5
Reviewed-on: https://pdfium-review.googlesource.com/36410
Commit-Queue: Art Snake <art-snake@yandex-team.ru>
Reviewed-by: Lei Zhang <thestig@chromium.org>
Diffstat (limited to 'core/fpdfapi/parser/cpdf_hint_tables_unittest.cpp')
-rw-r--r-- | core/fpdfapi/parser/cpdf_hint_tables_unittest.cpp | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/core/fpdfapi/parser/cpdf_hint_tables_unittest.cpp b/core/fpdfapi/parser/cpdf_hint_tables_unittest.cpp index dba39f5594..97ba434768 100644 --- a/core/fpdfapi/parser/cpdf_hint_tables_unittest.cpp +++ b/core/fpdfapi/parser/cpdf_hint_tables_unittest.cpp @@ -130,21 +130,33 @@ TEST_F(CPDF_HintTablesTest, PageAndGroupInfos) { EXPECT_EQ(777, hint_tables->SharedGroupInfos()[0].m_szOffset); EXPECT_EQ(254u, hint_tables->SharedGroupInfos()[0].m_dwLength); + EXPECT_EQ(39u, hint_tables->SharedGroupInfos()[0].m_dwStartObjNum); + EXPECT_EQ(1u, hint_tables->SharedGroupInfos()[0].m_dwObjectsCount); EXPECT_EQ(1031, hint_tables->SharedGroupInfos()[1].m_szOffset); EXPECT_EQ(389u, hint_tables->SharedGroupInfos()[1].m_dwLength); + EXPECT_EQ(40u, hint_tables->SharedGroupInfos()[1].m_dwStartObjNum); + EXPECT_EQ(1u, hint_tables->SharedGroupInfos()[1].m_dwObjectsCount); EXPECT_EQ(1420, hint_tables->SharedGroupInfos()[2].m_szOffset); EXPECT_EQ(726u, hint_tables->SharedGroupInfos()[2].m_dwLength); + EXPECT_EQ(41u, hint_tables->SharedGroupInfos()[2].m_dwStartObjNum); + EXPECT_EQ(1u, hint_tables->SharedGroupInfos()[2].m_dwObjectsCount); EXPECT_EQ(2146, hint_tables->SharedGroupInfos()[3].m_szOffset); EXPECT_EQ(290u, hint_tables->SharedGroupInfos()[3].m_dwLength); + EXPECT_EQ(42u, hint_tables->SharedGroupInfos()[3].m_dwStartObjNum); + EXPECT_EQ(1u, hint_tables->SharedGroupInfos()[3].m_dwObjectsCount); EXPECT_EQ(2436, hint_tables->SharedGroupInfos()[4].m_szOffset); EXPECT_EQ(2669u, hint_tables->SharedGroupInfos()[4].m_dwLength); + EXPECT_EQ(43u, hint_tables->SharedGroupInfos()[4].m_dwStartObjNum); + EXPECT_EQ(1u, hint_tables->SharedGroupInfos()[4].m_dwObjectsCount); EXPECT_EQ(10939, hint_tables->SharedGroupInfos()[5].m_szOffset); EXPECT_EQ(544u, hint_tables->SharedGroupInfos()[5].m_dwLength); + EXPECT_EQ(4u, hint_tables->SharedGroupInfos()[5].m_dwStartObjNum); + EXPECT_EQ(1u, hint_tables->SharedGroupInfos()[5].m_dwObjectsCount); } TEST_F(CPDF_HintTablesTest, FirstPageOffset) { |