Chromium Code Reviews| Index: core/fpdfapi/parser/cpdf_syntax_parser.h |
| diff --git a/core/fpdfapi/parser/cpdf_syntax_parser.h b/core/fpdfapi/parser/cpdf_syntax_parser.h |
| index eae5a00a41fbfc01c01859a1dfcd0fab8e8f5614..6aab8db3feaa4aca101665f794246a2d6d3906fa 100644 |
| --- a/core/fpdfapi/parser/cpdf_syntax_parser.h |
| +++ b/core/fpdfapi/parser/cpdf_syntax_parser.h |
| @@ -47,9 +47,6 @@ class CPDF_SyntaxParser { |
| bool bWholeWord, |
| bool bForward, |
| FX_FILESIZE limit); |
| - int SearchMultiWord(const CFX_ByteStringC& words, |
| - bool bWholeWord, |
| - FX_FILESIZE limit); |
| FX_FILESIZE FindTag(const CFX_ByteStringC& tag, FX_FILESIZE limit); |
| void SetEncrypt(std::unique_ptr<CPDF_CryptoHandler> pCryptoHandler); |
| @@ -67,6 +64,7 @@ class CPDF_SyntaxParser { |
| static int s_CurrentRecursionDepth; |
| uint32_t GetDirectNum(); |
| + bool ReadChar(FX_FILESIZE read_pos, uint32_t read_size); |
| bool GetNextChar(uint8_t& ch); |
| bool GetCharAtBackward(FX_FILESIZE pos, uint8_t& ch); |
| void GetNextWordInternal(bool* bIsNumber); |
| @@ -83,9 +81,13 @@ class CPDF_SyntaxParser { |
| uint32_t gennum); |
| CFX_ByteString MaybeIntern(const CFX_ByteString& str); |
| + inline bool CheckPosition(FX_FILESIZE pos) { |
|
Lei Zhang
2016/11/03 21:57:35
*shrug* I'm in the "let the compiler figure it out
|
| + return m_BufOffset >= pos || |
| + static_cast<FX_FILESIZE>(m_BufOffset + m_BufSize) <= pos; |
| + } |
| FX_FILESIZE m_Pos; |
| - int m_MetadataObjnum; |
| + uint32_t m_MetadataObjnum; |
| IFX_SeekableReadStream* m_pFileAccess; |
| FX_FILESIZE m_HeaderOffset; |
| FX_FILESIZE m_FileLen; |