2 commits - liveusb/creator.py liveusb/gui.py

Luke Macken lmacken at fedoraproject.org
Sat Jan 3 00:01:02 UTC 2009


 liveusb/creator.py |    6 +++---
 liveusb/gui.py     |    1 -
 2 files changed, 3 insertions(+), 4 deletions(-)

New commits:
commit 32a592aace66cc318ce920dcf1340d9c4580f2e6
Author: Luke Macken <lmacken at redhat.com>
Date:   Fri Jan 2 18:55:03 2009 -0500

    Fix our syslinux -d flag for linux

diff --git a/liveusb/creator.py b/liveusb/creator.py
index 7897374..421adc1 100755
--- a/liveusb/creator.py
+++ b/liveusb/creator.py
@@ -520,7 +520,7 @@ class LinuxLiveUSBCreator(LiveUSBCreator):
         os.unlink(os.path.join(self.dest, "syslinux", "isolinux.cfg"))
         self.popen('syslinux%s%s -d %s %s' %  (self.opts.force and ' -f' or ' ',
                    self.opts.safe and ' -s' or ' ',
-                   os.path.join(self.dest, 'syslinux'), self.drive['device']))
+                   'syslinux', self.drive['device']))
 
     def get_free_bytes(self, device=None):
         """ Return the number of available bytes on our device """


commit 0e78c9e6de065133f83a99077c7556463c1a8a64
Author: Luke Macken <lmacken at redhat.com>
Date:   Fri Jan 2 18:54:36 2009 -0500

    Revert our unmount change, as this sometimes causes random segfaults.

diff --git a/liveusb/creator.py b/liveusb/creator.py
index 025e0bd..7897374 100755
--- a/liveusb/creator.py
+++ b/liveusb/creator.py
@@ -431,7 +431,7 @@ class LinuxLiveUSBCreator(LiveUSBCreator):
         """ Unmount our device """
         import dbus
         unmount = self.drive.get('unmount', None)
-        if self.dest:
+        if self.dest and unmount:
             self.log.debug("Unmounting %s from %s" % (self.drive['device'],
                                                       self.dest))
             try:
@@ -537,13 +537,13 @@ class LinuxLiveUSBCreator(LiveUSBCreator):
 
     def terminate(self):
         import signal
-        self.log.info("Cleaning up...")
         for pid in self.pids:
             try:
                 os.kill(pid, signal.SIGHUP)
                 self.log.debug("Killed process %d" % pid)
             except OSError:
                 pass
+        self.unmount_device()
 
     def verify_iso_md5(self):
         """ Verify the ISO md5sum.
diff --git a/liveusb/gui.py b/liveusb/gui.py
index 8d73e74..39045b8 100755
--- a/liveusb/gui.py
+++ b/liveusb/gui.py
@@ -193,7 +193,6 @@ class LiveUSBThread(QtCore.QThread):
             self.live.update_configs()
             self.live.install_bootloader()
             self.live.bootable_partition()
-            self.live.unmount_device()
 
             duration = str(datetime.now() - now).split('.')[0]
             self.status(_("Complete! (%s)" % duration))




More information about the liveusb-creator mailing list