fix memleak
authorAndreas Monzner <andreas.monzner@multimedia-labs.de>
Thu, 12 May 2005 16:49:56 +0000 (16:49 +0000)
committerAndreas Monzner <andreas.monzner@multimedia-labs.de>
Thu, 12 May 2005 16:49:56 +0000 (16:49 +0000)
lib/gdi/gpixmap.cpp

index 9e8219a5e588caeae6e11b6938722a9c38895ca1..96a3e9b0ac4d4af2529333814a7c00b96ebf71a0 100644 (file)
@@ -74,15 +74,8 @@ gSurfaceSystem::gSurfaceSystem(eSize size, int _bpp)
                bypp=(bpp+7)/8;
        }
        stride=x*bypp;
                bypp=(bpp+7)/8;
        }
        stride=x*bypp;
-       if (bpp==8)
-       {
-               clut.colors=256;
-               clut.data=new gRGB[clut.colors];
-       } else
-       {
-               clut.colors=0;
-               clut.data=0;
-       }
+       clut.colors=0;
+       clut.data=0;
        data=malloc(x*y*bypp);
 }
 
        data=malloc(x*y*bypp);
 }