Oops realized DM decoder also benefits from that last possible fix
[zxing.git] / core / src / com / google / zxing / datamatrix / detector / Detector.java
index a22db60..aa81d8c 100644 (file)
@@ -237,6 +237,9 @@ public final class Detector {
       if (error > 0) {
         y += ystep;
         error -= dx;
+        if (y == toY) {
+          break;
+        }
       }
     }
     return new ResultPointsAndTransitions(from, to, transitions);