From nobody Fri May 3 23:03:23 2024 Delivered-To: importer@patchew.org Received-SPF: pass (zoho.com: domain of redhat.com designates 209.132.183.28 as permitted sender) client-ip=209.132.183.28; envelope-from=libvir-list-bounces@redhat.com; helo=mx1.redhat.com; Authentication-Results: mx.zohomail.com; spf=pass (zoho.com: domain of redhat.com designates 209.132.183.28 as permitted sender) smtp.mailfrom=libvir-list-bounces@redhat.com; dmarc=pass(p=none dis=none) header.from=redhat.com Return-Path: Received: from mx1.redhat.com (mx1.redhat.com [209.132.183.28]) by mx.zohomail.com with SMTPS id 1533709443322826.3827015944929; Tue, 7 Aug 2018 23:24:03 -0700 (PDT) Received: from smtp.corp.redhat.com (int-mx11.intmail.prod.int.phx2.redhat.com [10.5.11.26]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mx1.redhat.com (Postfix) with ESMTPS id 0A45130832D2; Wed, 8 Aug 2018 06:24:01 +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 9C087300193C; Wed, 8 Aug 2018 06:24:00 +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 B86364A463; Wed, 8 Aug 2018 06:23:58 +0000 (UTC) Received: from smtp.corp.redhat.com (int-mx03.intmail.prod.int.rdu2.redhat.com [10.11.54.3]) by lists01.pubmisc.prod.ext.phx2.redhat.com (8.13.8/8.13.8) with ESMTP id w786Nsge025539 for ; Wed, 8 Aug 2018 02:23:55 -0400 Received: by smtp.corp.redhat.com (Postfix) id D13921017CD2; Wed, 8 Aug 2018 06:23:54 +0000 (UTC) Received: from beluga.usersys.redhat.com (unknown [10.43.2.166]) by smtp.corp.redhat.com (Postfix) with ESMTP id 2A0E81018CA1; Wed, 8 Aug 2018 06:23:54 +0000 (UTC) From: Erik Skultety To: libvir-list@redhat.com Date: Wed, 8 Aug 2018 08:23:41 +0200 Message-Id: <81e9bc6c30218ba7a01778fdc76769b8a7fef7f4.1533709091.git.eskultet@redhat.com> In-Reply-To: References: In-Reply-To: References: X-Scanned-By: MIMEDefang 2.78 on 10.11.54.3 X-loop: libvir-list@redhat.com Cc: fiuczy@linux.vnet.ibm.com, Erik Skultety Subject: [libvirt] [PATCH 1/2] util: virnetdevopenvswitch: Drop an unused variable @ovs_timeout 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: , MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Sender: libvir-list-bounces@redhat.com Errors-To: libvir-list-bounces@redhat.com X-Scanned-By: MIMEDefang 2.84 on 10.5.11.26 X-Greylist: Sender IP whitelisted, not delayed by milter-greylist-4.5.16 (mx1.redhat.com [10.5.110.44]); Wed, 08 Aug 2018 06:24:01 +0000 (UTC) X-ZohoMail: RDMRC_0 RSF_0 Z_629925259 SPT_0 Content-Type: text/plain; charset="utf-8" Technically, it was never used ever since commit @f4d06ca8fd9 introduced it, but the fact that we called VIR_FREE on it was enough for Clang to never complain about it. Signed-off-by: Erik Skultety Reviewed-by: J=EF=BF=BDn Tomko --- CC'ing Boris, as he allowed specifying timeouts for openvswitch calls, howe= ver, this particular one hasn't been in use ever. src/util/virnetdevopenvswitch.c | 1 - 1 file changed, 1 deletion(-) diff --git a/src/util/virnetdevopenvswitch.c b/src/util/virnetdevopenvswitc= h.c index 69ae04ee5a..9a9435f8af 100644 --- a/src/util/virnetdevopenvswitch.c +++ b/src/util/virnetdevopenvswitch.c @@ -473,7 +473,6 @@ virNetDevOpenvswitchGetVhostuserIfname(const char *path, size_t ntokens =3D 0; int status; int ret =3D -1; - VIR_AUTOFREE(char *) ovs_timeout =3D NULL; /* Openvswitch vhostuser path are hardcoded to * //openvswitch/ -- 2.14.4 -- libvir-list mailing list libvir-list@redhat.com https://www.redhat.com/mailman/listinfo/libvir-list From nobody Fri May 3 23:03:23 2024 Delivered-To: importer@patchew.org Received-SPF: pass (zoho.com: domain of redhat.com designates 209.132.183.28 as permitted sender) client-ip=209.132.183.28; envelope-from=libvir-list-bounces@redhat.com; helo=mx1.redhat.com; Authentication-Results: mx.zohomail.com; spf=pass (zoho.com: domain of redhat.com designates 209.132.183.28 as permitted sender) smtp.mailfrom=libvir-list-bounces@redhat.com; dmarc=pass(p=none dis=none) header.from=redhat.com Return-Path: Received: from mx1.redhat.com (mx1.redhat.com [209.132.183.28]) by mx.zohomail.com with SMTPS id 153370946539797.39417444829348; Tue, 7 Aug 2018 23:24:25 -0700 (PDT) Received: from smtp.corp.redhat.com (int-mx04.intmail.prod.int.phx2.redhat.com [10.5.11.14]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mx1.redhat.com (Postfix) with ESMTPS id 1B1D2308FBAC; Wed, 8 Aug 2018 06:24:23 +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 D88A25D9C8; Wed, 8 Aug 2018 06:24:22 +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 96CD818037ED; Wed, 8 Aug 2018 06:24:22 +0000 (UTC) Received: from smtp.corp.redhat.com (int-mx03.intmail.prod.int.rdu2.redhat.com [10.11.54.3]) by lists01.pubmisc.prod.ext.phx2.redhat.com (8.13.8/8.13.8) with ESMTP id w786NtZv025544 for ; Wed, 8 Aug 2018 02:23:55 -0400 Received: by smtp.corp.redhat.com (Postfix) id 9DF3C10EE838; Wed, 8 Aug 2018 06:23:55 +0000 (UTC) Received: from beluga.usersys.redhat.com (unknown [10.43.2.166]) by smtp.corp.redhat.com (Postfix) with ESMTP id 1BD101017D4A; Wed, 8 Aug 2018 06:23:54 +0000 (UTC) From: Erik Skultety To: libvir-list@redhat.com Date: Wed, 8 Aug 2018 08:23:42 +0200 Message-Id: <7aeecddb82028ad7dedc4782ab3c4f5603074938.1533709091.git.eskultet@redhat.com> In-Reply-To: References: In-Reply-To: References: X-Scanned-By: MIMEDefang 2.78 on 10.11.54.3 X-loop: libvir-list@redhat.com Cc: Erik Skultety Subject: [libvirt] [PATCH 2/2] Fix the build on non-linux platforms after VIR_AUTOPTR related changes 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: , MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Sender: libvir-list-bounces@redhat.com Errors-To: libvir-list-bounces@redhat.com X-Scanned-By: MIMEDefang 2.79 on 10.5.11.14 X-Greylist: Sender IP whitelisted, not delayed by milter-greylist-4.5.16 (mx1.redhat.com [10.5.110.43]); Wed, 08 Aug 2018 06:24:23 +0000 (UTC) X-ZohoMail: RDMRC_0 RSF_0 Z_629925259 SPT_0 Content-Type: text/plain; charset="utf-8" Commits 7b706f33ac and 4acb7887e4 introduced some compound type *Free wrappers in order to use them with VIR_DEFINE_AUTOPTR_FUNC. However, since those were not used in the code right away, Clang complained about unused functions (static ones that are defined by the macro above). This patch puts the defined functions in use. Signed-off-by: Erik Skultety Reviewed-by: J=EF=BF=BDn Tomko --- src/util/virnetdev.c | 3 +-- src/util/virnetlink.c | 6 ++---- 2 files changed, 3 insertions(+), 6 deletions(-) diff --git a/src/util/virnetdev.c b/src/util/virnetdev.c index 9eca786c95..8eac419725 100644 --- a/src/util/virnetdev.c +++ b/src/util/virnetdev.c @@ -2833,7 +2833,7 @@ static int virNetDevGetMcastList(const char *ifname, char *buf =3D NULL; char *next =3D NULL; int ret =3D -1, len; - virNetDevMcastEntryPtr entry =3D NULL; + VIR_AUTOPTR(virNetDevMcastEntry) entry =3D NULL; =20 mcast->entries =3D NULL; mcast->nentries =3D 0; @@ -2867,7 +2867,6 @@ static int virNetDevGetMcastList(const char *ifname, ret =3D 0; cleanup: VIR_FREE(buf); - VIR_FREE(entry); =20 return ret; } diff --git a/src/util/virnetlink.c b/src/util/virnetlink.c index 2702c12d24..162efe6f99 100644 --- a/src/util/virnetlink.c +++ b/src/util/virnetlink.c @@ -305,7 +305,7 @@ int virNetlinkCommand(struct nl_msg *nl_msg, .nl_groups =3D 0, }; struct pollfd fds[1]; - virNetlinkHandle *nlhandle =3D NULL; + VIR_AUTOPTR(virNetlinkHandle) nlhandle =3D NULL; int len =3D 0; =20 memset(fds, 0, sizeof(fds)); @@ -333,7 +333,6 @@ int virNetlinkCommand(struct nl_msg *nl_msg, *respbuflen =3D 0; } =20 - virNetlinkFree(nlhandle); return ret; } =20 @@ -355,7 +354,7 @@ virNetlinkDumpCommand(struct nl_msg *nl_msg, .nl_pid =3D dst_pid, .nl_groups =3D 0, }; - virNetlinkHandle *nlhandle =3D NULL; + VIR_AUTOPTR(virNetlinkHandle) nlhandle =3D NULL; =20 if (!(nlhandle =3D virNetlinkSendRequest(nl_msg, src_pid, nladdr, protocol, groups))) @@ -382,7 +381,6 @@ virNetlinkDumpCommand(struct nl_msg *nl_msg, =20 cleanup: VIR_FREE(resp); - virNetlinkFree(nlhandle); return ret; } =20 --=20 2.14.4 -- libvir-list mailing list libvir-list@redhat.com https://www.redhat.com/mailman/listinfo/libvir-list