changeset 4887:1f6e544f7a7f

Importer: Use cp1252 instead of latin-9 to guess filename encodings
author Andre Heinecke <aheinecke@intevation.de>
date Mon, 28 Jan 2013 12:45:41 +0100
parents 8e99d2d9364d
children 3f0c8ef42b7a 28f992c0f937
files flys-backend/contrib/shpimporter/utils.py
diffstat 1 files changed, 2 insertions(+), 2 deletions(-) [+]
line wrap: on
line diff
--- a/flys-backend/contrib/shpimporter/utils.py	Mon Jan 28 12:44:41 2013 +0100
+++ b/flys-backend/contrib/shpimporter/utils.py	Mon Jan 28 12:45:41 2013 +0100
@@ -29,5 +29,5 @@
     try:
         return unicode.encode(unicode(path, sys.getfilesystemencoding()), "UTF-8")
     except UnicodeDecodeError:
-        # Probably Windows iso-8859-x names so lets try again
-        return unicode.encode(unicode(path, "iso-8859-15"), "UTF-8")
+        # Probably European Windows names so lets try again
+        return unicode.encode(unicode(path, "cp1252"), "UTF-8")

http://dive4elements.wald.intevation.org