mirror of
https://github.com/zxing/zxing.git
synced 2025-03-05 20:48:51 -08:00
Avoid possible NPE when there is no bounding box?
git-svn-id: https://zxing.googlecode.com/svn/trunk@2801 59b500cc-1b3d-0410-9834-0bbf25fbcc57
This commit is contained in:
parent
5214bf1840
commit
2561cb3ce6
|
@ -72,7 +72,7 @@ public final class PDF417ScanningDecoder {
|
||||||
if (detectionResult == null) {
|
if (detectionResult == null) {
|
||||||
throw NotFoundException.getNotFoundInstance();
|
throw NotFoundException.getNotFoundInstance();
|
||||||
}
|
}
|
||||||
if (i == 0 &&
|
if (i == 0 && detectionResult.getBoundingBox() != null &&
|
||||||
(detectionResult.getBoundingBox().getMinY() < boundingBox.getMinY() || detectionResult.getBoundingBox()
|
(detectionResult.getBoundingBox().getMinY() < boundingBox.getMinY() || detectionResult.getBoundingBox()
|
||||||
.getMaxY() > boundingBox.getMaxY())) {
|
.getMaxY() > boundingBox.getMaxY())) {
|
||||||
boundingBox = detectionResult.getBoundingBox();
|
boundingBox = detectionResult.getBoundingBox();
|
||||||
|
|
Loading…
Reference in a new issue