Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(1708)

Unified Diff: core/src/fpdfapi/fpdf_parser/fpdf_parser_parser.cpp

Issue 1430643007: Remove state from RebuildCrossRef state-machine. (Closed) Base URL: https://pdfium.googlesource.com/pdfium.git@master
Patch Set: Created 5 years, 1 month ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: core/src/fpdfapi/fpdf_parser/fpdf_parser_parser.cpp
diff --git a/core/src/fpdfapi/fpdf_parser/fpdf_parser_parser.cpp b/core/src/fpdfapi/fpdf_parser/fpdf_parser_parser.cpp
index f5ada7c6eb6c3c3d0712cb45dacbe7f4a48d79c2..db0e8b19e1ebdebba867c9df2104253966613a2b 100644
--- a/core/src/fpdfapi/fpdf_parser/fpdf_parser_parser.cpp
+++ b/core/src/fpdfapi/fpdf_parser/fpdf_parser_parser.cpp
@@ -926,17 +926,10 @@ FX_BOOL CPDF_Parser::RebuildCrossRef() {
}
break;
case 11:
- if (byte == '<' && inside_index == 1) {
- status = 12;
- } else if (byte == '>') {
+ if (byte == '>' || (byte == '<' && inside_index == 1))
status = 0;
- }
inside_index = 0;
break;
- case 12:
- --i;
- status = 0;
- break;
case 13:
if (PDFCharIsDelimiter(byte) || PDFCharIsWhitespace(byte)) {
--i;
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698