Return-Path: X-Original-To: apmail-cloudstack-commits-archive@www.apache.org Delivered-To: apmail-cloudstack-commits-archive@www.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id EE9A510D9D for ; Thu, 19 Dec 2013 00:11:59 +0000 (UTC) Received: (qmail 11384 invoked by uid 500); 19 Dec 2013 00:11:59 -0000 Delivered-To: apmail-cloudstack-commits-archive@cloudstack.apache.org Received: (qmail 11353 invoked by uid 500); 19 Dec 2013 00:11:59 -0000 Mailing-List: contact commits-help@cloudstack.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@cloudstack.apache.org Delivered-To: mailing list commits@cloudstack.apache.org Received: (qmail 11339 invoked by uid 99); 19 Dec 2013 00:11:59 -0000 Received: from tyr.zones.apache.org (HELO tyr.zones.apache.org) (140.211.11.114) by apache.org (qpsmtpd/0.29) with ESMTP; Thu, 19 Dec 2013 00:11:59 +0000 Received: by tyr.zones.apache.org (Postfix, from userid 65534) id 7515E9DFB; Thu, 19 Dec 2013 00:11:59 +0000 (UTC) Content-Type: text/plain; charset="us-ascii" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit From: mchen@apache.org To: commits@cloudstack.apache.org Date: Thu, 19 Dec 2013 00:11:59 -0000 Message-Id: <54f498aaf05d48a682dd6299e90c4385@git.apache.org> X-Mailer: ASF-Git Admin Mailer Subject: [1/2] git commit: updated refs/heads/master to afcf967 Updated Branches: refs/heads/master 231e7c01f -> afcf967d2 CLOUDSTACK-5541: Template Creation from snapshot failed with S3 store. Project: http://git-wip-us.apache.org/repos/asf/cloudstack/repo Commit: http://git-wip-us.apache.org/repos/asf/cloudstack/commit/bb91b739 Tree: http://git-wip-us.apache.org/repos/asf/cloudstack/tree/bb91b739 Diff: http://git-wip-us.apache.org/repos/asf/cloudstack/diff/bb91b739 Branch: refs/heads/master Commit: bb91b739a8908ba7fa8ebc8db79be79ec82a800a Parents: 231e7c0 Author: Min Chen Authored: Wed Dec 18 15:41:37 2013 -0800 Committer: Min Chen Committed: Wed Dec 18 15:44:00 2013 -0800 ---------------------------------------------------------------------- .../cloudstack/storage/motion/AncientDataMotionStrategy.java | 8 +++----- 1 file changed, 3 insertions(+), 5 deletions(-) ---------------------------------------------------------------------- http://git-wip-us.apache.org/repos/asf/cloudstack/blob/bb91b739/engine/storage/datamotion/src/org/apache/cloudstack/storage/motion/AncientDataMotionStrategy.java ---------------------------------------------------------------------- diff --git a/engine/storage/datamotion/src/org/apache/cloudstack/storage/motion/AncientDataMotionStrategy.java b/engine/storage/datamotion/src/org/apache/cloudstack/storage/motion/AncientDataMotionStrategy.java index 5c1ff40..48c39cd 100644 --- a/engine/storage/datamotion/src/org/apache/cloudstack/storage/motion/AncientDataMotionStrategy.java +++ b/engine/storage/datamotion/src/org/apache/cloudstack/storage/motion/AncientDataMotionStrategy.java @@ -497,11 +497,9 @@ public class AncientDataMotionStrategy implements DataMotionStrategy { answer = ep.sendMessage(cmd); } } - // clean up cache entry in case of failure - if (answer == null || !answer.getResult()) { - if (cacheData != null) { - cacheMgr.deleteCacheObject(cacheData); - } + // clean up cache entry + if (cacheData != null) { + cacheMgr.deleteCacheObject(cacheData); } return answer; } catch (Exception e) {