diff --git a/3rdParty/SheenBidi/CMakeLists.txt b/3rdParty/SheenBidi/CMakeLists.txt index 7f8633c91b5..283b6e71a9a 100644 --- a/3rdParty/SheenBidi/CMakeLists.txt +++ b/3rdParty/SheenBidi/CMakeLists.txt @@ -6,7 +6,7 @@ set(ASAN OFF) set(UBSAN OFF) FetchContent_Declare_ExcludeFromAll(SheenBidi - URL https://github.com/Tehreer/SheenBidi/archive/a1a55a8d6fbb63bab26f4f8ff43bdea5ec30a60a.tar.gz - URL_HASH MD5=f652da33c6a437ff8038d25c6fc9a01c + URL https://github.com/Tehreer/SheenBidi/archive/c44eb1163c0aac67544862b4fef8d1d3c747f1f0.tar.gz + URL_HASH MD5=2ae98ceaccb6d0be165766c9af1a6c2b ) FetchContent_MakeAvailable_ExcludeFromAll(SheenBidi) diff --git a/Source/utils/utf8.cpp b/Source/utils/utf8.cpp index 01f57c5e375..25e9962694d 100644 --- a/Source/utils/utf8.cpp +++ b/Source/utils/utf8.cpp @@ -13,13 +13,9 @@ namespace devilution { char32_t DecodeFirstUtf8CodePoint(std::string_view input, std::size_t *len) { - SBCodepointSequence seq { - .stringEncoding = SBStringEncodingUTF8, - .stringBuffer = const_cast(static_cast(input.data())), - .stringLength = static_cast(input.size()) - }; SBUInteger index = 0; - SBCodepoint result = SBCodepointSequenceGetCodepointAt(&seq, &index); + SBCodepoint result = SBCodepointDecodeNextFromUTF8( + reinterpret_cast(input.data()), static_cast(input.size()), &index); *len = index; return result; }