use final upstream harfbuzz fix
Change-Id: Ibc57f684d45ab59332f22546f36f0e5bf79c5d23 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/185067 Reviewed-by: Caolán McNamara <caolan.mcnamara@collabora.com> Tested-by: Jenkins
This commit is contained in:
parent
3dd2d7f449
commit
6deb75dfee
32
external/harfbuzz/0001-buffer-Allow-unsafe_to_break-whole-buffer-to-succeed.patch.1
vendored
Normal file
32
external/harfbuzz/0001-buffer-Allow-unsafe_to_break-whole-buffer-to-succeed.patch.1
vendored
Normal file
@ -0,0 +1,32 @@
|
||||
From 39896512cfd6f37e416cdc9c598e977d9548426a Mon Sep 17 00:00:00 2001
|
||||
From: Behdad Esfahbod <behdad@behdad.org>
|
||||
Date: Wed, 7 May 2025 16:11:37 -0600
|
||||
Subject: [PATCH] [buffer] Allow unsafe_to_break() whole buffer to succeed
|
||||
|
||||
Fixes https://github.com/harfbuzz/harfbuzz/pull/5315
|
||||
---
|
||||
src/hb-buffer.hh | 6 +++---
|
||||
1 file changed, 3 insertions(+), 3 deletions(-)
|
||||
|
||||
diff --git a/src/hb-buffer.hh b/src/hb-buffer.hh
|
||||
index 6c620db69..1a534aad2 100644
|
||||
--- a/src/hb-buffer.hh
|
||||
+++ b/src/hb-buffer.hh
|
||||
@@ -410,11 +410,11 @@ struct hb_buffer_t
|
||||
bool interior = false,
|
||||
bool from_out_buffer = false)
|
||||
{
|
||||
- end = hb_min (end, len);
|
||||
-
|
||||
- if (unlikely (end - start > 255))
|
||||
+ if (unlikely (end != (unsigned) -1 && end - start > 255))
|
||||
return;
|
||||
|
||||
+ end = hb_min (end, len);
|
||||
+
|
||||
if (interior && !from_out_buffer && end - start < 2)
|
||||
return;
|
||||
|
||||
--
|
||||
2.49.0
|
||||
|
@ -1,44 +0,0 @@
|
||||
From 3bb296559745a08d7d7d05bf3e39bf010c68de55 Mon Sep 17 00:00:00 2001
|
||||
From: =?UTF-8?q?Caol=C3=A1n=20McNamara?= <caolan.mcnamara@collabora.com>
|
||||
Date: Tue, 6 May 2025 11:48:46 +0100
|
||||
Subject: [PATCH] increase maximum set_flags range
|
||||
|
||||
This a problem for LibreOffice since:
|
||||
|
||||
commit 0d8717275ac5809812c254c1b0923f2fc052c582
|
||||
CommitDate: Tue Apr 22 15:40:06 2025 -0600
|
||||
|
||||
[buffer] Limit the extent of set_flags range
|
||||
|
||||
where we now see an asset of:
|
||||
|
||||
vcl/source/gdi/impglyphitem.cxx:319: void checkGlyphsEqual(const SalLayoutGlyphs&, const SalLayoutGlyphs&): Assertion `l1->isLayoutEquivalent(l2)' failed.
|
||||
|
||||
as noted in https://gerrit.libreoffice.org/c/core/+/184761
|
||||
|
||||
on checking in debug-builds if reusing a subset of a previous laid out
|
||||
string as a cache for the same subtext seen again does really give the
|
||||
same results.
|
||||
|
||||
In our test documents, empirically checking what number here works,
|
||||
there's one case which still fails at len 2029 but succeeds at 2030.
|
||||
---
|
||||
src/hb-buffer.hh | 2 +-
|
||||
1 file changed, 1 insertion(+), 1 deletion(-)
|
||||
|
||||
diff --git a/src/hb-buffer.hh b/src/hb-buffer.hh
|
||||
index 6c620db69..c922ec592 100644
|
||||
--- a/src/hb-buffer.hh
|
||||
+++ b/src/hb-buffer.hh
|
||||
@@ -412,7 +412,7 @@ struct hb_buffer_t
|
||||
{
|
||||
end = hb_min (end, len);
|
||||
|
||||
- if (unlikely (end - start > 255))
|
||||
+ if (unlikely (end - start >= 2048))
|
||||
return;
|
||||
|
||||
if (interior && !from_out_buffer && end - start < 2)
|
||||
--
|
||||
2.49.0
|
||||
|
@ -15,13 +15,10 @@ $(eval $(call gb_UnpackedTarball_update_autoconf_configs,harfbuzz))
|
||||
|
||||
$(eval $(call gb_UnpackedTarball_set_patchlevel,harfbuzz,0))
|
||||
|
||||
# See https://github.com/harfbuzz/harfbuzz/pull/5315 for
|
||||
# 0001-increase-maximum-set_flags-range.patch.1
|
||||
|
||||
$(eval $(call gb_UnpackedTarball_add_patches,harfbuzz, \
|
||||
external/harfbuzz/tdf159529.patch.0 \
|
||||
external/harfbuzz/harfbuzz_visibility.patch.1 \
|
||||
external/harfbuzz/0001-increase-maximum-set_flags-range.patch.1 \
|
||||
external/harfbuzz/0001-buffer-Allow-unsafe_to_break-whole-buffer-to-succeed.patch.1 \
|
||||
))
|
||||
|
||||
# meson will replace python3 from shebang in build commands with the
|
||||
|
Loading…
x
Reference in New Issue
Block a user