summaryrefslogtreecommitdiff
path: root/sys-libs/libosinfo/files/1.11.0-osinfo-Make-xmlError-struct-constant-in-propagate_li.patch
blob: ea05c46a03b03efab09c459513cc7fcb524ba0e7 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
From 5bbdd06503456784c5ffa22409e8bab50470d673 Mon Sep 17 00:00:00 2001
Message-ID: <5bbdd06503456784c5ffa22409e8bab50470d673.1701161424.git.mprivozn@redhat.com>
From: Michal Privoznik <mprivozn@redhat.com>
Date: Mon, 27 Nov 2023 15:11:45 +0100
Subject: [PATCH] osinfo: Make xmlError struct constant in
 propagate_libxml_error()

In libxml2 commit v2.12.0~14 the API changed so that
xmlGetLastError() returns pointer to a constant xmlError struct.
Reflect this change in our code.

Signed-off-by: Michal Privoznik <mprivozn@redhat.com>
---
 osinfo/osinfo_install_script.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/osinfo/osinfo_install_script.c b/osinfo/osinfo_install_script.c
index 5800f37..303245a 100644
--- a/osinfo/osinfo_install_script.c
+++ b/osinfo/osinfo_install_script.c
@@ -769,7 +769,7 @@ static void propagate_libxml_error(GError **error, const char *format, ...) G_GN
 
 static void propagate_libxml_error(GError **error, const char *format, ...)
 {
-    xmlErrorPtr err = xmlGetLastError();
+    const xmlError *err = xmlGetLastError();
     char *prefix;
     va_list ap;
 
-- 
2.41.0