OLD | NEW |
1 // Copyright 2014 PDFium Authors. All rights reserved. | 1 // Copyright 2014 PDFium Authors. All rights reserved. |
2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
4 | 4 |
5 // Original code copyright 2014 Foxit Software Inc. http://www.foxitsoftware.com | 5 // Original code copyright 2014 Foxit Software Inc. http://www.foxitsoftware.com |
6 | 6 |
7 #include <set> | 7 #include <set> |
8 #include <utility> | 8 #include <utility> |
9 #include <vector> | 9 #include <vector> |
10 | 10 |
11 #include "../../../../third_party/base/nonstd_unique_ptr.h" | |
12 #include "../../../../third_party/base/stl_util.h" | |
13 #include "../../../include/fpdfapi/fpdf_module.h" | 11 #include "../../../include/fpdfapi/fpdf_module.h" |
14 #include "../../../include/fpdfapi/fpdf_page.h" | 12 #include "../../../include/fpdfapi/fpdf_page.h" |
15 #include "../../../include/fpdfapi/fpdf_parser.h" | 13 #include "../../../include/fpdfapi/fpdf_parser.h" |
16 #include "../../../include/fxcrt/fx_safe_types.h" | 14 #include "../../../include/fxcrt/fx_safe_types.h" |
17 #include "../fpdf_page/pageint.h" | 15 #include "../fpdf_page/pageint.h" |
18 #include "parser_int.h" | 16 #include "parser_int.h" |
| 17 #include "third_party/base/nonstd_unique_ptr.h" |
| 18 #include "third_party/base/stl_util.h" |
19 | 19 |
20 namespace { | 20 namespace { |
21 | 21 |
22 struct SearchTagRecord { | 22 struct SearchTagRecord { |
23 const uint8_t* m_pTag; | 23 const uint8_t* m_pTag; |
24 FX_DWORD m_Len; | 24 FX_DWORD m_Len; |
25 FX_DWORD m_Offset; | 25 FX_DWORD m_Offset; |
26 }; | 26 }; |
27 | 27 |
28 int CompareFileSize(const void* p1, const void* p2) { | 28 int CompareFileSize(const void* p1, const void* p2) { |
(...skipping 4917 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
4946 if (!m_pLinearizedDict) | 4946 if (!m_pLinearizedDict) |
4947 return -1; | 4947 return -1; |
4948 CPDF_Array* pRange = m_pLinearizedDict->GetArray(FX_BSTRC("H")); | 4948 CPDF_Array* pRange = m_pLinearizedDict->GetArray(FX_BSTRC("H")); |
4949 if (!pRange) | 4949 if (!pRange) |
4950 return -1; | 4950 return -1; |
4951 CPDF_Object* pStreamLen = pRange->GetElementValue(1); | 4951 CPDF_Object* pStreamLen = pRange->GetElementValue(1); |
4952 if (!pStreamLen) | 4952 if (!pStreamLen) |
4953 return -1; | 4953 return -1; |
4954 return pStreamLen->GetInteger(); | 4954 return pStreamLen->GetInteger(); |
4955 } | 4955 } |
OLD | NEW |