From nobody Tue Feb 10 12:45:18 2026 Delivered-To: importer@patchew.org Received-SPF: pass (zohomail.com: domain of redhat.com designates 216.205.24.124 as permitted sender) client-ip=216.205.24.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 216.205.24.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=1612411110; cv=none; d=zohomail.com; s=zohoarc; b=JBywO/D14OpV2DwLQTh04blW14dh54kgLbo3LnYgHTnlS96iZsaW3X6ISMTVrwo/ZwZXAofCfwvs69Hhf4zJxcq4vogYAD+77r+xz8fx6Xlj1QPp3GXXYE4UgAqJlpvWiWf3gOZxLF7JfitCC/QAb1R8C0Vh//Gyl0Eer53ZrW4= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1612411110; 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=WcZHXge8zlcExK5SQEe87jcEE+ZaJfNFu5Diqxk+6ec=; b=VMoYDXGXNsj7no8KHaWEkM6OKR3Wi/apYMK+HulskzsUsKm8WnGB7+q/HSxNIzwp96z6ajezDjxQFp1hL5ywzuwifOw65sl4mEAjZTOKaW0ra0/orqZjmp6GQw7Ih+FdW1ebOUR7TPWnh/9rOM61P5GMr5R0TMq3N43hWT/++FQ= ARC-Authentication-Results: i=1; mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of redhat.com designates 216.205.24.124 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-124.mimecast.com (us-smtp-delivery-124.mimecast.com [216.205.24.124]) by mx.zohomail.com with SMTPS id 161241111065835.19913765139995; Wed, 3 Feb 2021 19:58:30 -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-163-a-7ESeq-OzGyglOX8CzDEg-1; Wed, 03 Feb 2021 22:58:26 -0500 Received: from smtp.corp.redhat.com (int-mx05.intmail.prod.int.phx2.redhat.com [10.5.11.15]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mimecast-mx01.redhat.com (Postfix) with ESMTPS id 5E29E801978; Thu, 4 Feb 2021 03:58:20 +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 39DE25B697; Thu, 4 Feb 2021 03:58:20 +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 0169C5807F; Thu, 4 Feb 2021 03:58:20 +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 1143w678003450 for ; Wed, 3 Feb 2021 22:58:06 -0500 Received: by smtp.corp.redhat.com (Postfix) id 96E585B697; Thu, 4 Feb 2021 03:58:06 +0000 (UTC) Received: from vhost2.laine.org (ovpn-112-199.phx2.redhat.com [10.3.112.199]) by smtp.corp.redhat.com (Postfix) with ESMTP id 61A595B695 for ; Thu, 4 Feb 2021 03:58:06 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1612411109; 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=WcZHXge8zlcExK5SQEe87jcEE+ZaJfNFu5Diqxk+6ec=; b=DFsUG/dS0KEll/YfkwMLmPoRvwGDefWLH6okL/d70+jORyoDkdIpw7XbXI/BuAg5l+9m31 FDU/m4bqtLi+rvx50s7P7VG1gVcE1F3mQyRuMU+MzwfizxydY9kmDhe7KP9ZAu1EUCei5u kIah/zl7EV0GsEmBIwIIqpSYzl8O1vw= X-MC-Unique: a-7ESeq-OzGyglOX8CzDEg-1 From: Laine Stump To: libvir-list@redhat.com Subject: [libvirt PATCH v2 16/24] tools: replace VIR_FREE with g_free in all vir*Free() functions Date: Wed, 3 Feb 2021 22:57:43 -0500 Message-Id: <20210204035751.164765-17-laine@redhat.com> In-Reply-To: <20210204035751.164765-1-laine@redhat.com> References: <20210204035751.164765-1-laine@redhat.com> MIME-Version: 1.0 X-Scanned-By: MIMEDefang 2.79 on 10.5.11.15 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.15 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) Content-Type: text/plain; charset="utf-8" Signed-off-by: Laine Stump --- tools/virsh-checkpoint.c | 6 +++--- tools/virsh-domain-monitor.c | 4 ++-- tools/virsh-domain.c | 2 +- tools/virsh-interface.c | 4 ++-- tools/virsh-network.c | 8 ++++---- tools/virsh-nodedev.c | 4 ++-- tools/virsh-nwfilter.c | 8 ++++---- tools/virsh-pool.c | 4 ++-- tools/virsh-secret.c | 4 ++-- tools/virsh-snapshot.c | 6 +++--- tools/virsh-volume.c | 4 ++-- tools/vsh-table.c | 10 +++++----- tools/vsh.c | 6 +++--- 13 files changed, 35 insertions(+), 35 deletions(-) diff --git a/tools/virsh-checkpoint.c b/tools/virsh-checkpoint.c index f6396d16eb..6e68ba66ff 100644 --- a/tools/virsh-checkpoint.c +++ b/tools/virsh-checkpoint.c @@ -552,11 +552,11 @@ virshCheckpointListFree(virshCheckpointListPtr checkp= ointlist) if (checkpointlist->chks) { for (i =3D 0; i < checkpointlist->nchks; i++) { virshDomainCheckpointFree(checkpointlist->chks[i].chk); - VIR_FREE(checkpointlist->chks[i].parent); + g_free(checkpointlist->chks[i].parent); } - VIR_FREE(checkpointlist->chks); + g_free(checkpointlist->chks); } - VIR_FREE(checkpointlist); + g_free(checkpointlist); } =20 =20 diff --git a/tools/virsh-domain-monitor.c b/tools/virsh-domain-monitor.c index 5d0a03afa9..02ff1fbd62 100644 --- a/tools/virsh-domain-monitor.c +++ b/tools/virsh-domain-monitor.c @@ -1609,9 +1609,9 @@ virshDomainListFree(virshDomainListPtr domlist) if (domlist && domlist->domains) { for (i =3D 0; i < domlist->ndomains; i++) virshDomainFree(domlist->domains[i]); - VIR_FREE(domlist->domains); + g_free(domlist->domains); } - VIR_FREE(domlist); + g_free(domlist); } =20 static virshDomainListPtr diff --git a/tools/virsh-domain.c b/tools/virsh-domain.c index fb8b4bdb72..98a87dd43c 100644 --- a/tools/virsh-domain.c +++ b/tools/virsh-domain.c @@ -1796,7 +1796,7 @@ virshBlockJobWaitFree(virshBlockJobWaitDataPtr data) if (data->cb_id2 >=3D 0) virConnectDomainEventDeregisterAny(priv->conn, data->cb_id2); =20 - VIR_FREE(data); + g_free(data); } =20 =20 diff --git a/tools/virsh-interface.c b/tools/virsh-interface.c index 858052d341..a11d4ba607 100644 --- a/tools/virsh-interface.c +++ b/tools/virsh-interface.c @@ -176,9 +176,9 @@ virshInterfaceListFree(virshInterfaceListPtr list) if (list->ifaces[i]) virInterfaceFree(list->ifaces[i]); } - VIR_FREE(list->ifaces); + g_free(list->ifaces); } - VIR_FREE(list); + g_free(list); } =20 static virshInterfaceListPtr diff --git a/tools/virsh-network.c b/tools/virsh-network.c index 9e3b31a60c..a203fa64ff 100644 --- a/tools/virsh-network.c +++ b/tools/virsh-network.c @@ -459,9 +459,9 @@ virshNetworkListFree(virshNetworkListPtr list) if (list->nets[i]) virNetworkFree(list->nets[i]); } - VIR_FREE(list->nets); + g_free(list->nets); } - VIR_FREE(list); + g_free(list); } =20 static virshNetworkListPtr @@ -1676,9 +1676,9 @@ virshNetworkPortListFree(virshNetworkPortListPtr list) if (list->ports[i]) virNetworkPortFree(list->ports[i]); } - VIR_FREE(list->ports); + g_free(list->ports); } - VIR_FREE(list); + g_free(list); } =20 static virshNetworkPortListPtr diff --git a/tools/virsh-nodedev.c b/tools/virsh-nodedev.c index 69422e20f5..fedc8497f8 100644 --- a/tools/virsh-nodedev.c +++ b/tools/virsh-nodedev.c @@ -205,9 +205,9 @@ virshNodeDeviceListFree(virshNodeDeviceListPtr list) if (list->devices[i]) virNodeDeviceFree(list->devices[i]); } - VIR_FREE(list->devices); + g_free(list->devices); } - VIR_FREE(list); + g_free(list); } =20 static virshNodeDeviceListPtr diff --git a/tools/virsh-nwfilter.c b/tools/virsh-nwfilter.c index 768a96e949..0d09a016bc 100644 --- a/tools/virsh-nwfilter.c +++ b/tools/virsh-nwfilter.c @@ -234,9 +234,9 @@ virshNWFilterListFree(virshNWFilterListPtr list) if (list->filters[i]) virNWFilterFree(list->filters[i]); } - VIR_FREE(list->filters); + g_free(list->filters); } - VIR_FREE(list); + g_free(list); } =20 static virshNWFilterListPtr @@ -654,9 +654,9 @@ virshNWFilterBindingListFree(virshNWFilterBindingListPt= r list) if (list->bindings[i]) virNWFilterBindingFree(list->bindings[i]); } - VIR_FREE(list->bindings); + g_free(list->bindings); } - VIR_FREE(list); + g_free(list); } =20 =20 diff --git a/tools/virsh-pool.c b/tools/virsh-pool.c index 7835fa6d75..5256b50589 100644 --- a/tools/virsh-pool.c +++ b/tools/virsh-pool.c @@ -850,9 +850,9 @@ virshStoragePoolListFree(virshStoragePoolListPtr list) if (list->pools[i]) virStoragePoolFree(list->pools[i]); } - VIR_FREE(list->pools); + g_free(list->pools); } - VIR_FREE(list); + g_free(list); } =20 static virshStoragePoolListPtr diff --git a/tools/virsh-secret.c b/tools/virsh-secret.c index fcfbe5fe9e..7ca3e864da 100644 --- a/tools/virsh-secret.c +++ b/tools/virsh-secret.c @@ -410,9 +410,9 @@ virshSecretListFree(virshSecretListPtr list) for (i =3D 0; i < list->nsecrets; i++) virshSecretFree(list->secrets[i]); =20 - VIR_FREE(list->secrets); + g_free(list->secrets); } - VIR_FREE(list); + g_free(list); } =20 static virshSecretListPtr diff --git a/tools/virsh-snapshot.c b/tools/virsh-snapshot.c index 478657b5b6..1b10ef37e3 100644 --- a/tools/virsh-snapshot.c +++ b/tools/virsh-snapshot.c @@ -1032,11 +1032,11 @@ virshSnapshotListFree(virshSnapshotListPtr snaplist) if (snaplist->snaps) { for (i =3D 0; i < snaplist->nsnaps; i++) { virshDomainSnapshotFree(snaplist->snaps[i].snap); - VIR_FREE(snaplist->snaps[i].parent); + g_free(snaplist->snaps[i].parent); } - VIR_FREE(snaplist->snaps); + g_free(snaplist->snaps); } - VIR_FREE(snaplist); + g_free(snaplist); } =20 static int diff --git a/tools/virsh-volume.c b/tools/virsh-volume.c index c86abb863f..af2d1d42a3 100644 --- a/tools/virsh-volume.c +++ b/tools/virsh-volume.c @@ -1273,9 +1273,9 @@ virshStorageVolListFree(virshStorageVolListPtr list) if (list->vols[i]) virStorageVolFree(list->vols[i]); } - VIR_FREE(list->vols); + g_free(list->vols); } - VIR_FREE(list); + g_free(list); } =20 static virshStorageVolListPtr diff --git a/tools/vsh-table.c b/tools/vsh-table.c index 4471368687..d09cc9e14e 100644 --- a/tools/vsh-table.c +++ b/tools/vsh-table.c @@ -52,10 +52,10 @@ vshTableRowFree(vshTableRowPtr row) return; =20 for (i =3D 0; i < row->ncells; i++) - VIR_FREE(row->cells[i]); + g_free(row->cells[i]); =20 - VIR_FREE(row->cells); - VIR_FREE(row); + g_free(row->cells); + g_free(row); } =20 =20 @@ -69,8 +69,8 @@ vshTableFree(vshTablePtr table) =20 for (i =3D 0; i < table->nrows; i++) vshTableRowFree(table->rows[i]); - VIR_FREE(table->rows); - VIR_FREE(table); + g_free(table->rows); + g_free(table); } =20 =20 diff --git a/tools/vsh.c b/tools/vsh.c index 0e2d4955b4..202bd564f7 100644 --- a/tools/vsh.c +++ b/tools/vsh.c @@ -719,8 +719,8 @@ vshCommandOptFree(vshCmdOpt * arg) =20 a =3D a->next; =20 - VIR_FREE(tmp->data); - VIR_FREE(tmp); + g_free(tmp->data); + g_free(tmp); } } =20 @@ -735,7 +735,7 @@ vshCommandFree(vshCmd *cmd) c =3D c->next; =20 vshCommandOptFree(tmp->opts); - VIR_FREE(tmp); + g_free(tmp); } } =20 --=20 2.29.2