From 3a86642a4b961d8e01b5dbc0c742335a721f0494 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Caol=C3=A1n=20McNamara?= Date: Sat, 12 Jul 2025 21:35:46 +0100 Subject: [PATCH] const up xmlsec MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Change-Id: I67e5946baaac3dbb7dd6aed429d66ac97673f615 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/187789 Tested-by: Jenkins Reviewed-by: Caolán McNamara --- .../0001-const-up-xmlSecErrorsTable.patch | 26 +++++++++++++++++++ external/xmlsec/UnpackedTarball_xmlsec.mk | 2 ++ 2 files changed, 28 insertions(+) create mode 100644 external/xmlsec/0001-const-up-xmlSecErrorsTable.patch diff --git a/external/xmlsec/0001-const-up-xmlSecErrorsTable.patch b/external/xmlsec/0001-const-up-xmlSecErrorsTable.patch new file mode 100644 index 000000000000..d580909ea53c --- /dev/null +++ b/external/xmlsec/0001-const-up-xmlSecErrorsTable.patch @@ -0,0 +1,26 @@ +From 49382b442e2c1c651019c58966f7a6378759954b Mon Sep 17 00:00:00 2001 +From: =?UTF-8?q?Caol=C3=A1n=20McNamara?= +Date: Sat, 12 Jul 2025 21:33:34 +0100 +Subject: [PATCH] const up xmlSecErrorsTable + +to move it out of the .data table +--- + src/errors.c | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +diff --git a/src/errors.c b/src/errors.c +index 075265d6..fe7e6601 100644 +--- a/src/errors.c ++++ b/src/errors.c +@@ -41,7 +41,7 @@ struct _xmlSecErrorDescription { + const char* errorMsg; + }; + +-static xmlSecErrorDescription xmlSecErrorsTable[XMLSEC_ERRORS_MAX_NUMBER + 1] = { ++static const xmlSecErrorDescription xmlSecErrorsTable[XMLSEC_ERRORS_MAX_NUMBER + 1] = { + { XMLSEC_ERRORS_R_XMLSEC_FAILED, "xmlsec library function failed" }, + { XMLSEC_ERRORS_R_MALLOC_FAILED, "malloc function failed" }, + { XMLSEC_ERRORS_R_STRDUP_FAILED, "strdup function failed" }, +-- +2.49.0 + diff --git a/external/xmlsec/UnpackedTarball_xmlsec.mk b/external/xmlsec/UnpackedTarball_xmlsec.mk index 77d3386b27dc..36641d89cd20 100644 --- a/external/xmlsec/UnpackedTarball_xmlsec.mk +++ b/external/xmlsec/UnpackedTarball_xmlsec.mk @@ -10,6 +10,8 @@ xmlsec_patches := # Remove this when Ubuntu 20.04 is EOL in 2025. xmlsec_patches += old-nss.patch.1 +# Upstreamed as: https://github.com/lsh123/xmlsec/pull/937 +xmlsec_patches += 0001-const-up-xmlSecErrorsTable.patch $(eval $(call gb_UnpackedTarball_UnpackedTarball,xmlsec))