Index: /applications/editors/josm/plugins/czechaddress/src/org/openstreetmap/josm/plugins/czechaddress/StringUtils.java
===================================================================
--- /applications/editors/josm/plugins/czechaddress/src/org/openstreetmap/josm/plugins/czechaddress/StringUtils.java	(revision 18893)
+++ /applications/editors/josm/plugins/czechaddress/src/org/openstreetmap/josm/plugins/czechaddress/StringUtils.java	(revision 18894)
@@ -111,4 +111,9 @@
     }
 
+    public static String tryTrim(String s) {
+        if (s == null) return null;
+        return s.trim();
+    }
+
     /**
      * Capitalizes the given string (first letter of every word upper-case,
Index: /applications/editors/josm/plugins/czechaddress/src/org/openstreetmap/josm/plugins/czechaddress/parser/MvcrParser.java
===================================================================
--- /applications/editors/josm/plugins/czechaddress/src/org/openstreetmap/josm/plugins/czechaddress/parser/MvcrParser.java	(revision 18893)
+++ /applications/editors/josm/plugins/czechaddress/src/org/openstreetmap/josm/plugins/czechaddress/parser/MvcrParser.java	(revision 18894)
@@ -2,4 +2,5 @@
 
 import static org.openstreetmap.josm.plugins.czechaddress.StringUtils.capitalize;
+import static org.openstreetmap.josm.plugins.czechaddress.StringUtils.tryTrim;
 
 import java.io.FileInputStream;
@@ -43,6 +44,6 @@
         if (name.equals("a")) {
 
-            String cp = attributes.getValue("p");
-            String co = attributes.getValue("o");
+            String cp = tryTrim(attributes.getValue("p"));
+            String co = tryTrim(attributes.getValue("o"));
             if ((cp == null) && (co == null))
                 return;
@@ -59,5 +60,5 @@
         // ========== PARSING STREET ========== //
         if (name.equals("ulice")) {
-            String nazev = attributes.getValue("nazev");
+            String nazev = tryTrim(attributes.getValue("nazev"));
 
             // If the street filter is on, apply it!
@@ -85,5 +86,5 @@
                 return;
 
-            String nazev = attributes.getValue("nazev");
+            String nazev = tryTrim(attributes.getValue("nazev"));
 
             // If the suburb filter is on, apply it!
@@ -106,5 +107,5 @@
         if (name.equals("obec")) {
 
-            String nazev = attributes.getValue("nazev");
+            String nazev = tryTrim(attributes.getValue("nazev"));
 
             // If the viToCi filter is on, apply it!
@@ -129,5 +130,6 @@
 
             // If the region filter is on, apply it!
-            if (filRegion != null && !attributes.getValue("nazev").equals(filRegion)) {
+            if (filRegion != null &&
+                    !attributes.getValue("nazev").trim().equals(filRegion)) {
                 curRegion = null;
                 curViToCi = null;
@@ -144,7 +146,7 @@
             if (curRegion == null) {*/
                 curRegion = new Region(
-                    capitalize(attributes.getValue("nazev")),
-                    capitalize(attributes.getValue("kraj")),
-                    capitalize(attributes.getValue("okres")));
+                    capitalize(tryTrim(attributes.getValue("nazev"))),
+                    capitalize(tryTrim(attributes.getValue("kraj"))),
+                    capitalize(tryTrim(attributes.getValue("okres"))));
 
                 target.regions.add(curRegion);
