about summary refs log tree commit diff
path: root/editor/pamaltsat.c
diff options
context:
space:
mode:
authorgiraffedata <giraffedata@9d0c8265-081b-0410-96cb-a4ca84ce46f8>2018-09-25 03:36:21 +0000
committergiraffedata <giraffedata@9d0c8265-081b-0410-96cb-a4ca84ce46f8>2018-09-25 03:36:21 +0000
commit427b46e80fa203ffbd5e1eba0d360bd5fd1c8dca (patch)
tree33a6e7facbdad3eefedf12ccd771a14de4fc4983 /editor/pamaltsat.c
parentca00385342fb1122965d02e55fff15288138ee40 (diff)
downloadnetpbm-mirror-427b46e80fa203ffbd5e1eba0d360bd5fd1c8dca.tar.gz
netpbm-mirror-427b46e80fa203ffbd5e1eba0d360bd5fd1c8dca.tar.xz
netpbm-mirror-427b46e80fa203ffbd5e1eba0d360bd5fd1c8dca.zip
cleanup, fix comment, fix compiler warning
git-svn-id: http://svn.code.sf.net/p/netpbm/code/trunk@3339 9d0c8265-081b-0410-96cb-a4ca84ce46f8
Diffstat (limited to 'editor/pamaltsat.c')
-rw-r--r--editor/pamaltsat.c7
1 files changed, 4 insertions, 3 deletions
diff --git a/editor/pamaltsat.c b/editor/pamaltsat.c
index 64a099e4..6d9b91e0 100644
--- a/editor/pamaltsat.c
+++ b/editor/pamaltsat.c
@@ -41,7 +41,7 @@ methodFmNm(const char * const methodNm) {
 /*----------------------------------------------------------------------------
    The method of saturation whose name is 'methodNm'
 -----------------------------------------------------------------------------*/
-    uchar  i;
+    uint  i;
     bool found;
     Method method;
 
@@ -56,6 +56,7 @@ methodFmNm(const char * const methodNm) {
         /* Issue error message and abort */
         char * methodList;
         uint   methodListLen;
+        uint   i;
 
         /* Allocate a buffer to store the list of known saturation methods: */
         for (i = 0, methodListLen = 0; i < ARRAY_SIZE(methodTable); ++i)
@@ -65,7 +66,7 @@ methodFmNm(const char * const methodNm) {
 
         if (!methodList)
             pm_error("Failed to allocate memory for %lu saturation "
-                     "method names", ARRAY_SIZE(methodTable));
+                     "method names", (unsigned long)ARRAY_SIZE(methodTable));
 
         /* Fill the list of methods: */
         for (i = 0, methodList[0] = '\0'; i < ARRAY_SIZE(methodTable); ++i) {
@@ -409,7 +410,7 @@ saturateSpectrum(LinSampleInfo * const siP,
         /* To satisfy both constraints, choose the strictest: */
         double const km = km1 > km2 ? km2 : km1;
 
-        /* Ensure the saturation factor does exceed the maximum
+        /* Ensure the saturation factor does not exceed the maximum
            possible value:
         */
         k = sat < km ? sat : km;