You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@cloudstack.apache.org by pr...@apache.org on 2013/05/16 20:22:18 UTC
[53/68] [abbrv] git commit: updated refs/heads/planner_reserve to
ed8ff40
CLOUDSTACK-2515: Verify if the targetPath isn't null before comparing
Project: http://git-wip-us.apache.org/repos/asf/cloudstack/repo
Commit: http://git-wip-us.apache.org/repos/asf/cloudstack/commit/68a428f8
Tree: http://git-wip-us.apache.org/repos/asf/cloudstack/tree/68a428f8
Diff: http://git-wip-us.apache.org/repos/asf/cloudstack/diff/68a428f8
Branch: refs/heads/planner_reserve
Commit: 68a428f84dea9c051456882d6762f419c40d90db
Parents: 9b65134
Author: Wido den Hollander <wi...@widodh.nl>
Authored: Wed May 15 13:57:58 2013 +0200
Committer: Wido den Hollander <wi...@widodh.nl>
Committed: Wed May 15 13:57:58 2013 +0200
----------------------------------------------------------------------
.../kvm/storage/LibvirtStorageAdaptor.java | 3 ++-
1 files changed, 2 insertions(+), 1 deletions(-)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/cloudstack/blob/68a428f8/plugins/hypervisors/kvm/src/com/cloud/hypervisor/kvm/storage/LibvirtStorageAdaptor.java
----------------------------------------------------------------------
diff --git a/plugins/hypervisors/kvm/src/com/cloud/hypervisor/kvm/storage/LibvirtStorageAdaptor.java b/plugins/hypervisors/kvm/src/com/cloud/hypervisor/kvm/storage/LibvirtStorageAdaptor.java
index 8f58719..e7e4bbf 100644
--- a/plugins/hypervisors/kvm/src/com/cloud/hypervisor/kvm/storage/LibvirtStorageAdaptor.java
+++ b/plugins/hypervisors/kvm/src/com/cloud/hypervisor/kvm/storage/LibvirtStorageAdaptor.java
@@ -465,7 +465,8 @@ public class LibvirtStorageAdaptor implements StorageAdaptor {
StoragePool p = conn.storagePoolLookupByName(poolname);
LibvirtStoragePoolDef pdef = getStoragePoolDef(conn, p);
- if (pdef.getTargetPath().equals(path)) {
+ String targetPath = pdef.getTargetPath();
+ if (targetPath != null && targetPath.equals(path)) {
s_logger.debug("Storage pool utilizing path '" + path + "' already exists as pool "
+ poolname + ", undefining so we can re-define with correct name " + name);
if (p.isPersistent() == 1) {