From nobody Sun Feb 8 20:53:40 2026 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 ARC-Seal: i=1; a=rsa-sha256; t=1561393697; cv=none; d=zoho.com; s=zohoarc; b=Dxi6fF/99rpCoedMptdHopENCbBYm7AKPtfbc7qEPI3g6aguFGv70GYV7vK5T6Rx8XGcrUJKLKOdIbozm8eaK91NtReHVzF2No3cRjGFofKSWgUzYmzPAHPsRHRDb1dcKsLxzoHWCzveZrbd5iK1vdn57CkSNcy/mkBzxNfHpGg= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zoho.com; s=zohoarc; t=1561393697; 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:ARC-Authentication-Results; bh=hkKqrKeRVhcFOLxVtCuYPTsfCnzoU5l1l/9FPsWOY20=; b=Rky8njx8wek5/g7UxMSSABZCUiUxaC6d8in/ApuU5viR7LDhdXl/6CKVbwHQcKYK+IORvm1gB+0IhamSSVz9u/ok7g9PpCwi2RcoSlLnRUJlqZILK0hrT8/WvDxMa/7qiYVL8UcLXqd6b4zokAE798UvKRBK6b2lUZIyMo/xwEQ= ARC-Authentication-Results: i=1; mx.zoho.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 header.from= (p=none dis=none) header.from= Return-Path: Received: from mx1.redhat.com (mx1.redhat.com [209.132.183.28]) by mx.zohomail.com with SMTPS id 156139369703679.54211488911187; Mon, 24 Jun 2019 09:28:17 -0700 (PDT) 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 mx1.redhat.com (Postfix) with ESMTPS id C4DF1882FB; Mon, 24 Jun 2019 16:28:14 +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 995DB5D721; Mon, 24 Jun 2019 16:28:13 +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 57A0C149E6; Mon, 24 Jun 2019 16:28:12 +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 x5OGRJSU003843 for ; Mon, 24 Jun 2019 12:27:19 -0400 Received: by smtp.corp.redhat.com (Postfix) id 898CD5D721; Mon, 24 Jun 2019 16:27:19 +0000 (UTC) Received: from angien.brq.redhat.com (unknown [10.43.2.229]) by smtp.corp.redhat.com (Postfix) with ESMTP id 1588F5D70D for ; Mon, 24 Jun 2019 16:27:18 +0000 (UTC) From: Peter Krempa To: libvir-list@redhat.com Date: Mon, 24 Jun 2019 18:27:13 +0200 Message-Id: In-Reply-To: References: MIME-Version: 1.0 X-Scanned-By: MIMEDefang 2.79 on 10.5.11.15 X-loop: libvir-list@redhat.com Subject: [libvirt] [PATCH 3/3] conf: domain: Restore XPath context after virSecurityDeviceLabelDefParseXML 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: , 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.15 X-Greylist: Sender IP whitelisted, not delayed by milter-greylist-4.5.16 (mx1.redhat.com [10.5.110.28]); Mon, 24 Jun 2019 16:28:15 +0000 (UTC) Content-Type: text/plain; charset="utf-8" The function modifies the context but did not care to restore it back. If a was used on a disk, the would not be parsed. Signed-off-by: Peter Krempa Reviewed-by: J=C3=A1n Tomko --- src/conf/domain_conf.c | 1 + tests/qemustatusxml2xmldata/modern-out.xml | 12 +++++++++++- 2 files changed, 12 insertions(+), 1 deletion(-) diff --git a/src/conf/domain_conf.c b/src/conf/domain_conf.c index 33253edfdd..3323c9a5b1 100644 --- a/src/conf/domain_conf.c +++ b/src/conf/domain_conf.c @@ -8872,6 +8872,7 @@ virSecurityDeviceLabelDefParseXML(virSecurityDeviceLa= belDefPtr **seclabels_rtn, xmlXPathContextPtr ctxt, unsigned int flags) { + VIR_XPATH_NODE_AUTORESTORE(ctxt); virSecurityDeviceLabelDefPtr *seclabels =3D NULL; size_t nseclabels =3D 0; int n; diff --git a/tests/qemustatusxml2xmldata/modern-out.xml b/tests/qemustatusx= ml2xmldata/modern-out.xml index 108e07eee0..f7104efa01 100644 --- a/tests/qemustatusxml2xmldata/modern-out.xml +++ b/tests/qemustatusxml2xmldata/modern-out.xml @@ -318,7 +318,17 @@ - + + + + + + base.qcow2 + + + + + --=20 2.21.0 -- libvir-list mailing list libvir-list@redhat.com https://www.redhat.com/mailman/listinfo/libvir-list