From ff8dc315d1f7ec73669ec96a10187def6139da5f Mon Sep 17 00:00:00 2001 From: Werner Lemberg Date: Wed, 22 Jan 2014 09:19:57 +0100 Subject: [PATCH] * src/autofit/hbshim.c (af_get_coverage): Fix memory leaks. --- ChangeLog | 4 ++++ src/autofit/hbshim.c | 5 +++-- 2 files changed, 7 insertions(+), 2 deletions(-) diff --git a/ChangeLog b/ChangeLog index ecdb4ec66..324ed1897 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,7 @@ +2014-01-22 Werner Lemberg + + * src/autofit/hbshim.c (af_get_coverage): Fix memory leaks. + 2014-01-16 Werner Lemberg [autofit] Improve tracing of style coverages. diff --git a/src/autofit/hbshim.c b/src/autofit/hbshim.c index 5e6ebd205..35cf1d341 100644 --- a/src/autofit/hbshim.c +++ b/src/autofit/hbshim.c @@ -168,7 +168,7 @@ gsub_lookups ); if ( hb_set_is_empty( gsub_lookups ) ) - return FT_Err_Ok; /* nothing to do */ + goto Exit; /* nothing to do */ hb_ot_layout_collect_lookups( face, HB_OT_TAG_GPOS, @@ -282,7 +282,7 @@ if ( !found ) { FT_TRACE4(( " no blue characters found; style skipped\n" )); - return FT_Err_Ok; + goto Exit; } } @@ -360,6 +360,7 @@ FT_TRACE4(( "\n\n" )); #endif + Exit: hb_set_destroy( gsub_lookups ); hb_set_destroy( gsub_glyphs ); hb_set_destroy( gpos_lookups );