about summary refs log tree commit diff
diff options
context:
space:
mode:
authorgiraffedata <giraffedata@9d0c8265-081b-0410-96cb-a4ca84ce46f8>2022-01-25 02:13:08 +0000
committergiraffedata <giraffedata@9d0c8265-081b-0410-96cb-a4ca84ce46f8>2022-01-25 02:13:08 +0000
commitad09f3039be71150e9a27191014acb9f055c4cb4 (patch)
tree5896354a211328926b0a65e6342b0285d28b71f2
parent1518f561b220fc93dbdcaafa26be1ff82501869b (diff)
downloadnetpbm-mirror-ad09f3039be71150e9a27191014acb9f055c4cb4.tar.gz
netpbm-mirror-ad09f3039be71150e9a27191014acb9f055c4cb4.tar.xz
netpbm-mirror-ad09f3039be71150e9a27191014acb9f055c4cb4.zip
Release 10.86.30
git-svn-id: http://svn.code.sf.net/p/netpbm/code/stable@4259 9d0c8265-081b-0410-96cb-a4ca84ce46f8
-rw-r--r--doc/HISTORY7
-rw-r--r--editor/specialty/pgmabel.c11
-rw-r--r--version.mk2
3 files changed, 13 insertions, 7 deletions
diff --git a/doc/HISTORY b/doc/HISTORY
index 750d76ed..4c41843c 100644
--- a/doc/HISTORY
+++ b/doc/HISTORY
@@ -4,6 +4,13 @@ Netpbm.
 CHANGE HISTORY 
 --------------
 
+22.01.25 BJH  Release 10.86.30
+
+              pgmabel: Fix incorrect output.  Always broken.  (Program was
+              new in Netpbm 10.3 (July 2002).
+
+              libnetpbm: Fix version number
+
 22.01.24 BJH  Release 10.86.29
 
               picttoppm:  Fix inability to compile introduced in Netpbm
diff --git a/editor/specialty/pgmabel.c b/editor/specialty/pgmabel.c
index 1a6e481f..0f4233ac 100644
--- a/editor/specialty/pgmabel.c
+++ b/editor/specialty/pgmabel.c
@@ -100,20 +100,19 @@ abel ( float *y, int N, double *adl)
 {
     register int n;
     double *rho, *rhop;       /* results and new index                       */
-    float  *yp;               /* new indizes for the y-array                 */
 
     MALLOCARRAY(rho, N);
     if( !rho )
         pm_error( "out of memory" );
+    for (n=0 ; n<N ; n++)
+        rho[n] = 0;
+
     rhop = rho;
-    yp  = y;
 
     for (n=0 ; n<N ; n++)
     {
-        *(rhop++) = ((*yp++) - Sum(n,rho,N,adl))/(adl[n*N+n]);
-/*    *(rhop++) = ((*yp++) - Sum(n,rho,N))/(dr(n,n+0.5,N));  old version */
-        if ( *rhop < 0.0 ) *rhop = 0.0;         /*  error correction !       */
-/*   if (n > 2) rhop[n-1] = (rho[n-2]+rho[n-1]+rho[n])/3.0;  stabilization*/
+        rhop[n] = MAX(0, (y[n] - Sum(n,rho,N,adl))/(adl[n*N+n]));
+            /* Clip to 0 for error correction !  */
     }
     for (n=0 ; n<N ; n++)
         {
diff --git a/version.mk b/version.mk
index 08e54cbf..c3491542 100644
--- a/version.mk
+++ b/version.mk
@@ -1,3 +1,3 @@
 NETPBM_MAJOR_RELEASE = 10
 NETPBM_MINOR_RELEASE = 86
-NETPBM_POINT_RELEASE = 28
+NETPBM_POINT_RELEASE = 30