From nobody Mon Feb 9 13:59:34 2026 Delivered-To: importer@patchew.org Received-SPF: pass (zohomail.com: domain of redhat.com designates 207.211.31.81 as permitted sender) client-ip=207.211.31.81; envelope-from=libvir-list-bounces@redhat.com; helo=us-smtp-delivery-1.mimecast.com; Authentication-Results: mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of redhat.com designates 207.211.31.81 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=1582271135; cv=none; d=zohomail.com; s=zohoarc; b=ClKolCQxYyXsRqmSr62DNRmLi+fLVvieqBr2hSEc32XmR77ZwwEMk6H1lAGOm+MhWO6mshgreL+GH4iHqJzYTjYPUg6sj+P+xbv5kOzlPVHlUxAYgFrhvHW89QZTb1TYHOmvjESqXj9h6KtwxRQ0uVPxAo9nDu05cna3fBlxjNc= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1582271135; 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=Y+vPIiZMfvBShXAghxehI3ssi1kXCGE8Sxl4wC2lv3Q=; b=VCaoXK1wh42my5bIzex4wFatfHMsJQuiVxHMOHC0+JOY/hW2oTB3A5DduQNut+J36vulX+hANxbjcYueao1Xl5Hxhbd5BJRVW9dt7MATPK6TDmq0DpsyScVopMnB6yxmK+UMa41xP4/0mEbkRsLYGAYTTS+vifX//bNlH1sZPSI= ARC-Authentication-Results: i=1; mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of redhat.com designates 207.211.31.81 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-1.mimecast.com (us-smtp-2.mimecast.com [207.211.31.81]) by mx.zohomail.com with SMTPS id 1582271135393249.92064863234486; Thu, 20 Feb 2020 23:45:35 -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-139-UgozSYkLMHiV3rU0dCbPwA-1; Fri, 21 Feb 2020 02:45:29 -0500 Received: from smtp.corp.redhat.com (int-mx03.intmail.prod.int.phx2.redhat.com [10.5.11.13]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mimecast-mx01.redhat.com (Postfix) with ESMTPS id 13C28100550E; Fri, 21 Feb 2020 07:45:24 +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 D3CC087B11; Fri, 21 Feb 2020 07:45:23 +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 5C01A18089CF; Fri, 21 Feb 2020 07:45:23 +0000 (UTC) Received: from smtp.corp.redhat.com (int-mx04.intmail.prod.int.phx2.redhat.com [10.5.11.14]) by lists01.pubmisc.prod.ext.phx2.redhat.com (8.13.8/8.13.8) with ESMTP id 01L7ivJb012502 for ; Fri, 21 Feb 2020 02:44:57 -0500 Received: by smtp.corp.redhat.com (Postfix) id 46D695DA76; Fri, 21 Feb 2020 07:44:57 +0000 (UTC) Received: from moe.redhat.com (unknown [10.43.2.30]) by smtp.corp.redhat.com (Postfix) with ESMTP id BEFEA5D9E2 for ; Fri, 21 Feb 2020 07:44:56 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1582271134; 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=Y+vPIiZMfvBShXAghxehI3ssi1kXCGE8Sxl4wC2lv3Q=; b=XbnFLtJqWUBfK+fHpsgtxYDjTBZPE2vyTDWcCAaqxE8WY92b+fsQRLt4YN6UAci60ovQYL uxUFu+leJCln9CYCWbIkePMlkYYLQ/G4mKQfbBaE8baZIZiyWbjXmPUtRBX6goE6rFpmTs qgvTgBl3oKwV5hBVrd3WW8NEj9QMc+s= From: Michal Privoznik To: libvir-list@redhat.com Subject: [PATCH 2/3] virDomainNetDefClear: Free @persistent name Date: Fri, 21 Feb 2020 08:44:50 +0100 Message-Id: <362810b72715d3793dd732d7917a9690b3f488c6.1582271073.git.mprivozn@redhat.com> In-Reply-To: References: MIME-Version: 1.0 X-Scanned-By: MIMEDefang 2.79 on 10.5.11.14 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.13 X-MC-Unique: UgozSYkLMHiV3rU0dCbPwA-1 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" The persistent alias name @persistent is allocated in virDomainNetDefParseXML() but never freed. =3D=3D119642=3D=3D 22 bytes in 2 blocks are definitely lost in loss record = 178 of 671 =3D=3D119642=3D=3D at 0x483579F: malloc (vg_replace_malloc.c:309) =3D=3D119642=3D=3D by 0x58F89F1: xmlStrndup (in /usr/lib64/libxml2.so.2.= 9.9) =3D=3D119642=3D=3D by 0x4BA3B74: virXMLPropString (virxml.c:520) =3D=3D119642=3D=3D by 0x4BDB0C5: virDomainNetDefParseXML (domain_conf.c:= 11876) =3D=3D119642=3D=3D by 0x4BF9EF4: virDomainDefParseXML (domain_conf.c:211= 96) =3D=3D119642=3D=3D by 0x4BFCD5B: virDomainDefParseNode (domain_conf.c:21= 943) =3D=3D119642=3D=3D by 0x4BFCC36: virDomainDefParse (domain_conf.c:21901) =3D=3D119642=3D=3D by 0x4BFCCCB: virDomainDefParseFile (domain_conf.c:21= 924) =3D=3D119642=3D=3D by 0x114A9D: testCompareXMLToArgv (qemuxml2argvtest.c= :452) =3D=3D119642=3D=3D by 0x13894F: virTestRun (testutils.c:143) =3D=3D119642=3D=3D by 0x11F46E: mymain (qemuxml2argvtest.c:1316) =3D=3D119642=3D=3D by 0x13A60E: virTestMain (testutils.c:839 Signed-off-by: Michal Privoznik Reviewed-by: J=C3=A1n Tomko --- src/conf/domain_conf.c | 1 + 1 file changed, 1 insertion(+) diff --git a/src/conf/domain_conf.c b/src/conf/domain_conf.c index bd2ca53f1d..cef49df3f8 100644 --- a/src/conf/domain_conf.c +++ b/src/conf/domain_conf.c @@ -2444,6 +2444,7 @@ virDomainNetDefClear(virDomainNetDefPtr def) =20 VIR_FREE(def->backend.tap); VIR_FREE(def->backend.vhost); + VIR_FREE(def->teaming.persistent); VIR_FREE(def->virtPortProfile); VIR_FREE(def->script); VIR_FREE(def->domain_name); --=20 2.24.1