You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@cloudstack.apache.org by su...@apache.org on 2024/06/28 13:16:12 UTC

(cloudstack) branch 4.18 updated: Fixed src datastore on copy check for PowerFlex/ScaleIO storage driver (#9310)

This is an automated email from the ASF dual-hosted git repository.

sureshanaparti pushed a commit to branch 4.18
in repository https://gitbox.apache.org/repos/asf/cloudstack.git


The following commit(s) were added to refs/heads/4.18 by this push:
     new 983f164c57f Fixed src datastore on copy check for PowerFlex/ScaleIO storage driver (#9310)
983f164c57f is described below

commit 983f164c57fb47ccacd6b9eb1eb9448191a72150
Author: Suresh Kumar Anaparti <su...@gmail.com>
AuthorDate: Fri Jun 28 18:46:06 2024 +0530

    Fixed src datastore on copy check for PowerFlex/ScaleIO storage driver (#9310)
---
 .../storage/datastore/driver/ScaleIOPrimaryDataStoreDriver.java         | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/plugins/storage/volume/scaleio/src/main/java/org/apache/cloudstack/storage/datastore/driver/ScaleIOPrimaryDataStoreDriver.java b/plugins/storage/volume/scaleio/src/main/java/org/apache/cloudstack/storage/datastore/driver/ScaleIOPrimaryDataStoreDriver.java
index 431fddb566f..600720d594a 100644
--- a/plugins/storage/volume/scaleio/src/main/java/org/apache/cloudstack/storage/datastore/driver/ScaleIOPrimaryDataStoreDriver.java
+++ b/plugins/storage/volume/scaleio/src/main/java/org/apache/cloudstack/storage/datastore/driver/ScaleIOPrimaryDataStoreDriver.java
@@ -1153,7 +1153,7 @@ public class ScaleIOPrimaryDataStoreDriver implements PrimaryDataStoreDriver {
 
     @Override
     public boolean canCopy(DataObject srcData, DataObject destData) {
-        DataStore srcStore = destData.getDataStore();
+        DataStore srcStore = srcData.getDataStore();
         DataStore destStore = destData.getDataStore();
         if ((srcStore.getRole() == DataStoreRole.Primary && (srcData.getType() == DataObjectType.TEMPLATE || srcData.getType() == DataObjectType.VOLUME))
                 && (destStore.getRole() == DataStoreRole.Primary && destData.getType() == DataObjectType.VOLUME)) {