- if dev == None:
- logger.error("Error retrieving instance for devid %s" % devid)
This is verifying that we get an instance back. It's not likely to
happen, but the GetInstance() call could fail to find the instance but
return a successful return code.
+ if dev.DeviceID == None:
Instead of dev.DeviceID == None, should this be dev.DeviceID != devid?
+ logger.error("Error retrieving instance for devid
%s" % dev.DeviceID)
I think this error message would make more sense as something like:
"DeviceID reported incorrectly (%s instead of %s)" % (dev.DeviceID, devid)
cxml.undefine(options.ip)
return FAIL
--
Kaitlin Rupert
IBM Linux Technology Center
kaitlin(a)linux.vnet.ibm.com