From a24d4e9261ccd280e874177e6d21bdf40dd6d76d Mon Sep 17 00:00:00 2001 From: Behdad Esfahbod Date: Thu, 1 Dec 2022 20:27:56 -0700 Subject: [PATCH] [array] Oops. Fix memcpy copy()! --- src/hb-array.hh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/hb-array.hh b/src/hb-array.hh index 4c61f1a73..17562bc33 100644 --- a/src/hb-array.hh +++ b/src/hb-array.hh @@ -286,7 +286,7 @@ struct hb_array_t : hb_iter_with_fallback_t, Type&> TRACE_SERIALIZE (this); auto* out = c->start_embed (arrayZ); if (unlikely (!c->extend_size (out, get_size (), false))) return_trace (hb_array_t ()); - hb_memcpy (out, arrayZ, length); + hb_memcpy (out, arrayZ, get_size ()); return_trace (hb_array_t (out, length)); }