cd109a3c3a
- bmptopnm: Don't crash on invalid zero value of image height in the BMP header of a compressed file. Always broken. - bmptopnm: don't crash on large invalid value of 'colorsused' in the BMP header. - ilbmtoppm: Don't crash on image that has a transparent color index, but no color map. "pkgsrc" changes: - Add a lot of patches written by Thomas Klausner and me to make this compile with PNG 1.5.
19 lines
678 B
Text
19 lines
678 B
Text
$NetBSD: patch-al,v 1.5 2011/01/15 18:37:46 tron Exp $
|
|
|
|
Fix build with png-1.5.
|
|
|
|
--- converter/other/pamrgbatopng.c.orig 2006-08-19 04:12:28.000000000 +0100
|
|
+++ converter/other/pamrgbatopng.c 2011-01-15 18:24:36.000000000 +0000
|
|
@@ -101,10 +101,8 @@
|
|
if (!infoP)
|
|
pm_error("Could not allocate PNG info structure");
|
|
else {
|
|
- infoP->width = pamP->width;
|
|
- infoP->height = pamP->height;
|
|
- infoP->bit_depth = 8;
|
|
- infoP->color_type = PNG_COLOR_TYPE_RGB_ALPHA;
|
|
+ png_set_IHDR(pngP, infoP, pamP->width, pamP->height,
|
|
+ 8, PNG_COLOR_TYPE_RGB_ALPHA, 0, 0, 0);
|
|
|
|
png_init_io(pngP, ofP);
|
|
|