summaryrefslogtreecommitdiff
path: root/javase
AgeCommit message (Collapse)AuthorFilesLines
2026-06-26reject negative and overflowing crop in BufferedImageLuminanceSource (#2111)jmestwa-coder2-1/+30
2026-06-22Validate crop rectangle for TYPE_BYTE_GRAY images in ↵Vasiliy Mikhailov2-5/+75
BufferedImageLuminanceSource (#2107) The crop-bounds check was only in the else branch, so TYPE_BYTE_GRAY images skipped it and an out-of-bounds crop was accepted, failing later with an ArrayIndexOutOfBoundsException instead of IllegalArgumentException. Hoist the check above the image-type branch so it applies to all images. Adds a test.
2026-06-22wrap invalid base64 as IOException in readDataURIImage (#2105)jmestwa-coder2-2/+13
2026-04-08Fix QR decode failure for small/native-size images (#2061)Andrew Szeto1-0/+54
* Fix QR decode failure for small/native-size images (#1976) QRCodeWriter.encode(..., 0, 0) produces a 33x33 native-size QR that ZXing cannot decode. The CENTER_QUORUM filter in selectBestPatterns() (added in 110ef9e to fix #1567) removes finder patterns with count < 2. For small images, the row-skip interval (iSkip=3, MIN_SKIP) means the scanner only crosses the top two finder pattern centers on a single row each, giving them count=1. The bottom-left pattern gets count=2 because it's scanned after iSkip drops to 2. The filter then removes the two count=1 patterns, leaving 1 of the 3 needed, and throws NotFoundException. The fix: only apply the CENTER_QUORUM filter when either (a) at least 3 confirmed patterns would survive, or (b) the total candidate list exceeds a size threshold. This preserves #1567 protection while allowing small images through. Why a size threshold: the filter was added to prevent O(n^3) blowup in the triangle-selection loop when noisy images produce thousands of spurious candidates. When the candidate list is small (<= 25 entries, yielding <= ~2300 loop iterations), the cubic cost is negligible regardless of whether the patterns are real or spurious. A clean single-QR image produces ~3 candidates; even a noisy image below the threshold is computationally trivial. Above the threshold, the filter applies unconditionally, matching today's behavior. Alternatives considered: - Removing the filter entirely: all 561 existing tests pass, but re-opens #1567 for pathological images with thousands of spurious count=1 candidates. - Reducing MIN_SKIP from 3 to 1 for small images: addresses the symptom (more scan rows = higher counts) but doesn't fix the fundamental interaction between iSkip and the quorum filter, and changes scan behavior for all small images. - Fallback (try with filter, retry without on failure): re-opens #1567 whenever fewer than 3 confirmed patterns exist, which is exactly the scenario that produces thousands of unconfirmed candidates in noisy images. * Increase noisy-image test timeout from 5s to 30s GitHub shared runners timed out at 5s. Local measurement shows ~1.2s, implying at least 4x slowdown on CI. 30s gives a comfortable margin while still catching the O(n^3) regression from #1567.
2025-11-11[maven-release-plugin] prepare for next development iterationSean Owen1-2/+2
2025-11-11[maven-release-plugin] prepare release zxing-3.5.4zxing-3.5.4Sean Owen1-1/+1
2025-11-11Restore 3.5.4-SNAPSHOTSean Owen1-1/+1
2025-11-11[maven-release-plugin] prepare release zxing-3.5.4Sean Owen1-2/+2
2025-11-11[maven-release-plugin] rollback the release of zxing-3.5.4Sean Owen1-2/+2
2025-11-11[maven-release-plugin] prepare for next development iterationSean Owen1-2/+2
2025-11-11[maven-release-plugin] prepare release zxing-3.5.4Sean Owen1-2/+2
2025-11-11[maven-release-plugin] rollback the release of zxing-3.5.4Sean Owen1-2/+2
2025-11-11[maven-release-plugin] prepare release zxing-3.5.4Sean Owen1-2/+2
2024-09-09Update plugins and depsSean Owen1-1/+1
2024-04-16Update jcommander 1.82 -> 1.83 (#1793)Matthew Zavislak1-2/+2
Switch to current artifact name `org.jcommander:jcommander` https://jcommander.org/#_download
2024-01-31[maven-release-plugin] prepare for next development iterationSean Owen1-2/+2
2024-01-31[maven-release-plugin] prepare release zxing-3.5.3zxing-3.5.3Sean Owen1-2/+2
2023-09-07Prevent --raw CLR option from failing if result.getRawBytes() is null (#1683)Dan Lenski1-6/+9
Fixes https://github.com/zxing/zxing/issues/1682
2023-07-30[maven-release-plugin] prepare for next development iterationSean Owen1-2/+2
2023-07-30[maven-release-plugin] prepare release zxing-3.5.2zxing-3.5.2Sean Owen1-2/+2
2023-07-30[maven-release-plugin] rollback the release of zxing-3.5.2Sean Owen1-2/+2
2023-07-30[maven-release-plugin] prepare for next development iterationSean Owen1-2/+2
2023-07-30[maven-release-plugin] prepare release zxing-3.5.2Sean Owen1-2/+2
2023-07-30[maven-release-plugin] rollback the release of zxing-3.5.2Sean Owen1-2/+2
2023-07-30[maven-release-plugin] prepare for next development iterationSean Owen1-2/+2
2023-07-30[maven-release-plugin] prepare release zxing-3.5.2Sean Owen1-2/+2
2023-07-21javase/test/matrix: check format support (#1668)Valérian Rousset1-5/+10
2022-11-02[maven-release-plugin] prepare for next development iterationSean Owen1-2/+2
2022-11-02[maven-release-plugin] prepare release zxing-3.5.1zxing-3.5.1Sean Owen1-2/+2
2022-10-24Use SwingUtilities to avoid deadlock in GUI mini appSean Owen1-5/+16
2022-05-01[maven-release-plugin] prepare for next development iterationSean Owen1-2/+2
2022-05-01[maven-release-plugin] prepare release zxing-3.5.0zxing-3.5.0Sean Owen1-2/+2
2022-02-17Update to 3.5.0-SNAPSHOT for next release; deps updatesSean Owen1-3/+3
2022-01-14Set FEATURE_SECURE_PROCESSING when reading XML in HtmlAssetTranslator, just ↵Sean Owen1-1/+3
in case (#1482)
2021-10-13Minor code style updates to MinimalEncoder and a few other files ; minor dep ↵Sean Owen1-1/+1
updates
2021-10-05Enforce line length and indent in checkstyle (#1448)Sean Owen1-2/+3
2021-09-28Add option to output raw bitstream from CommandLineRunner. (#1442)Anders Hammarquist2-0/+17
* Add option to output raw bitstream from CommandLineRunner. Useful for debugging barcodes. Same as the web decoder. * Use StringBuilder. Fix indentation.
2021-04-02Update dependencies and add one new testSean Owen1-1/+1
2020-12-09Improve test coverageSean Owen4-7/+31
2020-09-30[maven-release-plugin] prepare for next development iterationSean Owen1-2/+2
2020-09-30[maven-release-plugin] prepare release zxing-3.4.1zxing-3.4.1Sean Owen1-2/+2
2020-09-30[maven-release-plugin] rollback the release of zxing-3.4.1Sean Owen1-2/+2
2020-09-30[maven-release-plugin] prepare release zxing-3.4.1Sean Owen1-2/+2
2020-09-29[maven-release-plugin] rollback the release of zxing-3.4.1Sean Owen1-2/+2
2020-09-29[maven-release-plugin] prepare for next development iterationSean Owen1-2/+2
2020-09-29[maven-release-plugin] prepare release zxing-3.4.1Sean Owen1-2/+2
2019-12-12Plugin updates; misc code simplifications and optimizationsSean Owen2-12/+13
2019-05-18[maven-release-plugin] prepare for next development iterationSean Owen1-2/+2
2019-05-18[maven-release-plugin] prepare release zxing-3.4.0zxing-3.4.0Sean Owen1-2/+2
2019-05-16Add module name to javaseSean Owen1-0/+11