From nobody Mon Feb 9 10:30:17 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=1630789649; cv=none; d=zohomail.com; s=zohoarc; b=DTBfTNrForQAY+1QAD7XJRf49lDc324sDkzQDZYX20jr4Yif/8sl0pnEapaQFBtpxbmQDfx5QOeENo7uaGb5X8hKC9uPia4wvHA5NCpEfpV3w2p5AwU1/pN5MTrQs8PSzXO1Peo8sy1fS0IQvrO8QN8YsEmXrsLiKQUKp95eXM8= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1630789649; 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=b02apZKTW2VNR4Qmp3YsE8qnFgJH/BaEU1QkWSV6sZk=; b=XhUrd75kdFk0iYC6z6b4qXzW3PdK9OSlnbpEdOmCY1ViAdJO82PtNCaNvC380qq3cy/GHGEwWEuAgmbt7LGFFyr9JO2bG+Nmc9a3VpNLblrejkx3fkOjmyV9cdNNoBjBUTKdCaR+0eflghFhar0tnwRTFelk196a9xhmd4Jjl5k= 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 1630789649358411.70009442871446; Sat, 4 Sep 2021 14:07:29 -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-422-1Z9RMJWMP82ZQrOyfFhjVQ-1; Sat, 04 Sep 2021 17:07:26 -0400 Received: from smtp.corp.redhat.com (int-mx01.intmail.prod.int.phx2.redhat.com [10.5.11.11]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mimecast-mx01.redhat.com (Postfix) with ESMTPS id 8C383800FEF; Sat, 4 Sep 2021 21:07:21 +0000 (UTC) Received: from colo-mx.corp.redhat.com (colo-mx01.intmail.prod.int.phx2.redhat.com [10.5.11.20]) by smtp.corp.redhat.com (Postfix) with ESMTPS id 7284C6E6E7; Sat, 4 Sep 2021 21:07:21 +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 43BA018087F1; Sat, 4 Sep 2021 21:07:21 +0000 (UTC) Received: from smtp.corp.redhat.com (int-mx08.intmail.prod.int.phx2.redhat.com [10.5.11.23]) by lists01.pubmisc.prod.ext.phx2.redhat.com (8.13.8/8.13.8) with ESMTP id 184Kicf1008834 for ; Sat, 4 Sep 2021 16:44:38 -0400 Received: by smtp.corp.redhat.com (Postfix) id 6CC321F4; Sat, 4 Sep 2021 20:44:38 +0000 (UTC) Received: from hjs.redhat.com (unknown [10.43.2.20]) by smtp.corp.redhat.com (Postfix) with ESMTP id E9D5926367 for ; Sat, 4 Sep 2021 20:44:37 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1630789648; 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=b02apZKTW2VNR4Qmp3YsE8qnFgJH/BaEU1QkWSV6sZk=; b=dpVPE84hUkzHtXYX2BwZOtVlGNAst6z5XpQ6QQ6o+ovbtAe8/nDSsCJ1GF6b45pQ8HfKA6 ptP/DsDgi1seN0ddqThLYJO0quC9A0Ig/UAyp+CKnDtSLaj9FwOYxxkFJrF6jX8F1peJSC tbvenlzMVX/IdnjmL1Bvnt+caJV07rM= X-MC-Unique: 1Z9RMJWMP82ZQrOyfFhjVQ-1 From: =?UTF-8?q?J=C3=A1n=20Tomko?= To: libvir-list@redhat.com Subject: [libvirt PATCH 13/24] tests: use g_auto for virCPUDataFree Date: Sat, 4 Sep 2021 22:44:11 +0200 Message-Id: <28371660a65f93bd5136097a0c30d7df0f22aea8.1630788206.git.jtomko@redhat.com> In-Reply-To: References: MIME-Version: 1.0 X-Scanned-By: MIMEDefang 2.84 on 10.5.11.23 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.11 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: 1630789650262100001 Signed-off-by: J=C3=A1n Tomko --- tests/qemumonitorjsontest.c | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/tests/qemumonitorjsontest.c b/tests/qemumonitorjsontest.c index 542b35850e..b68351d9d8 100644 --- a/tests/qemumonitorjsontest.c +++ b/tests/qemumonitorjsontest.c @@ -2158,7 +2158,7 @@ static int testQemuMonitorJSONGetCPUData(const void *opaque) { const struct testCPUData *data =3D opaque; - virCPUData *cpuData =3D NULL; + g_autoptr(virCPUData) cpuData =3D NULL; g_autofree char *jsonFile =3D NULL; g_autofree char *dataFile =3D NULL; g_autofree char *jsonStr =3D NULL; @@ -2208,7 +2208,6 @@ testQemuMonitorJSONGetCPUData(const void *opaque) =20 ret =3D 0; cleanup: - virCPUDataFree(cpuData); return ret; } =20 @@ -2217,7 +2216,7 @@ testQemuMonitorJSONGetNonExistingCPUData(const void *= opaque) { const testGenericData *data =3D opaque; virDomainXMLOption *xmlopt =3D data->xmlopt; - virCPUData *cpuData =3D NULL; + g_autoptr(virCPUData) cpuData =3D NULL; int rv, ret =3D -1; g_autoptr(qemuMonitorTest) test =3D NULL; =20 @@ -2251,7 +2250,6 @@ testQemuMonitorJSONGetNonExistingCPUData(const void *= opaque) =20 ret =3D 0; cleanup: - virCPUDataFree(cpuData); return ret; } =20 --=20 2.31.1