diff options
author | Eskil Abrahamsen Blomfeldt <eskil.abrahamsen-blomfeldt@qt.io> | 2023-02-27 09:53:00 +0100 |
---|---|---|
committer | Eskil Abrahamsen Blomfeldt <eskil.abrahamsen-blomfeldt@qt.io> | 2023-03-01 06:37:29 +0100 |
commit | a6edf9cbe5bd1d1c6bc08733f97fc07812126bde (patch) | |
tree | 7013520fe3cf1828c75c3eee562c90c41465b567 /src/3rdparty/harfbuzz-ng/src/hb-serialize.hh | |
parent | 5f32c9edce208125f642c86a4bc9e73564386243 (diff) |
Update Harfbuzz to 7.0.1
Note: 6.4.x update has to be done in a separate commit
because it did not get the update to 6.0.0, so the
cherry-pick will not apply.
Pick-to: 6.2 6.5
Task-number: QTBUG-111535
Change-Id: I9d4aae98f8267827ec983ca89b1310006c6aee78
Reviewed-by: Volker Hilsheimer <volker.hilsheimer@qt.io>
Diffstat (limited to 'src/3rdparty/harfbuzz-ng/src/hb-serialize.hh')
-rw-r--r-- | src/3rdparty/harfbuzz-ng/src/hb-serialize.hh | 11 |
1 files changed, 9 insertions, 2 deletions
diff --git a/src/3rdparty/harfbuzz-ng/src/hb-serialize.hh b/src/3rdparty/harfbuzz-ng/src/hb-serialize.hh index d5573281f1..61ec0253a0 100644 --- a/src/3rdparty/harfbuzz-ng/src/hb-serialize.hh +++ b/src/3rdparty/harfbuzz-ng/src/hb-serialize.hh @@ -81,11 +81,11 @@ struct hb_serialize_context_t head = o.head; tail = o.tail; next = nullptr; - real_links.alloc (o.num_real_links); + real_links.alloc (o.num_real_links, true); for (unsigned i = 0 ; i < o.num_real_links; i++) real_links.push (o.real_links[i]); - virtual_links.alloc (o.num_virtual_links); + virtual_links.alloc (o.num_virtual_links, true); for (unsigned i = 0; i < o.num_virtual_links; i++) virtual_links.push (o.virtual_links[i]); } @@ -629,6 +629,13 @@ struct hb_serialize_context_t template <typename Type> Type *embed (const Type &obj) { return embed (std::addressof (obj)); } + char *embed (const char *obj, unsigned size) + { + char *ret = this->allocate_size<char> (size, false); + if (unlikely (!ret)) return nullptr; + hb_memcpy (ret, obj, size); + return ret; + } template <typename Type, typename ...Ts> auto _copy (const Type &src, hb_priority<1>, Ts&&... ds) HB_RETURN |