Index: /trunk/src/org/openstreetmap/josm/data/osm/visitor/paint/StyledMapRenderer.java
===================================================================
--- /trunk/src/org/openstreetmap/josm/data/osm/visitor/paint/StyledMapRenderer.java	(revision 6925)
+++ /trunk/src/org/openstreetmap/josm/data/osm/visitor/paint/StyledMapRenderer.java	(revision 6926)
@@ -112,5 +112,9 @@
             if (idx == nodes.size() - 1) {
                 ++idx;
-                return new Point(x_prev0 + current.x - prev.x, y_prev0 + current.y - prev.y);
+                if (prev != null) {
+                    return new Point(x_prev0 + current.x - prev.x, y_prev0 + current.y - prev.y);
+                } else {
+                    return current;
+                }
             }
 
