[prev in list] [next in list] [prev in thread] [next in thread] 

List:       kde-commits
Subject:    kdelibs/kdefx
From:       Albert Astals Cid <tsdgeos () terra ! es>
Date:       2004-01-14 18:06:27
Message-ID: 20040114180627.8E921907E () office ! kde ! org
[Download RAW message or body]

CVS commit by aacid: 

Fix memory leak


  M +2 -2      kimageeffect.cpp   1.50


--- kdelibs/kdefx/kimageeffect.cpp  #1.49:1.50
@@ -626,5 +626,4 @@ QImage& KImageEffect::intensity(QImage &
 
     int segColors = image.depth() > 8 ? 256 : image.numColors();
-    unsigned char *segTbl = new unsigned char[segColors];
     int pixels = image.depth() > 8 ? image.width()*image.height() :
         image.numColors();
@@ -760,4 +759,5 @@ QImage& KImageEffect::intensity(QImage &
 #endif // USE_MMX_INLINE_ASM
     {
+        unsigned char *segTbl = new unsigned char[segColors];
         int tmp;
         if(brighten){ // keep overflow check out of loops


[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic