diff options
| author | Alexander Golubev <fatzer2@gmail.com> | 2025-07-28 22:51:51 +0300 |
|---|---|---|
| committer | Alexander Golubev <fatzer2@gmail.com> | 2025-08-03 06:58:21 +0300 |
| commit | da1d4d6aae97ba298b2473dba085cac5136303a2 (patch) | |
| tree | 7853e28c3d2fcf8a043578cc8e80784138d01bd1 | |
| parent | 0bd9d5459891e6fb17ee6802878f85e217cb9f54 (diff) | |
| download | koffice-da1d4d6a.tar.gz koffice-da1d4d6a.zip | |
filters/xsltfilter: fix FTBFS against libxml 2.13+
See: https://gitlab.gnome.org/GNOME/libxml2/-/commit/c011e7605d42030cf21acdece466aaddaeb5a360
Closes: https://mirror.git.trinitydesktop.org/gitea/TDE/koffice/issues/96
Signed-off-by: Alexander Golubev <fatzer2@gmail.com>
(cherry picked from commit 8870815cc64f172228322891053943d7ab8557bb)
| -rw-r--r-- | filters/xsltfilter/export/xsltproc.cpp | 4 | ||||
| -rw-r--r-- | filters/xsltfilter/import/xsltproc.cpp | 4 |
2 files changed, 8 insertions, 0 deletions
diff --git a/filters/xsltfilter/export/xsltproc.cpp b/filters/xsltfilter/export/xsltproc.cpp index 3bd20408a..d252cdcd6 100644 --- a/filters/xsltfilter/export/xsltproc.cpp +++ b/filters/xsltfilter/export/xsltproc.cpp @@ -287,7 +287,11 @@ int XSLTProc::parse() * disable CDATA from being built in the document tree */ xmlDefaultSAXHandlerInit(); +#if LIBXML_VERSION < 21300 + // In 2.13.0 this global variable was made constant and claimed that + // it "hasn't had an effect for a long time" xmlDefaultSAXHandler.cdataBlock = NULL; +#endif // LIBXML_VERSION if ((cur != NULL) && (cur->errors == 0)) { diff --git a/filters/xsltfilter/import/xsltproc.cpp b/filters/xsltfilter/import/xsltproc.cpp index 3bd20408a..d252cdcd6 100644 --- a/filters/xsltfilter/import/xsltproc.cpp +++ b/filters/xsltfilter/import/xsltproc.cpp @@ -287,7 +287,11 @@ int XSLTProc::parse() * disable CDATA from being built in the document tree */ xmlDefaultSAXHandlerInit(); +#if LIBXML_VERSION < 21300 + // In 2.13.0 this global variable was made constant and claimed that + // it "hasn't had an effect for a long time" xmlDefaultSAXHandler.cdataBlock = NULL; +#endif // LIBXML_VERSION if ((cur != NULL) && (cur->errors == 0)) { |
