ia64/xen-unstable

changeset 6735:5c49ed1145cc

Fix xm info handling of empty strings (fix bugzilla bug #216)

Signed-off-by: Steven Hand <steven@xensource.com>
author shand@ubuntu.eng.hq.xensource.com
date Fri Sep 09 15:11:18 2005 -0800 (2005-09-09)
parents 41a74438bcba
children 4b2c87242ad3 bf58d21a1e3a
files tools/python/xen/xm/main.py
line diff
     1.1 --- a/tools/python/xen/xm/main.py	Fri Sep 09 10:36:48 2005 -0800
     1.2 +++ b/tools/python/xen/xm/main.py	Fri Sep 09 15:11:18 2005 -0800
     1.3 @@ -450,7 +450,10 @@ def xm_info(args):
     1.4      info = server.xend_node()
     1.5      
     1.6      for x in info[1:]:
     1.7 -        print "%-23s:" % x[0], x[1]
     1.8 +        if len(x) < 2: 
     1.9 +            print "%-23s: (none)" % x[0]
    1.10 +        else: 
    1.11 +            print "%-23s:" % x[0], x[1]
    1.12  
    1.13  # TODO: remove as soon as console server shows up
    1.14  def xm_console(args):