From nobody Sun Feb 8 22:08:31 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=pass(p=none dis=none) header.from=redhat.com ARC-Seal: i=1; a=rsa-sha256; t=1593006588; cv=none; d=zohomail.com; s=zohoarc; b=mUFwcvjdstIhMI/rj810T3nWD6LJhZC88d086T4mRe3Po6mWeSckymaOqiQSCJChWJzvu/tcX+3zmiPpCLMQGZnHOshnuA6575rThuxSGGhmUINhyE+G2cC8v+j9g3GB+ofbEiYUvKGkkO0DPlknwadsMFaeHP58F0A2HOe0SBQ= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1593006588; h=Content-Type:Content-Transfer-Encoding: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=xHz5u8Ea86Jg/Nsaj7kMakq7iu7Ogdx/t055JbT+Lu0=; b=lz4w33/uBVuTJNsKFpAEDxmq2Jwk+ag0fXLkq0ohYyLtW089J1hJwvKM8oW9Rjlv2fbhF6n9T87QC3srxplzo89stqCrhl0p4ApdQm9sLLzY1O6eYnIrsTyixAS46oGZBgd8+4XZQX1JnJKq66DMeFrHu4kOuYtEtJq6fFs21Ag= 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=pass 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 159300658854986.29994815962937; Wed, 24 Jun 2020 06:49:48 -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-439-iAMTpnHaNm-GHJv9KkBIRw-1; Wed, 24 Jun 2020 09:49:45 -0400 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 74958107ACF9; Wed, 24 Jun 2020 13:49:38 +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 5442160C80; Wed, 24 Jun 2020 13:49:38 +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 24C3787542; Wed, 24 Jun 2020 13:49:38 +0000 (UTC) Received: from smtp.corp.redhat.com (int-mx04.intmail.prod.int.phx2.redhat.com [10.5.11.14]) by lists01.pubmisc.prod.ext.phx2.redhat.com (8.13.8/8.13.8) with ESMTP id 05ODnLOQ015668 for ; Wed, 24 Jun 2020 09:49:21 -0400 Received: by smtp.corp.redhat.com (Postfix) id 0F4B95DA27; Wed, 24 Jun 2020 13:49:21 +0000 (UTC) Received: from localhost.localdomain (unknown [10.40.195.7]) by smtp.corp.redhat.com (Postfix) with ESMTP id 848955D9DC for ; Wed, 24 Jun 2020 13:49:20 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1593006587; h=from:from:sender:sender:reply-to:subject:subject:date:date: message-id:message-id:to:to: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=xHz5u8Ea86Jg/Nsaj7kMakq7iu7Ogdx/t055JbT+Lu0=; b=Sw+JnXpbFXJYFO3vQ090P1oA+epz68XSi0d6bAf0vU6OYCL+eDWyuHi5kSmeNdFh3bN52R Vzde4Lm5Ujkct8ncC2LhGaMhCAepbjaRLWZp79y+lLuw36Zj/1mb0Nm5neYQQpFwchWcTM qIqqhuD1FQeHGUPRXEvX/hT5dc4vjmg= X-MC-Unique: iAMTpnHaNm-GHJv9KkBIRw-1 From: Michal Privoznik To: libvir-list@redhat.com Subject: [PATCH 05/13] qemuBuildMachineCommandLine: Drop needless check Date: Wed, 24 Jun 2020 15:49:03 +0200 Message-Id: In-Reply-To: References: MIME-Version: 1.0 X-Scanned-By: MIMEDefang 2.79 on 10.5.11.14 X-loop: libvir-list@redhat.com 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 X-Mimecast-Originator: redhat.com Content-Transfer-Encoding: quoted-printable X-ZohoMail-DKIM: pass (identity @redhat.com) Content-Type: text/plain; charset="utf-8" The machine can not be NULL at this point - qemuDomainDefPostParse() makes sure it isn't. Signed-off-by: Michal Privoznik Reviewed-by: Daniel Henrique Barboza --- src/qemu/qemu_command.c | 7 ------- 1 file changed, 7 deletions(-) diff --git a/src/qemu/qemu_command.c b/src/qemu/qemu_command.c index 05e5c19118..c5b0ee231e 100644 --- a/src/qemu/qemu_command.c +++ b/src/qemu/qemu_command.c @@ -6722,13 +6722,6 @@ qemuBuildMachineCommandLine(virCommandPtr cmd, g_auto(virBuffer) buf =3D VIR_BUFFER_INITIALIZER; size_t i; =20 - /* This should *never* be NULL, since we always provide - * a machine in the capabilities data for QEMU. So this - * check is just here as a safety in case the unexpected - * happens */ - if (!def->os.machine) - return 0; - virCommandAddArg(cmd, "-machine"); virBufferAdd(&buf, def->os.machine, -1); =20 --=20 2.26.2