From nobody Sun Feb 8 20:32:59 2026 Delivered-To: importer@patchew.org Received-SPF: pass (zoho.com: domain of redhat.com designates 205.139.110.120 as permitted sender) client-ip=205.139.110.120; envelope-from=libvir-list-bounces@redhat.com; helo=us-smtp-1.mimecast.com; Authentication-Results: mx.zohomail.com; dkim=pass; spf=pass (zoho.com: domain of redhat.com designates 205.139.110.120 as permitted sender) smtp.mailfrom=libvir-list-bounces@redhat.com; dmarc=fail(p=none dis=none) header.from=gmail.com ARC-Seal: i=1; a=rsa-sha256; t=1571737046; cv=none; d=zoho.com; s=zohoarc; b=QkexI7h4XIQbdZ8iB/udFTDvNWsAe6VBbffObnGUsuarzjkOB09U1OZHugd5kzK3BswLuI9yqcir5AKcH/XcJpYRFqGdN/gaOpDMqY6DOa5Tv1m/3BhuK6FKTMZTQaGPb1s33lzq6bh4Oy0VahhGSU/RzdD/8cskW5we5+vVsd8= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zoho.com; s=zohoarc; t=1571737046; h=Content-Type:Content-Transfer-Encoding:Cc:Date:From:In-Reply-To:List-Subscribe:List-Post:List-Id:List-Archive:List-Help:List-Unsubscribe:MIME-Version:Message-ID:References:Sender:Subject:To; bh=Vkcy+7aWW/TvcAx6ay7/bHJW9ahW6bwFCorW8jdaFDA=; b=hOYBEobyAhGkqeBCqdNUGBMSkSsj9JMq51zYEcktWjc6PGWwIhzOjgMuQr0HcI5x7ahPhQcGcTxTXbsnUq3RENkSHbOgzw339Pj28QwDSPCS1rmlQ9ZogDfyVgNCaXGqxzjgcdkdrZE5EsDXJXLj4ruDKg37AbUgJ1FWeypqw9E= ARC-Authentication-Results: i=1; mx.zoho.com; dkim=pass; spf=pass (zoho.com: domain of redhat.com designates 205.139.110.120 as permitted sender) smtp.mailfrom=libvir-list-bounces@redhat.com; dmarc=fail header.from= (p=none dis=none) header.from= Return-Path: Received: from us-smtp-1.mimecast.com (us-smtp-delivery-1.mimecast.com [205.139.110.120]) by mx.zohomail.com with SMTPS id 1571737046473474.76898386812843; Tue, 22 Oct 2019 02:37:26 -0700 (PDT) Received: from mimecast-mx01.redhat.com (mimecast-mx01.redhat.com [209.132.183.4]) (Using TLS) by relay.mimecast.com with ESMTP id us-mta-262-HvB0nQVWPJ6GkVUEzEYf3A-1; Tue, 22 Oct 2019 05:37:23 -0400 Received: from smtp.corp.redhat.com (int-mx04.intmail.prod.int.phx2.redhat.com [10.5.11.14]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mimecast-mx01.redhat.com (Postfix) with ESMTPS id 47B75800D57; Tue, 22 Oct 2019 09:37:18 +0000 (UTC) Received: from colo-mx.corp.redhat.com (colo-mx01.intmail.prod.int.phx2.redhat.com [10.5.11.20]) by smtp.corp.redhat.com (Postfix) with ESMTPS id 236235ED23; Tue, 22 Oct 2019 09:37:18 +0000 (UTC) Received: from lists01.pubmisc.prod.ext.phx2.redhat.com (lists01.pubmisc.prod.ext.phx2.redhat.com [10.5.19.33]) by colo-mx.corp.redhat.com (Postfix) with ESMTP id D5E1518198F3; Tue, 22 Oct 2019 09:37:17 +0000 (UTC) Received: from smtp.corp.redhat.com (int-mx05.intmail.prod.int.phx2.redhat.com [10.5.11.15]) by lists01.pubmisc.prod.ext.phx2.redhat.com (8.13.8/8.13.8) with ESMTP id x9LIJn31000668 for ; Mon, 21 Oct 2019 14:19:49 -0400 Received: by smtp.corp.redhat.com (Postfix) id 2EC335D6B0; Mon, 21 Oct 2019 18:19:49 +0000 (UTC) Received: from mx1.redhat.com (ext-mx24.extmail.prod.ext.phx2.redhat.com [10.5.110.65]) by smtp.corp.redhat.com (Postfix) with ESMTPS id 29CD95D6A5 for ; Mon, 21 Oct 2019 18:19:49 +0000 (UTC) Received: from mail-qk1-f173.google.com (mail-qk1-f173.google.com [209.85.222.173]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by mx1.redhat.com (Postfix) with ESMTPS id 7723310BF01A for ; Mon, 21 Oct 2019 18:19:48 +0000 (UTC) Received: by mail-qk1-f173.google.com with SMTP id a194so9488967qkg.10 for ; Mon, 21 Oct 2019 11:19:48 -0700 (PDT) Received: from rekt.ibmuc.com ([2804:431:c7c6:7979:d16f:4e5e:8e8d:1141]) by smtp.gmail.com with ESMTPSA id d205sm9248741qke.96.2019.10.21.11.19.46 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 21 Oct 2019 11:19:47 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1571737045; h=from:from:sender:sender:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:cc:mime-version:mime-version: content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references:list-id:list-help: list-unsubscribe:list-subscribe:list-post; bh=Vkcy+7aWW/TvcAx6ay7/bHJW9ahW6bwFCorW8jdaFDA=; b=iuzZctMk/Xd2Xm3CCW8NHs7XNq+b0jO0yHEV3rbtuoIHJJThBHexe9YCPuWd761v8HW6lF KGj6cDOXQhiaS93cB8sV1m0SepBexZSkLXFksiY9tvWyIi6LhgCBXiXQQn0J7hWJe9qDt4 SOiK4g9q53/5sLro3wwLhFrq0aRXDUM= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=dUgU2s+C7RZuGvhu/Xs+M/K8ZkNFqRAFxO9nteRhWEs=; b=EIFz49Tt4NWhs4fHwVUNETPSKa1Oa0KHpDxwuXXYsAZOx2EgZyrLOe7PD95AQ6nLV9 My9MXMOdQB7iL/0FwCcx3tSVgbct3vUy2sQrqBzFE+cBBzqppy/hHHNzKb6tOjdi7c4C 2WH7JA0wwrC6d/fAadGJab3Tx+XxnQLwPkqAlmWsPKQtDydaVgREfQ9FHOJcvmveLwUN GrGGYQJPPkGXtaDf1+hxvf+qJ0gW0BZBebZM5794nPTky8eJXaZ2P177ajTUHajCxH3D hF5168CE7jxzbroRCjnxUVqrGIOR0ly5ah9UN7yfcmR9e9VokVWvWB8fTj3EYJ4bqDHW OpfQ== X-Gm-Message-State: APjAAAXrI8PySThz9EaWbT8Tu8U2km2IYNvvjiiG5UQHfrPgfXktgcxN fc/xCFPP4mfvlPfbI7OV20hqPwekAR8= X-Google-Smtp-Source: APXvYqx4t5cct8gDCxPNRwC1gNPTEqVhKrq2sxbqZyWlAAXOnu9OrohMXFRCmwaFEDPnHKjN87Aq/w== X-Received: by 2002:a37:a1c7:: with SMTP id k190mr24735007qke.167.1571681987568; Mon, 21 Oct 2019 11:19:47 -0700 (PDT) From: Daniel Henrique Barboza To: libvir-list@redhat.com Date: Mon, 21 Oct 2019 15:19:06 -0300 Message-Id: <20191021181911.14986-17-danielhb413@gmail.com> In-Reply-To: <20191021181911.14986-1-danielhb413@gmail.com> References: <20191021181911.14986-1-danielhb413@gmail.com> MIME-Version: 1.0 X-Greylist: Sender IP whitelisted, not delayed by milter-greylist-4.6.2 (mx1.redhat.com [10.5.110.65]); Mon, 21 Oct 2019 18:19:48 +0000 (UTC) X-Greylist: inspected by milter-greylist-4.6.2 (mx1.redhat.com [10.5.110.65]); Mon, 21 Oct 2019 18:19:48 +0000 (UTC) for IP:'209.85.222.173' DOMAIN:'mail-qk1-f173.google.com' HELO:'mail-qk1-f173.google.com' FROM:'danielhb413@gmail.com' RCPT:'' X-RedHat-Spam-Score: 0.15 (DKIM_SIGNED, DKIM_VALID, DKIM_VALID_AU, FREEMAIL_ENVFROM_END_DIGIT, FREEMAIL_FROM, RCVD_IN_DNSWL_NONE, RCVD_IN_MSPIKE_H2, SPF_HELO_NONE, SPF_PASS) 209.85.222.173 mail-qk1-f173.google.com 209.85.222.173 mail-qk1-f173.google.com X-Scanned-By: MIMEDefang 2.84 on 10.5.110.65 X-Scanned-By: MIMEDefang 2.79 on 10.5.11.15 X-loop: libvir-list@redhat.com Cc: Daniel Henrique Barboza Subject: [libvirt] [PATCH v1 16/21] libxl_driver.c: remove unneeded cleanup label X-BeenThere: libvir-list@redhat.com X-Mailman-Version: 2.1.12 Precedence: junk List-Id: Development discussions about the libvirt library & tools List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: libvir-list-bounces@redhat.com Errors-To: libvir-list-bounces@redhat.com X-Scanned-By: MIMEDefang 2.79 on 10.5.11.14 X-MC-Unique: HvB0nQVWPJ6GkVUEzEYf3A-1 X-Mimecast-Spam-Score: 0 Content-Transfer-Encoding: quoted-printable X-ZohoMail-DKIM: pass (identity @redhat.com) Content-Type: text/plain; charset="utf-8" Signed-off-by: Daniel Henrique Barboza Reviewed-by: J=C3=A1n Tomko --- src/libxl/libxl_driver.c | 16 ++++++---------- 1 file changed, 6 insertions(+), 10 deletions(-) diff --git a/src/libxl/libxl_driver.c b/src/libxl/libxl_driver.c index 5cc6b87b8c..267f2106b2 100644 --- a/src/libxl/libxl_driver.c +++ b/src/libxl/libxl_driver.c @@ -4066,7 +4066,6 @@ libxlDomainUpdateDeviceConfig(virDomainDefPtr vmdef, = virDomainDeviceDefPtr dev) { virDomainDiskDefPtr orig; virDomainDiskDefPtr disk; - int ret =3D -1; =20 switch (dev->type) { case VIR_DOMAIN_DEVICE_DISK: @@ -4074,31 +4073,28 @@ libxlDomainUpdateDeviceConfig(virDomainDefPtr vmdef= , virDomainDeviceDefPtr dev) if (!(orig =3D virDomainDiskByTarget(vmdef, disk->dst))) { virReportError(VIR_ERR_INVALID_ARG, _("target %s doesn't exist."), disk->dst); - goto cleanup; + return -1; } if (!(orig->device =3D=3D VIR_DOMAIN_DISK_DEVICE_CDROM)) { virReportError(VIR_ERR_INVALID_ARG, "%s", _("this disk doesn't support update")); - goto cleanup; + return -1; } =20 if (virDomainDiskSetSource(orig, virDomainDiskGetSource(disk))= < 0) - goto cleanup; + return -1; virDomainDiskSetType(orig, virDomainDiskGetType(disk)); virDomainDiskSetFormat(orig, virDomainDiskGetFormat(disk)); if (virDomainDiskSetDriver(orig, virDomainDiskGetDriver(disk))= < 0) - goto cleanup; + return -1; break; default: virReportError(VIR_ERR_CONFIG_UNSUPPORTED, "%s", _("persistent update of device is not supported= ")); - goto cleanup; + return -1; } =20 - ret =3D 0; - - cleanup: - return ret; + return 0; } =20 =20 --=20 2.21.0 -- libvir-list mailing list libvir-list@redhat.com https://www.redhat.com/mailman/listinfo/libvir-list