incubator-tashi-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From mry...@apache.org
Subject svn commit: r792662 - /incubator/tashi/trunk/src/tashi/clustermanager/clustermanagerservice.py
Date Thu, 09 Jul 2009 20:18:51 GMT
Author: mryan3
Date: Thu Jul  9 20:18:51 2009
New Revision: 792662

URL: http://svn.apache.org/viewvc?rev=792662&view=rev
Log:
Minor bug fix in updateVm -- an exception was raised during some other updateVm operations
since the changes to add an IP address were introduced


Modified:
    incubator/tashi/trunk/src/tashi/clustermanager/clustermanagerservice.py

Modified: incubator/tashi/trunk/src/tashi/clustermanager/clustermanagerservice.py
URL: http://svn.apache.org/viewvc/incubator/tashi/trunk/src/tashi/clustermanager/clustermanagerservice.py?rev=792662&r1=792661&r2=792662&view=diff
==============================================================================
--- incubator/tashi/trunk/src/tashi/clustermanager/clustermanagerservice.py (original)
+++ incubator/tashi/trunk/src/tashi/clustermanager/clustermanagerservice.py Thu Jul  9 20:18:51
2009
@@ -440,11 +440,12 @@
 				oldInstance.vmId = instance.vmId
 			if (instance.hostId):
 				oldInstance.hostId = instance.hostId
-			for nic in instance.nics:
-				if (nic.ip):
-					for oldNic in oldInstance.nics:
-						if (oldNic.mac == nic.mac):
-							oldNic.ip = nic.ip
+			if (instance.nics):
+				for nic in instance.nics:
+					if (nic.ip):
+						for oldNic in oldInstance.nics:
+							if (oldNic.mac == nic.mac):
+								oldNic.ip = nic.ip
 			oldInstance.decayed = False
 			self.updateDecay(self.decayedInstances, oldInstance)
 			self.data.releaseInstance(oldInstance)



Mime
View raw message