From 3fb00de77fae03538fc03c78ea31298a280aac37 Mon Sep 17 00:00:00 2001 From: Evgeni Golov Date: Mon, 13 May 2013 09:21:50 +0200 Subject: [PATCH] "if not" also triggers when value is 0, use "if is None" instead --- grml2usb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/grml2usb b/grml2usb index e2cffe8..e1d7f5c 100755 --- a/grml2usb +++ b/grml2usb @@ -1556,7 +1556,7 @@ def handle_mbr(device): return 0 mbr_device, partition_number = get_device_from_partition(device) - if not partition_number: + if partition_number is None: logging.warn("Could not detect partition number, not activating partition") # if we get e.g. /dev/loop1 as device we don't want to put the MBR -- 2.1.4