From nobody Tue Feb 10 17:08:19 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=1650481714; cv=none; d=zohomail.com; s=zohoarc; b=TOp5ymjFUw1GTpqOnFO50na9kOB8tt6iuWqkDYkcpmrmmUqtcf28IWhwGe5zfxRtIkZZCyt3VTQTq6vZpRn0YerDeZMlN4WrNVruR1kJRfBY++68kwuLrm6/d/MjOS4V3dZPJ37HNRiJmEbaV5tPQv3pt/BgrKMiwTyVicuI1gI= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1650481714; 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=AHIik0LUBEsNkWOZpoOTT871SxdITcqU5FQrIwz5vpE=; b=AuyVwLg0d+N5YFBsAPz912SP9itYf1yDsJk5a+Oj5Dp2nMp1qiiF8sCSqiI9D5nmpq4MSqSCGUjNEMSFTrK22YEUJXqsB0W9vh94EZJ52TBJeWhDZxgkMlUlqIGCPJyVuwLK7i9IqAm0gx/1zA8lpd8jZjva5j9cTkgeGJj9txU= 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 165048171447870.88941915489045; Wed, 20 Apr 2022 12:08:34 -0700 (PDT) Received: from mimecast-mx02.redhat.com (mimecast-mx02.redhat.com [66.187.233.88]) by relay.mimecast.com with ESMTP with STARTTLS (version=TLSv1.2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id us-mta-508-S0j9Bp8mOHOkIOMzi5KPFQ-1; Wed, 20 Apr 2022 15:08:30 -0400 Received: from smtp.corp.redhat.com (int-mx10.intmail.prod.int.rdu2.redhat.com [10.11.54.10]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mimecast-mx02.redhat.com (Postfix) with ESMTPS id DA302803533; Wed, 20 Apr 2022 19:08:26 +0000 (UTC) Received: from mm-prod-listman-01.mail-001.prod.us-east-1.aws.redhat.com (mm-prod-listman-01.mail-001.prod.us-east-1.aws.redhat.com [10.30.29.100]) by smtp.corp.redhat.com (Postfix) with ESMTP id C62CD572326; Wed, 20 Apr 2022 19:08:26 +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 B5FAA1940351; Wed, 20 Apr 2022 19:08:25 +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 201271940354 for ; Wed, 20 Apr 2022 19:08:23 +0000 (UTC) Received: by smtp.corp.redhat.com (Postfix) id 05464551E88; Wed, 20 Apr 2022 19:08:23 +0000 (UTC) Received: from tapioca.home (unknown [10.40.193.11]) by smtp.corp.redhat.com (Postfix) with ESMTP id 6B00F551E82 for ; Wed, 20 Apr 2022 19:08:22 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1650481713; 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=AHIik0LUBEsNkWOZpoOTT871SxdITcqU5FQrIwz5vpE=; b=DlMRF7itQkgL5iqRGHqVfZPyJNkNmskNs7h4pnGH9vIFRb5cSg9XX9sHFaX0Ze9IJ5BLlx DsgEmVe+ewR5MvPf9yIMViqVG3v1SVxI31rxMKCyvAqoNv+j0q+K7Cbt3FPYyqzYJEoTjo Uu1tNxqqQ639nG8HPSEnxMB5MRo90ik= X-MC-Unique: S0j9Bp8mOHOkIOMzi5KPFQ-1 X-Original-To: libvir-list@listman.corp.redhat.com From: Victor Toso To: libvir-list@redhat.com Subject: [PATCH v3 02/30] syntax-check: prohibit_virXXXFree: skip strings Date: Wed, 20 Apr 2022 21:07:51 +0200 Message-Id: <20220420190819.3093205-3-victortoso@redhat.com> In-Reply-To: <20220420190819.3093205-1-victortoso@redhat.com> References: <20220420190819.3093205-1-victortoso@redhat.com> 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.10 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-Transfer-Encoding: quoted-printable X-ZohoMail-DKIM: pass (identity @redhat.com) X-ZM-MESSAGEID: 1650481716296100003 Content-Type: text/plain; charset="utf-8" We should allow strings (not the functions) in the format of "virDomainFree" and friends. This fixes an error in latter commit "scripts: apibuild: parse 'Since' for functions" as it uses this function names as keys in a dictionary. Fixes: | ... | prohibit_virXXXFree | libvirt/scripts/apibuild.py:163: 'virDomainFree': '0.0.1', | make: Leaving directory '/home/toso/src/libvirt/build/build-aux' | stderr: | build-aux/syntax-check.mk: avoid using virXXXFree, use virObjectUnref i= nstead | make: *** [libvirt/build-aux/syntax-check.mk:829: sc_prohibit_virXXXFre= e] Error 1 Signed-off-by: Victor Toso --- build-aux/syntax-check.mk | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/build-aux/syntax-check.mk b/build-aux/syntax-check.mk index eb403f3d3f..07e0295995 100644 --- a/build-aux/syntax-check.mk +++ b/build-aux/syntax-check.mk @@ -827,7 +827,7 @@ sc_prohibit_system_error_with_vir_err: # docs, examples, tools, src/libvirt-*.c, and include/libvirt/libvirt-*.h sc_prohibit_virXXXFree: @prohibit=3D'\bvir(Domain|Network|NodeDevice|StorageVol|StoragePool|Strea= m|Secret|NWFilter|Interface|DomainSnapshot)Free\b' \ - exclude=3D'sc_prohibit_virXXXFree' \ + exclude=3D"sc_prohibit_virXXXFree|'vir.*?Free'" \ halt=3D'avoid using virXXXFree, use virObjectUnref instead' \ $(_sc_search_regexp) =20 --=20 2.35.1