dom0/qvm-ls: don't crash when multiple options given

This commit is contained in:
Marek Marczykowski 2012-03-09 17:06:50 +01:00
parent cdd73f3d14
commit c7f3b1a685

View File

@ -130,12 +130,15 @@ def main():
fields_to_display += ["mem"]
if (options.network):
fields_to_display.remove ("template")
if 'template' in fields_to_display:
fields_to_display.remove ("template")
fields_to_display += ["ip", "netmask", "gateway"]
if (options.disk):
fields_to_display.remove ("template")
fields_to_display.remove ("netvm")
if 'template' in fields_to_display:
fields_to_display.remove ("template")
if 'netvm' in fields_to_display:
fields_to_display.remove ("netvm")
fields_to_display += ["priv-curr", "priv-max", "root-curr", "root-max", "disk" ]