mirror of
https://github.com/storytold/harfbuzz.git
synced 2026-11-21 06:51:01 +01:00
FreeType requires face creation and destruction on a shared FT_Library to be serialized. Protect the lazily-created static library, its reference count, and its internally-owned faces with a lazy mutex. Keep caller-owned FT_Library instances outside the new lock, and add a multithreaded regression test for blob-backed faces and font funcs. Tests: meson test -C build (272/272 passed) Fixes: https://github.com/harfbuzz/harfbuzz/issues/6224 Assisted-by: OpenAI Codex <codex@openai.com>