Author: ranger
Date: Thu Aug 23 18:49:36 2007
New Revision: 929

URL: 
http://svn.finkproject.org/websvn/listing.php?sc=1&rev=929&repname=user%3a+ranger
Log:
updated imlib

Modified:
    trunk/experimental/10.3/main/finkinfo/graphics/imlib2-loaders.info
    trunk/experimental/10.3/main/finkinfo/graphics/imlib2.info
    trunk/experimental/10.3/main/finkinfo/graphics/imlib2.patch
    trunk/experimental/10.4/main/finkinfo/graphics/imlib2-loaders.info
    trunk/experimental/10.4/main/finkinfo/graphics/imlib2.info
    trunk/experimental/10.4/main/finkinfo/graphics/imlib2.patch
    trunk/experimental/common/main/finkinfo/graphics/imlib2-loaders.info
    trunk/experimental/common/main/finkinfo/graphics/imlib2.info
    trunk/experimental/common/main/finkinfo/graphics/imlib2.patch

Modified: trunk/experimental/10.3/main/finkinfo/graphics/imlib2-loaders.info
URL: 
http://svn.finkproject.org/websvn/diff.php?path=/trunk/experimental/10.3/main/finkinfo/graphics/imlib2-loaders.info&rev=929&repname=user%3a+ranger
==============================================================================
--- trunk/experimental/10.3/main/finkinfo/graphics/imlib2-loaders.info 
(original)
+++ trunk/experimental/10.3/main/finkinfo/graphics/imlib2-loaders.info Thu Aug 
23 18:49:36 2007
@@ -1,5 +1,5 @@
 Package: imlib2-loaders
-Version: 1.2.2
+Version: 1.4.0
 Revision: 11
 Description: Image handling library (extra loaders)
 License: GPL
@@ -16,7 +16,7 @@
 <<
 
 Source: mirror:sourceforge:enlightenment/imlib2_loaders-%v.tar.gz
-Source-MD5: d6442646a4544901433173ec359bd8c5
+Source-MD5: 6f51ef8d566769b9ac17c640a34fb1c8
 PatchScript:   perl -pi -e 's,need_relink=yes,need_relink=no,g; 
s,hardcode_direct=yes,hardcode_direct=no,g; s,-flat_namespace -undefined 
suppress,-undefined dynamic_lookup,g' ltmain.sh configure
 
 SetLIBS: -L%p/lib

Modified: trunk/experimental/10.3/main/finkinfo/graphics/imlib2.info
URL: 
http://svn.finkproject.org/websvn/diff.php?path=/trunk/experimental/10.3/main/finkinfo/graphics/imlib2.info&rev=929&repname=user%3a+ranger
==============================================================================
--- trunk/experimental/10.3/main/finkinfo/graphics/imlib2.info (original)
+++ trunk/experimental/10.3/main/finkinfo/graphics/imlib2.info Thu Aug 23 
18:49:36 2007
@@ -1,6 +1,6 @@
 Package: imlib2
-Version: 1.2.2
-Revision: 13
+Version: 1.4.0
+Revision: 11
 Description: Image handling library for X11
 License: BSD
 Maintainer: Benjamin Reed <[EMAIL PROTECTED]>
@@ -23,7 +23,7 @@
 BuildDependsOnly: true
 
 Source: mirror:sourceforge:enlightenment/%n-%v.tar.gz
-Source-MD5: 07b2a7745ddd3c7c4480b50cb916174c
+Source-MD5: 69f7ee996c943142332b4c98597b095c
 UpdateLibtoolInDirs: libltdl
 PatchScript: <<
        perl -pi -e 's,need_relink=yes,need_relink=no,g; 
s,hardcode_direct=yes,hardcode_direct=no,g; s,-flat_namespace -undefined 
suppress,-undefined dynamic_lookup,g' ltmain.sh configure

