X-Git-Url: http://git.grml.org/?p=grml2usb.git;a=blobdiff_plain;f=grml2usb;h=749fcd1d412ec3510afa43fb0e1da7a0ee5b0a25;hp=867bea0a9f0e69cb2d2647fbd77108844fedab40;hb=657b880f0229f3e11d7eff07f0b285bf708606ff;hpb=fcf63b74e77193db1cc5e797e79f20736de23222 diff --git a/grml2usb b/grml2usb index 867bea0..749fcd1 100755 --- a/grml2usb +++ b/grml2usb @@ -503,6 +503,12 @@ def get_partition_for_path(path): def check_boot_flag(device): + if os.path.isdir(device): + logging.debug( + "Device %s is a directory, skipping check for boot flag." % device + ) + return + boot_dev, x = get_device_from_partition(device) logging.info("Checking for boot flag") @@ -1881,10 +1887,6 @@ def install_grml(mountpoint, device): register_tmpfile(device_mountpoint) remove_device_mountpoint = True try: - check_for_fat(device) - if not options.skipbootflag: - check_boot_flag(device) - set_rw(device) mount(device, device_mountpoint, ["-o", "utf8,iocharset=iso8859-1"]) except CriticalException: @@ -2169,6 +2171,9 @@ def main(): # provide upgrade path handle_compat_warning(device) + if not options.skipbootflag: + check_boot_flag(device) + # check for vfat partition handle_vfat(device)