Index: /trunk/src/org/openstreetmap/josm/gui/draw/MapViewPath.java
===================================================================
--- /trunk/src/org/openstreetmap/josm/gui/draw/MapViewPath.java	(revision 11144)
+++ /trunk/src/org/openstreetmap/josm/gui/draw/MapViewPath.java	(revision 11145)
@@ -203,5 +203,5 @@
     private class ClampingPathVisitor extends MapPath2D {
         private final MapViewRectangle clip;
-        private double strokeOffset;
+        private double strokeProgress;
         private final double strokeLength;
         private MapViewPoint lastMoveTo;
@@ -212,5 +212,5 @@
         ClampingPathVisitor(MapViewRectangle clip, double strokeOffset, double strokeLength) {
             this.clip = clip;
-            this.strokeOffset = strokeOffset;
+            this.strokeProgress = Math.min(strokeLength - strokeOffset, 0);
             this.strokeLength = strokeLength;
         }
@@ -269,5 +269,5 @@
                 cursorIsActive = exit.equals(next);
             }
-            strokeOffset += cursor.distanceToInView(next);
+            strokeProgress += cursor.distanceToInView(next);
 
             cursor = next;
@@ -282,5 +282,5 @@
 
             double distance = Math.sqrt(distanceSq);
-            double offset = ((strokeOffset + distance)) % strokeLength;
+            double offset = ((strokeProgress + distance)) % strokeLength;
             if (offset < 0.01) {
                 return entry;
