CS-15542, return success when vif is not there on deipassoc

This commit is contained in:
Anthony Xu 2012-09-07 17:29:49 -07:00 committed by Alex Huang
parent 5d5d69cd51
commit 945aea9c55
1 changed files with 6 additions and 1 deletions

View File

@ -1326,7 +1326,12 @@ public class VmwareResource implements StoragePoolResource, ServerResource, Vmwa
int ethDeviceNum = this.findRouterEthDeviceIndex(domrName, routerIp, ip.getVifMacAddress());
if (ethDeviceNum < 0) {
throw new InternalErrorException("Failed to find DomR VIF to associate/disassociate IP with.");
if (ip.isAdd()) {
throw new InternalErrorException("Failed to find DomR VIF to associate/disassociate IP with.");
} else {
s_logger.debug("VIF to deassociate IP with does not exist, return success");
return;
}
}
String args = "";