Index: /applications/editors/josm/plugins/validator/src/org/openstreetmap/josm/plugins/validator/tests/UnclosedWays.java
===================================================================
--- /applications/editors/josm/plugins/validator/src/org/openstreetmap/josm/plugins/validator/tests/UnclosedWays.java	(revision 13597)
+++ /applications/editors/josm/plugins/validator/src/org/openstreetmap/josm/plugins/validator/tests/UnclosedWays.java	(revision 13598)
@@ -8,5 +8,5 @@
 import java.util.List;
 
-import org.openstreetmap.josm.data.coor.LatLon;
+import org.openstreetmap.josm.data.osm.Node;
 import org.openstreetmap.josm.data.osm.OsmPrimitive;
 import org.openstreetmap.josm.data.osm.OsmUtils;
@@ -103,16 +103,17 @@
             set(true, 1130, marktr("area"));
 
-        if (type != null) {
-            LatLon s = w.nodes.get(0).coor;
-            LatLon e = w.nodes.get(w.nodes.size() - 1).coor;
-            /* take unclosed ways with end-to-end-distance below 10 km */
-            if (s != e && (force || s.greatCircleDistance(e) < 10000)) {
+        if (type != null && !w.isClosed())
+        {
+            Node f = w.nodes.get(0);
+            Node l = w.nodes.get(w.nodes.size() - 1);
+            if(force || f.coor.greatCircleDistance(l.coor) < 10000)
+            {
                 List<OsmPrimitive> primitives = new ArrayList<OsmPrimitive>();
                 List<OsmPrimitive> highlight = new ArrayList<OsmPrimitive>();
                 primitives.add(w);
-                // The important parts of an unclosed way are the first and 
+                // The important parts of an unclosed way are the first and
                 // the last node which should be connected, therefore we highlight them
-                highlight.add(w.nodes.get(0)); 
-                highlight.add(w.nodes.get(w.nodes.size() - 1));
+                highlight.add(f);
+                highlight.add(l);
                 errors.add(new TestError(this, Severity.WARNING, tr("Unclosed way"), type, etype, mode, primitives,
                         highlight));
Index: /applications/editors/josm/plugins/validator/src/org/openstreetmap/josm/plugins/validator/tests/UnconnectedWays.java
===================================================================
--- /applications/editors/josm/plugins/validator/src/org/openstreetmap/josm/plugins/validator/tests/UnconnectedWays.java	(revision 13597)
+++ /applications/editors/josm/plugins/validator/src/org/openstreetmap/josm/plugins/validator/tests/UnconnectedWays.java	(revision 13598)
@@ -83,5 +83,5 @@
             for(MyWaySegment s : ways)
             {
-                if(!s.highway && s.nearby(en, mindist))
+                if(!s.highway && s.nearby(en, mindist) && !s.isArea())
                     map.put(en, s.w);
             }
@@ -91,5 +91,5 @@
             for(MyWaySegment s : ways)
             {
-                if(s.nearby(en, mindist))
+                if(s.nearby(en, mindist) && !s.isArea())
                     map.put(en, s.w);
             }
@@ -166,4 +166,10 @@
             return !w.nodes.contains(n)
             && line.ptSegDist(n.eastNorth.east(), n.eastNorth.north()) < dist;
+        }
+        
+        public boolean isArea() {
+            return w.get("landuse") != null
+                || w.get("leisure") != null
+                || w.get("building") != null;
         }
     }
