From a5fd4f7b5501df5ae1f692509617fb0c6a736b0e Mon Sep 17 00:00:00 2001 From: giraffedata Date: Tue, 25 Feb 2014 03:11:59 +0000 Subject: Fix buffer overrun git-svn-id: http://svn.code.sf.net/p/netpbm/code/trunk@2138 9d0c8265-081b-0410-96cb-a4ca84ce46f8 --- analyzer/pgmtexture.c | 2 +- doc/HISTORY | 3 +++ 2 files changed, 4 insertions(+), 1 deletion(-) diff --git a/analyzer/pgmtexture.c b/analyzer/pgmtexture.c index d14ba547..07317336 100644 --- a/analyzer/pgmtexture.c +++ b/analyzer/pgmtexture.c @@ -928,7 +928,7 @@ main (int argc, const char ** argv) { FILE * ifP; gray ** grays; - unsigned int tone[PGM_MAXMAXVAL]; + unsigned int tone[PGM_MAXMAXVAL+1]; unsigned int r0, r45, r90; unsigned int d; unsigned int x, y; diff --git a/doc/HISTORY b/doc/HISTORY index fe27396a..82708142 100644 --- a/doc/HISTORY +++ b/doc/HISTORY @@ -28,6 +28,9 @@ not yet BJH Release 10.66.00 ppmrelief: fix crash when input image is too small. Always broken. Thanks Prophet of the Way . + pgmtexture: fix buffer overflow. Always broken. (Program + was added in primordial Netpbm in 1991). + pamdeinterlace: fix incorrect output with -takeodd and image has only one row. Always broken (pamdeinterlace was introduced in Netpbm 9.21 (January 2001)). Thanks Prophet of the Way -- cgit 1.4.1