Fix memory leak in graphite2 face shaper unhappy path (#6263)

This commit is contained in:
egoism authored and GitHub committed 2026-09-15 21:16:07 -06:00
1 parent bf6414323c
commit d8c712f41c
1 file changed
+3 -1
+3 -1
View File
@@ -128,7 +128,9 @@ _hb_graphite2_shaper_face_data_create (hb_face_t *face)
data->grface = gr_make_face_with_ops (data, &ops, gr_face_preloadAll);
if (unlikely (!data->grface)) {
hb_free (data);
/* data->tlist has already been populated by the callback,
* so everything needs to be destroyed */
_hb_graphite2_shaper_face_data_destroy (data);
return nullptr;
}