SWF::GlyphList also uses delete where should use delete[].
This patch fix it.
Index: src/SWFGlyphList.cpp
===================================================================
--- src/SWFGlyphList.cpp        (revision 243)
+++ src/SWFGlyphList.cpp        (working copy)
@@ -12,8 +12,8 @@
 }
 
 GlyphList::~GlyphList() {
-       if( glyphs ) delete glyphs;
-       if( map ) delete map;
+       delete[] glyphs;
+       delete[] map;
 }
 
 bool GlyphList::parse( Reader *r, int end, Context *ctx ) {
@@ -242,8 +242,8 @@
 }
 
 void GlyphList::allocate( int n ) {
-       if( map ) delete map;
-       if( glyphs ) delete glyphs;
+       delete[] map;
+       delete[] glyphs;
 
        nGlyphs = n;
        glyphs = new GlyphShape[ nGlyphs ];
_______________________________________________
swfmill mailing list
swfmill@osflash.org
http://osflash.org/mailman/listinfo/swfmill_osflash.org

Reply via email to