summaryrefslogtreecommitdiff
path: root/core/src/fpdfapi/fpdf_parser/fpdf_parser_parser_unittest.cpp
AgeCommit message (Collapse)Author
2016-02-08Tidy fpdfsave.cppTom Sepez
Remove CFX_PtrArray filelist. Promote ScopedFileStream to .h file and use it. Fix _CAPS names, bool returns, and put in anonymous namespace. FX_CreateMemoryStream() can't return null, so remove checks. R=thestig@chromium.org Review URL: https://codereview.chromium.org/1672153002 .
2016-02-01Merge to XFA: Remove the m_ObjVersion member variable from CPDF_Parser.Lei Zhang
Use the gennum field in the m_ObjectInfo map instead. BUG=pdfium:111 R=weili@chromium.org TBR=weili@chromium.org Review URL: https://codereview.chromium.org/1654303002 . (cherry picked from commit a620372c9e1d0ff825bcbe6620fe7e1b63c769c2) Review URL: https://codereview.chromium.org/1653023004 .
2016-02-01Merge to XFA: Remove the m_V5Type member variable from CPDF_Parser.chromium/2641chromium/2640chromium/2639chromium/2638Lei Zhang
Use the type field in the m_ObjectInfo map instead. BUG=pdfium:111 TBR=weili@chromium.org Review URL: https://codereview.chromium.org/1650793002 . (cherry picked from commit 93c196d868535f684007a7d3ed1f7146851a0ab9) Review URL: https://codereview.chromium.org/1652083004 .
2016-01-08Merge to XFA: Clean up misc nits found while fixing bugs.Lei Zhang
Some bits regressed in commit 338805f. Also merge: IWYU fix after commit c5a8933. R=tsepez@chromium.org TBR=tsepez@chromium.org Review URL: https://codereview.chromium.org/1544963002 . Review URL: https://codereview.chromium.org/1570973002 . (cherry picked from commit c5a8933f260ca1034fde902058442984e55c0f7a) (cherry picked from commit e6bd31873c3dba3f79c5ebbbefed636948629cc9) Review URL: https://codereview.chromium.org/1577453002 .
2015-12-24Merge to XFA: Switch from nonstd::unique_ptr to std::unique_ptr.Lei Zhang
TBR=thakis@chromium.org Review URL: https://codereview.chromium.org/1547833002 . (cherry picked from commit d20dfba2ae10e8aeb328328f09da79ff904110a8) Review URL: https://codereview.chromium.org/1545183002 .
2015-12-22Merge to XFA: Convert CPDF_Parser::m_CrossRef to a std::map.Lei Zhang
This improvements memory usage in case PDFs have sparse object numbers. The map holds a struct that currently has only one member. The struct will contain more members as other internal data structures get converted. BUG=pdfium:111 TBR=weili@chromium.org Review URL: https://codereview.chromium.org/1539573003 . (cherry picked from commit f6dafc90ec1a0df8d618efc68c0223f0cdd80ffb) Review URL: https://codereview.chromium.org/1544913002 .
2015-12-16Merge to XFA: Make clang_warning_flags work for standalone builds.Lei Zhang
Also fix a newly introduced override warning. Also define a host_clang GYP variable. TBR=thakis@chromium.org Review URL: https://codereview.chromium.org/1532723003 . Review URL: https://codereview.chromium.org/1533763002 . (cherry picked from commit e096ca507db9944aebc47d6c2cc1c6fab39498c5) (cherry picked from commit 0a9158b99a2002fb82301ebec20dbc23b3fc084c) Review URL: https://codereview.chromium.org/1535603003 .
2015-12-15Merge to XFA: Fix free entry handling for cross reference v4 reading.Wei Li
While reading free entries in v4 cross reference table, changing the start_objnum caused crossref table built wrong. BUG=569795 TBR=jun_fang@foxitsoftware.com, thestig@chromium.org Review URL: https://codereview.chromium.org/1527823003 . (cherry picked from commit c89cd979fb8654d85b822909cba9263d5f13760c) Review URL: https://codereview.chromium.org/1528153003 .
2015-12-01Merge to XFA: Add basic checking for RebuildCrossRefWei Li
RebuildCrossRef function returns false when we can not find file trailer or any indirect object. This serves as a basic file format checking. BUG=pdfium:215 TBR=jun_fang@foxitsoftware.com Review URL: https://codereview.chromium.org/1476163002 . (cherry picked from commit f14da1d58e8e12633c7a47e6efd5ffe43bb37b4b) Review URL: https://codereview.chromium.org/1486383002 .
2015-11-10Merge to XFA: Fix relative includes within core/Lei Zhang
TBR=tsepez@chromium.org Review URL: https://codereview.chromium.org/1427633010 . (cherry picked from commit 9fb27cb9797937499c9678bc74cf7846cbf5d2b8) Review URL: https://codereview.chromium.org/1438573002 .
2015-11-09Merge to XFA: Add path service to retrieve test data directory at run time ↵Wei Li
so tests can be run from any directory. Previously the tests which read test files assume the current directory is under pdfium. Running from any other directory will break the build. R=thestig@chromium.org Review URL: https://codereview.chromium.org/1408003014 . (cherry picked from commit c0e93a9a942fe7d99800502a61d2fbb58cf9276f) Conflicts: core/src/fpdfapi/fpdf_parser/fpdf_parser_parser_embeddertest.cpp fpdfsdk/src/fpdfdoc_embeddertest.cpp testing/embedder_test.cpp testing/embedder_test.h Review URL: https://codereview.chromium.org/1411403012 .
2015-11-05Merge to XFA: Add base test for RebuildCrossRef function.Wei Li
This tests whether RebuildCrossRef could handle well-formatted pdf file. R=thestig@chromium.org Review URL: https://codereview.chromium.org/1409013005 . (cherry picked from commit 4544797e8998a31e7bc3f5439a5982f7f66dff26) Review URL: https://codereview.chromium.org/1413343004 .
2015-11-03Merge to XFA: Add test for CPDF_SyntaxParser::ReadHexString.Dan Sinclair
This CL adds tests for the ReadHexString method of the syntax parser. TBR=tsepez@chromium.org Review URL: https://codereview.chromium.org/1433503002 . (cherry picked from commit 71ad9a0028a183605fba734c48b4756d6caa7754) Review URL: https://codereview.chromium.org/1424923007 .