You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@cloudstack.apache.org by ra...@apache.org on 2017/02/23 06:39:25 UTC

[2/4] git commit: updated refs/heads/master to cd68e99

CLOUDSTACK-8857 listProjects doesn't return tags vmstopped or vmrunning when their value is zero


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

Branch: refs/heads/master
Commit: c6e9d82595aa3461d72907ae75817eae4527ba63
Parents: 7da95172
Author: Bharat Kumar <bh...@citrix.com>
Authored: Thu Feb 19 10:40:16 2015 +0530
Committer: Bharat Kumar <bh...@accelerite.com>
Committed: Mon Dec 12 13:36:46 2016 +0530

----------------------------------------------------------------------
 server/src/com/cloud/api/query/dao/AccountJoinDaoImpl.java | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/cloudstack/blob/c6e9d825/server/src/com/cloud/api/query/dao/AccountJoinDaoImpl.java
----------------------------------------------------------------------
diff --git a/server/src/com/cloud/api/query/dao/AccountJoinDaoImpl.java b/server/src/com/cloud/api/query/dao/AccountJoinDaoImpl.java
index b110478..a8d3b68 100644
--- a/server/src/com/cloud/api/query/dao/AccountJoinDaoImpl.java
+++ b/server/src/com/cloud/api/query/dao/AccountJoinDaoImpl.java
@@ -162,8 +162,8 @@ public class AccountJoinDaoImpl extends GenericDaoBase<AccountJoinVO, Long> impl
         response.setTemplateAvailable(templateAvail);
 
         // Get stopped and running VMs
-        response.setVmStopped(account.getVmStopped());
-        response.setVmRunning(account.getVmRunning());
+        response.setVmStopped(account.getVmStopped()!=null ? account.getVmStopped() : 0);
+        response.setVmRunning(account.getVmRunning()!=null ? account.getVmRunning() : 0);
 
         //get resource limits for networks
         long networkLimit = ApiDBUtils.findCorrectResourceLimit(account.getNetworkLimit(), account.getId(), ResourceType.network);