Age | Commit message (Collapse) | Author |
|
This method duplicates the behaviour of the const [] operator and
doesn't offer any additional safety. Folding them into one
implementation.
SetAt is retained, since implementing the non-const [] operator to
replace SetAt has potential performance concerns. Specifically many
non-obvious cases of reading an element using [] will cause a realloc
& copy.
BUG=pdfium:860
Change-Id: I3ef5e5e5a15376f040256b646eb0d90636e24b67
Reviewed-on: https://pdfium-review.googlesource.com/10870
Commit-Queue: Ryan Harrison <rharrison@chromium.org>
Reviewed-by: Tom Sepez <tsepez@chromium.org>
|
|
The various string/byte classes support Mid(), Left(), and Right() for
extracting substrings. Mid() can handle all possible cases, but Left()
and Right() are useful for common cases and more explicit about what
is going on.
Calls like Mid(offset, length - offset) can be converted to
Right(length - offset). Calls like Mid(0, length) can be converted to
Left(length).
If the substring being extracted does not extend all the way to one of
the edges of the string, then Mid() still needs to be used.
BUG=pdfium:828
Change-Id: I2ec46ad3d71aac0f7b513e103c69cbe8c854cf62
Reviewed-on: https://pdfium-review.googlesource.com/9510
Commit-Queue: Ryan Harrison <rharrison@chromium.org>
Reviewed-by: Tom Sepez <tsepez@chromium.org>
|
|
Change-Id: I8365ba80e3395d59a3cf35dbd9d9162e86e712e3
Reviewed-on: https://pdfium-review.googlesource.com/5970
Commit-Queue: Tom Sepez <tsepez@chromium.org>
Reviewed-by: Lei Zhang <thestig@chromium.org>
|
|
Change-Id: Idcc05fb8c5a1448f552b4db5ae131ad82aef4d59
Reviewed-on: https://pdfium-review.googlesource.com/4258
Reviewed-by: Tom Sepez <tsepez@chromium.org>
Commit-Queue: Lei Zhang <thestig@chromium.org>
|
|
Change-Id: Iff738c99fb4fe38d35515c280057b489624d734f
Reviewed-on: https://pdfium-review.googlesource.com/3752
Reviewed-by: Tom Sepez <tsepez@chromium.org>
Commit-Queue: Lei Zhang <thestig@chromium.org>
|
|
No caller cares about the exception values anyway. Remove the unused
ones. Also use more std::unique_ptr to stop potential leaks.
Change-Id: Ic5955fb0d879f55e1c6a005c0204df50246dab19
Reviewed-on: https://pdfium-review.googlesource.com/3715
Commit-Queue: Lei Zhang <thestig@chromium.org>
Reviewed-by: Tom Sepez <tsepez@chromium.org>
|
|
Use std::vector and return booleans results when possible.
Change-Id: If3ce4559f137fb449fd1ab818750558a1b5f8df0
Reviewed-on: https://pdfium-review.googlesource.com/3561
Commit-Queue: Lei Zhang <thestig@chromium.org>
Reviewed-by: Tom Sepez <tsepez@chromium.org>
|
|
Remove a bunch of unused code, including gotos.
Fix some potential memory leaks.
Change-Id: Ia2775e2ab176f4741b765e259a24a293a5717394
Reviewed-on: https://pdfium-review.googlesource.com/3560
Commit-Queue: Lei Zhang <thestig@chromium.org>
Reviewed-by: Tom Sepez <tsepez@chromium.org>
|
|
This Cl drops the FXSYS_ from mem methods which are the same on all
platforms.
Bug: pdfium:694
Change-Id: I9d5ae905997dbaaec5aa0b2ae4c07358ed9c6236
Reviewed-on: https://pdfium-review.googlesource.com/3613
Reviewed-by: Tom Sepez <tsepez@chromium.org>
Commit-Queue: dsinclair <dsinclair@chromium.org>
|
|
Change-Id: I327a3f94cf6f00366d7a78ed9f973d00f702f397
Reviewed-on: https://pdfium-review.googlesource.com/3559
Reviewed-by: Tom Sepez <tsepez@chromium.org>
Commit-Queue: Lei Zhang <thestig@chromium.org>
|
|
Roll DEPS for testing corpus to 2c5a026 to verify.
This regressed in commit c8017b2.
BUG=pdfium:692
Change-Id: Ic09ed53db8b3cc81abb2bdea863b8cf32f614197
Reviewed-on: https://pdfium-review.googlesource.com/3510
Commit-Queue: Tom Sepez <tsepez@chromium.org>
Reviewed-by: Tom Sepez <tsepez@chromium.org>
|
|
This CL replaces some new's with pdfium::MakeUnique.
Change-Id: I50faf3ed55e7730b094c14a7989a9dd51cf33cbb
Reviewed-on: https://pdfium-review.googlesource.com/3430
Commit-Queue: dsinclair <dsinclair@chromium.org>
Reviewed-by: Tom Sepez <tsepez@chromium.org>
|
|
Nothing in fxbarcode/ depends on XFA code. This CL moves xfa/fxbarcode
to be fxbarcode/ and creates a static_library for fxbarcode which is
depend on by the xfa library.
Change-Id: I0b708737b07efb94b769a5238d92af92bc62880d
Reviewed-on: https://pdfium-review.googlesource.com/3291
Reviewed-by: Tom Sepez <tsepez@chromium.org>
Commit-Queue: dsinclair <dsinclair@chromium.org>
|