You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@cloudstack.apache.org by ap...@apache.org on 2012/06/19 07:57:26 UTC

git commit: Fix bug CS-15261 In case IP address is passed to deployVirtualMachine API, the default property on NIC was not getting set and as a result there was a failure down the line and VM creation was failing.

Updated Branches:
  refs/heads/master 590b2332d -> 817595daf


Fix bug CS-15261 In case IP address is passed to deployVirtualMachine API, the default property on NIC was not getting set and as a result there was a failure down the line and VM creation was failing.

Signed-off-by: U-CITRITE\koushikd <ko...@banlkoushikd01.citrite.net>
Signed-off-by: Abhinandan Prateek <ap...@apache.org>


Project: http://git-wip-us.apache.org/repos/asf/incubator-cloudstack/repo
Commit: http://git-wip-us.apache.org/repos/asf/incubator-cloudstack/commit/817595da
Tree: http://git-wip-us.apache.org/repos/asf/incubator-cloudstack/tree/817595da
Diff: http://git-wip-us.apache.org/repos/asf/incubator-cloudstack/diff/817595da

Branch: refs/heads/master
Commit: 817595daf864d40ac0fe47756914b2966394e825
Parents: 590b233
Author: U-CITRITE\\koushikd <ko...@banlkoushikd01.citrite.net>
Authored: Thu Jun 14 14:24:39 2012 +0530
Committer: Abhinandan Prateek <ap...@apache.org>
Committed: Tue Jun 19 06:53:43 2012 +0100

----------------------------------------------------------------------
 server/src/com/cloud/vm/UserVmManagerImpl.java |    3 ++-
 1 files changed, 2 insertions(+), 1 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-cloudstack/blob/817595da/CS-15261.patch
----------------------------------------------------------------------
diff --git a/CS-15261.patch b/CS-15261.patch
new file mode 100644
index 0000000..e69de29

http://git-wip-us.apache.org/repos/asf/incubator-cloudstack/blob/817595da/server/src/com/cloud/vm/UserVmManagerImpl.java
----------------------------------------------------------------------
diff --git a/server/src/com/cloud/vm/UserVmManagerImpl.java b/server/src/com/cloud/vm/UserVmManagerImpl.java
index ba76d22..101e35a 100755
--- a/server/src/com/cloud/vm/UserVmManagerImpl.java
+++ b/server/src/com/cloud/vm/UserVmManagerImpl.java
@@ -2347,11 +2347,12 @@ public class UserVmManagerImpl implements UserVmManager, UserVmService, Manager
             
             if (defaultNetworkNumber == 0) {
             	 defaultNetworkNumber++;
-            	 profile.setDefaultNic(true);
                  // if user requested specific ip for default network, add it
                  if (defaultNetworkIp != null) {
                      profile = new NicProfile(defaultNetworkIp);
                  }
+
+            	 profile.setDefaultNic(true);
             }
 
             networks.add(new Pair<NetworkVO, NicProfile>(network, profile));