Memory leak fixes from Masatake YAMATO, #130652
authorOwen Taylor <otaylor@redhat.com>
Fri, 13 Feb 2004 16:11:40 +0000 (16:11 +0000)
committerOwen Taylor <otaylor@src.gnome.org>
Fri, 13 Feb 2004 16:11:40 +0000 (16:11 +0000)
Fri Feb 13 10:54:18 2004  Owen Taylor  <otaylor@redhat.com>

        Memory leak fixes from Masatake YAMATO, #130652

        * pango/opentype/ftxgdef.c (TT_Done_GDEF_Table):
        Free the gdef table as well as the contained data.

        * pango/opentype/ftxgdef.c (TT_GDEF_Build_ClassDefinition):
        Set gcd->loaded, so that the contents get freed later.

src/ftxgdef.c

index d1cbda1..3614697 100644 (file)
     
     Free_NewGlyphClasses( gdef, memory );
 
+    FREE( gdef );
+
     return TT_Err_Ok;
   }
 
     gdef->MarkAttachClassDef_offset = 0L;
     gdef->MarkAttachClassDef.loaded = FALSE;
 
+    gcd->loaded = TRUE;
+
     return TT_Err_Ok;
 
   Fail1: