fixed mismatched free/delete[]
authorkramm <kramm>
Sun, 6 Apr 2008 16:51:36 +0000 (16:51 +0000)
committerkramm <kramm>
Sun, 6 Apr 2008 16:51:36 +0000 (16:51 +0000)
lib/pdf/GFXOutputDev.cc

index 8ee24b4..227ea4d 100644 (file)
@@ -2175,7 +2175,7 @@ void GFXOutputDev::drawGeneralImage(GfxState *state, Object *ref, Stream *str,
 
          width = realwidth;
          height = realheight;
-         free(pic);
+         delete[] pic;
          pic = pic2;
          
          /* make a black/white palette */
@@ -2197,8 +2197,8 @@ void GFXOutputDev::drawGeneralImage(GfxState *state, Object *ref, Stream *str,
        }
       }
       drawimagelossless(device, pic2, width, height, x1,y1,x2,y2,x3,y3,x4,y4);
-      free(pic2);
-      free(pic);
+      delete[] pic2;
+      delete[] pic;
       delete imgStr;
       if(maskbitmap) free(maskbitmap);
       return;