Ah, my bad. It really bothers me that GCC doesn't crash on it. So I reorganized code to make sure the same mistake won't happen again. I'm planning on removing the code in Arabic shape fallback soon though.
behdad On 09/04/2012 02:31 AM, Kenichi Ishibashi wrote: > Hi Behdad, > > Thank you for the change, but it seems that we need to do it for > hb_apply_context_t(), not hb_would_apply_context_t() to fix the crash :) > > > > On Tue, Sep 4, 2012 at 9:19 AM, Behdad Esfahbod <[email protected] > <mailto:[email protected]>> wrote: > > src/hb-ot-layout-gsubgpos-private.hh | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) > > New commits: > commit f8fa2b5cf67b02d74514dec7885d03de73ec7349 > Author: Behdad Esfahbod <[email protected] <mailto:[email protected]>> > Date: Mon Sep 3 20:19:46 2012 -0400 > > Fix possible NULL dereference > > As reported by Kenichi Ishibashi. > > diff --git a/src/hb-ot-layout-gsubgpos-private.hh > b/src/hb-ot-layout-gsubgpos-private.hh > index 00bc563..40d5c57 100644 > --- a/src/hb-ot-layout-gsubgpos-private.hh > +++ b/src/hb-ot-layout-gsubgpos-private.hh > @@ -92,7 +92,7 @@ struct hb_would_apply_context_t > glyphs (glyphs_), > len (len_), > zero_context (zero_context_), > - digest (*digest_), > + digest (digest_ ? *digest_ : > hb_set_digest_t()), > debug_depth (0) {}; > }; > > _______________________________________________ > HarfBuzz mailing list > [email protected] <mailto:[email protected]> > http://lists.freedesktop.org/mailman/listinfo/harfbuzz > > _______________________________________________ HarfBuzz mailing list [email protected] http://lists.freedesktop.org/mailman/listinfo/harfbuzz
