From nobody Sun Feb 8 05:41:02 2026 Delivered-To: importer@patchew.org Received-SPF: pass (zohomail.com: domain of redhat.com designates 207.211.31.81 as permitted sender) client-ip=207.211.31.81; envelope-from=libvir-list-bounces@redhat.com; helo=us-smtp-delivery-1.mimecast.com; Authentication-Results: mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of redhat.com designates 207.211.31.81 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=1576789800; cv=none; d=zohomail.com; s=zohoarc; b=DftEDE7YpZg1yogvxHaAAyIr2GHc6w8apBmVbIQobbq1Q3trj88TX3hB2yap4Ycdsj9N4IsGpubIY2/1XR+kKY9aSpp3dxP22e4xN7NBOQYxuADH+ty+Zn6tfIGP/6Vk1ga7U2WLGSzmLaMetpg5pQop6UuWXgJecbueQbHJzp8= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1576789800; 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=TYgZLEdxGLFFirgdUuJxvJKsJ2wFWw37fN5YDeyBhco=; b=A+of9/xXHSciKdJARGE3V7183R+RRNXAlBlHVO2KbyqmceujrQQU/v8ZtvXBAI1Ixkvp5fWYl1iC6k0x8Z8b7rZjZnojCo5CWS/ZUBf+koadohkGkDjBR8wGcETYUWSOpuYHg3L096Wh+8HlcKFv09FZYH7TqHuqmOagGQiItKE= ARC-Authentication-Results: i=1; mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of redhat.com designates 207.211.31.81 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-delivery-1.mimecast.com (us-smtp-2.mimecast.com [207.211.31.81]) by mx.zohomail.com with SMTPS id 157678980040074.10584187507914; Thu, 19 Dec 2019 13:10:00 -0800 (PST) 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-257-SuCsMAOvP1qHw-k6w9_GIg-1; Thu, 19 Dec 2019 16:09:57 -0500 Received: from smtp.corp.redhat.com (int-mx02.intmail.prod.int.phx2.redhat.com [10.5.11.12]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mimecast-mx01.redhat.com (Postfix) with ESMTPS id 903BC18A8CA2; Thu, 19 Dec 2019 21:09:50 +0000 (UTC) Received: from colo-mx.corp.redhat.com (colo-mx02.intmail.prod.int.phx2.redhat.com [10.5.11.21]) by smtp.corp.redhat.com (Postfix) with ESMTPS id 67A7E60C87; Thu, 19 Dec 2019 21:09:50 +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 1C3F0252D8; Thu, 19 Dec 2019 21:09:50 +0000 (UTC) Received: from smtp.corp.redhat.com (int-mx06.intmail.prod.int.rdu2.redhat.com [10.11.54.6]) by lists01.pubmisc.prod.ext.phx2.redhat.com (8.13.8/8.13.8) with ESMTP id xBJL9TMY001658 for ; Thu, 19 Dec 2019 16:09:29 -0500 Received: by smtp.corp.redhat.com (Postfix) id 7E22C2166B2A; Thu, 19 Dec 2019 21:09:29 +0000 (UTC) Received: from mimecast-mx02.redhat.com (mimecast02.extmail.prod.ext.rdu2.redhat.com [10.11.55.18]) by smtp.corp.redhat.com (Postfix) with ESMTPS id 787E92166B2C for ; Thu, 19 Dec 2019 21:09:27 +0000 (UTC) Received: from us-smtp-1.mimecast.com (us-smtp-delivery-1.mimecast.com [205.139.110.120]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-SHA384 (256/256 bits)) (No client certificate requested) by mimecast-mx02.redhat.com (Postfix) with ESMTPS id BCEEB803B34 for ; Thu, 19 Dec 2019 21:09:27 +0000 (UTC) Received: from mail-qk1-f193.google.com (mail-qk1-f193.google.com [209.85.222.193]) (Using TLS) by relay.mimecast.com with ESMTP id us-mta-272-IhwhrrgfNOaW6u9TNFF2ig-1; Thu, 19 Dec 2019 16:09:26 -0500 Received: by mail-qk1-f193.google.com with SMTP id c17so5844819qkg.7 for ; Thu, 19 Dec 2019 13:09:25 -0800 (PST) Received: from rekt.ibmuc.com ([2804:431:c7c7:2968:dc54:84c2:3c64:baf7]) by smtp.gmail.com with ESMTPSA id a19sm2111694qka.75.2019.12.19.13.09.24 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 19 Dec 2019 13:09:25 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1576789799; 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=TYgZLEdxGLFFirgdUuJxvJKsJ2wFWw37fN5YDeyBhco=; b=SlQf39y5wL576OIEbOmIJjH4DX6CIPGyrT+JsFJYU5PBrdeh3lYq5C0OROC612mdOMZJ1O OtFMFryxwWumqj94tzTsd4053nmcID5AKlmEMa76Tx5arrKvcFuP3Cvb9qQ6JyC7EOYzGW RBm00Pwm3yYovViDn6tCJcl2OLPyuEk= 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=i4T2ZxL/ftq/6MqLThNoOmkw0P6lDDrG/e+ILCt2rug=; b=dY6s2D8nKkU+RQS45gnG8Wco5aSPAMSykPQrGiKCGzFgF8roXca0FODw9efwG8l2aA 9TFuDv63CrzYi9ARQLpZZ1P883InABkfs9PadIiPoCyO6tTt4pNmrat3ZOPnNB7H8xrB eFqZdc/8a1o+jlCMlGRwUnvLGVMh7atKbbl6pg3T1nwCSeXNKOmy3m4MXV43EowtcCsX +Pm/l8klW83XyN5AL8wMdpHYZEZq0Ggx7C/uHqW9Jcejg4kg8g/NxM7GefNk/aazDC8s 03/2kiD0SHDQRMuhqaH/TO/YFGXXayzROqp9sCgr5IWpkwbbrXVum3GdbM4wQybYqUyE fjmA== X-Gm-Message-State: APjAAAUfagJlZBpV0DxLV18pwe3xgaOsSAOzZO7AgESAnv1+U4P4lBa/ q99YUt3J2zlFUoTonECXXPBjpZpi58Y= X-Google-Smtp-Source: APXvYqwh7vyFi1Z2Ynh2KpJmDHLVmfzZZmtwE+vo/6svzhM6GCbWqtB7bEV8bIEBE/5V0zWSSuj+Jw== X-Received: by 2002:a05:620a:1663:: with SMTP id d3mr10429120qko.204.1576789765486; Thu, 19 Dec 2019 13:09:25 -0800 (PST) From: Daniel Henrique Barboza To: libvir-list@redhat.com Date: Thu, 19 Dec 2019 18:09:09 -0300 Message-Id: <20191219210909.1567102-5-danielhb413@gmail.com> In-Reply-To: <20191219210909.1567102-1-danielhb413@gmail.com> References: <20191219210909.1567102-1-danielhb413@gmail.com> MIME-Version: 1.0 X-MC-Unique: IhwhrrgfNOaW6u9TNFF2ig-1 X-MC-Unique: SuCsMAOvP1qHw-k6w9_GIg-1 X-Scanned-By: MIMEDefang 2.78 on 10.11.54.6 X-MIME-Autoconverted: from quoted-printable to 8bit by lists01.pubmisc.prod.ext.phx2.redhat.com id xBJL9TMY001658 X-loop: libvir-list@redhat.com Cc: Daniel Henrique Barboza Subject: [libvirt] [PATCH v4 4/4] qemu_process.c: remove 'cleanup' label from qemuProcessCreatePretendCmd() 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.12 X-Mimecast-Spam-Score: 0 Content-Transfer-Encoding: quoted-printable X-ZohoMail-DKIM: pass (identity @redhat.com) Content-Type: text/plain; charset="utf-8" The 'cleanup' flag is doing no cleaup in this function. We can remove it and return NULL on error or qemuBuildCommandLine(). Signed-off-by: Daniel Henrique Barboza --- As mentioned in the cover, sending this one in its own patch simply because it is not related to the cleanup made in this series - I spotted by code inspection. The maintainer is welcome to squash this one in the previous patch. src/qemu/qemu_process.c | 37 ++++++++++++++++--------------------- 1 file changed, 16 insertions(+), 21 deletions(-) diff --git a/src/qemu/qemu_process.c b/src/qemu/qemu_process.c index 184bd6e816..2a629c0de7 100644 --- a/src/qemu/qemu_process.c +++ b/src/qemu/qemu_process.c @@ -7152,11 +7152,9 @@ qemuProcessCreatePretendCmd(virQEMUDriverPtr driver, bool standalone, unsigned int flags) { - virCommandPtr cmd =3D NULL; - - virCheckFlagsGoto(VIR_QEMU_PROCESS_START_COLD | - VIR_QEMU_PROCESS_START_PAUSED | - VIR_QEMU_PROCESS_START_AUTODESTROY, cleanup); + virCheckFlags(VIR_QEMU_PROCESS_START_COLD | + VIR_QEMU_PROCESS_START_PAUSED | + VIR_QEMU_PROCESS_START_AUTODESTROY, NULL); =20 flags |=3D VIR_QEMU_PROCESS_START_PRETEND; flags |=3D VIR_QEMU_PROCESS_START_NEW; @@ -7165,26 +7163,23 @@ qemuProcessCreatePretendCmd(virQEMUDriverPtr driver, =20 if (qemuProcessInit(driver, vm, NULL, QEMU_ASYNC_JOB_NONE, !!migrateURI, flags) < 0) - goto cleanup; + return NULL; =20 if (qemuProcessPrepareDomain(driver, vm, flags) < 0) - goto cleanup; + return NULL; =20 VIR_DEBUG("Building emulator command line"); - cmd =3D qemuBuildCommandLine(driver, - NULL, - driver->securityManager, - vm, - migrateURI, - NULL, - VIR_NETDEV_VPORT_PROFILE_OP_NO_OP, - standalone, - enableFips, - NULL, - NULL); - - cleanup: - return cmd; + return qemuBuildCommandLine(driver, + NULL, + driver->securityManager, + vm, + migrateURI, + NULL, + VIR_NETDEV_VPORT_PROFILE_OP_NO_OP, + standalone, + enableFips, + NULL, + NULL); } =20 =20 --=20 2.23.0 -- libvir-list mailing list libvir-list@redhat.com https://www.redhat.com/mailman/listinfo/libvir-list