From commits-return-71124-archive-asf-public=cust-asf.ponee.io@cloudstack.apache.org Sat Jan 20 00:57:59 2018 Return-Path: X-Original-To: archive-asf-public@eu.ponee.io Delivered-To: archive-asf-public@eu.ponee.io Received: from cust-asf.ponee.io (cust-asf.ponee.io [163.172.22.183]) by mx-eu-01.ponee.io (Postfix) with ESMTP id C4A97180607 for ; Sat, 20 Jan 2018 00:57:59 +0100 (CET) Received: by cust-asf.ponee.io (Postfix) id B2F2C160C49; Fri, 19 Jan 2018 23:57:59 +0000 (UTC) Delivered-To: archive-asf-public@cust-asf.ponee.io Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by cust-asf.ponee.io (Postfix) with SMTP id F13F0160C36 for ; Sat, 20 Jan 2018 00:57:58 +0100 (CET) Received: (qmail 54012 invoked by uid 500); 19 Jan 2018 23:57:58 -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 54003 invoked by uid 99); 19 Jan 2018 23:57:58 -0000 Received: from ec2-52-202-80-70.compute-1.amazonaws.com (HELO gitbox.apache.org) (52.202.80.70) by apache.org (qpsmtpd/0.29) with ESMTP; Fri, 19 Jan 2018 23:57:58 +0000 From: GitBox To: commits@cloudstack.apache.org Subject: [GitHub] wido commented on a change in pull request #2415: CLOUDSTACK-10244: KVM online storage migration fails and corrupts disk Message-ID: <151640627757.11520.4927524805717245324.gitbox@gitbox.apache.org> wido commented on a change in pull request #2415: CLOUDSTACK-10244: KVM online storage migration fails and corrupts disk URL: https://github.com/apache/cloudstack/pull/2415#discussion_r162760506 ########## File path: plugins/hypervisors/kvm/src/com/cloud/hypervisor/kvm/resource/wrapper/LibvirtMigrateCommandWrapper.java ########## @@ -132,8 +132,9 @@ Use VIR_DOMAIN_XML_SECURE (value = 1) prior to v1.0.0. vmsnapshots = libvirtComputingResource.cleanVMSnapshotMetadata(dm); Map mapMigrateStorage = command.getMigrateStorage(); + boolean migrateStorage = MapUtils.isNotEmpty(mapMigrateStorage); Review comment: Would it not be safer to make this boolean a final one? That way you are 100% sure it's not changed anywhere. ---------------------------------------------------------------- This is an automated message from the Apache Git Service. To respond to the message, please log on GitHub and use the URL above to go to the specific comment. For queries about this service, please contact Infrastructure at: users@infra.apache.org With regards, Apache Git Services