Mount vfat devices with explicit iocharset option. [Closes: issue735]
authorUlrich Dangel <uli@spamt.net>
Tue, 10 Nov 2009 09:57:12 +0000 (10:57 +0100)
committerUlrich Dangel <uli@spamt.net>
Tue, 10 Nov 2009 09:59:20 +0000 (10:59 +0100)
grml2usb

index ce22882..487f315 100755 (executable)
--- a/grml2usb
+++ b/grml2usb
@@ -1714,11 +1714,15 @@ def handle_iso(iso, device):
         register_tmpfile(device_mountpoint)
         remove_device_mountpoint = True
         try:
-            mount(device, device_mountpoint, "")
+            check_for_fat(device)
+            mount(device, device_mountpoint, ['-o', 'utf8,iocharset=iso8859-1'])
         except CriticalException, error:
-            logging.critical("Fatal: %s", error)
-            cleanup()
-            sys.exit(1)
+            try:
+                mount(device, device_mountpoint, "")
+            except CriticalException, error:
+                logging.critical("Fatal: %s", error)
+                cleanup()
+                sys.exit(1)
 
     try:
         try: