SHA256
1
0
forked from pool/netpbm
netpbm/netpbm-10.35.69-pnmtopng-CAN-2005-2978.patch
OBS User autobuild f06553deec Accepting request 25498 from graphics
Copy from graphics/netpbm based on submit request 25498 from user pgajdos

OBS-URL: https://build.opensuse.org/request/show/25498
OBS-URL: https://build.opensuse.org/package/show/openSUSE:Factory/netpbm?expand=0&rev=19
2009-12-04 10:32:11 +00:00

21 lines
560 B
Diff

--- converter/other/pnmtopng.c
+++ converter/other/pnmtopng.c
@@ -521,7 +521,7 @@
unsigned int * const bestMatchP) {
unsigned int paletteIndex;
- unsigned int bestIndex;
+ unsigned int bestIndex = 0;
unsigned int bestMatch;
assert(paletteSize > 0);
@@ -2342,7 +2342,7 @@
/* The color part of the color/alpha palette passed to the PNG
compressor
*/
- unsigned int palette_size;
+ unsigned int palette_size = MAXCOLORS;
gray trans_pnm[MAXCOLORS];
png_byte trans[MAXCOLORS];