Modified: trunk/experimental/10.3/main/finkinfo/graphics/imlib2.patch
URL: 
http://svn.finkproject.org/websvn/diff.php?path=/trunk/experimental/10.3/main/finkinfo/graphics/imlib2.patch&rev=929&repname=user%3a+ranger
==============================================================================
--- trunk/experimental/10.3/main/finkinfo/graphics/imlib2.patch (original)
+++ trunk/experimental/10.3/main/finkinfo/graphics/imlib2.patch Thu Aug 23 
18:49:36 2007
@@ -1,14 +1,105 @@
 
---- imlib2-1.2.2/imlib2.pc.in  2006-01-23 22:46:12.000000000 -0500
-+++ imlib2-1.2.2-new/imlib2.pc.in      2006-07-05 22:24:36.000000000 -0400
-@@ -5,8 +5,6 @@
- 
+--- imlib2-1.4.0/imlib2.pc.in  2007-03-23 05:32:39.000000000 -0400
++++ imlib2-1.4.0-new/imlib2.pc.in      2007-08-23 12:29:22.000000000 -0400
+@@ -6,6 +6,6 @@
  Name: imlib2
  Description: Powerful image loading and rendering library
--Requires: @requirements@
  Version: @VERSION@
 -Libs: -L${libdir} -lImlib2
 -Cflags: -I${includedir}
--
 +Libs: [EMAIL PROTECTED]@/lib/freetype219/lib -L${libdir} -lImlib2 -lfreetype
 +Cflags: [EMAIL PROTECTED]@/lib/freetype219/include -I${includedir}
