From 6b11fea99716e22522b563d919ef7c72fe9a3c45 Mon Sep 17 00:00:00 2001 From: Behdad Esfahbod Date: Wed, 25 Jul 2018 16:01:37 -0700 Subject: [PATCH] [closure] Allocate out set on the stack --- src/hb-ot-layout-gsubgpos-private.hh | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/src/hb-ot-layout-gsubgpos-private.hh b/src/hb-ot-layout-gsubgpos-private.hh index c03e0335..747811e6 100644 --- a/src/hb-ot-layout-gsubgpos-private.hh +++ b/src/hb-ot-layout-gsubgpos-private.hh @@ -75,7 +75,7 @@ struct hb_closure_context_t : hb_face_t *face; hb_set_t *glyphs; - hb_set_t *out; + hb_auto_t out[1]; recurse_func_t recurse_func; unsigned int nesting_level_left; unsigned int debug_depth; @@ -86,7 +86,6 @@ struct hb_closure_context_t : unsigned int nesting_level_left_ = HB_MAX_NESTING_LEVEL) : face (face_), glyphs (glyphs_), - out (hb_set_create ()), recurse_func (nullptr), nesting_level_left (nesting_level_left_), debug_depth (0), @@ -95,7 +94,6 @@ struct hb_closure_context_t : ~hb_closure_context_t (void) { flush (); - hb_set_destroy (out); } void set_recurse_func (recurse_func_t func) { recurse_func = func; } -- GitLab