You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@cloudstack.apache.org by ed...@apache.org on 2014/01/09 02:08:16 UTC

git commit: updated refs/heads/4.3 to 1f70154

Updated Branches:
  refs/heads/4.3 693f0c280 -> 1f70154c3


CLOUDSTACK-5831: Fix NPE, in case the volume isn't attached to any pool


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

Branch: refs/heads/4.3
Commit: 1f70154c34d51d9ffb3d4cc82f23f08ca78c7fc3
Parents: 693f0c2
Author: edison <su...@gmail.com>
Authored: Wed Jan 8 17:07:45 2014 -0800
Committer: edison <su...@gmail.com>
Committed: Wed Jan 8 17:07:45 2014 -0800

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


http://git-wip-us.apache.org/repos/asf/cloudstack/blob/1f70154c/server/src/com/cloud/api/query/QueryManagerImpl.java
----------------------------------------------------------------------
diff --git a/server/src/com/cloud/api/query/QueryManagerImpl.java b/server/src/com/cloud/api/query/QueryManagerImpl.java
index 3d908b4..9045550 100644
--- a/server/src/com/cloud/api/query/QueryManagerImpl.java
+++ b/server/src/com/cloud/api/query/QueryManagerImpl.java
@@ -1644,6 +1644,10 @@ public class QueryManagerImpl extends ManagerBase implements QueryService {
                 new VolumeJoinVO[result.first().size()]));
         for(VolumeResponse vr : volumeResponses) {
             String poolId = vr.getStoragePoolId();
+            if (poolId == null) {
+                continue;
+            }
+
             DataStore store = dataStoreManager.getPrimaryDataStore(poolId);
             if (store == null) {
                 continue;