Don't confuse {KB, MB, GB} with {KiB, MiB, GiB}.
[invirt/packages/invirt-remote.git] / host / usr / sbin / invirt-lvm
index 78ce700..22a7805 100755 (executable)
@@ -67,7 +67,7 @@ if subcommand == "lvremove":
     # it. There's not really anything sane to do with errors (since
     # this is running non-interactively), so let's just drop them on
     # the floor for now.
     # it. There's not really anything sane to do with errors (since
     # this is running non-interactively), so let's just drop them on
     # the floor for now.
-    if os.fork() != 0:
+    if os.fork() == 0:
         call(["/bin/dd", "if=/dev/zero", "of=%s" % new_lvpath])
         call(["/sbin/lvchange", "-a", "n", new_lvpath])
         call(["/sbin/lvchange", "-a", "ey", new_lvpath])
         call(["/bin/dd", "if=/dev/zero", "of=%s" % new_lvpath])
         call(["/sbin/lvchange", "-a", "n", new_lvpath])
         call(["/sbin/lvchange", "-a", "ey", new_lvpath])