File netpbm-10.26.44-pnmtopng-overflow.patch of Package netpbm

--- converter/other/pnmtopng.c
+++ converter/other/pnmtopng.c
@@ -919,9 +919,9 @@
     colorhist_vector chv;
     unsigned int colors;
 
-    gray *alphas_of_color[MAXPALETTEENTRIES];
+    gray *alphas_of_color[MAXPALETTEENTRIES + 1];
     unsigned int alphas_first_index[MAXPALETTEENTRIES];
-    unsigned int alphas_of_color_cnt[MAXPALETTEENTRIES];
+    unsigned int alphas_of_color_cnt[MAXPALETTEENTRIES + 1];
  
     getChv(ifP, imagepos, cols, rows, maxval, format, MAXCOLORS, 
            &chv, &colors);
openSUSE Build Service is sponsored by