From 05642cdf845ba2757b22e468a57869390faaa639 Mon Sep 17 00:00:00 2001 From: Eric Espie Date: Thu, 10 Jul 2025 16:53:36 +0200 Subject: [PATCH] =?UTF-8?q?N=C2=B08306=20-=20Wrong=20line=20number=20error?= =?UTF-8?q?=20if=20XML=20is=20over=2065535=20lines?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .make/release/update.classes.inc.php | 2 +- core/designdocument.class.inc.php | 5 +++++ 2 files changed, 6 insertions(+), 1 deletion(-) diff --git a/.make/release/update.classes.inc.php b/.make/release/update.classes.inc.php index 8f1499439..5b67edad3 100644 --- a/.make/release/update.classes.inc.php +++ b/.make/release/update.classes.inc.php @@ -199,7 +199,7 @@ class DatamodelsXmlFiles extends AbstractGlobFileVersionUpdater libxml_clear_errors(); $oFileXml->formatOutput = true; $oFileXml->preserveWhiteSpace = false; - $oFileXml->loadXML($sFileContent); + $oFileXml->loadXML($sFileContent, LIBXML_BIGLINES); $oFileItopFormat = new iTopDesignFormat($oFileXml); diff --git a/core/designdocument.class.inc.php b/core/designdocument.class.inc.php index 3965c68ec..c4a1e8e34 100644 --- a/core/designdocument.class.inc.php +++ b/core/designdocument.class.inc.php @@ -71,6 +71,11 @@ class DesignDocument extends DOMDocument $this->preserveWhiteSpace = true; // otherwise the formatOutput option would have no effect } + public function loadXML(string $source, int $options = 0) + { + parent::loadXML($source, $options | LIBXML_BIGLINES); + } + /** * Overload of the standard API *