+ 
+--- imlib2-1.4.0/src/modules/loaders/loader_argb.c     2007-04-09 
18:40:40.000000000 -0400
++++ imlib2-1.4.0-new/src/modules/loaders/loader_argb.c 2007-08-23 
12:36:18.000000000 -0400
+@@ -10,7 +10,7 @@
+ load(ImlibImage * im, ImlibProgressFunction progress,
+      char progress_granularity, char immediate_load)
+ {
+-   int                 w, h, alpha;
++   int                 w=0, h=0, alpha=0;
+    FILE               *f;
+ 
+    if (im->data)
+@@ -23,6 +23,8 @@
+    {
+       char                buf[256], buf2[256];
+ 
++      memset(buf, 0, sizeof(buf));
++      memset(buf2, 0, sizeof(buf));
+       if (!fgets(buf, 255, f))
+         {
+            fclose(f);
+--- imlib2-1.4.0/src/modules/loaders/loader_jpeg.c     2007-04-09 
18:40:40.000000000 -0400
++++ imlib2-1.4.0-new/src/modules/loaders/loader_jpeg.c 2007-08-23 
12:37:51.000000000 -0400
+@@ -94,8 +94,9 @@
+         im->w = w = cinfo.output_width;
+         im->h = h = cinfo.output_height;
+ 
+-        if (cinfo.rec_outbuf_height > 16)
++        if (cinfo.rec_outbuf_height > 16 || w < 1 || h < 1 || w > 8192 || h > 
8192)
+           {
++             im->w = im->h = 0;
+              jpeg_destroy_decompress(&cinfo);
+              fclose(f);
+              return 0;
+--- imlib2-1.4.0/src/modules/loaders/loader_lbm.c      2007-04-09 
18:40:40.000000000 -0400
++++ imlib2-1.4.0-new/src/modules/loaders/loader_lbm.c  2007-08-23 
12:37:03.000000000 -0400
+@@ -437,6 +437,7 @@
+         }
+     }
+     if (!full || !ok) {
++        im->w = im->h = 0;
+         freeilbm(&ilbm);
+         return ok;
+     }
+@@ -451,12 +452,13 @@
+     cancel = 0;
+     plane[0] = NULL;
+ 
++    n = ilbm.depth;
++    if (ilbm.mask == 1) n++;
++
+     im->data = malloc(im->w * im->h * sizeof(DATA32));
+-    if (im->data) {
+-        n = ilbm.depth;
+-        if (ilbm.mask == 1) n++;
++    plane[0] = malloc(((im->w + 15) / 16) * 2 * n);
++    if (im->data && plane[0]) {
+ 
+-        plane[0] = malloc(((im->w + 15) / 16) * 2 * n);
+         for (i = 1; i < n; i++) plane[i] = plane[i - 1] + ((im->w + 15) / 16) 
* 2;
+ 
+         z = ((im->w + 15) / 16) * 2 * n;
+@@ -495,6 +497,7 @@
+    * the memory for im->data.
+    *----------*/
+     if (!ok) {
++        im->w = im->h = 0;
+         if (im->data) free(im->data);
+         im->data = NULL;
+     }
+--- imlib2-1.4.0/src/modules/loaders/loader_pnm.c      2007-04-09 
18:40:40.000000000 -0400
++++ imlib2-1.4.0-new/src/modules/loaders/loader_pnm.c  2007-08-23 
12:28:37.000000000 -0400
+@@ -68,7 +68,7 @@
+              int                 i = 0;
+ 
+              /* read numbers */
+-             while (c != EOF && !isspace(c))
++             while (c != EOF && i+1 < sizeof(buf) && !isspace(c))
+                {
+                   buf[i++] = c;
+                   c = fgetc(f);
+--- imlib2-1.4.0/src/modules/loaders/loader_tga.c      2007-04-09 
18:40:40.000000000 -0400
++++ imlib2-1.4.0-new/src/modules/loaders/loader_tga.c  2007-08-23 
12:44:11.000000000 -0400
+@@ -350,7 +350,9 @@
+                   else
+                      dataptr = im->data + (y * im->w);
+ 
+-                  for (x = 0; x < im->w; x++)   /* for each pixel in the row 
*/
++                  for (x = 0;
++                       x < im->w && bufptr+bpp/8 < bufend;
++                       x++)   /* for each pixel in the row */
+                     {
+                        switch (bpp)
+                          {

Modified: trunk/experimental/10.4/main/finkinfo/graphics/imlib2-loaders.info
URL: 
http://svn.finkproject.org/websvn/diff.php?path=/trunk/experimental/10.4/main/finkinfo/graphics/imlib2-loaders.info&rev=929&repname=user%3a+ranger
==============================================================================
--- trunk/experimental/10.4/main/finkinfo/graphics/imlib2-loaders.info 
(original)
+++ trunk/experimental/10.4/main/finkinfo/graphics/imlib2-loaders.info Thu Aug 
23 18:49:36 2007
@@ -1,5 +1,5 @@
 Package: imlib2-loaders
-Version: 1.2.2
+Version: 1.4.0
 Revision: 1021
 Description: Image handling library (extra loaders)
 License: GPL
@@ -16,7 +16,7 @@
 <<
 
 Source: mirror:sourceforge:enlightenment/imlib2_loaders-%v.tar.gz
-Source-MD5: d6442646a4544901433173ec359bd8c5
+Source-MD5: 6f51ef8d566769b9ac17c640a34fb1c8
 PatchScript:   perl -pi -e 's,need_relink=yes,need_relink=no,g; 
s,hardcode_direct=yes,hardcode_direct=no,g; s,-flat_namespace -undefined 
suppress,-undefined dynamic_lookup,g' ltmain.sh configure
 
 SetLIBS: -L%p/lib

Modified: trunk/experimental/10.4/main/finkinfo/graphics/imlib2.info
URL: 
http://svn.finkproject.org/websvn/diff.php?path=/trunk/experimental/10.4/main/finkinfo/graphics/imlib2.info&rev=929&repname=user%3a+ranger
==============================================================================
--- trunk/experimental/10.4/main/finkinfo/graphics/imlib2.info (original)
+++ trunk/experimental/10.4/main/finkinfo/graphics/imlib2.info Thu Aug 23 
18:49:36 2007
@@ -1,6 +1,6 @@
 Package: imlib2
-Version: 1.2.2
-Revision: 1023
+Version: 1.4.0
+Revision: 1021
 Description: Image handling library for X11
 License: BSD
 Maintainer: Benjamin Reed <[EMAIL PROTECTED]>
@@ -23,7 +23,7 @@
 BuildDependsOnly: true
 
 Source: mirror:sourceforge:enlightenment/%n-%v.tar.gz
-Source-MD5: 07b2a7745ddd3c7c4480b50cb916174c
+Source-MD5: 69f7ee996c943142332b4c98597b095c
 UpdateLibtoolInDirs: libltdl
 PatchScript: <<
        perl -pi -e 's,need_relink=yes,need_relink=no,g; 
s,hardcode_direct=yes,hardcode_direct=no,g; s,-flat_namespace -undefined 
suppress,-undefined dynamic_lookup,g' ltmain.sh configure

Modified: trunk/experimental/10.4/main/finkinfo/graphics/imlib2.patch
URL: 
http://svn.finkproject.org/websvn/diff.php?path=/trunk/experimental/10.4/main/finkinfo/graphics/imlib2.patch&rev=929&repname=user%3a+ranger
==============================================================================
--- trunk/experimental/10.4/main/finkinfo/graphics/imlib2.patch (original)
+++ trunk/experimental/10.4/main/finkinfo/graphics/imlib2.patch Thu Aug 23 
18:49:36 2007
@@ -1,14 +1,105 @@
 
---- imlib2-1.2.2/imlib2.pc.in  2006-01-23 22:46:12.000000000 -0500
-+++ imlib2-1.2.2-new/imlib2.pc.in      2006-07-05 22:24:36.000000000 -0400
-@@ -5,8 +5,6 @@
- 
+--- imlib2-1.4.0/imlib2.pc.in  2007-03-23 05:32:39.000000000 -0400
++++ imlib2-1.4.0-new/imlib2.pc.in      2007-08-23 12:29:22.000000000 -0400
+@@ -6,6 +6,6 @@
  Name: imlib2
  Description: Powerful image loading and rendering library
--Requires: @requirements@
  Version: @VERSION@
 -Libs: -L${libdir} -lImlib2
 -Cflags: -I${includedir}
--
 +Libs: [EMAIL PROTECTED]@/lib/freetype219/lib -L${libdir} -lImlib2 -lfreetype
 +Cflags: [EMAIL PROTECTED]@/lib/freetype219/include -I${includedir}
+ 
+--- imlib2-1.4.0/src/modules/loaders/loader_argb.c     2007-04-09 
18:40:40.000000000 -0400
++++ imlib2-1.4.0-new/src/modules/loaders/loader_argb.c 2007-08-23 
12:36:18.000000000 -0400
+@@ -10,7 +10,7 @@
+ load(ImlibImage * im, ImlibProgressFunction progress,
+      char progress_granularity, char immediate_load)
+ {
+-   int                 w, h, alpha;
++   int                 w=0, h=0, alpha=0;
+    FILE               *f;
+ 
+    if (im->data)
+@@ -23,6 +23,8 @@
+    {
+       char                buf[256], buf2[256];
+ 
++      memset(buf, 0, sizeof(buf));
++      memset(buf2, 0, sizeof(buf));
+       if (!fgets(buf, 255, f))
+         {
+            fclose(f);
+--- imlib2-1.4.0/src/modules/loaders/loader_jpeg.c     2007-04-09 
18:40:40.000000000 -0400
++++ imlib2-1.4.0-new/src/modules/loaders/loader_jpeg.c 2007-08-23 
12:37:51.000000000 -0400
+@@ -94,8 +94,9 @@
+         im->w = w = cinfo.output_width;
+         im->h = h = cinfo.output_height;
+ 
+-        if (cinfo.rec_outbuf_height > 16)
++        if (cinfo.rec_outbuf_height > 16 || w < 1 || h < 1 || w > 8192 || h > 
8192)
+           {
++             im->w = im->h = 0;
+              jpeg_destroy_decompress(&cinfo);
+              fclose(f);
+              return 0;
+--- imlib2-1.4.0/src/modules/loaders/loader_lbm.c      2007-04-09 
18:40:40.000000000 -0400
++++ imlib2-1.4.0-new/src/modules/loaders/loader_lbm.c  2007-08-23 
12:37:03.000000000 -0400
+@@ -437,6 +437,7 @@
+         }
+     }
+     if (!full || !ok) {
++        im->w = im->h = 0;
+         freeilbm(&ilbm);
+         return ok;
+     }
+@@ -451,12 +452,13 @@
+     cancel = 0;
+     plane[0] = NULL;
+ 
++    n = ilbm.depth;
++    if (ilbm.mask == 1) n++;
++
+     im->data = malloc(im->w * im->h * sizeof(DATA32));
+-    if (im->data) {
+-        n = ilbm.depth;
+-        if (ilbm.mask == 1) n++;
++    plane[0] = malloc(((im->w + 15) / 16) * 2 * n);
++    if (im->data && plane[0]) {
+ 
+-        plane[0] = malloc(((im->w + 15) / 16) * 2 * n);
+         for (i = 1; i < n; i++) plane[i] = plane[i - 1] + ((im->w + 15) / 16) 
* 2;
+ 
+         z = ((im->w + 15) / 16) * 2 * n;
+@@ -495,6 +497,7 @@
+    * the memory for im->data.
+    *----------*/
+     if (!ok) {
++        im->w = im->h = 0;
+         if (im->data) free(im->data);
+         im->data = NULL;
+     }
+--- imlib2-1.4.0/src/modules/loaders/loader_pnm.c      2007-04-09 
18:40:40.000000000 -0400
++++ imlib2-1.4.0-new/src/modules/loaders/loader_pnm.c  2007-08-23 
12:28:37.000000000 -0400
+@@ -68,7 +68,7 @@
+              int                 i = 0;
+ 
+              /* read numbers */
+-             while (c != EOF && !isspace(c))
++             while (c != EOF && i+1 < sizeof(buf) && !isspace(c))
+                {
+                   buf[i++] = c;
+                   c = fgetc(f);
+--- imlib2-1.4.0/src/modules/loaders/loader_tga.c      2007-04-09 
18:40:40.000000000 -0400
++++ imlib2-1.4.0-new/src/modules/loaders/loader_tga.c  2007-08-23 
12:44:11.000000000 -0400
+@@ -350,7 +350,9 @@
+                   else
+                      dataptr = im->data + (y * im->w);
+ 
+-                  for (x = 0; x < im->w; x++)   /* for each pixel in the row 
*/
++                  for (x = 0;
++                       x < im->w && bufptr+bpp/8 < bufend;
++                       x++)   /* for each pixel in the row */
+                     {
+                        switch (bpp)
+                          {

Modified: trunk/experimental/common/main/finkinfo/graphics/imlib2-loaders.info
URL: 
http://svn.finkproject.org/websvn/diff.php?path=/trunk/experimental/common/main/finkinfo/graphics/imlib2-loaders.info&rev=929&repname=user%3a+ranger
==============================================================================
--- trunk/experimental/common/main/finkinfo/graphics/imlib2-loaders.info 
(original)
+++ trunk/experimental/common/main/finkinfo/graphics/imlib2-loaders.info Thu 
Aug 23 18:49:36 2007
@@ -1,8 +1,8 @@
 Package: imlib2-loaders
-Version: 1.2.2
+Version: 1.4.0
 Revision: 1
 Source: mirror:sourceforge:enlightenment/imlib2_loaders-%v.tar.gz
-Source-MD5: d6442646a4544901433173ec359bd8c5
+Source-MD5: 6f51ef8d566769b9ac17c640a34fb1c8
 BuildDepends: imlib2 (>= %v-1), libgettext3-dev, gettext-bin, gettext-tools, 
libiconv-dev, x11-dev
 Depends: imlib2-shlibs (>= %v-1)
 SetLIBS: -L%p/lib

Modified: trunk/experimental/common/main/finkinfo/graphics/imlib2.info
URL: 
http://svn.finkproject.org/websvn/diff.php?path=/trunk/experimental/common/main/finkinfo/graphics/imlib2.info&rev=929&repname=user%3a+ranger
==============================================================================
--- trunk/experimental/common/main/finkinfo/graphics/imlib2.info (original)
+++ trunk/experimental/common/main/finkinfo/graphics/imlib2.info Thu Aug 23 
18:49:36 2007
@@ -1,8 +1,8 @@
 Package: imlib2
-Version: 1.2.2
-Revision: 3
+Version: 1.4.0
+Revision: 1
 Source: mirror:sourceforge:enlightenment/%n-%v.tar.gz
-Source-MD5: 07b2a7745ddd3c7c4480b50cb916174c
+Source-MD5: 69f7ee996c943142332b4c98597b095c
 BuildDepends: freetype219, libgettext3-dev, gettext-bin, gettext-tools, 
libid3tag, libiconv-dev, libjpeg, libpng3, libtiff, giflib | libungif, x11-dev
 Depends: %N-shlibs (= %v-%r)
 Replaces: %N-shlibs (<<1.1.0-14)

Modified: trunk/experimental/common/main/finkinfo/graphics/imlib2.patch
URL: 
http://svn.finkproject.org/websvn/diff.php?path=/trunk/experimental/common/main/finkinfo/graphics/imlib2.patch&rev=929&repname=user%3a+ranger
==============================================================================
--- trunk/experimental/common/main/finkinfo/graphics/imlib2.patch (original)
+++ trunk/experimental/common/main/finkinfo/graphics/imlib2.patch Thu Aug 23 
18:49:36 2007
@@ -1,14 +1,110 @@
-diff -uNr imlib2-1.2.2/imlib2.pc.in imlib2-1.2.2-new/imlib2.pc.in
---- imlib2-1.2.2/imlib2.pc.in  2006-01-23 22:46:12.000000000 -0500
-+++ imlib2-1.2.2-new/imlib2.pc.in      2006-07-05 22:24:36.000000000 -0400
-@@ -5,8 +5,6 @@
- 
+diff -uNr imlib2-1.4.0/imlib2.pc.in imlib2-1.4.0-new/imlib2.pc.in
+--- imlib2-1.4.0/imlib2.pc.in  2007-03-23 05:32:39.000000000 -0400
++++ imlib2-1.4.0-new/imlib2.pc.in      2007-08-23 12:29:22.000000000 -0400
+@@ -6,6 +6,6 @@
  Name: imlib2
  Description: Powerful image loading and rendering library
--Requires: @requirements@
  Version: @VERSION@
 -Libs: -L${libdir} -lImlib2
 -Cflags: -I${includedir}
--
 +Libs: [EMAIL PROTECTED]@/lib/freetype219/lib -L${libdir} -lImlib2 -lfreetype
 +Cflags: [EMAIL PROTECTED]@/lib/freetype219/include -I${includedir}
+ 
+diff -uNr imlib2-1.4.0/src/modules/loaders/loader_argb.c 
imlib2-1.4.0-new/src/modules/loaders/loader_argb.c
+--- imlib2-1.4.0/src/modules/loaders/loader_argb.c     2007-04-09 
18:40:40.000000000 -0400
++++ imlib2-1.4.0-new/src/modules/loaders/loader_argb.c 2007-08-23 
12:36:18.000000000 -0400
+@@ -10,7 +10,7 @@
+ load(ImlibImage * im, ImlibProgressFunction progress,
+      char progress_granularity, char immediate_load)
+ {
+-   int                 w, h, alpha;
++   int                 w=0, h=0, alpha=0;
+    FILE               *f;
+ 
+    if (im->data)
+@@ -23,6 +23,8 @@
+    {
+       char                buf[256], buf2[256];
+ 
++      memset(buf, 0, sizeof(buf));
++      memset(buf2, 0, sizeof(buf));
+       if (!fgets(buf, 255, f))
+         {
+            fclose(f);
+diff -uNr imlib2-1.4.0/src/modules/loaders/loader_jpeg.c 
imlib2-1.4.0-new/src/modules/loaders/loader_jpeg.c
+--- imlib2-1.4.0/src/modules/loaders/loader_jpeg.c     2007-04-09 
18:40:40.000000000 -0400
++++ imlib2-1.4.0-new/src/modules/loaders/loader_jpeg.c 2007-08-23 
12:37:51.000000000 -0400
+@@ -94,8 +94,9 @@
+         im->w = w = cinfo.output_width;
+         im->h = h = cinfo.output_height;
+ 
+-        if (cinfo.rec_outbuf_height > 16)
++        if (cinfo.rec_outbuf_height > 16 || w < 1 || h < 1 || w > 8192 || h > 
8192)
+           {
++             im->w = im->h = 0;
+              jpeg_destroy_decompress(&cinfo);
+              fclose(f);
+              return 0;
+diff -uNr imlib2-1.4.0/src/modules/loaders/loader_lbm.c 
imlib2-1.4.0-new/src/modules/loaders/loader_lbm.c
+--- imlib2-1.4.0/src/modules/loaders/loader_lbm.c      2007-04-09 
18:40:40.000000000 -0400
++++ imlib2-1.4.0-new/src/modules/loaders/loader_lbm.c  2007-08-23 
12:37:03.000000000 -0400
+@@ -437,6 +437,7 @@
+         }
+     }
+     if (!full || !ok) {
++        im->w = im->h = 0;
+         freeilbm(&ilbm);
+         return ok;
+     }
+@@ -451,12 +452,13 @@
+     cancel = 0;
+     plane[0] = NULL;
+ 
++    n = ilbm.depth;
++    if (ilbm.mask == 1) n++;
++
+     im->data = malloc(im->w * im->h * sizeof(DATA32));
+-    if (im->data) {
+-        n = ilbm.depth;
+-        if (ilbm.mask == 1) n++;
++    plane[0] = malloc(((im->w + 15) / 16) * 2 * n);
++    if (im->data && plane[0]) {
+ 
+-        plane[0] = malloc(((im->w + 15) / 16) * 2 * n);
+         for (i = 1; i < n; i++) plane[i] = plane[i - 1] + ((im->w + 15) / 16) 
* 2;
+ 
+         z = ((im->w + 15) / 16) * 2 * n;
+@@ -495,6 +497,7 @@
+    * the memory for im->data.
+    *----------*/
+     if (!ok) {
++        im->w = im->h = 0;
+         if (im->data) free(im->data);
+         im->data = NULL;
+     }
+diff -uNr imlib2-1.4.0/src/modules/loaders/loader_pnm.c 
imlib2-1.4.0-new/src/modules/loaders/loader_pnm.c
+--- imlib2-1.4.0/src/modules/loaders/loader_pnm.c      2007-04-09 
18:40:40.000000000 -0400
++++ imlib2-1.4.0-new/src/modules/loaders/loader_pnm.c  2007-08-23 
12:28:37.000000000 -0400
+@@ -68,7 +68,7 @@
+              int                 i = 0;
+ 
+              /* read numbers */
+-             while (c != EOF && !isspace(c))
++             while (c != EOF && i+1 < sizeof(buf) && !isspace(c))
+                {
+                   buf[i++] = c;
+                   c = fgetc(f);
+diff -uNr imlib2-1.4.0/src/modules/loaders/loader_tga.c 
imlib2-1.4.0-new/src/modules/loaders/loader_tga.c
+--- imlib2-1.4.0/src/modules/loaders/loader_tga.c      2007-04-09 
18:40:40.000000000 -0400
++++ imlib2-1.4.0-new/src/modules/loaders/loader_tga.c  2007-08-23 
12:44:11.000000000 -0400
+@@ -350,7 +350,9 @@
+                   else
+                      dataptr = im->data + (y * im->w);
+ 
+-                  for (x = 0; x < im->w; x++)   /* for each pixel in the row 
*/
++                  for (x = 0;
++                       x < im->w && bufptr+bpp/8 < bufend;
++                       x++)   /* for each pixel in the row */
+                     {
+                        switch (bpp)
+                          {


-------------------------------------------------------------------------
This SF.net email is sponsored by: Splunk Inc.
Still grepping through log files to find problems?  Stop.
Now Search log events and configuration files using AJAX and a browser.
Download your FREE copy of Splunk now >>  http://get.splunk.com/
_______________________________________________
Fink-commits mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/fink-commits

Reply via email to