File libxml2-CVE-2025-49795.patch of Package libxml2.39888
From ea338a6ddc9b9e2699d4d15990832549156a92c0 Mon Sep 17 00:00:00 2001
From: Michael Mann <mmann78@netscape.net>
Date: Sat, 21 Jun 2025 12:11:30 -0400
Subject: [PATCH] Schematron: Fix null pointer dereference leading to DoS
(CVE-2025-49795)
Fixes #932
---
schematron.c | 2 ++
1 file changed, 2 insertions(+)
Index: libxml2-2.10.3/schematron.c
===================================================================
--- libxml2-2.10.3.orig/schematron.c
+++ libxml2-2.10.3/schematron.c
@@ -1481,6 +1481,8 @@ xmlSchematronFormatReport(xmlSchematronV
select = xmlGetNoNsProp(child, BAD_CAST "select");
comp = xmlXPathCtxtCompile(ctxt->xctxt, select);
eval = xmlXPathCompiledEval(comp, ctxt->xctxt);
+ if (eval == NULL)
+ return ret;
switch (eval->type) {
case XPATH_NODESET: {