Age | Commit message (Collapse) | Author |
|
This CL changes the table information so it can be indexed, and allows
moving all of the information to the CJBig2_HuffmanTable implementation,
which is the only real user of the data.
Change-Id: I88780bee32c8509198518fd3b1e82d68ae7ff707
Reviewed-on: https://pdfium-review.googlesource.com/32635
Commit-Queue: Nicolás Peña Moreno <npm@chromium.org>
Reviewed-by: Lei Zhang <thestig@chromium.org>
|
|
Currently the PartitionRealloc code path will only exit, with no
option to return nullptr on failure, unlike PartitionAlloc code path.
This CL refactors the realloc code path to be similar to alloc code
path, following the upstream patch:
https://chromium-review.googlesource.com/c/chromium/src/+/1044971
This also changes the version of realloc exposed to third party C libs
to have the nullptr behaviour, like the exposed version of alloc.
This CL is a redo of
https://pdfium-review.googlesource.com/c/pdfium/+/31990
BUG=chromium:783022
Change-Id: Ib1b659079585dfd0423d683b8a2c7b6758a22a01
Reviewed-on: https://pdfium-review.googlesource.com/32613
Commit-Queue: Ryan Harrison <rharrison@chromium.org>
Reviewed-by: Tom Sepez <tsepez@chromium.org>
Reviewed-by: Chris Palmer <palmer@chromium.org>
|
|
Pick up https://crrev.com/515947 and https://crrev.com/542972
Change-Id: Idccd388ee2f9cc71ace7ed5f598c820754e87b6e
Reviewed-on: https://pdfium-review.googlesource.com/32631
Commit-Queue: Ryan Harrison <rharrison@chromium.org>
Reviewed-by: Ryan Harrison <rharrison@chromium.org>
|
|
Bug: pdfium:1085
Change-Id: I62c526ae865f0cadfddd2e75a616bce73de0f88d
Reviewed-on: https://pdfium-review.googlesource.com/32632
Reviewed-by: dsinclair <dsinclair@chromium.org>
Commit-Queue: Tom Sepez <tsepez@chromium.org>
|
|
They are not used outside of it.
Change-Id: I0baa84c5a015621bc0ba211c2ddb01608997dc7d
Reviewed-on: https://pdfium-review.googlesource.com/32633
Reviewed-by: dsinclair <dsinclair@chromium.org>
Commit-Queue: Tom Sepez <tsepez@chromium.org>
|
|
Change-Id: Ibbc020393e38405f9d1cb0d483ef875777d4e721
Reviewed-on: https://pdfium-review.googlesource.com/32650
Reviewed-by: Henrique Nakashima <hnakashima@chromium.org>
Commit-Queue: Lei Zhang <thestig@chromium.org>
|
|
Remove some unused args along the way.
Change-Id: I234a674d4d6cc79b33087bc850f5df36bae25870
Reviewed-on: https://pdfium-review.googlesource.com/32596
Commit-Queue: Tom Sepez <tsepez@chromium.org>
Reviewed-by: dsinclair <dsinclair@chromium.org>
|
|
FindBit() is called frequently by other fax codec code. Use 16 more
bytes of space to store the two possible values memset() can set.
Change-Id: Ibeb549c44928bbb468ac4eb4cef2d9339cf6490d
Reviewed-on: https://pdfium-review.googlesource.com/32630
Reviewed-by: Henrique Nakashima <hnakashima@chromium.org>
Commit-Queue: Lei Zhang <thestig@chromium.org>
|
|
Bug: pdfium:1085
Change-Id: I121152527333e143d23e7cb852c8c1a745026453
Reviewed-on: https://pdfium-review.googlesource.com/32618
Reviewed-by: dsinclair <dsinclair@chromium.org>
Commit-Queue: dsinclair <dsinclair@chromium.org>
|
|
We never use the return values of these methods, switch to void from
bool.
Change-Id: I8b0d96e5be90ac08281bbb82d2c7205d94abea2b
Reviewed-on: https://pdfium-review.googlesource.com/32616
Reviewed-by: Tom Sepez <tsepez@chromium.org>
Reviewed-by: Henrique Nakashima <hnakashima@chromium.org>
Commit-Queue: dsinclair <dsinclair@chromium.org>
|
|
Change-Id: I959fe5dc30fcfe2176c7e5a64b07d082313a22b4
Reviewed-on: https://pdfium-review.googlesource.com/32595
Commit-Queue: Tom Sepez <tsepez@chromium.org>
Reviewed-by: dsinclair <dsinclair@chromium.org>
|
|
Use the system ICU header when USE_SYSTEM_ICUUC is defined.
Change-Id: Ieeb0e4a11ae86da871644dd0fd84de07e9917fde
Reviewed-on: https://pdfium-review.googlesource.com/32490
Reviewed-by: Lei Zhang <thestig@chromium.org>
Commit-Queue: Lei Zhang <thestig@chromium.org>
|
|
This CL cleans up the CPDF_ContentParser code. The m_bIsDone flag has
been removed and a kComplete stage added. Each of the processing methods
returns the next stage instead of setting the internal flag
automatically. The infinite loop is removed for simpler straight line
code.
Change-Id: Id817a5fa054e28c331c68c63ec2c12b369cb0233
Reviewed-on: https://pdfium-review.googlesource.com/32611
Commit-Queue: dsinclair <dsinclair@chromium.org>
Reviewed-by: Henrique Nakashima <hnakashima@chromium.org>
|
|
Provides more lifetime/bounds checking "for free".
Change-Id: Ifaf7a95c0f6f288777cd6ef35996e01b3dc4bc63
Reviewed-on: https://pdfium-review.googlesource.com/32594
Reviewed-by: dsinclair <dsinclair@chromium.org>
Commit-Queue: Tom Sepez <tsepez@chromium.org>
|
|
The CFX_BidiLine class is just a thin wrapper to hold a set of methods.
This CL moves the methods into the anonymous namespace and calls them
directly from FX_BidiLine.
Change-Id: Iea2ba178fb08339445702c9af4251f3c8ba2beb6
Reviewed-on: https://pdfium-review.googlesource.com/32617
Reviewed-by: Henrique Nakashima <hnakashima@chromium.org>
Commit-Queue: dsinclair <dsinclair@chromium.org>
|
|
This CL converts the WidetextBuf reference to a pointer in the formcalc
ToJavaScript methods.
Change-Id: Ia05c7255a99a2eaa3d9a57f77580969896ad90a0
Reviewed-on: https://pdfium-review.googlesource.com/32612
Reviewed-by: Henrique Nakashima <hnakashima@chromium.org>
Commit-Queue: dsinclair <dsinclair@chromium.org>
|
|
This CL adds verification to the m_iWidth value when adding the
characters width.
Bug: chromium:843096
Change-Id: I7b2e7b1e786a9cba77f5aceafbb5d2bf13dc8eb9
Reviewed-on: https://pdfium-review.googlesource.com/32610
Reviewed-by: Ryan Harrison <rharrison@chromium.org>
Commit-Queue: dsinclair <dsinclair@chromium.org>
|
|
This CL verifies that the provided BidiPos is within the acceptable size
for the vector before accessing.
Bug: chromium:843100
Change-Id: I2955a3ca628b19ee51dd4233726b859729c125af
Reviewed-on: https://pdfium-review.googlesource.com/32593
Reviewed-by: Henrique Nakashima <hnakashima@chromium.org>
Commit-Queue: dsinclair <dsinclair@chromium.org>
|
|
Remove the unused GetChar method and GetPiece method from CFX_BreakLine.
Change-Id: Ieee8e7b20513b37537d304e2bff46f0d1629576c
Reviewed-on: https://pdfium-review.googlesource.com/32592
Reviewed-by: Henrique Nakashima <hnakashima@chromium.org>
Commit-Queue: dsinclair <dsinclair@chromium.org>
|
|
This CL inlines the call to pdfium::CollectionSize for the one usage of
CFX_BreakLine::CountPieces.
Change-Id: I7eb64486c0a84c329d773f6d55ae277604098baf
Reviewed-on: https://pdfium-review.googlesource.com/32591
Reviewed-by: Henrique Nakashima <hnakashima@chromium.org>
Commit-Queue: dsinclair <dsinclair@chromium.org>
|
|
The CFX_BreakLine::CountChars is a thin wrapper around getting the size
of the m_LineChars vector. This CL removes CountChars and uses the
vectory directly.
Change-Id: I6b172c090aa7acf3282df517a8ae2bbdd55ff15b
Reviewed-on: https://pdfium-review.googlesource.com/32590
Reviewed-by: Henrique Nakashima <hnakashima@chromium.org>
Commit-Queue: dsinclair <dsinclair@chromium.org>
|
|
Change-Id: I1d2a91619a1c944b6fdca00b2f9c5bb338326986
Reviewed-on: https://pdfium-review.googlesource.com/32572
Commit-Queue: Tom Sepez <tsepez@chromium.org>
Reviewed-by: Lei Zhang <thestig@chromium.org>
|
|
When detecting the exponent on a floating point number, cap the maximum
amount we'll multiply by otherwise we can get excessivly large numbers.
Bug: chromium:843074
Change-Id: I6a8d1b4c20b66e305d2727f464119b1e74beb699
Reviewed-on: https://pdfium-review.googlesource.com/32570
Reviewed-by: Henrique Nakashima <hnakashima@chromium.org>
Commit-Queue: dsinclair <dsinclair@chromium.org>
|
|
Also format the trailer in a cleaner multi-line format.
Change-Id: If145834b56f8678f97247b346cc0cfd4d367c501
Reviewed-on: https://pdfium-review.googlesource.com/32571
Reviewed-by: Lei Zhang <thestig@chromium.org>
Commit-Queue: Tom Sepez <tsepez@chromium.org>
|
|
Precursor to testing app.beep() in chrome's browser tests.
Change-Id: I09ef497bd6a8094e389783b144fa04c9230cbe3d
Reviewed-on: https://pdfium-review.googlesource.com/32550
Reviewed-by: Lei Zhang <thestig@chromium.org>
Commit-Queue: Tom Sepez <tsepez@chromium.org>
|
|
This CL separates the parts of CPDF_ContentParser::Continue into three
distinct methods. It clarifes when and what is returned from Continue.
Change-Id: Id7a9bf1aa16f366f567cce74006c27c452cb5dcc
Reviewed-on: https://pdfium-review.googlesource.com/32531
Reviewed-by: Henrique Nakashima <hnakashima@chromium.org>
Commit-Queue: dsinclair <dsinclair@chromium.org>
|
|
Use the same limit as JBIG2 codecs.
BUG=chromium:834633
Change-Id: I11d12c841e10ab48fd85df792bf8a034fe40493c
Reviewed-on: https://pdfium-review.googlesource.com/32514
Commit-Queue: Lei Zhang <thestig@chromium.org>
Reviewed-by: Henrique Nakashima <hnakashima@chromium.org>
|
|
In case there are long runs of data to be skipped, FindBit() runs much
faster reading and comparing 8 bytes at a time.
BUG=chromium:834633
Change-Id: Ifc7b348d123c5a72cf09fbf53d764075f8abfba0
Reviewed-on: https://pdfium-review.googlesource.com/32513
Commit-Queue: Lei Zhang <thestig@chromium.org>
Reviewed-by: Henrique Nakashima <hnakashima@chromium.org>
|
|
Get rid of a few more fxbarcode exception codes.
Change-Id: Ia9c9cdcef581174e25be8dc2fba181915dc6d729
Reviewed-on: https://pdfium-review.googlesource.com/32471
Commit-Queue: Lei Zhang <thestig@chromium.org>
Reviewed-by: Ryan Harrison <rharrison@chromium.org>
|
|
Change-Id: Ibc446d9f4606d29f997ee3521f31f0fbcf1ad84b
Reviewed-on: https://pdfium-review.googlesource.com/32176
Commit-Queue: Lei Zhang <thestig@chromium.org>
Reviewed-by: Ryan Harrison <rharrison@chromium.org>
|
|
Break out parts of ProcessTextObject() into helper functions.
Change-Id: I76ad141728ce77e8d24d7dc9635722d670663f39
Reviewed-on: https://pdfium-review.googlesource.com/32175
Reviewed-by: Ryan Harrison <rharrison@chromium.org>
Commit-Queue: Lei Zhang <thestig@chromium.org>
|
|
This CL folds the StartParse() method of CPDF_Form into the
ParserContent method. The no arguments ParseContent is removed and
ParseContentWithParams renamed to ParseContent. The callsites are
updated to pass the nullptr's.
Bug: chromium:813349
Change-Id: I304b77aef1de1b9aa20e4a3044db5023f5701584
Reviewed-on: https://pdfium-review.googlesource.com/32511
Reviewed-by: Henrique Nakashima <hnakashima@chromium.org>
Commit-Queue: dsinclair <dsinclair@chromium.org>
|
|
This CL switches the usage of wcstod to use the FXSYS_wcstof to
determine if a given string is a valid floating point number.
Using the internal method makes linux slightly slower (10's of ms)
makes mac a lot faster 900ms to 60ms for the test case in the bug.
The FXSYS_wcstof method has been extended to handle the parsing of
float exponents. Unittests were added for FXSYS_wcstof.
Bug: chromium:813646
Change-Id: Ie68287a336e3b95a0c0b845d5bf39db6fc82b39c
Reviewed-on: https://pdfium-review.googlesource.com/32510
Reviewed-by: Ryan Harrison <rharrison@chromium.org>
Commit-Queue: dsinclair <dsinclair@chromium.org>
|
|
Bug: 840922
Change-Id: I984db568153bd55eff6d217e6a5219fd8a32c947
Reviewed-on: https://pdfium-review.googlesource.com/32470
Reviewed-by: Henrique Nakashima <hnakashima@chromium.org>
Commit-Queue: Tom Sepez <tsepez@chromium.org>
|
|
Change-Id: Ia3a79aa7cc65aaecd1b0f0a5ea07df4e9d33a012
Reviewed-on: https://pdfium-review.googlesource.com/32396
Commit-Queue: Henrique Nakashima <hnakashima@chromium.org>
Reviewed-by: Ryan Harrison <rharrison@chromium.org>
Reviewed-by: Tom Sepez <tsepez@chromium.org>
|
|
Change-Id: Ic39b843ab21e7eb738849511a5187822ad49d67a
Reviewed-on: https://pdfium-review.googlesource.com/32413
Commit-Queue: Henrique Nakashima <hnakashima@chromium.org>
Reviewed-by: Tom Sepez <tsepez@chromium.org>
Reviewed-by: Ryan Harrison <rharrison@chromium.org>
|
|
This CL merges some of the values of JBig2_Result. The only checks are
against Success and EndOfFile || EndOfPage, so we only need three
values: Success, EndReached, and Failure (for anything that does not
match either of those two).
Change-Id: I552c54f2d70aa8e8bf52702dab4dfc00d528ef76
Reviewed-on: https://pdfium-review.googlesource.com/32393
Commit-Queue: Nicolás Peña Moreno <npm@chromium.org>
Reviewed-by: Lei Zhang <thestig@chromium.org>
|
|
This is useful for comparing images without slowing down performance
with a profiler.
Change-Id: Ia0c41bf8ef32d82bbc24f47f44586e22d991aa51
Reviewed-on: https://pdfium-review.googlesource.com/32352
Reviewed-by: Lei Zhang <thestig@chromium.org>
Commit-Queue: Henrique Nakashima <hnakashima@chromium.org>
|
|
Do not open the html in a browser automatically.
Change-Id: I7394b86f4a46a701dedb4fa0887515211561aee7
Reviewed-on: https://pdfium-review.googlesource.com/32315
Reviewed-by: Lei Zhang <thestig@chromium.org>
Commit-Queue: Henrique Nakashima <hnakashima@chromium.org>
|
|
Change-Id: I952cf31cb2e3f5ca19ea3af5e9e4e11881f0a90d
Reviewed-on: https://pdfium-review.googlesource.com/32395
Commit-Queue: Henrique Nakashima <hnakashima@chromium.org>
Reviewed-by: Tom Sepez <tsepez@chromium.org>
|
|
Change-Id: Id70a0c068f565ab87d10d021803a29a56ea92d67
Reviewed-on: https://pdfium-review.googlesource.com/32411
Commit-Queue: Henrique Nakashima <hnakashima@chromium.org>
Reviewed-by: Tom Sepez <tsepez@chromium.org>
|
|
The methods removed are not called anymore, and the members removed
then become unused too.
Change-Id: I5832f801a678f6907faf623ac678f9b3818c2af7
Reviewed-on: https://pdfium-review.googlesource.com/32394
Commit-Queue: Henrique Nakashima <hnakashima@chromium.org>
Reviewed-by: Tom Sepez <tsepez@chromium.org>
|
|
Change-Id: I707273c81d51124cf6ca7ba43cf1a817f3c852ea
Reviewed-on: https://pdfium-review.googlesource.com/32412
Commit-Queue: Henrique Nakashima <hnakashima@chromium.org>
Reviewed-by: Tom Sepez <tsepez@chromium.org>
|
|
Change-Id: I0247abb14a68cdb845f4c0060de9d30592a32d3d
Reviewed-on: https://pdfium-review.googlesource.com/32392
Commit-Queue: Henrique Nakashima <hnakashima@chromium.org>
Reviewed-by: Tom Sepez <tsepez@chromium.org>
Reviewed-by: Ryan Harrison <rharrison@chromium.org>
|
|
It is never instantiated.
Change-Id: I6b97abbe4bd7013e8a540e788da6cea7d0ba978b
Reviewed-on: https://pdfium-review.googlesource.com/32410
Commit-Queue: Henrique Nakashima <hnakashima@chromium.org>
Reviewed-by: Ryan Harrison <rharrison@chromium.org>
Reviewed-by: Tom Sepez <tsepez@chromium.org>
|
|
This reverts commit 466bd4f4e0cb2bc2a7b3626948609268c52c4690.
Reason for revert: On closer inspection, it seems the test is not
flaky, and the root cause of the failure is an SEH exception,
which is the true source of flakiness. Other tests are also affected.
Original change's description:
> Revert "Filter out "Type" and "DecodeParms" from trailer keys."
>
> This reverts commit 5f7c5be8b7072d46e8d8088a1ec14370ecfad44c.
>
> Reason for revert: New test is flaky, ID is not stable.
>
> Original change's description:
> > Filter out "Type" and "DecodeParms" from trailer keys.
> >
> > Bug: pdfium:873
> > Change-Id: I12ae5b8776f5a73c4be81bed53ada05c94d46882
> > Reviewed-on: https://pdfium-review.googlesource.com/32190
> > Reviewed-by: dsinclair <dsinclair@chromium.org>
> > Commit-Queue: dsinclair <dsinclair@chromium.org>
>
> TBR=dsinclair@chromium.org,hnakashima@chromium.org
>
> # Not skipping CQ checks because original CL landed > 1 day ago.
>
> Bug: pdfium:873
> Change-Id: I642771e12c61181c7b81681dae7b2f5549c14b18
> Reviewed-on: https://pdfium-review.googlesource.com/32430
> Reviewed-by: Henrique Nakashima <hnakashima@chromium.org>
> Commit-Queue: Henrique Nakashima <hnakashima@chromium.org>
TBR=dsinclair@chromium.org,hnakashima@chromium.org
Change-Id: I2552729610c9f8adf02c70a2a43e2383ceda19b5
No-Presubmit: true
No-Tree-Checks: true
No-Try: true
Bug: pdfium:873
Reviewed-on: https://pdfium-review.googlesource.com/32397
Reviewed-by: Henrique Nakashima <hnakashima@chromium.org>
Commit-Queue: Henrique Nakashima <hnakashima@chromium.org>
|
|
The non-Disform versions are gone, so inline the Disform_ versions
to reduce indirection.
Change-Id: Icf261795e5df6e5015055ec64f3dcdba56789a07
Reviewed-on: https://pdfium-review.googlesource.com/32373
Commit-Queue: Henrique Nakashima <hnakashima@chromium.org>
Reviewed-by: Ryan Harrison <rharrison@chromium.org>
Reviewed-by: Tom Sepez <tsepez@chromium.org>
|
|
This reverts commit 5f7c5be8b7072d46e8d8088a1ec14370ecfad44c.
Reason for revert: New test is flaky, ID is not stable.
Original change's description:
> Filter out "Type" and "DecodeParms" from trailer keys.
>
> Bug: pdfium:873
> Change-Id: I12ae5b8776f5a73c4be81bed53ada05c94d46882
> Reviewed-on: https://pdfium-review.googlesource.com/32190
> Reviewed-by: dsinclair <dsinclair@chromium.org>
> Commit-Queue: dsinclair <dsinclair@chromium.org>
TBR=dsinclair@chromium.org,hnakashima@chromium.org
# Not skipping CQ checks because original CL landed > 1 day ago.
Bug: pdfium:873
Change-Id: I642771e12c61181c7b81681dae7b2f5549c14b18
Reviewed-on: https://pdfium-review.googlesource.com/32430
Reviewed-by: Henrique Nakashima <hnakashima@chromium.org>
Commit-Queue: Henrique Nakashima <hnakashima@chromium.org>
|
|
This method always returns true, so make that assumption and clean up
dead code.
More cleanups will follow this one to remove the code that can now
be inferred to be dead.
Change-Id: I73f077561ab511a1c2c09ac6990ab5cdc5bfb055
Reviewed-on: https://pdfium-review.googlesource.com/32391
Reviewed-by: Ryan Harrison <rharrison@chromium.org>
Reviewed-by: Tom Sepez <tsepez@chromium.org>
Commit-Queue: Henrique Nakashima <hnakashima@chromium.org>
|
|
Use one std::vector<>, too. As a result, make GetDecodeAndMaskArray()
update that member directly rather than forcing callers to assign to
it each time.
Change-Id: I51a039b9e8cce7ff885edf395622eaf6a5c4816a
Reviewed-on: https://pdfium-review.googlesource.com/32313
Commit-Queue: Tom Sepez <tsepez@chromium.org>
Reviewed-by: dsinclair <dsinclair@chromium.org>
|