Bug 1082167 - don't leak featurelookups within InputsForOpenTypeFeature. r=jfkthame
authorJohn Daggett <jdaggett@mozilla.com>
Wed, 15 Oct 2014 08:38:03 +0900
changeset 210472 301ecb286faa4b4c589ead0caa36466a3dbc2732
parent 210471 9b99cd13756daaa46a0e8c3b72fe49e1fc4177b7
child 210473 dc83111c2f8719645db9b75e41aa827135fb7d09
push id1
push userroot
push dateMon, 20 Oct 2014 17:29:22 +0000
reviewersjfkthame
bugs1082167
milestone36.0a1
Bug 1082167 - don't leak featurelookups within InputsForOpenTypeFeature. r=jfkthame
gfx/thebes/gfxFontEntry.cpp
--- a/gfx/thebes/gfxFontEntry.cpp
+++ b/gfx/thebes/gfxFontEntry.cpp
@@ -989,16 +989,17 @@ gfxFontEntry::InputsForOpenTypeFeature(i
         hb_ot_layout_collect_lookups(face, kGSUB, scriptTags, nullptr,
                                      features, featurelookups);
         hb_codepoint_t index = -1;
         while (hb_set_next(featurelookups, &index)) {
             hb_ot_layout_lookup_collect_glyphs(face, kGSUB, index,
                                                nullptr, inputGlyphs,
                                                nullptr, nullptr);
         }
+        hb_set_destroy(featurelookups);
     }
 
     hb_face_destroy(face);
 
     mFeatureInputs->Put(scriptFeature, inputGlyphs);
     return inputGlyphs;
 }