From ee35af738b5c802ca62eb1c39b77f0bd992329df Mon Sep 17 00:00:00 2001 From: Behdad Esfahbod Date: Thu, 2 Aug 2018 01:37:57 -0700 Subject: [PATCH] Make lazy-loader safe for nil objectification --- src/hb-machinery-private.hh | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/src/hb-machinery-private.hh b/src/hb-machinery-private.hh index 140bff6c8..40e42071f 100644 --- a/src/hb-machinery-private.hh +++ b/src/hb-machinery-private.hh @@ -656,6 +656,8 @@ struct hb_lazy_loader_t : hb_base_lazy_loader_t (&Null(T)); T *p = (T *) calloc (1, sizeof (T)); if (unlikely (!p)) p = const_cast (&Null(T)); @@ -678,6 +680,8 @@ struct hb_table_lazy_loader_t : hb_base_lazy_loader_t (face); } static inline void destroy (hb_blob_t *p)