From nobody Mon Feb 9 07:32:10 2026 Delivered-To: importer@patchew.org Received-SPF: pass (zohomail.com: domain of redhat.com designates 170.10.133.124 as permitted sender) client-ip=170.10.133.124; envelope-from=libvir-list-bounces@redhat.com; helo=us-smtp-delivery-124.mimecast.com; Authentication-Results: mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of redhat.com designates 170.10.133.124 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=1652882493; cv=none; d=zohomail.com; s=zohoarc; b=MhJ9NiXmWbvByKUqklgTh0imlBsRTHMuqJeOASPOTHl3Gfpr2dd2YjA+ejTOqHADCxtHOT2NosjS18C/hnncsNCJaYE+1b0NhvG3SHm9qdF+B7Y5kzhy7xDVvdhLfK+V8HJF7+ed6EJxpyYjlfbkJq5qilTIFK7Xw87E55/96+c= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1652882493; 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=cphqlkZ/sl878IdDgmqo095qpqsePod8IVetus2oBSs=; b=c6ZAcbayXLPwRV0iTVth8prx2l7fi3GYPSKXvZySQx2u/PGV8wpor7I5/6zt2aI2V4bpd56ovD0RCuGuWPFX4gVzxQt60+wM6gqlBR8xXcMkzpSDYrEw/5pmzYXXz3fzKoBy2Ar1Fo2XYBWuXKD1DwtorGzOEZtPSVk74cXvA5c= ARC-Authentication-Results: i=1; mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of redhat.com designates 170.10.133.124 as permitted sender) smtp.mailfrom=libvir-list-bounces@redhat.com; dmarc=pass header.from= (p=none dis=none) Return-Path: Received: from us-smtp-delivery-124.mimecast.com (us-smtp-delivery-124.mimecast.com [170.10.133.124]) by mx.zohomail.com with SMTPS id 1652882493695479.70703379044164; Wed, 18 May 2022 07:01:33 -0700 (PDT) Received: from mimecast-mx02.redhat.com (mx3-rdu2.redhat.com [66.187.233.73]) by relay.mimecast.com with ESMTP with STARTTLS (version=TLSv1.2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id us-mta-572-uOQ6XFE3MVy5bjyEq1VdCg-1; Wed, 18 May 2022 10:01:28 -0400 Received: from smtp.corp.redhat.com (int-mx07.intmail.prod.int.rdu2.redhat.com [10.11.54.7]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mimecast-mx02.redhat.com (Postfix) with ESMTPS id 8A5C1294EDC7; Wed, 18 May 2022 14:01:12 +0000 (UTC) Received: from mm-prod-listman-01.mail-001.prod.us-east-1.aws.redhat.com (unknown [10.30.29.100]) by smtp.corp.redhat.com (Postfix) with ESMTP id 6E1DD1415102; Wed, 18 May 2022 14:01:12 +0000 (UTC) Received: from mm-prod-listman-01.mail-001.prod.us-east-1.aws.redhat.com (localhost [IPv6:::1]) by mm-prod-listman-01.mail-001.prod.us-east-1.aws.redhat.com (Postfix) with ESMTP id 52A6E1947B91; Wed, 18 May 2022 14:01:12 +0000 (UTC) Received: from smtp.corp.redhat.com (int-mx09.intmail.prod.int.rdu2.redhat.com [10.11.54.9]) by mm-prod-listman-01.mail-001.prod.us-east-1.aws.redhat.com (Postfix) with ESMTP id 0BE221947B8F for ; Wed, 18 May 2022 14:01:03 +0000 (UTC) Received: by smtp.corp.redhat.com (Postfix) id B58DF492CA2; Wed, 18 May 2022 14:01:02 +0000 (UTC) Received: from hjs.redhat.com (unknown [10.43.2.85]) by smtp.corp.redhat.com (Postfix) with ESMTP id 5D51B492C3B for ; Wed, 18 May 2022 14:01:02 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1652882492; 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=cphqlkZ/sl878IdDgmqo095qpqsePod8IVetus2oBSs=; b=CR5i+7r8pQsJX8ruLlb8cp3ARsQzkBmBplBOyfoI6xvPhgjJPW87QuEDp/QbT9R3EWmmaG JMAvr+1Z4m9A6g4kCs+Or7GExrh2FScDRGdmqWnokzmQ69WkdpxR51j/jmmK0q2Epk5olL otNCUt7iIWkd/GacQq/aRzaiY0u3ihI= X-MC-Unique: uOQ6XFE3MVy5bjyEq1VdCg-1 X-Original-To: libvir-list@listman.corp.redhat.com From: =?UTF-8?q?J=C3=A1n=20Tomko?= To: libvir-list@redhat.com Subject: [libvirt PATCH 1/5] Do not check if unsigned vars are less than zero Date: Wed, 18 May 2022 16:00:56 +0200 Message-Id: In-Reply-To: References: MIME-Version: 1.0 X-Scanned-By: MIMEDefang 2.85 on 10.11.54.9 X-BeenThere: libvir-list@redhat.com X-Mailman-Version: 2.1.29 Precedence: list List-Id: Development discussions about the libvirt library & tools List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: libvir-list-bounces@redhat.com Sender: "libvir-list" X-Scanned-By: MIMEDefang 2.85 on 10.11.54.7 Authentication-Results: relay.mimecast.com; auth=pass smtp.auth=CUSA124A263 smtp.mailfrom=libvir-list-bounces@redhat.com X-Mimecast-Spam-Score: 0 X-Mimecast-Originator: redhat.com Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable X-ZohoMail-DKIM: pass (identity @redhat.com) X-ZM-MESSAGEID: 1652882495248100004 Signed-off-by: J=C3=A1n Tomko --- src/esx/esx_stream.c | 2 +- src/libvirt-qemu.c | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/src/esx/esx_stream.c b/src/esx/esx_stream.c index b356fbed70..51c96ff0e0 100644 --- a/src/esx/esx_stream.c +++ b/src/esx/esx_stream.c @@ -287,7 +287,7 @@ esxStreamRecvFlags(virStreamPtr stream, if (esxStreamTransfer(priv, false) < 0) return -1; =20 - if (priv->buffer_used <=3D 0) + if (priv->buffer_used =3D=3D 0) return -2; } else /* blocking */ { do { diff --git a/src/libvirt-qemu.c b/src/libvirt-qemu.c index 3cd8c8f745..5020b5dc1b 100644 --- a/src/libvirt-qemu.c +++ b/src/libvirt-qemu.c @@ -233,7 +233,7 @@ virDomainQemuAttach(virConnectPtr conn, virResetLastError(); =20 virCheckConnectReturn(conn, NULL); - virCheckPositiveArgGoto(pid_value, error); + virCheckNonZeroArgGoto(pid_value, error); if (pid !=3D pid_value) { virReportInvalidArg(pid_value, _("pid_value in %s is too large"), --=20 2.34.1