diff options
author | Artem Strygin <art-snake@yandex-team.ru> | 2018-07-03 18:18:34 +0000 |
---|---|---|
committer | Chromium commit bot <commit-bot@chromium.org> | 2018-07-03 18:18:34 +0000 |
commit | c205b6da9307232594bcb3f30c89306c9b1362a8 (patch) | |
tree | 789330ed9deb8c2a98aa07f3a16d87affa6a361c /core/fpdfapi/parser/cpdf_syntax_parser.h | |
parent | d27675ef285d426c6df1844558f53dcc2ecd1084 (diff) | |
download | pdfium-c205b6da9307232594bcb3f30c89306c9b1362a8.tar.xz |
Do data request for CPDF_Stream more smoothly.
For DocumentLoader we should do reconnect to skip non-requested blocks
on each requested offset jump.
To reduce reconnections, read stream data first, then do all checks.
Thereby the DocumentLoader will continue loading data without
reconnections.
Change-Id: I344d045e59c5de9e1a4aed0002ea122caa92f240
Reviewed-on: https://pdfium-review.googlesource.com/13450
Commit-Queue: Art Snake <art-snake@yandex-team.ru>
Reviewed-by: Lei Zhang <thestig@chromium.org>
Diffstat (limited to 'core/fpdfapi/parser/cpdf_syntax_parser.h')
-rw-r--r-- | core/fpdfapi/parser/cpdf_syntax_parser.h | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/core/fpdfapi/parser/cpdf_syntax_parser.h b/core/fpdfapi/parser/cpdf_syntax_parser.h index a8f6bb2033..a29d631c95 100644 --- a/core/fpdfapi/parser/cpdf_syntax_parser.h +++ b/core/fpdfapi/parser/cpdf_syntax_parser.h @@ -87,6 +87,8 @@ class CPDF_SyntaxParser { ByteString ReadString(); ByteString ReadHexString(); unsigned int ReadEOLMarkers(FX_FILESIZE pos); + FX_FILESIZE FindWordPos(const ByteStringView& word); + FX_FILESIZE FindStreamEndPos(); std::unique_ptr<CPDF_Stream> ReadStream( std::unique_ptr<CPDF_Dictionary> pDict); |