mirror of
https://github.com/zxing/zxing.git
synced 2025-03-05 20:48:51 -08:00
False positive avoidance
git-svn-id: https://zxing.googlecode.com/svn/trunk@1885 59b500cc-1b3d-0410-9834-0bbf25fbcc57
This commit is contained in:
parent
4863e3ed8c
commit
ecd6a7d77d
|
@ -448,7 +448,7 @@ public final class Code128Reader extends OneDReader {
|
||||||
|
|
||||||
String resultString = result.toString();
|
String resultString = result.toString();
|
||||||
|
|
||||||
if (resultString.length() == 0) {
|
if (resultString.length() < 2) {
|
||||||
// Almost surely a false positive
|
// Almost surely a false positive
|
||||||
throw FormatException.getFormatInstance();
|
throw FormatException.getFormatInstance();
|
||||||
}
|
}
|
||||||
|
|
|
@ -92,7 +92,7 @@ public final class Code93Reader extends OneDReader {
|
||||||
throw NotFoundException.getNotFoundInstance();
|
throw NotFoundException.getNotFoundInstance();
|
||||||
}
|
}
|
||||||
|
|
||||||
if (result.length() < 2) {
|
if (result.length() < 4) {
|
||||||
// Almost surely a false positive
|
// Almost surely a false positive
|
||||||
throw NotFoundException.getNotFoundInstance();
|
throw NotFoundException.getNotFoundInstance();
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue