external/boost/UnpackedTarball_boost.mk      |    1 +
 external/boost/boost.fallback.encoding.patch |   13 +++++++++++++
 2 files changed, 14 insertions(+)

New commits:
commit 1145909db26849350fb4f89392f17ddaeef69951
Author:     Michael Meeks <michael.me...@collabora.com>
AuthorDate: Thu Feb 17 22:44:25 2022 +0000
Commit:     Andras Timar <andras.ti...@collabora.com>
CommitDate: Fri Feb 18 15:12:41 2022 +0100

    boost: use utf-8 encoding for unknown locales.
    
    More exotic locales like es-419 cannot be parsed by boost, so we
    fall-back to the default encoding. This avoids an exception:
    invalid_charset_error of the form:
    
    "Invalid or unsupported charset:us-ascii or UTF-8"
    
    for this case.
    
    Change-Id: I6796dd893ec774b221956ea9febbcc19495d47b5
    Reviewed-on: https://gerrit.libreoffice.org/c/core/+/130121
    Tested-by: Jenkins CollaboraOffice <jenkinscollaboraoff...@gmail.com>
    Reviewed-by: Andras Timar <andras.ti...@collabora.com>

diff --git a/external/boost/UnpackedTarball_boost.mk 
b/external/boost/UnpackedTarball_boost.mk
index c93de3e1f169..c9ba682af61e 100644
--- a/external/boost/UnpackedTarball_boost.mk
+++ b/external/boost/UnpackedTarball_boost.mk
@@ -17,6 +17,7 @@ boost_patches += boost.utility.Wundef.warnings.patch
 
 boost_patches += boost.noiconv.patch
 boost_patches += boost.between.warning.patch
+boost_patches += boost.fallback.encoding.patch
 
 boost_patches += ubsan.patch.0
 boost_patches += rtti.patch.0
diff --git a/external/boost/boost.fallback.encoding.patch 
b/external/boost/boost.fallback.encoding.patch
new file mode 100644
index 000000000000..51ac7fc72308
--- /dev/null
+++ b/external/boost/boost.fallback.encoding.patch
@@ -0,0 +1,13 @@
+--- foo/misc/boost.orig/libs/locale/src/util/locale_data.cpp.new       
2022-02-17 22:41:27.730549039 +0000
++++ foo/misc/boost/libs/locale/src/util/locale_data.cpp
+@@ -18,8 +18,8 @@
+         language = "C";
+         country.clear();
+         variant.clear();
+-        encoding = "us-ascii";
+-        utf8=false;
++        encoding = "UTF-8";
++        utf8=true;
+         parse_from_lang(locale_name);
+     }
+ 

Reply via email to